Computer VisionMachine Learning
A from-scratch nearest-neighbour classifier on 32 x 32 faces, compared with SVM and Naive Bayes.
Notebook with recorded results; the demo runs KNN on the repository's dataset in your browser.
NumPyscikit-learnPCATypeScript (demo)

Overview
Identification of 10 subjects from 1,700 grayscale 32 x 32 face images using a hand-written KNN, benchmarked against scikit-learn SVM and Gaussian Naive Bayes, with a 3D PCA view of the data.
Interactive demo
Loads the repository's 1,700-face dataset and runs the same KNN (k=7, Euclidean, L2-normalised rows) in your browser.
Recorded results
- KNN accuracy
- 0.96
- 200 test faces, k = 7
- Source: i211697_Q2.ipynb, cell 2
- SVM accuracy
- 1.00
- Same split
- Source: i211697_Q2.ipynb, cell 2
- Gaussian NB accuracy
- 0.85
- Same split
- Source: i211697_Q2.ipynb, cell 2