A C++ implementation of a KD Tree supporting efficient k-Nearest Neighbor (KNN) search and classification on the MNIST dataset.
This project demonstrates efficient multidimensional spatial indexing using a balanced KD Tree and branch-and-bound nearest neighbor search.
- Balanced KD Tree construction
- Fast KNN search
- Point insertion and lookup
- MNIST digit classification
- Efficient multidimensional search
- src/Point.h – Point representation in k-dimensional space.
- src/KDTree.h – KD Tree implementation.
- src/BoundedPQueue.h – Priority queue for KNN search.
- src/main.cc – Runs KD Tree operations and KNN classification.
make
./mainBuilt using C++ and the STL to demonstrate efficient spatial indexing and nearest-neighbor search algorithms.