Code Monkey home page Code Monkey logo

ece699's Introduction

ECE699

Downloading Code for First Time

You may need to set up an ssh certificate for git.

https://docs.github.com/en/authentication/connecting-to-github-with-ssh/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent

How to run

  1. Make the file using make
  2. Get the output using ./output
  3. If needed, clear the object files (*.o) using make clean

How to run different examples

There are three different examples for you to choose:

  1. Very simple integer BP: example_fc_int_bp_very_simple()
  2. Fully connected (fc) mnist integer BP: example_fc_int_bp_mnist()
  3. Fully connected (fc) mnist integer DFA: example_fc_int_dfa_mnist()
  4. Fully connected (fc) fashion mnist integer DFA: example_fc_int_dfa_fashion_mnist()

You can comment out the current function and call the new function in the main.cpp file

TODO

  1. For mnist dataset training,use classification loss function batchCrossEntropyLoss() and test the accuracy

Debug

  1. Error: output: pktnn_mat.cpp:566: pktnn::pktmat& pktnn::pktmat::matElemDivMat(pktnn::pktmat&, pktnn::pktmat&): Assertion `mat1.dimsEqual(mat2)' failed

    Cause: backward() --> computeDeltas() --> matElemDivMat()

  2. Training Accuracy low, for example 9.8% Cause: useDfa(false)

  3. Training Accuracy 100%, maybe not correct either Try to modify the layer setting to match with BP_simple_training

    //Modified the fc layers to do BP training
    fc1.useDfa(false).initWeightBias().setActv(a).setNextLayer(fc2);         //Use BP for training, set useDfa(false)
    fc2.useDfa(false).initWeightBias().setActv(a).setPrevLayer(fc1).setNextLayer(fcLast);
    fcLast.useDfa(false).setActv(b).setPrevLayer(fc2);
    

Reference

  1. Neural Networks and Deep Learning - Michael Nielsen http://neuralnetworksanddeeplearning.com/
  2. Different activation functions and initialization functions https://shahaab-co.com/mag/en-articles/weight-initialization-in-deep-learning/

To be continued...

ece699's People

Contributors

joshmeiyb avatar

Stargazers

 avatar

Watchers

 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.