MNIST Pattern Recognition with Convolutional Neural Network (CNN)
This project implements a Convolutional Neural Network (CNN) for recognizing handwritten digits from the MNIST dataset. The model is built using TensorFlow and Keras, and it supports both single-GPU and multi-GPU training. The project includes training, testing, and a user-friendly GUI for inference.
Features
- Customizable CNN Architecture: Includes convolutional, pooling, normalization, and dense layers.
- Multi-GPU Support: Leverages TensorFlow's
MirroredStrategy
for distributed training. - Training Visualization: Generates plots for training/validation accuracy and loss.
- Evaluation Metrics: Outputs confusion matrix, classification report, and precision/recall/F1 scores.
- Interactive GUI: Built with Streamlit for real-time image recognition.
- Docker Support: Easily deployable using Docker.
Model Architecture
- Two convolutional layers with ReLU activation and max-pooling.
- Layer normalization for improved convergence.
- Fully connected dense layers with dropout for regularization.
- Softmax output layer for classification into 10 digit classes.
Training
The model is trained on the MNIST dataset, which contains 60,000 training images and 10,000 test images of handwritten digits (28x28 grayscale). The training process includes:
- Data normalization to scale pixel values to the range [0, 1].
- Categorical cross-entropy loss and accuracy as the evaluation metric.
- Model checkpointing to save the best-performing model based on validation accuracy.
Final result
Full code at Github
- Downloads last month
- 1
Inference Providers
NEW
This model isn't deployed by any Inference Provider.
🙋
Ask for provider support