Skip to content

Latest commit

 

History

History
116 lines (66 loc) · 3.88 KB

README.md

File metadata and controls

116 lines (66 loc) · 3.88 KB

Neural_Net_Newbies

Repository of machine learning python packages' code examples to build, train and run a neural net on MNIST data. A small code sample is used in my PyCon 2015 presentation and the rest is for reference afterwards under lib/slide_code.py.

The MNIST Dataset is the "hello world" of neural nets, and the link is the original source about the dataset.

Note: All examples assume supervised learning.

Theano

The MNIST example in this repo is based off this link with modifications.

  • Data is located at this link.
  • Additional tutorial at this link.

Run code from command line:

  python lib/theano_mnist.py

Setup:

  pip install theano

General Reference for more information about the package.

Graphlab/Dato:

MNIST sample tutorial can be found at this link. This machine learning library is built off of CXXNet.

Run code from command line:

  python lib/graphlab_mnist.py

Setup:

  pip install graphlab-create 
  • Add product key to environment variable or config file

General Reference for more information about the package.

OpenDeep

The MNIST example in this repo is based off this link. This deep learning library is built off of Theano.

Run from command line:

  python lib/opendeep_mnist.py

Setup:

General Reference for more information about the package.

Lasagne

The MNIST example in this repo is based off this link with modifications. This machine learning library is built off of Theano.

Run from command line:

  python lib/lasagne_mnist.py

Setup:

General Reference for more information about the package.

PyLearn2

MNIST example in this repo is based off this link with modifications. Built off of Theano and requires a yaml file to config neural net structure and optimization method.

Run from command line:

     python lib/pylearn2_mnist.py

Setup:

    git clone git://github.com/lisa-lab/pylearn2.git
    
    cd pylearn2 && python setup.py develop

    OR 

    cd pylearn2 && python setup.py develop --user

General Reference for more information.

Scikit-Learn

MNIST example in this repo is based off this link with modifications. This library uses an RBM model and they are combining the RBM with Logistict Regression to create the model that runs predictions.

Run from command line:

  python sklearn_mnist.py

Setup:

pip install -U numpy scipy scikit-learn

General Reference for more information.

Other:

Most setup references assume python and pip installed. Check documentation for other options especially if setting up on GPUs.

If you want to add to this repo, send me a PR.