rnn

command module
v0.0.0-...-be65bb2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 1, 2016 License: MIT Imports: 4 Imported by: 0

README

rnn

Source code for a series of posts about recurrent neural networks. (It's in Russian though, beware.)

You'll need to install the linear algebra library for Go:

$ go get github.com/gonum/matrix/mat64

You can execute any of the examples in the blog like this:

$ go run main.go [--basicNN | --Elman | --Jordan | --LSTM]

For example, you can train an Elman network:

$ go run main.go --Elman
====================================================
Testing basic Vanilla RNN on sample series dataset:
====================================================
Epoch:  0
_________________________________________________________________
Input:  1  .  .  .  Expected:  .  1  .  .  Predicted:  1  .  .  1
Input:  .  1  .  .  Expected:  .  .  1  .  Predicted:  1  .  .  1
Input:  .  .  1  .  Expected:  .  .  .  1  Predicted:  1  .  .  1
Input:  .  .  .  1  Expected:  .  .  1  .  Predicted:  1  .  .  1
Input:  .  .  1  .  Expected:  .  1  .  .  Predicted:  1  .  .  1
Input:  .  1  .  .  Expected:  1  .  .  .  Predicted:  1  .  .  1

Epoch:  1000
_________________________________________________________________
Input:  1  .  .  .  Expected:  .  1  .  .  Predicted:  .  1  .  .
Input:  .  1  .  .  Expected:  .  .  1  .  Predicted:  .  .  .  .
Input:  .  .  1  .  Expected:  .  .  .  1  Predicted:  .  1  .  .
Input:  .  .  .  1  Expected:  .  .  1  .  Predicted:  .  .  1  .
Input:  .  .  1  .  Expected:  .  1  .  .  Predicted:  .  1  .  .
Input:  .  1  .  .  Expected:  1  .  .  .  Predicted:  .  .  1  .

Epoch:  2000
_________________________________________________________________
Input:  1  .  .  .  Expected:  .  1  .  .  Predicted:  .  1  .  .
Input:  .  1  .  .  Expected:  .  .  1  .  Predicted:  .  .  1  .
Input:  .  .  1  .  Expected:  .  .  .  1  Predicted:  .  1  .  .
Input:  .  .  .  1  Expected:  .  .  1  .  Predicted:  .  .  1  .
Input:  .  .  1  .  Expected:  .  1  .  .  Predicted:  .  1  .  .
Input:  .  1  .  .  Expected:  1  .  .  .  Predicted:  .  .  1  .

Epoch:  3000
_________________________________________________________________
Input:  1  .  .  .  Expected:  .  1  .  .  Predicted:  .  1  .  .
Input:  .  1  .  .  Expected:  .  .  1  .  Predicted:  .  .  1  .
Input:  .  .  1  .  Expected:  .  .  .  1  Predicted:  .  .  .  .
Input:  .  .  .  1  Expected:  .  .  1  .  Predicted:  .  .  1  .
Input:  .  .  1  .  Expected:  .  1  .  .  Predicted:  .  1  .  .
Input:  .  1  .  .  Expected:  1  .  .  .  Predicted:  .  .  1  .

Epoch:  4000
_________________________________________________________________
Input:  1  .  .  .  Expected:  .  1  .  .  Predicted:  .  1  .  .
Input:  .  1  .  .  Expected:  .  .  1  .  Predicted:  .  .  1  .
Input:  .  .  1  .  Expected:  .  .  .  1  Predicted:  .  .  .  1
Input:  .  .  .  1  Expected:  .  .  1  .  Predicted:  .  .  1  .
Input:  .  .  1  .  Expected:  .  1  .  .  Predicted:  .  1  .  .
Input:  .  1  .  .  Expected:  1  .  .  .  Predicted:  1  .  .  .

This repository also contains source code for RNNs implemented in Python using the awesome Tensorflow library. You'll need to install tensorflow to run those sources.

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
go

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL