Giter Club home page Giter Club logo

simpleneuralnet's Introduction

Using a Neural Network as a parity bit checking system - Dec 2nd, 2021
Brock University COSC3P71

-------------------------------------------------------------------------------
                                  Numpy
-------------------------------------------------------------------------------

This project is built with the help of numpy, so if you don't 
already have it installed you can install it using the pip installer.  

Type "pip3 install numpy" or "pip install numpy"

-------------------------------------------------------------------------------
                           Execution Instructions
-------------------------------------------------------------------------------

To run:

1. Navigate to the assignment folder in your terminal
2. Type the command "python3 main.py" or "python main.py"

If numpy isn't found by your terminal, what worked for me (on linux) was the command

"/bin/python3 main.py"

-------------------------------------------------------------------------------
                          Changing Parameters
-------------------------------------------------------------------------------

All of the neural net related parameters can be changed in the main method.

The layer sizes can be changed with the layer_sizes tuple 
(Note: the third value, the output layer size, must be 1)

The training_examples variable is a list of decimal integers to be converted 
into binary and used to generate inputs and expected ouputs to the network during training. 

The testing_examples is the same thing, but for testing.

The epochs and learning rate are pretty self-explanatory.

-------------------------------------------------------------------------------
                                   Note
------------------------------------------------------------------------------
Although the network was able to memorize training examples with 100% accuracy, I 
wasn't able to get it to generalize to work on new examples (testing_data). I'm not really sure why. 
I believe my backpropagation algorithm is working well, since the mean squared error goes 
down epoch-to-epoch.  I've tried multiple things to prevent overfitting, nothing seemed 
to work though.  Anyways, the general idea is there and it does kind of work.

simpleneuralnet's People

Contributors

raykeating 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.