Logo

Register Now

View My GitHub Profile

Environment setup

Requirements

Please install the following software:

Warning: You may need a few Gb of space in your hard drive (10Gb should be enough) to accommodate software and data so please make sure you have some room before continuing!

Also, you will need to create a github.com user if you don’t have one. You may want to setup SSH key based authentication for github for convenience.

Conda environment setup

(This step is to be run after you have installed the Miniconda software from the previous section)

In order to manage the different packages we will use during the course, we will create a conda environment from the provided configuration file:

wget https://mlinproduction.github.io/env_setup/env_setup.tar
tar -xvf env_setup.tar
conda env create -f ml_in_prod_env.yml 

Whenever we want to run any piece of code, we just need to make sure that this environment is active:

conda activate ml_in_prod

If you need to install additional packages, please remember to make sure that your conda environment is activated prior to running conda install or pip install. This will ensure that the packages are installed in the ml_in_prod environment instead of your base environment or your system’s python libraries.

Tip: If you install additional packages and would like to export the configuration so that you can create an environment from it, you can run conda env export > ml_in_prod_env.yml

Jupyter notebook setup

In order to set up a Jupyter Notebook kernel under the ml_in_prod environment please run:

conda activate ml_in_prod
ipython kernel install --user --name="ml_in_prod"

Testing your environment

Please run the following environment testing script, which tests whether the main libraries and tools can be imported correctly.

Note: One of the tests will ask for your password. It’s expected!

# In the same folder where you ran the steps for `Conda environment setup`
conda activate ml_in_prod
python env_test/env_test.py