The application which can detect
skin cancer


Ml5.js is a library which provide access to machine learning algorithms and models in the browser.
MobileNets are a class of convolutional neural network which are trained to recognize images.

With the deep learning we can teach to an artificial intelligence to recognize images.
We give to a computer many images, like cat's images, but with different cat in each image : different colors, different postures, different races, different sizes.

With all those images, the artificial intelligence (AI) will learn and keep those images in its image database.

With an algorithm, the AI will try to recognize another image that we gave to it.
The AI will try to compare the image with all of the images which are on its image database.



Oystercatcher MobileNet Cat
As you can see on these images, MobileNet tell you what the AI recognize and also the pourcent of confidence.






To better understand how the AI can recognize and tell what is on the image, I invit you to watch this video on a conference of TED
"How computers learn to recognize objects instantly"





TO BEGIN :

You need to set up ml5.js and MobileNet to classify an image, there is a code to help you

code




MobileNet can recognize images in two ways :




As I explain to you before with mlc.5 and with MobileNet, the AI can recognize an image based on a image database.
But to recognize it, the AI need to learn many images of different things in order to recognize an object in a picture.



If you want to document you, here is an article which explain you more
how you can create image classifier with MobileNet :


FIRST :


You need to teach to the AI many different images of what you want it to recognize.
Therefore, for an application which can detect skin cancer, you need to teach to the AI many images of normal moles and of melanoma.




NORMAL MOLES :

  • Common small brown spots or growths on the skin
  • Appear il the first few decades of life
  • On the skin of almost everyone
  • Can be either flat or elevated
  • Are generally round and regulary shaped
  • Many are caused by sun exposure
MELANOMA :

  • One of the deadliest form of skin cancer
  • Appears as an asymmetrica, irregularly bordered, multicolored or tan/brown spot
  • Or as a growth that continues to increase in size over time

molemelanome

The ABCDE system tells you some of the things to look out for.
A melanoma may show one or more of the ABCDE system.



To have a good and interesant image database, I advise you to ask dermatologists because it will be difficult
to find good pictures of all mole and melanoma on the internet.

You will need to find many pictures so that the AI could learn all the possibilty based on the ABCDE system.

When you have all the image you need, you will have to insert those images.


I advise you to watch this video to understand how to get your own image database :





WHEN YOU HAVE CREATED YOUR OWN IMAGE DATABASE :


You will have that result when you will use MobileNet :

mole Melanoma

As you can see, for the melanoma the AI is 95,76% sure and for the normal mole the AI is not really sure with a confidence of 40,68%. Therefore, to have efficient results you really need to upload many different pictures of mole and melanoma on your image database.

THE MORE YOU TRAIN THE AI, THE MORE PRECISE IT WILL BE.



THEN YOU NEED TO ADD THE LIVE VIDEO IN THE CLASSIFIER :


With the live video, the AI will be able to recognize an object or something else when you will be filming.
There is a code that you can use to add the live video :


code

code


When you add the live video you can show to the camera one of your mole
and the AI will recognize it and tell you if it is a mole or a melanoma :


Oystercatcher





Well Done !









This application would be very useful because if it is marketed as an application
that can be on a phone, users can take a picture of their moles
to find out if they are melanoma or not.


The results may even be better than dermatologists’ results.


However, if we really want the best possible results,
I think it would be better to use a more performant open-source software like ImageJ.


This is an article which explain ImageJ,
an open-software for Biomedical Image Analysis :