The problem
Skin cancer is the most common cancer worldwide, and dermatoscopy — magnified imaging of pigmented lesions — is how dermatologists triage them. Deep learning reached dermatologist-level classification on the HAM10000 benchmark (Tschandl et al., 10,015 dermatoscopic images, 7 diagnostic categories), making it one of the most cited medical-imaging results. This project reproduces that pipeline: an ImageNet-pretrained EfficientNet-B0 fine-tuned on HAM10000 with class weights for the heavy imbalance toward benign nevi. A live web demo makes the dermatology tangible — upload a close-up lesion photo and the app segments it by Otsu thresholding, then computes real ABCD features from the pixels: asymmetry by mirror-overlap, border irregularity by compactness, color by distinct cluster count, diameter by lesion extent. Because the demo states plainly that the ABCD score is a transparent rule and the project is an educational prototype, the student can defend the scope honestly in the viva.
How it works
- HAM10000 images are loaded with their 7-class labels, stratified-split, normalized and augmented with documented transforms (rotation, flip, color jitter).
- EfficientNet-B0 (ImageNet weights) is fine-tuned with a 256-unit dense head, dropout 0.4 and class-weighted cross-entropy to counter the nv majority.
- The held-out split is evaluated once: balanced accuracy, per-class precision/recall/F1, top-2 accuracy and the confusion matrix are generated for the report.
- In the web demo, an uploaded photo is segmented by Otsu thresholding on the brown-pigment channel to isolate the lesion.
- Real ABCD features are computed from the mask: asymmetry by mirror non-overlap, border by 8 − compactness×8, color by distinct quantized clusters, diameter by lesion width fraction.
- The transparent ABCD rule combines them into a triage score with clinical bands; the built-to-order CNN replaces the rule with learned 7-class probabilities.
Tech stack:
- Python 3, TensorFlow/Keras (EfficientNet)
- NumPy, OpenCV, scikit-learn (metrics)
- Jupyter Notebook (training & evaluation)
- HTML5 canvas + JavaScript (live ABCD demo)
- HAM10000 dataset
Dataset & model details
- Dataset: HAM10000 (Tschandl et al., Harvard / Medical University of Vienna) — 10,015 dermatoscopic images across 7 categories: akiec, bcc, bkl, df, mel, nv, vasc. Ground truth from histopathology and expert consensus; the nv (benign nevus) class dominates and is handled with class weights.
- Task: Lesion classification; input = 224×224×3 dermatoscopic image, output = probability distribution over the 7 HAM10000 categories.
- Model: EfficientNet-B0 (ImageNet initialization) → global average pooling → Dense(256, ReLU) → Dropout(0.4) → Dense(7, softmax); class-weighted cross-entropy, fine-tuning schedule documented.
- Metrics: Balanced accuracy ≥ 80% (design target), melanoma recall ≥ 85% (design target), top-2 accuracy reported (evaluated), per-class precision/recall/F1. No metric is claimed as measured until the training run executes for the order.
| Parameter | Value |
|---|---|
| Input format | 224 × 224 × 3 dermatoscopic |
| Classes | 7 (akiec, bcc, bkl, df, mel, nv, vasc) |
| Dataset | HAM10000, 10,015 images, histopathology ground truth |
| Balanced accuracy | ≥ 80% (design target, not a measured claim) |
| Melanoma recall | ≥ 85% (design target) |
| Scope | Educational prototype — not a medical device |
| Demo features | Real ABCD: Otsu segmentation, mirror asymmetry, compactness, color clusters |
| Demo | Single-file web app, runs offline after download |
Project features
- [7-class CNN classifier] EfficientNet-B0 with ImageNet initialization, global pooling, a 256-unit dense head and 7-way softmax over the HAM10000 categories — architecture documented layer by layer.
- [Live ABCD analyzer demo] Upload a lesion close-up; the app segments it by Otsu thresholding on the brown-pigment channel and computes real asymmetry, border, color and diameter from the actual pixels.
- [Transparent ABCD scoring] The clinical scoring rule (score = 1.3·A + 0.1·B + 0.5·C + 0.5·D) applied to the measured features with the published interpretation bands — clearly labeled as the rule, not the CNN.
- [ABCD Lab] Each letter of the dermatology rule explained with the exact computation used, so the viva can walk through asymmetry, border, color and diameter precisely.
- [Full training notebook] HAM10000 loading, augmentation, class-weighted loss, fine-tuning schedule and evaluation in one reproducible Jupyter notebook.
- [Per-class metrics] Precision, recall and F1 for each of the seven categories plus the confusion matrix, so the viva can discuss exactly which lesions confuse the model.
- [Imbalance handling] The nv-majority imbalance addressed with class weights and documented augmentation, with the effect measured and reported.
What is included
- Complete training & evaluation Jupyter notebook on HAM10000
- Fine-tuned EfficientNet model file with preprocessing code
- Live ABCD lesion analyzer + ABCD Lab + System Report web demo
- Confusion matrix, per-class metrics and training-curve plots
- Project report PDF (dermatology background, ABCD rule, transfer-learning rationale, methodology, results, clinical limitations)
- PPT presentation for final review
- Viva Q&A preparation document (transfer learning, class imbalance, ABCD rule, medical-AI limits)
Limitations & prerequisites
- This is an educational prototype, not a medical device: it cannot diagnose, rule out or grade any skin condition. Any real skin concern must be assessed by a qualified dermatologist with dermoscopy and histopathology. The report, demo and page all state this.
- ≥80% balanced accuracy and ≥85% melanoma recall are design targets for the training run, stated honestly — the report documents the actual achieved figures after training.
- The demo's ABCD score is a transparent clinical rule computed from the photo, not the CNN output — the report and demo both say this explicitly.
- HAM10000 is dermatoscopic (magnified, polarized); phone-camera close-ups differ in lighting and scale — the report states this domain gap.
- Rare classes (df, vasc) have few examples; their metrics carry wide uncertainty, reported honestly in the per-class table.
Frequently Asked Questions
What is HAM10000?
A public benchmark from Tschandl et al. (Harvard / Medical University of Vienna): 10,015 dermatoscopic images of pigmented skin lesions across 7 diagnostic categories, with ground truth from histopathology and expert consensus. It is the standard dataset for lesion-classification research.
What is the ABCD rule?
The dermatology triage rule for pigmented lesions: Asymmetry, Border irregularity, Color variegation, Diameter. Each is scored and combined (1.3·A + 0.1·B + 0.5·C + 0.5·D); the demo computes all four from the photo's pixels with the published interpretation bands.
What does the demo's score actually come from?
The transparent ABCD clinical rule applied to real measured features — not from the CNN. The fine-tuned CNN, which ships with the order, outputs learned probabilities over the 7 categories instead.
Why transfer learning?
10,015 images are too few to train a deep CNN from scratch. Starting from ImageNet-pretrained EfficientNet-B0 gives the network proven visual features; fine-tuning adapts them to dermatoscopy with a fraction of the data.
Can this diagnose skin cancer?
No — absolutely not. It is an educational prototype for coursework. The report, the demo and this page all carry the same limitation explicitly.
Is this project suitable for a final-year project?
Yes — for AI/ML, Computer Science and biomedical-oriented programs. It demonstrates transfer learning, classical image analysis, benchmark evaluation and honest medical-AI scoping. Suitable for B.E./B.Tech final-year projects in AI & Machine Learning, Computer Science and Biomedical-related programs.
Components & software requirements
- Python 3, TensorFlow/Keras (EfficientNet)
- NumPy, OpenCV, scikit-learn (metrics)
- Jupyter Notebook (training & evaluation)
- HTML5 canvas + JavaScript (live ABCD demo)
- HAM10000 dataset
Dataset & model details
- Dataset: HAM10000 (Tschandl et al., Harvard / Medical University of Vienna) — 10,015 dermatoscopic images across 7 categories: akiec, bcc, bkl, df, mel, nv, vasc. Ground truth from histopathology and expert consensus; the nv (benign nevus) class dominates and is handled with class weights.
- Task: Lesion classification; input = 224×224×3 dermatoscopic image, output = probability distribution over the 7 HAM10000 categories.
- Model: EfficientNet-B0 (ImageNet initialization) → global average pooling → Dense(256, ReLU) → Dropout(0.4) → Dense(7, softmax); class-weighted cross-entropy, fine-tuning schedule documented.
- Metrics: Balanced accuracy ≥ 80% (design target), melanoma recall ≥ 85% (design target), top-2 accuracy reported (evaluated), per-class precision/recall/F1. No metric is claimed as measured until the training run executes for the order.
Delivery information
Built-to-order project. Delivery timeline is shared after order confirmation based on current queue.
Support terms
Complete documentation, setup guide, and viva preparation included. Support for setup and explanation provided.