-
Notifications
You must be signed in to change notification settings - Fork 0
Project Initial Setup
- Open bash or zsh terminal
- Use
terminal
(zsh) if you are using MacOS - Use
terminal
(bash) if you are using Linux - Use
git bash
(bash) if you are using Windows
- Use
- Use
cd <path>
to move to the desired directory where you want to set up the project - Run
git clone https://github.com/fedele7008/MNIST_DNN.git
to clone the project into your local computer - Use
cd MNIST_DNN
to move into the project directory - Run
source env_setup.sh
to set up the development environment - you may use specific python version to setup usingsource env_setup.sh --python-version <python>
. Otherwise, the script will automatically try to detect valid python (It may take 5 - 10 minutes to set up for the first time)
For example, if you use python 3.9 when running
python3
, runsource env_setup.sh --python-version python3
to use python 3.9 for setup. For more information about env_setup.sh, trysource env_setup --help
You should run source env_setup.sh
every time you start working on the project
After you complete the source env_setup.sh
, it will provide useful tools to work on our project.
These tools are only provided after running source env_setup.sh
; you should run this script whenever you open a new shell terminal.
If you want to skip running the script, add the script into your shell profile depending on your environment (not recommended - this may confuse if you have multiple clones of this project)
The setup contents are saved in a folder named dev/
- this folder is included in the .gitignore
list by default, it should not be uploaded to GitHub by any chance.
There are three virtual python environments:
You would probably never use publish-venv
manually. It is used for upload.sh
script to deploy the package production to PyPI.
This virtual environment is used for mnist_dnn package.
- If you would like to turn this environment on, use
enter dnn
orenter d
- If you would like to turn this environment off, use
enter off
orenter o
orenter
- To move into the package location, use
dnn
You should turn on the environment before developing mnist_dnn package
This virtual environment is used for mnist_dnn_api package.
- If you would like to turn this environment on, use
enter api
orenter a
- If you would like to turn this environment off, use
enter off
orenter o
orenter
- To move into the package location, use
api
You should turn on the environment before developing mnist_dnn_api package
Please use enter off
or enter o
or enter
to turn off the environment rather than deactivating manually using deactivate
- this may cause an error in further use of tools
If you installed a new library in pip, use update_package dnn
or update_package api
to update requirements.txt
in the selected package.
If you want to move to your MNIST_DNN project root directory, use root
.
- Run
cd <path-to-project-root>
- Run
source env_setup.sh
- Run
enter dnn
- Run
python -m mnist_dnn
to run__main__.py
of mnist_dnn package