Run microsoft/cntk on MacOS | Microsoft: DAT236x

Thu Sep 13 2018

During the edX Microsoft: DAT236x on Deep Learning Explained I came across an issue where I couldn’t run Microsoft Cognitive Toolkit on a Mac natively. Looks like there is a docker container that can help us do that.

So the steps to run the library are the following:

    1. Install docker and pull the microsoft/cntk image
      docker pull microsoft/cntk:2.0-cpu-python3.5
    2. Download the course material to a folder named “course” or any other folder you like
    3. Then from your terminal run
      docker run -d -p 8888:8888 --name cntk_container1 -ti -v THE_PATH_TO_THE_COURSE_DIR/course:/course microsoft/cntk bash

      This will load the container.

    4. From a new terminal window run
      docker exec -it cntk_container1 bash -c "source /cntk/activate-cntk && jupyter-notebook --no-browser --port=8888 --ip= --notebook-dir=/course --allow-root"

And now you are running jupyter with the necessary libraries. When you visit you can run all of the course’s material.

Full Stack Weekly Newsletter

A free weekly newsletter for full stack web developers!