GithubHelp home page GithubHelp logo

mlp's Introduction

Connect to the server via ssh

Given the account information as below,

Id Name Username Password IP Port-22 Port-6006 Port-8888
0 Alice alice password 166.111.69.245 22000 23000 24000

ssh to the server with

ssh -p 22000 [email protected]

For Mac / Linux, you can use terminal. For Windows, you can use MobaXterm

Jupyter

Jupyter notebook is recommented to used in this homework.

If you are not familar with Jupyter notebook, see Jupyter notebook basics.

Run the jupyter notebook on the server,

git clone https://github.com/wujian752/MLP
cd MLP
jupyter notebook --ip 0.0.0.0

Jupyter would return you a url like

http://0.0.0.0:8888/?token=70f9d9457fec7045f5f991ad9d896060122b13d60cafbbc0

Replace the 0.0.0.0 with 166.111.69.245 and the port 8888 with 24000.

Then copy/paste this URL into your browser.

What are these files ?

Jupyter notebook files
Problem.ipynb: build and train your model in this notebook.

Demo.ipynb: a demo of this framework in which a MLP is built with builtin FCLayer, ReLULayer.
Python files
layers/
    - fc_layer.py: implement the forward and backward of fully connected layer in this file.
    - sigmoid_layer.py: implement the forward and backward of ReLU layer in this file.
    - relu_layer.py: implement the forward and backward of Sigmoid layer in this file.
    - __init__.py: mark layers/ as Python package directory.

criterion/
    - softmax_cross_entropy.py: the softmax cross entropy criterion.
    - __init__.py: mark criterion/ as Python package directory.

builtin/
    - Some pyc files that can be executed.

MNIST_data/
    - the directory in which MNIST dataset is stored.

network.py: the class network is defined here.

optimizer.py: the SGD is defined here and you need to implement the SGD with momentum in this file.

solver.py: the train function and test function are defined here.

You can train a MLP in the Demo.ipynb with the builtin layers.

And after you implement your FCLayer, SigmoidLayer and ReLULayer in layers, you can set use_builtin to False and run the program again to test your implementation.

Then, build and train the SigmoidMLP and ReLUMLP in Problem.ipynb.

Finally, implement SGDwithMomentum in optimizer.py and train ReLUMLP_momentum with SGDwithMomentum in Problem.ipynb.

mlp's People

Contributors

wujian752 avatar

Watchers

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