Giter Site home page Giter Site logo

sudl's Introduction

SUDL

A light deep learning tools box by c++

Contains

Network Architecture

  1. Convolutional Neural Network
  2. Normal Neural Network
  3. Reccurent Neural Network with three mainstream varieties(LSTM, LSTM-peelhole, GRU)(deep arcitecture supported)
  4. bi-directional LSTM & GRU & RNN(deep arcitecture supported)

Nonlinearities

  1. ReLU
  2. Sigmoid
  3. tanh

Usage

  1. ANN

layers.push_back(new FullConnLayer(4, 8));
layers.push_back(new ReluLayer());
layers.push_back(new FullConnLayer(8, 32));
layers.push_back(new SigmoidLayer());
layers.push_back(new FullConnLayer(32, 3));
layers.push_back(new SigmoidLayer());
ANN<MeanSquareLossLayer> *ann = new ANN<MeanSquareLossLayer>();
ann->build_ann(layers);
ann->load_data(argv[1]);
ann->train();

  1. CNN

std::vector<Layer*> layers;
layers.push_back(new ConvLayer(1, 6, 5, 5, 24, 24));
layers.push_back(new SigmoidLayer());
layers.push_back(new PoolingLayer(6, 6, 2, 2, 12, 12));
layers.push_back(new ConvLayer(6, 6, 5, 5, 8, 8));
layers.push_back(new SigmoidLayer());
layers.push_back(new PoolingLayer(6, 6, 2, 2, 4, 4));
layers.push_back(new ConvLayer(6, 10, 2, 2, 3, 3));
layers.push_back(new SigmoidLayer());
layers.push_back(new FlatternLayer());
layers.push_back(new FullConnLayer(90, 32));
layers.push_back(new SigmoidLayer());
layers.push_back(new FullConnLayer(32, 4));
layers.push_back(new SigmoidLayer());
CNN<MeanSquareLossLayer> *cnn = new CNN<MeanSquareLossLayer>();
cnn->build_cnn(layers);
cnn->load_data(argv[1]);
cnn->train();

  1. RNN

3.1 singel layer

std::vector<Layer*> layers;
layers.push_back(new WordEmbeddingLayer(14));
layers.push_back(new RnnCell(8, 16));
layers.push_back(new SeqFullConnLayer(16, 4));
layers.push_back(new SeqActiveLayer());
ReccurentNet *rnet = new ReccurentNet(4);
rnet->_build_rnn(layers);

3.2 multi layers

std::vector<Layer*> layers;
layers.push_back(new WordEmbeddingLayer(14));
layers.push_back(new RnnCell(8, 8));
layers.push_back(new RnnCell(8, 16));
layers.push_back(new SeqFullConnLayer(16, 4));
layers.push_back(new SeqActiveLayer());
ReccurentNet *rnet = new ReccurentNet(4);
rnet->_build_rnn(layers);

std::vector<Layer*> layers;
layers.push_back(new WordEmbeddingLayer(14));
layers.push_back(new LstmCell(8, 8));
layers.push_back(new LstmCell(8, 16));
layers.push_back(new SeqFullConnLayer(16, 4));
layers.push_back(new SeqActiveLayer());
ReccurentNet *rnet = new ReccurentNet(4);
rnet->_build_rnn(layers);

3.3 different layers

std::vector<Layer*> layers;
layers.push_back(new WordEmbeddingLayer(14));
layers.push_back(new RnnCell(8, 8));
layers.push_back(new LstmCell(8, 16));
layers.push_back(new SeqFullConnLayer(16, 4));
layers.push_back(new SeqActiveLayer());
ReccurentNet *rnet = new ReccurentNet(4);
rnet->_build_rnn(layers);

sudl's People

Contributors

kymo avatar

Watchers

James Cloos avatar kxgwan 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.