This repository provides a comprehensive implementation for classifying handwritten digits (0-9) from the MNIST dataset using deep learning. The project covers the entire workflow, from data preprocessing and visualization to training, evaluation, and result analysis, making it an excellent resource for learning and applying deep learning techniques to image classification tasks.
The MNIST dataset is a benchmark dataset in the field of machine learning, consisting of 70,000 grayscale images of handwritten digits, each of size 28x28 pixels. This project utilizes a deep learning approach to train a neural network capable of accurately recognizing these digits.
- Loading and preprocessing the MNIST dataset.
- Building a deep learning model using TensorFlow and Keras.
- Training the model and optimizing its performance.
- Visualizing and analyzing model performance with metrics and confusion matrices.
Normalize pixel values to improve model convergence. Visualize sample images from the dataset for better understanding.
Use TensorFlow and Keras to design a feedforward neural network. Train the model on the training dataset and validate on a separate validation dataset.
Evaluate model accuracy and loss on the test dataset. Generate a confusion matrix to analyze classification performance. Visualize training metrics such as accuracy and loss curves.
Display input images and their predicted labels. Plot confusion matrices and training performance curves using Seaborn and Matplotlib.
NumPy: For efficient numerical computations and data manipulation.
Matplotlib.pyplot: For visualizing sample images, model metrics, and results.
Seaborn: For advanced visualization, including the confusion matrix.
Pillow (PIL): For handling image data.
OpenCV (cv2): For image preprocessing and manipulation.
Google Colab Patches: For convenient visualization when running in Google Colab.
TensorFlow: Core framework for building, training, and evaluating the deep learning model.
Keras: High-level API of TensorFlow for building neural networks.
Confusion Matrix: To assess model performance on test data.