How ganeshkumar-133/handwritten-digit-recognition- works
This is an MNIST handwritten-digit classifier with two user-facing workflows: main.py trains and evaluates an MLP, while the desktop uploader predicts a digit from an image and displays confidence. Training loads and preprocesses MNIST, builds and fits the model, then saves a checkpoint and training curves; evaluation reloads the checkpoint and reports metrics with a confusion matrix. Image prediction preprocesses an uploaded image before model inference. Edges reflect the shown calls and documented workflow; unsampled artifacts are included only where their roles are supported.
Main entry points: train.py Model training · config.py Project configuration · evaluate.py Model evaluation · upload_app.py Image uploader
Components 13
Workflow
- Pipeline entry
main.py - Image uploader
src/upload_app.py
Training and evaluation
- MNIST dataset
- Data preprocessing
src/data_loader.py - MLP architecture
src/model.py - Model training
src/train.py - Model evaluation
src/evaluate.py
Image inference
- Digit prediction
src/predict.py
Shared configuration and artifacts
- Project configuration
config.py - Saved model
models/mlp_mnist.h5 - Training curves
outputs - Evaluation report
outputs
Other components
- User
Connections 21
- User → Pipeline entry: runs
README - Pipeline entry → Model training: starts training
main.py - Pipeline entry → Model evaluation: then evaluates
main.py - User → Image uploader: uploads image
README - Image uploader → Digit prediction: requests prediction
src/upload_app.py - MNIST dataset → Data preprocessing: provides data
src/data_loader.py - Model training → Data preprocessing: loads data
src/train.py - Model training → MLP architecture: builds model
src/train.py - Model training → Saved model: saves checkpoint
src/train.py - Model training → Training curves: saves curves
src/train.py - Model evaluation → Data preprocessing: loads test data
src/evaluate.py - Model evaluation → Saved model: loads checkpoint
src/evaluate.py - Model evaluation → Evaluation report: saves matrix
src/evaluate.py - Digit prediction → Saved model: loads model
src/predict.py - Image uploader → Saved model: loads model
src/upload_app.py - Model training → Project configuration: reads settings
src/train.py - Data preprocessing → Project configuration: reads settings
src/data_loader.py - MLP architecture → Project configuration: reads settings
src/model.py - Model evaluation → Project configuration: reads settings
src/evaluate.py - Digit prediction → Project configuration: reads settings
src/predict.py - Image uploader → Project configuration: reads model path
src/upload_app.py