Skip to content

Academic

Handwritten Digit Recognition

Command-line tool that recognizes handwritten digits with the KNN algorithm.

Context

Data Mining coursework: implement a classifier from scratch instead of calling a library.

Approach

  • Loads MNIST images from one folder per label and binarizes them with Otsu thresholding.
  • k-nearest neighbours written by hand: Euclidean distance over 784-pixel vectors and a majority vote.
  • A menu sets the number of training and test samples and k, computes accuracy and predicts sample images.
Role
Developer (Data Mining course)
Stack
PythonKNN

Have a project in mind?

Tell me what you are building. I reply by email, usually within two working days.

Start a conversation