Giter VIP home page Giter VIP logo

convolutional-neural-networks-from-scratch's Introduction

Convolutional-Neural-Networks-from-Scratch

Python Library for creating and training CNNs. Implemented from scratch.

This repo contains a project i did during my second year in college. I wanted to have a deeper understanding of how gradients were calculated and backpropagated through the Network and I felt like if I could implement backprop of a Convolutional Nerual Net that would help me immensely.

The project can be divided into 3 parts:

  • Optimizers.py
  • ConvNetModule.py
  • Layers.py


Optimizers.py

Contains four Algorithms for optimization

  • SGD
  • Adam
  • Momentum
  • RMSProp

ConvNetModule.py

Controls the training process, interacts with the layers and sends the gradients to the optimizers.


Layers.py

The hardest part to implement. Contains forward and backward operations for all the layers.


Additional Libraries used: Numpy(matrix operations), tqdm(appearance) and Matplotlib(plotting).


There are still some things that need work and can be found here.

For help with understanding the Backward operation of Convolutions:
https://github.com/JeyrajK/convolutional-neural-networks/blob/master/Back%20propagation%20of%20cnn.ipynb
https://towardsdatascience.com/forward-and-backward-propagations-for-2d-convolutional-layers-ed970f8bf602
https://cs231n.github.io/
https://www.jefkine.com/general/2016/09/05/backpropagation-in-convolutional-neural-networks/
https://towardsdatascience.com/backpropagation-in-a-convolutional-layer-24c8d64d8509

convolutional-neural-networks-from-scratch's People

Contributors

cabbagito avatar

Stargazers

 avatar

Watchers

 avatar

convolutional-neural-networks-from-scratch's Issues

Vectorize Convolution Operations

The Convolution operation has been implemented naively using for loops, this is very inefficient and should be implemented in a vectorized form.

Fix Validation Procedure

During training the entire Validation Dataset is being shuffled and then the first couple of Data points are being chosen,
This is stupid.
The Validation Dataset should be shuffled beforehand and then random indices should be chosen.

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.