Skip to content

riddhiroy/Digit-Recogniser

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Digit-Recogniser

An application that uses Convolutional Neural Networks to recognize handwritten digits.

Done in Python using Keras with Tensorflow Backend Technologies used (python libraries used):

  • Pygame
  • Opencv
  • Pandas
  • Keras
  • Tensorflow/theano
  • Numpy
  • Matplotlib
  • Scipy

By clicking on the launchapp.py file, the pygame user interface gets opened which allows you to draw a number on the left half of the screen. Start drawing by the mouse left click and release the button when drawing is complete. Right-click to refresh the screen.

I have used Keras with Tensorflow backend to train my machine learning model.
Model Specifications:

  1. It is a sequential model.
  2. The neural network created by adding layers to this model is Convolutional Neural Network.
  3. The model training is done using the MNSIT dataset for digit classification provided in the Keras library.
  4. The layers of my model are:
    1. Convolutional Layer 1 : Conv2D, 32 filters, kernel size- 3X3, activation function- ReLU
    2. Convolutional Layer 2 : Conv2D, 64 filters, kernel size- 3X3, activation function- ReLU
    3. Maxpooling Layer 1: MaxPool2D, pool sixe- 2X2
    4. Dropout layer 1
    5. Flatten layer
    6. Dense Layer 1: activation function- ReLU
    7. Dropout layer 2
    8. Dense layer 2 (Output layer) : activation function- softmax
  5. Training was done over the 60,000 image+image-label training data for 10 epochs.
  6. The trained CNN model is stored in the digit_classifier.h5 file.

On running the launchapp.py file we get this initial pygame window:

initial window

As we draw/write our numbers on the left side of the window, we get the predicted label of the number in the right side:

one digit window

The app can also detect multiple numbers in the canvas:

multi digit window

About

An application that uses Convolutional Neural Networks to recognize handwritten digits.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages