# sifat192/intel-image-classification-pytorch architecture

> Architecture diagram of the GitHub repository sifat192/intel-image-classification-pytorch, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-28). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/sifat192/intel-image-classification-pytorch
- Repository: https://github.com/sifat192/intel-image-classification-pytorch

## Overview

This repository is a notebook-based PyTorch project for classifying Intel natural-scene images into six classes. Its main workflow downloads and prepares the dataset, loads batches, trains a custom CNN, and evaluates loss and accuracy. The README documents additional training and evaluation details; the notebook is present in the tree but its contents were not sampled, so internal wiring beyond that documented workflow is not independently verified.

Main entry points: [`notebook/Image_Classification.ipynb`](https://github.com/sifat192/intel-image-classification-pytorch/blob/main/notebook/Image_Classification.ipynb) (Training loop), [`Dataset`](https://github.com/sifat192/intel-image-classification-pytorch/blob/main/Dataset) (Image dataset)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_data["Dataset Preparation"]
  node_download["Dataset download"]
  node_images[("Image dataset")]
  node_preprocess["Image transforms"]
  node_loaders["DataLoaders"]
end

subgraph group_model["Model and Training"]
  node_cnn["Custom CNN"]
  node_loss["Cross-entropy loss"]
  node_optimizer["Adam optimizer"]
  node_training["Training loop"]
end

subgraph group_evaluation["Evaluation"]
  node_evaluation["Model evaluation"]
  node_metrics["Loss and accuracy"]
end

node_user(("Project user"))
node_kaggle[("Kaggle dataset")]

node_user -->|"runs notebook"| node_download
node_download -->|"downloads dataset"| node_kaggle
node_download -->|"stores images"| node_images
node_images -->|"reads images"| node_preprocess
node_preprocess -->|"transforms images"| node_loaders
node_loaders -->|"provides batches"| node_training
node_training -->|"trains model"| node_cnn
node_training -->|"computes loss"| node_loss
node_training -->|"updates weights"| node_optimizer
node_loaders -->|"provides test batches"| node_evaluation
node_evaluation -->|"evaluates model"| node_cnn
node_evaluation -->|"reports results"| node_metrics

click node_download "https://github.com/sifat192/intel-image-classification-pytorch/blob/main/notebook/Image_Classification.ipynb"
click node_images "https://github.com/sifat192/intel-image-classification-pytorch/blob/main/Dataset"
click node_preprocess "https://github.com/sifat192/intel-image-classification-pytorch/blob/main/notebook/Image_Classification.ipynb"
click node_loaders "https://github.com/sifat192/intel-image-classification-pytorch/blob/main/notebook/Image_Classification.ipynb"
click node_cnn "https://github.com/sifat192/intel-image-classification-pytorch/blob/main/notebook/Image_Classification.ipynb"
click node_loss "https://github.com/sifat192/intel-image-classification-pytorch/blob/main/notebook/Image_Classification.ipynb"
click node_optimizer "https://github.com/sifat192/intel-image-classification-pytorch/blob/main/notebook/Image_Classification.ipynb"
click node_training "https://github.com/sifat192/intel-image-classification-pytorch/blob/main/notebook/Image_Classification.ipynb"
click node_evaluation "https://github.com/sifat192/intel-image-classification-pytorch/blob/main/notebook/Image_Classification.ipynb"
click node_metrics "https://github.com/sifat192/intel-image-classification-pytorch/blob/main/notebook/Image_Classification.ipynb"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_download,node_images,node_preprocess,node_loaders,node_user toneBlue
class node_cnn,node_loss,node_optimizer,node_training,node_kaggle toneAmber
class node_evaluation,node_metrics toneMint
```

## Components

### Dataset Preparation

- [Dataset download](https://github.com/sifat192/intel-image-classification-pytorch/blob/main/notebook/Image_Classification.ipynb): `notebook/Image_Classification.ipynb`
- [Image dataset](https://github.com/sifat192/intel-image-classification-pytorch/blob/main/Dataset): `Dataset`
- [Image transforms](https://github.com/sifat192/intel-image-classification-pytorch/blob/main/notebook/Image_Classification.ipynb): `notebook/Image_Classification.ipynb`
- [DataLoaders](https://github.com/sifat192/intel-image-classification-pytorch/blob/main/notebook/Image_Classification.ipynb): `notebook/Image_Classification.ipynb`

### Model and Training

- [Custom CNN](https://github.com/sifat192/intel-image-classification-pytorch/blob/main/notebook/Image_Classification.ipynb): `notebook/Image_Classification.ipynb`
- [Cross-entropy loss](https://github.com/sifat192/intel-image-classification-pytorch/blob/main/notebook/Image_Classification.ipynb): `notebook/Image_Classification.ipynb`
- [Adam optimizer](https://github.com/sifat192/intel-image-classification-pytorch/blob/main/notebook/Image_Classification.ipynb): `notebook/Image_Classification.ipynb`
- [Training loop](https://github.com/sifat192/intel-image-classification-pytorch/blob/main/notebook/Image_Classification.ipynb): `notebook/Image_Classification.ipynb`

### Evaluation

- [Model evaluation](https://github.com/sifat192/intel-image-classification-pytorch/blob/main/notebook/Image_Classification.ipynb): `notebook/Image_Classification.ipynb`
- [Loss and accuracy](https://github.com/sifat192/intel-image-classification-pytorch/blob/main/notebook/Image_Classification.ipynb): `notebook/Image_Classification.ipynb`

### Other components

- **Project user**
- **Kaggle dataset**

## Connections

- Project user → Dataset download: runs notebook
- Dataset download → Kaggle dataset: downloads dataset
- Dataset download → Image dataset: stores images
- Image dataset → Image transforms: reads images
- Image transforms → DataLoaders: transforms images
- DataLoaders → Training loop: provides batches
- Training loop → Custom CNN: trains model
- Training loop → Cross-entropy loss: computes loss
- Training loop → Adam optimizer: updates weights
- DataLoaders → Model evaluation: provides test batches
- Model evaluation → Custom CNN: evaluates model
- Model evaluation → Loss and accuracy: reports results
