The Ugly Duckling Sign in Total Body Photography

In dermatology, the term “ugly duckling” takes on a significant and practical meaning.

Unlike the fairy tale, where the ugly duckling transforms into a beautiful swan, the “ugly duckling” sign in dermatology is a tool used to identify potentially malignant melanomas among a multitude of benign moles. It is based on the observation that most moles on a person's body resemble each other in size, shape, and colour. Hence, an “ugly duckling” mole is one that stands out from the rest. It might be darker, larger, or have a different shape compared to the other moles on the body. This visual discrepancy can be an indicator that the mole is atypical or potentially malignant.

Fig. 1 “Ugly duckling” sign is based on the concept that most normal moles in the body resemble one another, while melanomas stand out like ugly ducklings in comparison.

Total Body Photography

Total body photography (TBP) is a commonly used screening strategy in dermatology that involves capturing high-resolution images of the entire skin surface. This technique allows for comprehensive documentation of all moles and lesions on a patient’s body. TBP is particularly useful for patients with numerous moles or those at high risk of melanoma, providing a detailed visual record that can be used for comparison over time.

When combined with image processing, TBP becomes an even more powerful tool. Advanced algorithms can analyse the images to detect the patient’s moles and quantify their characteristics, which can be used to pinpoint suspicious or potentially malignant moles, or “ugly ducklings”.

Image processing in TBP

Since the entire cohort of a patient’s moles is captured by TBP, this visual record can be used in combination with deep neural networks to automatically detect and evaluate those moles and identify any that appear atypical.

When an image is processed by a neural network, such as a convolutional neural network (CNN), various layers of the network extract different levels of image characteristics. Early layers might detect simple features like edges and textures, while deeper layers capture more complex patterns and structures. After the image passes through these first layers, aka feature extraction layers, the network produces a high-level representation of the image in the form of a vector. This vector, or embedding, contains numerical values that encode the important features of the image, which in this case, contains the mole.

Fig. 2 Mole feature extraction. The image is passed through the feature extraction layers of the lesion classification model to obtain the corresponding embedding.

Embeddings are particularly useful because they allow for easy comparison between images. Similar images will have similar embeddings, meaning the distance between their vectors in the embedding space will be small. We can leverage this property to automatically compare all the patient’s moles. By performing statistical analysis on this dense, low-dimensional vector representations of the moles we can identify which of them deviate significantly from the others in terms of their features. Moles that stand out as different will be considered outliers, or “ugly ducklings” and will be flagged as potentially suspicious, suggesting they may require further medical evaluation.