diff --git a/README.md b/README.md index 08a0525..6f1301a 100644 --- a/README.md +++ b/README.md @@ -18,9 +18,32 @@ This approach is recommended if you prefer the smallest download. If you experie * [How-to install the RC using pip.](setup/install-pip.md) -### Want to report a bug? +--- +If you get stuck, please refer to the full installation [instructions](https://www.tensorflow.org/install/) on tensorflow.org. + +# Install other Dependencies + +* **For Linux only**, run: `$ sudo install_dependencies.sh --python_version (2 or 3)`, python_version is an optional argument the script will install the dependencies for both versions of Python 2 and 3 if not explictly defined. For more details check [install_dependices.sh](install_dependencies.sh). + + Or Install dependencies manyally: + * `python2 -m pip install jupyter numpy pandas matplotlib pillow` + * `python3 -m pip install jupyter numpy pandas matplotlib pillow` + +For other OS check the next section. + +**If you are not familiar with [Jupyter notebooks](http://jupyter.readthedocs.io/en/latest/index.html) is recommened to visit the website and learn more about it.** + +## Test if everything is working properly + +1. Clone this repo or download it +2. $ cd tensorflow-workshop +3. $ jupyter notebook +4. run test_install.ipynb +5. If you see any errors with the libraries, make sure you have them installed and run test_install.ipynb again. + +# Want to report a bug? Thanks! Can you please file an issue, or even better, a pull request? We'll be doing this workshop a couple times, and future developers will appreciate your help. - - - -General disclaimer, this is my personal repo and not an official Google product. If you'd like to use this code, say, to build a mission critical component of your giant space laser, you should know there's no warranty, etc. \ No newline at end of file +General disclaimer, this is my personal repo and not an official Google product. If you'd like to use this code, say, to build a mission critical component of your giant space laser, you should know there's no warranty, etc. diff --git a/install_dependencies.sh b/install_dependencies.sh new file mode 100644 index 0000000..ba13249 --- /dev/null +++ b/install_dependencies.sh @@ -0,0 +1,45 @@ +#!/bin/bash + +PYTHON_VERSION="2 and 3" + +function p2 { + apt-get install python-pip + python2 -m pip install --upgrade pip + python2 -m pip install jupyter numpy pandas matplotlib pillow +} + +function p3 { + apt-get install python3-pip + python3 -m pip install --upgrade pip + python3 -m pip install jupyter numpy pandas matplotlib pillow +} + +while [[ $# -gt 1 ]] +do + key="$1" + + case $key in + --python_version) + PYTHON_VERSION="$2" + shift # past argument + ;; + *) + # unknown option + ;; + esac + + shift # past argument or value +done + +echo PYTHON_VERSION = "${PYTHON_VERSION}" + +if [ "${PYTHON_VERSION}" == "2 and 3" ]; then + p2 + p3 +elif [ "${PYTHON_VERSION}" == "2" ]; then + p2 +elif [ "${PYTHON_VERSION}" == "3" ]; then + p3 +else + echo 'bad argument' +fi