Running NuPIC on Windows

NuPIC on Windows

This initiative is a work in progress!


Out of the box, pip install nupic won’t work on windows, since nupic is 64 bit only, you need to have 64 bit python installed along with a 64bit compiler toolchain. Specifically VS2008 since that’s what python2 is built with.

Visual C++ Compiler for Python 2.7

On method is to install the single package called Microsoft Visual C++ Compiler for Python 2.7. This package installs into %HOME%\AppData\Local\Programs\Common\Microsoft\Visual C++ for Python\9.0 directory and links into a Python 2.7.9+ x86-64 MSI install. This requires Python package setuptools>=6.0, see Building instructions below for how to upgrade that package using pip.

Visual C++ 2008 Express Edition and Windows 2008 SDK

Alternatively you can get VS2008 from here: . When you install, just install “Visual C++ 2008 Express Edition”. The 64bit windows toolchain is included with VS2008 Professional Edition and above (so if you have the Express edition, you won’t have access). Luckily, you can get the tools through the Windows 2008 SDK available here: .

When you install it, you should have these options selected:

Python Dependencies

Pre-built Python dependencies can be downloaded from Make sure to download cp27 win_amd64 wheel files. Python pip can be used to install these wheel packages.


From command prompt -

For the VC++ Compiler for Python 2.7 package install:

pip install setuptools --upgrade
pip install nupic

For the VS2008 package install:

"C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\bin\vcvarsx86_amd64.bat"
pip install nupic

Example installation steps

  1. Download and install Windows Python 2.7.11 x86-64 MSI installer into C:\Python27-x64\ (
  2. Download and install Microsoft Visual C++ Compiler for Python 2.7 (
  3. Download and install MySQL for Windows (

From a cmd prompt;

  1. Run echo %PATH% to make sure C:\Python27-x64\Scripts\;C:\Python27-x64\ in there
  2. Run pip install nupic Note: NumPy can take a long time to install
  3. Run pip list to make sure nupic install and is listed
  4. Run python -c "from nupic.bindings.math import Random; print Random().getUInt64();" to see if nupic.bindings work
  5. Run python, then import nupic, and finally exit() to check nupic install

MySQL setup for NuPIC;

  1. Copy to C:\Python27-x64\Lib\site-packages\nupic\support directory
  2. Rename this copied file to nupic-site.xml
  3. Use a text editor (e.g. notepad) to edit the nupic-site.xml file
  4. Update the <value> field for nupic.cluster.database.passwd (and other nupic.cluster.database entries, if required)


  1. Download and pip install wheel files from Christoph Gohlke’s website, cp27 amd64 versions (
  2. Git clone nupic.core (includes Python SWIG bindings)
  3. Git clone nupic (includes tests and examples)