DermaLens Skin Cancer Classification Model
A Deep Learning-based Skin Lesion Classification Model trained on the HAM10000 dataset using TensorFlow and Keras.
Overview
DermaLens is a Convolutional Neural Network (CNN) developed for automated skin lesion classification. The model analyzes dermoscopic skin images and predicts the most likely lesion category among seven classes from the HAM10000 dataset.
This project demonstrates the application of Deep Learning and Computer Vision techniques in healthcare and skin cancer screening research.
Model Information
| Property | Value |
|---|---|
| Model Name | DermaLens Skin Cancer Classification Model |
| Author | Mitanshu Makwana |
| Framework | TensorFlow / Keras |
| Model Format | .h5 |
| Model File | skin_cancer_cnn.h5 |
| Model Size | 533 MB |
| Dataset | HAM10000 |
| Number of Classes | 7 |
| Task | Multi-Class Image Classification |
| Accuracy | ~83% |
Dataset
The model was trained using the HAM10000 (Human Against Machine with 10,000 Training Images) dataset.
Dataset Statistics
- 10,000+ dermoscopic images
- 7 skin lesion categories
- Medical imaging benchmark dataset
- Widely used in dermatology AI research
Supported Classes
| Class Label | Disease Type |
|---|---|
akiec | Actinic Keratoses and Intraepithelial Carcinoma |
bcc | Basal Cell Carcinoma |
bkl | Benign Keratosis-like Lesions |
df | Dermatofibroma |
mel | Melanoma |
nv | Melanocytic Nevi |
vasc | Vascular Lesions |
Model Architecture
The model is based on a Convolutional Neural Network (CNN) architecture consisting of:
- Convolution Layers
- ReLU Activation Functions
- Max Pooling Layers
- Batch Normalization
- Dropout Layers
- Dense Fully Connected Layers
- Softmax Output Layer
Image Preprocessing
Before inference, images undergo:
- Image Resizing
- Pixel Normalization
- Batch Dimension Expansion
Training Configuration
| Parameter | Value |
|---|---|
| Framework | TensorFlow / Keras |
| Optimizer | Adam |
| Loss Function | Categorical Crossentropy |
| Evaluation Metric | Accuracy |
| Classification Type | Multi-Class |
Performance
Evaluation Results
| Metric | Score |
|---|---|
| Accuracy | ~83% |
| Classes | 7 |
Actual performance may vary depending on image quality, preprocessing pipeline, acquisition device, and dataset distribution.
Usage
Installation
pip install tensorflow numpy pillow
Load Model
from tensorflow.keras.models import load_model
model = load_model("skin_cancer_cnn.h5")
Prediction Example
import numpy as np
from tensorflow.keras.preprocessing import image
from tensorflow.keras.models import load_model
model = load_model("skin_cancer_cnn.h5")
img = image.load_img("sample.jpg", target_size=(224, 224))
img = image.img_to_array(img)
img = np.expand_dims(img, axis=0)
img = img / 255.0
prediction = model.predict(img)
predicted_class = np.argmax(prediction)
print("Predicted Class:", predicted_class)
Intended Use
Suitable For
- Educational Projects
- Research Experiments
- Computer Vision Learning
- Medical AI Demonstrations
- Academic Applications
Not Suitable For
- Clinical Diagnosis
- Patient Treatment Decisions
- Emergency Healthcare Applications
- Real-World Medical Deployment
Limitations
- Trained exclusively on the HAM10000 dataset.
- Performance may degrade on images from unseen sources.
- Sensitive to image quality and preprocessing.
- Dataset imbalance may affect minority-class predictions.
- Not validated in clinical environments.
Ethical Considerations
This model is intended solely for educational and research purposes.
Predictions generated by this model should not be interpreted as medical advice, diagnosis, or treatment recommendations.
Users should always consult qualified healthcare professionals for any medical concerns.
Citation
If you use this model in your research or projects, please cite:
@misc{dermalens2026,
title={DermaLens: Skin Cancer Classification using Deep Learning},
author={Mitanshu Makwana},
year={2026},
publisher={Hugging Face}
}
Contact
Author: Mitanshu Makwana
Project: DermaLens – Skin Cancer Detection System
Hugging Face: Mitanshu10/dermalens-skin-cancer-model
Disclaimer
⚠️ This model is not FDA-approved, CE-certified, or clinically validated.
It is provided strictly for research, educational, and demonstration purposes and must not be used as a substitute for professional medical diagnosis.