Skip to content

Deep Learning project using a Convolutional Neural Network (CNN) in TensorFlow/Keras to classify objects in the CIFAR-10 dataset with ~70% accuracy

Notifications You must be signed in to change notification settings

Rahilshah01/image-classification-cnn

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

4 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸ–ΌοΈ Image Classification using CNN (CIFAR-10)

πŸ“Œ Project Overview

In this project, I developed a Convolutional Neural Network (CNN) to classify low-resolution (32x32) color images into 10 distinct categories. This project demonstrates the power of Deep Learning in identifying spatial hierarchies and patterns in visual data.

πŸ› οΈ Tech Stack

  • Framework: TensorFlow / Keras
  • Libraries: NumPy, Matplotlib, Seaborn, Scikit-Learn
  • Dataset: CIFAR-10 (60,000 images across 10 classes)

πŸ—οΈ Model Architecture

The network consists of a series of convolutional and pooling layers designed to extract features from edges to complex shapes:

  1. Convolutional Layer 1: 32 filters (3x3), ReLU activation.
  2. Max Pooling: 2x2 downsampling.
  3. Convolutional Layer 2: 64 filters (3x3), ReLU activation.
  4. Max Pooling: 2x2 downsampling.
  5. Convolutional Layer 3: 64 filters (3x3).
  6. Fully Connected (Dense): 64 neurons leading to a 10-node output layer.

πŸ“Š Performance & Evaluation

  • Final Test Accuracy: 69.93% after 10 epochs.
  • Optimization: Used Adam optimizer and SparseCategoricalCrossentropy loss.

Confusion Matrix Analysis

Confusion Matrix

By analyzing the confusion matrix, I identified key behaviors of the model:

  • High Precision: The model performed exceptionally well on Ships (835 correct) and Automobiles (790 correct).
  • Class Confusion: The highest error rate occurred between Cats and Dogs, where 264 cats were misidentified as dogs, highlighting the challenges of classifying similar organic shapes in low resolution.

πŸš€ How to Run

  1. Clone the repository.
  2. Install dependencies: pip install tensorflow matplotlib seaborn scikit-learn.
  3. Run the notebook: jupyter notebook image-classification-cnn.ipynb.

About

Deep Learning project using a Convolutional Neural Network (CNN) in TensorFlow/Keras to classify objects in the CIFAR-10 dataset with ~70% accuracy

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published