Inspiration
Early-stage skin cancer detection is often only a privilege for those with specialized dermatologists with specialized equipment. We were inspired by the potential of explainable AI to improve diagnostics of skin cancer. We did not just want to make a black box model that says "Yes" or "No", we wanted a tool that demonstrates what the AI sees to promote transparency.
What it does
DermaTrace.ai is a transparent diagnostic assistant that classifies skin lesions into 7 distinct categories (including Melanoma, BCC, and Nevi).
It provides the original image, a morphologically cleaned version (hair removed), and a Grad-CAM heatmap.
Unlike standard models that "guess" on every image, DermaTrace features a confidence thresholding system that flags inconclusive results, preventing dangerous false positives.
Optimized to perform across diverse skin tones by testing against biopsy-proven, diverse datasets.
How we built it
We built DermaTrace.ai with the help of ResNet50, fine-tuned on the HAM10000 dataset and further bias-corrected the model on fitzpatrick datasets.
Challenges we ran into
Managing a large environment with pytorch/CUDA was a massive hurdle, making us pivot into a "Privacy First" architecture, where all app data is stored locally.
When we first trained on the HAM10000 dataset, we experienced model overfitting which led us to re-train the whole model several times.
We noticed that the HAM10000 trained model often failed when the images were non-dermoscopic, on the fitzpatrick dataset. This led us to use a dual-pipeline strategy, where one model is used for dermoscopic, medical-grade images, and another is used for normal photos, which can be taken from a smartphone.
Accomplishments that we're proud of
Moving beyond simple black-box architecture to a more sophisticated XAI methodology, with GradCAM to provide heatmaps to explain the "why" behind the AI's decision, helping improve trust among doctors.
Converting the skin samples into "cleaned" images with "no-ruler" and "dullrazor" algorithms has helped us eliminate training biases in the AI, where standard AI may fail by considering the ruler / hair near the lesion, incorrectly categorizing it as cancerous.
We are proud to report that our model has successfully overcome bias on lighter skin tones (when trained on the HAM10000 dataset, and is now more balanced with further training on the fitzpatrick dataset from Monk Skin Tones 1-6 on normal images; though we recognize that the model may not be accurate on darker skin tones (7-10).
What we learned
We learned that models often find the path of least resistance. Without our morphological cleaning, the AI might have learned that "hairy skin" or "surgical markings" were diagnostic features. This taught us that Preprocessing is 50% of the battle.
We discovered that a model’s greatest strength can be its silence. Implementing a Confidence Threshold taught us that in healthcare, "I don't know" is a much safer answer than a forced guess.
Privacy as an Architecture: Dealing with a large size of CUDA dependencies forced us to learn about Local-First deployment. We realized that keeping data on the user’s machine is a superior way to handle sensitive patient information.
What's next for DermaTrace.ai
Bridging the MST 7-10 Gap: Our top priority is sourcing and integrating dermatological data for darker skin tones (Monk Skin Tone 7-10) to ensure the tool is safe and effective for everyone, not just a subset of the population.
We plan on reducing our model-size to make it more accessible and easy to deploy in the future.
Log in or sign up for Devpost to join the conversation.