Machine Learning Report
Machine Learning Report
Date of
Announcement: Date
of Submission:
Branch/division: Computer-B
Semester: VII
R1 R2 R3 Total Signature
1
A MINI PROJECT REPORT
ON
BY
RUSHIKESH M. MANJE (B-09)
SANGARAM R. LAD (B-03)
UNDER GUIDANCE OF
Prof. P. P. Karhade
UNIVERSITY OF MUMBAI
DEPARTMENT OF COMPUTER ENGINEERING
DATTA MEGHE COLLEGE OF ENGINEERING
PLOT NO.98 SECTOR-3, AIROLI, NAVI MUMBAI
ACADAMIC YEAR 2024-25
2
DATTA MEGHE COLLEGE OF ENGINEERING
AIROLI, NAVI MUMBA
CERTIFICATE
This is to certify that the project entitled “Handwritten Digit Recognition” is bonafide work
of “Rushikesh Manje (09), Sangaram lad (03) ” submitted to the University of Mumbai in
partial fulfilment of the requirement for the award of BE in “Computer Engineering”.
3
DATTA MEGHE COLLEGE OF ENGINEERING
AIROLI, NAVI MUMBAI
This project report entitled “Handwritten Digit Recognition ” of the students “Rushikesh
Manje (09), Sangaram lad (03)” approved for the degree of Computer Engineering.
4
ACKNOWLEDGEMENT
Motivation and guidance are the keys towards success. I would like to extend my thanks to
all the sources of motivation.
We would like to grab this opportunity to thank Dr. P. A. Dode, Principal for
encouragement and support he has given for our project.
We express our deep gratitude to Dr. A. P. Pande, Head of the Department who has been
the constant driving force behind the completion of this project.
We wish to express our heartfelt appreciation and deep sense of gratitude to my project guide
Prof. P. P. Karhade for her encouragement, invaluable support, timely help, lucid
suggestions and excellent guidance which helped us to understand and achieve the project
goal. Her concrete directions and critical views have greatly helped us in successful
completion of this work.
We extend our sincere appreciation to all Professors for their valuable inside and tip during
the designing of the project. Their contributions have been valuable in so many ways that we
find it difficult to acknowledge of them individually.
We are also thankful to all those who helped us directly or indirectly in completion of this
work.
5
INDEX
1. INTRODUCTION
2. REQUIREMENT ANALYSIS
3. PROJECT DESIGN (flow chart)
4. TECHNOLOGIES USED
5. RESULTS AND DISCUSSIONS
6. CONCLUSIONS AND FUTURE SCOPE
7. REFERENCES
6
1. INTRODUCTION
This project aims to develop a Handwritten Digit Recognition system using machine learning
techniques to accurately classify handwritten digits from images. By utilizing a dataset such
as the MNIST (Modified National Institute of Standards and Technology), we can train
models to recognize digits based on their features.
2. REQUIREMENT ANALYSIS
7
3. PROJECT DESIGN (flow chart)
8
4. TECHNOLOGIES USED
Programming Language: Python was chosen due to its simplicity and the availability of
powerful libraries for machine learning and data processing.
Libraries Used:
TensorFlow/Keras: Used for building and training the CNN model.
OpenCV: Utilized for image processing tasks, such as resizing, normalization,
and augmentation of the handwritten digit images.
Scikit-learn: Used for implementing KNN and SVM models, and for splitting data
into training and testing sets.
Matplotlib & Seaborn: Libraries used for visualizing data distributions,
model performance metrics, and results.
Dataset: Instead of using the standard MNIST dataset, a custom dataset of handwritten digits
was created. The dataset consists of [number of images] images collected from [mention the
sources, e.g., various individuals or sources]. These images were preprocessed and split into
training and testing sets for model training and evaluation.
9
5. RESULTS
Source Code:
model=joblib.load("model/digit_recognizer")
image_folder="img/"
while True:
img=ImageGrab.grab(bbox=300,300,800,900))
img.save(images_folder+"img.png")
im = cv2.imread(images_folder+"img.png")
im_gray = cv2.cvtColor(im,cv2.COLOR_BGR2GRAY)
im_gray = cv2.GaussianBlur(im_gray, (5, 5), 0) # Smaller kernel for less blurring
rows,cols=roi.shape
X = []
predictions =model.predict([X])
print("Prediction:",predictions[0])
cv2.putText(im, "Prediction is: "+str(predictions[0]), (300,300, 0, 0.8,(0,500,0),2,cv2.LINE_AA)
cv2.startWindowThread()
cv2.namedWindow("Result")
cv2.imshow("Result",im)
cv2.waitKey(10000)
if cv2.waitKey(1)==13: #27 is the ascii value of esc, 13 is the ascii value of enter
break
cv2.destroyAllWindows()
10
Output:
11
6. CONCLUSION & FUTURE SCOPE
6.1 Conclusions:
The Handwritten Digit Recognition System built using machine learning algorithms
successfully classified handwritten digits from the MNIST dataset with a high degree of
accuracy. The CNN model proved to be the most effective due to its ability to process and
extract features from images efficiently.
Real-Time Recognition:
Future versions of the system could include real-time digit recognition, allowing users to draw
digits and get instant predictions.
Mobile Application:
Developing a mobile app for handwritten digit recognition would provide wider accessibility to
users in various sectors, such as education and banking.
Improved Accuracy:
Further improvement in accuracy can be achieved by fine-tuning hyperparameters or using more
advanced deep learning architectures like ResNet.
REFERENCES
12