- Table of Contents
⚠️ Frameworks and Libraries- 📁 Datasets
- 📖 Data Preprocessing
- 🔗 Download
- 🔑 Prerequisites
- 🚀 Installation
- 💡 How to Run
- 📂 Directory Tree
- 🔑 Results
- 👏 And it's done!
- 🙋 Citation
- ❤️ Owner
- 👀 License
- Pytorch: An open source machine learning framework that accelerates the path from research prototyping to production deployment.
- Matplotlib : Matplotlib is a comprehensive library for creating static, animated, and interactive visualizations in Python.
- Numpy: Caffe-based Single Shot-Multibox Detector (SSD) model used to detect faces
- Pandas: pandas is a fast, powerful, flexible and easy to use open source data analysis and manipulation tool, built on top of the Python programming language.
This dataset is a builtin dataset in pytorch MNIST dataset available from MNIST database;s page. The dataset may also be downloaded directly by importing torchvision.dataset
.
To convert the output rows into probabilities, we use the softmax function, which has the following formula:
Equation of Softmax:
Graph of Softmax:
Accuracy is often used as an evaluation metric for classification, but not as a loss function. A commonly used loss function for classification problems is the cross-entropy, which has the following formula:
Equation of Cross Entropy:
Graph of Cross Entropy:
Data pre-processing is an important step for the creation of a machine learning model. Initially, data may not be clean or in the required format for the model which can cause misleading outcomes. In pre-processing of data, we transform data into our required format. It is used to deal with noises, duplicates, and missing values of the dataset. Data pre-processing has the activities like importing datasets, splitting datasets, attribute scaling, etc. Preprocessing of data is required for improving the accuracy of the model.
The dataset is now available here !
All the dependencies and required libraries are included in the file requirements.txt
See here
The Code is written in Python 3.7. If you don’t have Python installed you can find it here. If you are using a lower version of Python you can upgrade using the pip package, ensuring you have the latest version of pip. To install the required packages and libraries, run this command in the project directory after cloning the repository:
- Clone the repo
git clone https://github.com/Chaganti-Reddy/Hand-Digit-Recognition.git
- Change your directory to the cloned repo
cd Hand-Digit-Recognition
- Now, run the following command in your Terminal/Command Prompt to install the libraries required
python3 -m virtualenv my_env
source my_env/bin/activate
pip3 install -r requirements.txt
- Open terminal. Go into the cloned project directory and type the following command:
python3 Digit-Recognition.py
├── assets
│ ├── digit5.png
│ ├── entropy.png
│ ├── graph.png
│ ├── home.png
│ ├── softmax-graph.png
│ └── softmax.png
├── data
│ └── MNIST
│ └── raw
│ ├── t10k-images-idx3-ubyte
│ ├── t10k-images-idx3-ubyte.gz
│ ├── t10k-labels-idx1-ubyte
│ ├── t10k-labels-idx1-ubyte.gz
│ ├── train-images-idx3-ubyte
│ ├── train-images-idx3-ubyte.gz
│ ├── train-labels-idx1-ubyte
│ └── train-labels-idx1-ubyte.gz
├── Digit-Recognition.ipynb
├── Digit-Recognition.py
├── LICENSE
├── mnist-logistic.pth
├── Readme.md
└── requirements.txt
Our Classification Model has successfully predicted the output with an excellent accuracy via PyTorch
Feel free to mail me for any doubts/query :email: chagantivenkataramireddy1@gmail.com
You are allowed to cite any part of the code or our dataset. You can use it in your Research Work or Project. Remember to provide credit to the Maintainer Chaganti Reddy by mentioning a link to this repository and her GitHub Profile.
Follow this format:
- Author's name - Chaganti Reddy
- Date of publication or update in parentheses.
- Title or description of document.
- URL.
Made with ❤️ by Chaganti Reddy
MIT © Chaganti Reddy