MelanoScan: AI Skin Lesion Detector
by MiloszKotlega in Circuits > Raspberry Pi
22 Views, 0 Favorites, 0 Comments
MelanoScan: AI Skin Lesion Detector

MelanoScan is a compact, DIY diagnostic station that uses AI to detect and classify skin lesions such as melanoma, keratosis and nevus using live camera feed.
The point of MelanoScan is to make early detection of potentially dangerous skin changes more accessible and efficient, supporting users at home. Early detection of melanoma and other skin cancers is important for effective treatment and improvement of survival rates.
The project is open and reproducible, making skin health more approchable.
Supplies



- Raspberry PI
- Breadboard
- USB camera (with led light like vor example AVER)
- LCD display
- LED light
- Power supply
- 8mm multiplex plywood
- Laser cutter
Data Collection


Collect images of skin lesions from open databases like ISIC (https://gallery.isic-archive.com/#!/topWithHeader/onlyHeaderTop/gallery?filter=%5B%5D).
Ensure each image is labeled.
You can use tools like Roboflow to organize, annotate and split your dataset into training, validation and test set.
Export dataset in YOLO format.
Model Training

Train on your computer.
Install required libraries like ultralytics, numpy and opencv-python.
Train YOLOv8 model using the prepared dataset.
Monitor metrics like accuracy, mAP during training to ensure the model is learning well.
Save the best trained model weights (e.g. best.pt)
Or use Roboflow model.
Coding
I wrote a Python code to:
- Capture frames from the webcam
- Run trained YOLO model on each frame to detect and classify lesions
- Overlay color coded boundingboxes with their classes name
I used libraries like OpenCV for capturing and displaying images and Ultralytics for running YOLO models.