Introduction:
This application, the Digit Recognizer, is a web-based tool designed to recognize handwritten digits using machine
learning techniques. With the advancement of deep learning and image recognition algorithms, it has become feasible to
build accurate models capable of identifying handwritten digits with high precision. My application leverages this
technology to provide users with a seamless experience for digit recognition tasks. Whether it’s recognizing handwritten
digits for digitizing documents or assisting in educational activities, my application offers a user-friendly interface
for efficient digit recognition.

Configuration:
To configure and deploy the Digit Recognizer application, follow these step-by-step instructions:
- Set up the environment:
- Ensure you have Python installed on your system.
- Create a virtual environment to manage dependencies using
venv
or conda
.
- Install dependencies:
- Use pip to install the required Python packages listed in the
requirements.txt
file.
- Prepare the dataset:
- Obtain the MNIST dataset, which contains handwritten digit images.
- Split the dataset into training and testing sets for model training and evaluation.
- Build the machine learning model:
- Choose a machine learning technique, such as SVM, k-Nearest Neighbors, or a neural network.
- Train the model using the training data and evaluate its performance using the testing data.
- Develop the web application:
- Use a web framework like Flask or Django to create the frontend and backend of the application.
- Design the user interface for uploading handwritten digit images and displaying recognition results.
- Integrate the machine learning model:
- Incorporate the trained machine learning model into the web application to perform digit recognition.
- Define endpoints for processing uploaded images and returning recognition results.
- Configure the environment variables:
- Set up environment variables for the Flask application, including the Flask secret key and any other necessary
configurations.
- Run the application:
- Start the Flask server to run the web application locally or deploy it to a hosting platform for online access.
- Test the application:
- Upload handwritten digit images through the web interface and verify that the application accurately recognizes
and
displays the digits.
- Deploy the application (optional):
- If desired, deploy the application to a hosting service such as Heroku, AWS, or Google Cloud Platform for online
accessibility.
Set up the project
- Clone the project repository:
git clone https://github.com/kavicastelo/digit_recognizer.git
- Navigate to the project directory:
- Create a virtual environment (optional but recommended):
- Activate the virtual environment:
- On Windows:
- On macOS/Linux:
- Install dependencies:
pip install -r requirements.txt
- Run the application locally:
- Start the Application on desktop:
- Start the Application on web(windows):
$env:FLASK_APP = "app.py"
- Start the Application on web(mac/linux):
- Test the application:
Upload handwritten digit images through the web interface and verify that the application accurately recognizes and
displays the digits.
YouTube Overview

Feel free to explore and contribute to this educational project! For any questions or issues, contact Kavindu Kokila.