# srimidhuna/intel_image_classification architecture

> Architecture diagram of the GitHub repository srimidhuna/intel_image_classification, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-03). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/srimidhuna/intel_image_classification
- Repository: https://github.com/srimidhuna/intel_image_classification

## Overview

This repository combines an Intel scene-classification training workflow with a Gradio image-prediction app. The documented training path runs from labeled images through preprocessing and CNN training to evaluation and visualizations; the app loads a trained model, preprocesses an uploaded image, and returns class scores. Training details come from the README, since the notebook was not sampled; the referenced model file is not present in the supplied tree.

Main entry points: [`app.py`](https://github.com/srimidhuna/intel_image_classification/blob/main/app.py) (Prediction and scores), [`code.ipynb`](https://github.com/srimidhuna/intel_image_classification/blob/main/code.ipynb) (CNN training), [`intel-image-classification/seg_train/seg_train`](https://github.com/srimidhuna/intel_image_classification/tree/main/intel-image-classification/seg_train/seg_train) (Training images), [`intel-image-classification/seg_test/seg_test`](https://github.com/srimidhuna/intel_image_classification/tree/main/intel-image-classification/seg_test/seg_test) (Test images)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_training["Training"]
  node_train_data[("Training images")]
  node_preparation["Preprocessing and augmentation<br/>[code.ipynb]"]
  node_cnn["CNN training<br/>[code.ipynb]"]
  node_model["Trained model"]
end

subgraph group_evaluation["Evaluation"]
  node_test_data[("Test images")]
  node_metrics["Classification metrics<br/>[code.ipynb]"]
  node_visuals["Training visualizations<br/>[code.ipynb]"]
end

subgraph group_serving["Prediction app"]
  node_interface["Gradio interface<br/>[app.py]"]
  node_image_prep["Image preprocessing<br/>[app.py]"]
  node_prediction["Prediction and scores<br/>[app.py]"]
end

node_user(("Image user"))

node_train_data -->|"preprocesses"| node_preparation
node_preparation -->|"feeds training"| node_cnn
node_cnn -->|"trains"| node_model
node_test_data -->|"evaluates"| node_metrics
node_model -->|"is evaluated"| node_metrics
node_cnn -->|"visualizes training"| node_visuals
node_user -->|"uploads image"| node_interface
node_interface -->|"invokes"| node_prediction
node_prediction -->|"preprocesses with"| node_image_prep
node_prediction -->|"predicts with"| node_model
node_prediction -->|"returns scores"| node_interface

click node_train_data "https://github.com/srimidhuna/intel_image_classification/tree/main/intel-image-classification/seg_train/seg_train"
click node_preparation "https://github.com/srimidhuna/intel_image_classification/blob/main/code.ipynb"
click node_cnn "https://github.com/srimidhuna/intel_image_classification/blob/main/code.ipynb"
click node_test_data "https://github.com/srimidhuna/intel_image_classification/tree/main/intel-image-classification/seg_test/seg_test"
click node_metrics "https://github.com/srimidhuna/intel_image_classification/blob/main/code.ipynb"
click node_visuals "https://github.com/srimidhuna/intel_image_classification/blob/main/code.ipynb"
click node_interface "https://github.com/srimidhuna/intel_image_classification/blob/main/app.py"
click node_image_prep "https://github.com/srimidhuna/intel_image_classification/blob/main/app.py"
click node_prediction "https://github.com/srimidhuna/intel_image_classification/blob/main/app.py"

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_train_data,node_preparation,node_cnn,node_model,node_user toneBlue
class node_test_data,node_metrics,node_visuals toneAmber
class node_interface,node_image_prep,node_prediction toneMint
```

## Components

### Training

- [Training images](https://github.com/srimidhuna/intel_image_classification/tree/main/intel-image-classification/seg_train/seg_train): `intel-image-classification/seg_train/seg_train`
- [Preprocessing and augmentation](https://github.com/srimidhuna/intel_image_classification/blob/main/code.ipynb): `code.ipynb`
- [CNN training](https://github.com/srimidhuna/intel_image_classification/blob/main/code.ipynb): `code.ipynb`
- **Trained model**

### Evaluation

- [Test images](https://github.com/srimidhuna/intel_image_classification/tree/main/intel-image-classification/seg_test/seg_test): `intel-image-classification/seg_test/seg_test`
- [Classification metrics](https://github.com/srimidhuna/intel_image_classification/blob/main/code.ipynb): `code.ipynb`
- [Training visualizations](https://github.com/srimidhuna/intel_image_classification/blob/main/code.ipynb): `code.ipynb`

### Prediction app

- [Gradio interface](https://github.com/srimidhuna/intel_image_classification/blob/main/app.py): `app.py`
- [Image preprocessing](https://github.com/srimidhuna/intel_image_classification/blob/main/app.py): `app.py`
- [Prediction and scores](https://github.com/srimidhuna/intel_image_classification/blob/main/app.py): `app.py`

### Other components

- **Image user**

## Connections

- Training images → Preprocessing and augmentation: preprocesses (evidence: `README.md`)
- Preprocessing and augmentation → CNN training: feeds training (evidence: `README.md`)
- CNN training → Trained model: trains (evidence: `README.md`)
- Test images → Classification metrics: evaluates (evidence: `README.md`)
- Trained model → Classification metrics: is evaluated (evidence: `README.md`)
- CNN training → Training visualizations: visualizes training (evidence: `README.md`)
- Image user → Gradio interface: uploads image (evidence: `app.py`)
- Gradio interface → Prediction and scores: invokes (evidence: `app.py`)
- Prediction and scores → Image preprocessing: preprocesses with (evidence: `app.py`)
- Prediction and scores → Trained model: predicts with (evidence: `app.py`)
- Prediction and scores → Gradio interface: returns scores (evidence: `app.py`)
