# ahmed0elsawy/skin-cancer-detection architecture

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

- Interactive diagram: https://gitdiagram.com/ahmed0elsawy/skin-cancer-detection
- Repository: https://github.com/ahmed0elsawy/skin-cancer-detection

## Overview

This repository is a Colab-oriented melanoma classifier workflow implemented in one notebook: obtain the Kaggle lesion dataset, build and train an EfficientNetB6 transfer-learning model, inspect training curves, predict on a test image, and save the trained model. The README documents the model layers and workflow; the notebook itself was not sampled, so the graph represents documented responsibilities rather than verified notebook calls. Dataset preprocessing details and exact runtime wiring are therefore omitted.

Main entry points: [`melanoma_detection.ipynb`](https://github.com/ahmed0elsawy/skin-cancer-detection/blob/main/melanoma_detection.ipynb) (Model Training)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_data["Dataset"]
  node_download["Download and Extract"]
  node_lesion_data[("Labeled Lesion Images")]
  node_train_test["Train and Test Splits"]
end

subgraph group_model["Model and Training"]
  node_augmentation["Image Augmentation"]
  node_efficientnet["EfficientNetB6 Features"]
  node_classifier["Classification Head"]
  node_training["Model Training"]
end

subgraph group_results["Evaluation and Outputs"]
  node_curves["Accuracy and Loss Curves"]
  node_test_prediction["Test Image Prediction"]
  node_saved_model["Saved Model"]
end

node_researcher(("Researcher"))
node_colab["Google Colab"]
node_kaggle["Kaggle Dataset"]

node_researcher -->|"runs notebook in"| node_colab
node_colab -->|"runs workflow"| node_download
node_kaggle -->|"provides dataset"| node_download
node_download -->|"downloads and extracts"| node_lesion_data
node_lesion_data -->|"contains splits"| node_train_test
node_train_test -.->|"feeds training images"| node_augmentation
node_augmentation -->|"augments inputs for"| node_efficientnet
node_efficientnet -->|"extracts features for"| node_classifier
node_classifier -->|"is trained by"| node_training
node_training -->|"produces plotted"| node_curves
node_training -->|"enables prediction"| node_test_prediction
node_training -->|"saves as"| node_saved_model

click node_download "https://github.com/ahmed0elsawy/skin-cancer-detection/blob/main/melanoma_detection.ipynb"
click node_lesion_data "https://github.com/ahmed0elsawy/skin-cancer-detection/blob/main/melanoma_detection.ipynb"
click node_train_test "https://github.com/ahmed0elsawy/skin-cancer-detection/blob/main/melanoma_detection.ipynb"
click node_augmentation "https://github.com/ahmed0elsawy/skin-cancer-detection/blob/main/melanoma_detection.ipynb"
click node_efficientnet "https://github.com/ahmed0elsawy/skin-cancer-detection/blob/main/melanoma_detection.ipynb"
click node_classifier "https://github.com/ahmed0elsawy/skin-cancer-detection/blob/main/melanoma_detection.ipynb"
click node_training "https://github.com/ahmed0elsawy/skin-cancer-detection/blob/main/melanoma_detection.ipynb"
click node_curves "https://github.com/ahmed0elsawy/skin-cancer-detection/blob/main/melanoma_detection.ipynb"
click node_test_prediction "https://github.com/ahmed0elsawy/skin-cancer-detection/blob/main/melanoma_detection.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_lesion_data,node_train_test toneBlue
class node_augmentation,node_efficientnet,node_classifier,node_training toneAmber
class node_curves,node_test_prediction,node_saved_model toneMint
class node_researcher,node_colab,node_kaggle toneIndigo
```

## Components

### Dataset

- [Download and Extract](https://github.com/ahmed0elsawy/skin-cancer-detection/blob/main/melanoma_detection.ipynb): `melanoma_detection.ipynb`
- [Labeled Lesion Images](https://github.com/ahmed0elsawy/skin-cancer-detection/blob/main/melanoma_detection.ipynb): `melanoma_detection.ipynb`
- [Train and Test Splits](https://github.com/ahmed0elsawy/skin-cancer-detection/blob/main/melanoma_detection.ipynb): `melanoma_detection.ipynb`

### Model and Training

- [Image Augmentation](https://github.com/ahmed0elsawy/skin-cancer-detection/blob/main/melanoma_detection.ipynb): `melanoma_detection.ipynb`
- [EfficientNetB6 Features](https://github.com/ahmed0elsawy/skin-cancer-detection/blob/main/melanoma_detection.ipynb): `melanoma_detection.ipynb`
- [Classification Head](https://github.com/ahmed0elsawy/skin-cancer-detection/blob/main/melanoma_detection.ipynb): `melanoma_detection.ipynb`
- [Model Training](https://github.com/ahmed0elsawy/skin-cancer-detection/blob/main/melanoma_detection.ipynb): `melanoma_detection.ipynb`

### Evaluation and Outputs

- [Accuracy and Loss Curves](https://github.com/ahmed0elsawy/skin-cancer-detection/blob/main/melanoma_detection.ipynb): `melanoma_detection.ipynb`
- [Test Image Prediction](https://github.com/ahmed0elsawy/skin-cancer-detection/blob/main/melanoma_detection.ipynb): `melanoma_detection.ipynb`
- **Saved Model**

### Other components

- **Researcher**
- **Google Colab**
- **Kaggle Dataset**

## Connections

- Researcher → Google Colab: runs notebook in (evidence: `README.md`)
- Google Colab → Download and Extract: runs workflow (evidence: `README.md`)
- Kaggle Dataset → Download and Extract: provides dataset (evidence: `README.md`)
- Download and Extract → Labeled Lesion Images: downloads and extracts (evidence: `README.md`)
- Labeled Lesion Images → Train and Test Splits: contains splits (evidence: `README.md`)
- Train and Test Splits → Image Augmentation: feeds training images
- Image Augmentation → EfficientNetB6 Features: augments inputs for (evidence: `README.md`)
- EfficientNetB6 Features → Classification Head: extracts features for (evidence: `README.md`)
- Classification Head → Model Training: is trained by (evidence: `README.md`)
- Model Training → Accuracy and Loss Curves: produces plotted (evidence: `README.md`)
- Model Training → Test Image Prediction: enables prediction (evidence: `README.md`)
- Model Training → Saved Model: saves as (evidence: `README.md`)
