## 8 Comparative Analysis of Neural Network Architectures and Datasets in Skin Diagnostics
### Comparison of Datasets
The authors deliberately limited themselves to pigmented skin lesions--there are no completely unpigmented lesions or images from the nail or mucosa region in the dataset [43]. Although this makes the data more homogeneous, it translates into narrow clinical heterogeneity, which may make it challenging to apply the models to cases outside this range (e.g., subungual or amelonic melanomas are not represented). Another limitation is incomplete histopathological verification: although more than half of the cases in HAM10000 are confirmed by histopathological examination, for the remaining cases, the \"ground truth\" is based on long-term observation of the lesions, expert consensus, or confocal microscopy rather than biopsy [43]. Finally, like most datasets of this time, HAM10000 does not contain information on the skin phototypes of the patients--the data come from Austria and Australia, which implies a predominance of lighter phototypes and a potential bias towards individuals with darker skin. **BCN20000**. The latest set, published in 2024, contains almost 19,000 dermoscopic images (exactly 18,946 images) from 2010 to 2016, registered at the University Hospital of Barcelona [224]. It includes eight classes of dermatoscopic diagnoses: melanoma, nevus, basal cell carcinoma (BCC), actinic keratosis (AK), squamous cell carcinoma (SCC), benign keratotic lesions (lentigo/seborrhoeic keratosis, BKL), dermatofibroma (DF), and vascular lesions (hemangioma, etc., VASC) [224]. Additionally, a ninth class, OOD, was extracted from the test set for lesions that do not fit into the above categories [224]. As in previous datasets, the balanced accuracy is used in model evaluations as the primary measure of the multiclass classification performance. BCN20000 was designed to address some of the shortcomings of its predecessors--it includes images of lesions in difficult locations (nails, mucosal areas) and lightly pigmented lesions, which were missing in the more cleaned HAM10000-type datasets [224]. However, some limitations remain. The dataset is from a single centre (Spain), so the population and skin type diversity may be limited (as with other datasets, there is a lack of broader representation of dark skin tones). Class imbalance also occurs: although BCN20000 is the largest multiclass dataset (providing the most images for each category), some diagnoses (e.g., dermatofibroma or vascular lesions) are still much less common than, e.g., nevus or BCC. The advantage of BCN20000 is the quality of its annotations: all melanoma and other malignancies are confirmed by histopathology and benign lesions are diagnosed based on histopathology, confocal microscopy, or a consensus opinion from two dermatologists, along with observations of changes over time [224]. This makes the annotations more reliable, reducing the risk of mislabeling. In summary, BCN20000 mitigates some of the biases present in ISIC/HAM (e.g., a wider range of lesion types and locations). However, it does not entirely eliminate the issues of skin bias or class size disparities. Additionally, its homogeneous geographic origin may affect the generalisability of the models. The following Table 6 presents a tabular summary of the key features of these three datasets, along with their corresponding bibliographic sources.