# jarrydstringy/transfer-learning-flower-classifier architecture

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

- Interactive diagram: https://gitdiagram.com/jarrydstringy/transfer-learning-flower-classifier
- Repository: https://github.com/jarrydstringy/transfer-learning-flower-classifier

## Overview

This repository is a script-based flower image classifier using ImageNet transfer learning. Its principal workflow prepares image data, adapts a frozen pretrained model to five flower classes, trains it, and evaluates or plots results; additional tasks compare optimizer settings. The sampled excerpts show the script’s functions and some main-program calls, but omit portions of the runner and task implementations, so unsampled call relationships are not inferred.

Main entry points: [`FlowerClassifier.py`](https://github.com/jarrydstringy/transfer-learning-flower-classifier/blob/main/FlowerClassifier.py) (Model training)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_data["Image data"]
  node_entry["Task runner"]
  node_load["Dataset setup"]
  node_prepare["Image preparation"]
end

subgraph group_model["Transfer model"]
  node_base["ImageNet base"]
  node_adapt["Five-class model"]
end

subgraph group_training["Training and analysis"]
  node_fit["Model training"]
  node_evaluate["Model evaluation"]
  node_plots["Results plots"]
  node_experiments["Optimizer experiments"]
end

node_user(("Script runner"))
node_dataset[("Flower images")]

node_user -->|"runs"| node_entry
node_entry -->|"calls"| node_load
node_dataset -->|"image files"| node_prepare
node_prepare -->|"prepares inputs"| node_base
node_base -->|"provides base"| node_adapt
node_prepare -->|"provides splits"| node_fit
node_adapt -->|"trains"| node_fit
node_fit -->|"evaluates"| node_evaluate
node_fit -->|"plots history"| node_plots
node_fit -->|"compares settings"| node_experiments

click node_entry "https://github.com/jarrydstringy/transfer-learning-flower-classifier/blob/main/FlowerClassifier.py"
click node_load "https://github.com/jarrydstringy/transfer-learning-flower-classifier/blob/main/FlowerClassifier.py"
click node_prepare "https://github.com/jarrydstringy/transfer-learning-flower-classifier/blob/main/FlowerClassifier.py"
click node_base "https://github.com/jarrydstringy/transfer-learning-flower-classifier/blob/main/FlowerClassifier.py"
click node_adapt "https://github.com/jarrydstringy/transfer-learning-flower-classifier/blob/main/FlowerClassifier.py"
click node_fit "https://github.com/jarrydstringy/transfer-learning-flower-classifier/blob/main/FlowerClassifier.py"
click node_evaluate "https://github.com/jarrydstringy/transfer-learning-flower-classifier/blob/main/FlowerClassifier.py"
click node_plots "https://github.com/jarrydstringy/transfer-learning-flower-classifier/blob/main/FlowerClassifier.py"
click node_experiments "https://github.com/jarrydstringy/transfer-learning-flower-classifier/blob/main/FlowerClassifier.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_entry,node_load,node_prepare toneBlue
class node_base,node_adapt,node_dataset toneAmber
class node_fit,node_evaluate,node_plots,node_experiments toneMint
class node_user toneIndigo
```

## Components

### Image data

- [Task runner](https://github.com/jarrydstringy/transfer-learning-flower-classifier/blob/main/FlowerClassifier.py): `FlowerClassifier.py`
- [Dataset setup](https://github.com/jarrydstringy/transfer-learning-flower-classifier/blob/main/FlowerClassifier.py): `FlowerClassifier.py`
- [Image preparation](https://github.com/jarrydstringy/transfer-learning-flower-classifier/blob/main/FlowerClassifier.py): `FlowerClassifier.py`

### Transfer model

- [ImageNet base](https://github.com/jarrydstringy/transfer-learning-flower-classifier/blob/main/FlowerClassifier.py): `FlowerClassifier.py`
- [Five-class model](https://github.com/jarrydstringy/transfer-learning-flower-classifier/blob/main/FlowerClassifier.py): `FlowerClassifier.py`

### Training and analysis

- [Model training](https://github.com/jarrydstringy/transfer-learning-flower-classifier/blob/main/FlowerClassifier.py): `FlowerClassifier.py`
- [Model evaluation](https://github.com/jarrydstringy/transfer-learning-flower-classifier/blob/main/FlowerClassifier.py): `FlowerClassifier.py`
- [Results plots](https://github.com/jarrydstringy/transfer-learning-flower-classifier/blob/main/FlowerClassifier.py): `FlowerClassifier.py`
- [Optimizer experiments](https://github.com/jarrydstringy/transfer-learning-flower-classifier/blob/main/FlowerClassifier.py): `FlowerClassifier.py`

### Other components

- **Script runner**
- **Flower images**

## Connections

- Script runner → Task runner: runs (evidence: `FlowerClassifier.py`)
- Task runner → Dataset setup: calls (evidence: `FlowerClassifier.py`)
- Flower images → Image preparation: image files (evidence: `FlowerClassifier.py`)
- Image preparation → ImageNet base: prepares inputs (evidence: `FlowerClassifier.py`)
- ImageNet base → Five-class model: provides base (evidence: `FlowerClassifier.py`)
- Image preparation → Model training: provides splits (evidence: `FlowerClassifier.py`)
- Five-class model → Model training: trains (evidence: `FlowerClassifier.py`)
- Model training → Model evaluation: evaluates (evidence: `FlowerClassifier.py`)
- Model training → Results plots: plots history (evidence: `FlowerClassifier.py`)
- Model training → Optimizer experiments: compares settings (evidence: `FlowerClassifier.py`)
