Giter Site home page Giter Site logo

nnet's Introduction

NNET - Neural Networks in Go Build Status

NNET is a small collection of neural network algorithms written in the pure Go language.

Packages

  • rbm - Binary-Binary Restricted Boltzmann Machines (RBMs)
  • gbrbm - Gaussian-Binary RBMs
  • mlp - Multi-Layer Perceptron (Feed Forward Neural Networks)
  • mlp3 - Three-Layer Perceptron
  • dbn - Deep Belief Nets (in develop stage)

Install

go get github.com/r9y9/nnet

Examples

Binary-Binary Restricted Bolztmann Machines on MNIST

cd examples/rbm
go run rbm_mnist.go -h # for help
go run rbm_mnist.go -epoch=5 -hidden_units=400 -learning_rate=0.1 -order=1 -output="rbm.json" -persistent -size=20

It took 32 minutes to train RBM on my macbook air at 07/28/2014.

Weight visualization

python visualize.py rbm.json

image

Multi-layer Perceptron

Training

cd examples/mlp3
go run mlp3_mnist.go -epoch=500000 -hidden_units=100 -learning_rate=0.1 -o="nn.json"

It took 10 minutes to train MLP on my macbook air at 07/30/2014.

Classification

go run mlp3_mnist.go -test -m=nn.json
...
Acc. 0.971000 (9710/10000)

TODO

  • Use linear algebra library such as gonum/matrix or go.matrix
  • GPU powered training
  • Refactor (write more idiomatic codes, speedup, etc.)
  • Tests for all packages
  • More flexibility like pylearn2

License

MIT

nnet's People

Contributors

r9y9 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.