Skip to content

A K-Nearest Neighbors (KNN) model to classify handwritten digits, trained on the MNIST dataset.

Notifications You must be signed in to change notification settings

sshovkov/handwritten-digit-classifier

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

A simple K-Nearest Neighbors (KNN) classifier to recognize handwritten digit input, trained on the MNIST dataset kindly borrowed from THE MNIST DATABASE of handwritten digits.

Run

  1. Clone the repo
  2. Upload a handwritten digit (black number on white background) to the local_test_image/ folder. Set image_path to the respective file path
  3. Run the program python main.py

The output will display handwritten digit prediction and its nearest three neighbors (if uncommented in display_results()) Screenshot 2023-09-20 at 5 59 30 PM

About

A K-Nearest Neighbors (KNN) model to classify handwritten digits, trained on the MNIST dataset.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages