Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add installation script #2

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,14 @@ Note: In Tensorflow 1.5 it is a known issue of TensorBoard not launching properl
python -m tensorboard.main --logdir=mnist_TB_logs
```

### Installation and running (with bash)

To install all the dependencies and execute all supposed
routines run the following:
```
sh install_and_run.sh
```

## Built With

* [TensorFlow](https://www.tensorflow.org/) - Framework version 1.2.1 used
Expand Down
25 changes: 25 additions & 0 deletions install_and_run.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Install modules for virtual environments
# if they aren't installed now

command -v mkvirtualenv >/dev/null 2>&1 || {
sudo pip3 install virtualenv virtualenvwrapper
echo'export WORKON_HOME=$HOME/.virtualenvs
export VIRTUALENVWRAPPER_PYTHON=/usr/bin/python3
source /usr/local/bin/virtualenvwrapper.sh' >> ~/.bashrc
}

# Make virtual environment
# with required version of TF

mkvirtualenv tf-1 -p python3
sudo pip install tensorflow==1.15

# Run main scripts

python CNN_TB_MNIST_Example.py
tensorboard --logdir mnist_TB_logs

# deactivate the virtual environments

deactivate