Archive for July, 2017

Install TensorFlow using Anaconda

July 17, 2017 Leave a comment

If you search online, there will be so many posts on how to install TensorFlow on mac, some are older ones, some are new, hard to decide which one to follow. Let’s just make the flow easier so we can focus on the core part to explore the deep learning.

Please note that starting v1.2 TensorFlow no longer support GPU on mac-os, so in the followings, we will just install the CPU version. It’s good to start with something simple. There are two ways of install it under Anaconda.

Use ‘conda’ command which can be quite straight forward.

# Python 2.7
$ conda create -n tensorflow python=2.7

$ source activate tensorflow
(tensorflow)$  # Your prompt should change

# Use 'conda' command: Linux/Mac OS X, Python 2.7/3.4/3.5, CPU only:
(tensorflow)$ conda install -c conda-forge tensorflow

Screen Shot 2017-07-17 at 4.26.00 PM

or use the pip command

(tensorflow)$ pip install --ignore-installed --upgrade \



You can follow up to install keras and ipython within the env:

# note this will downgrade tensor flow to 1.0

conda install -c conda-forge keras=2.0.2

conda install ipython


Categories: Deep learning, MacOS