Skip to content

RobCaamano/ResNet50-CNN-Visualization-and-Transfer-Learning

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 

Repository files navigation

ResNet-50 Visualization and Transfer Learning

Sections

About

The ResNet-50 Visualization and Transfer Learning project leverages the CIFAR-10 dataset to demonstrate advanced techniques in convolutional neural networks (CNNs). This project focuses on visualizing the inner workings of the ResNet-50 model and applying transfer learning for image classification.

  • CIFAR-10 Dataset: The project utilizes the CIFAR-10 dataset, which consists of 60,000 32x32 color images in 10 different classes. The labels are one-hot encoded to facilitate multi-class classification.

  • Class Filtering: Initially, the class "ship" is filtered out from the dataset and is later reintroduced through transfer learning.

  • Visualizations: The project includes two sets of plots for each model:

    • Intermediate Activations: Visualizing intermediate convolutional network outputs, or “intermediate activations” helps in understanding how successive convnet layers transform their input at different stages of the model.

    • Covnet Filters: Visualizing filters of the convolutional network reveals the specific visual patterns or concepts each filter is receptive to, offering deeper insights into the model’s internal representations.

As the model progresses through the layers, the visualizations become more abstract and harder for humans to see patterns. This increasing abstraction highlights how the model captures complex, high-level features that are not easily interpretable but are crucial for accurate predictions.

Resnet-50

A ResNet-50 model is employed as the core CNN architecture. This model is renowned for its depth and ability to handle image classification tasks effectively.

Original Image Preprocessed Image

Intermediate Activations

Covnet Filters

Transfer Learning on Resnet-50

In this section, we focus on applying fine-tuning and feature extraction methods of transfer learning using the ResNet-50 model specifically for the class "ship" from the CIFAR-10 dataset.

Original Image Preprocessed Image

Finetuned Model

Fine-tuning involves unfreezing the top layers of the pre-trained ResNet-50 model and jointly training both the newly added layers and the last layers of the original model. This allows the model to learn specific features relevant to the class "ship," improving its ability to recognize ships accurately.

Intermediate Activations

Covnet Filters

Feature Extraction Model

Feature extraction involves using the pre-trained ResNet-50 model as a fixed feature extractor, where the final classification layer is replaced with a new layer tailored to the class "ship." By leveraging the feature representations learned by ResNet-50 during pre-training on a large dataset, we can effectively classify ships with high accuracy.

Intermediate Activations

Covnet Filters

Releases

No releases published

Packages

No packages published