## 2 Materials and Methods
### Methods  
To provide an overview of the methodological approach, Figure 4 illustrates the complete processing pipeline adopted in the development of this study. The workflow consists of five sequential stages, beginning with the input image and progressing through preprocessing, data augmentation, model training using CNNs, fine-tuning and classification, and concluding with model explainability through Grad-CAM. This study evaluates three well-established convolutional neural network (CNN) architectures (VGG16, VGG19 and MobileNetV2) for medical imaging classification tasks. These models were chosen for their proven effectiveness in extracting critical visual features, their computational efficiency and their balance between performance and resource demands [17]. Additionally, their compatibility with model explainability techniques was considered an advantage. The VGG-16 and VGG-19 models are part of the VGGNet family, developed by [PERSON] and [PERSON] in 2015 [45]. Both architectures are characterised by their use of small 3 \(\times\) 3 convolutional filters and a deep stack of layers, which promotes a hierarchical and detailed extraction of visual features. The architecture was designed to increase the depth of the network without significantly increasing the number of parameters, and its success lies in the efficient use of convolutional layers followed by pooling to capture progressively more abstract features. VGG-16 is made up of 16 trainable layers, including 13 convolutional layers organised into five blocks, interspersed with MaxPooling layers, which progressively reduce the spatial dimensions of the representations. The last layers are made up of two dense layers with 4096 units each, followed by an output layer with the softmax activation function. This architecture is widely used in image classification tasks due to its simplicity and effectiveness. On the other hand, VGG-19 adds three extra convolutional layers, totalling 19 trainable layers, which increases the network's ability to capture finer details in complex images. This architecture also maintains the organisation into convolution and pooling blocks, but the extra depth makes it even more suitable for tasks where visual details are critical, such as the case of classifying diabetic foot ulcers. Despite their effectiveness, both models have a relatively high number of parameters, with approximately 138 million parameters in VGG16 and 143 million in VGG19. This high complexity makes it necessary to use regularisation techniques to mitigate the risk of overfitting, especially with smaller datasets. Figure 5 illustrates the structural differences between VGG16 and VGG19, highlighting the additional convolutional layers in VGG19 and the identical configuration of the dense layers, in later stages, used for classification. The MobileNetV2 architecture, on the other hand, was designed with low/medium resourced devices in mind. By using a set of blocks with depthwise separable convolutions, which includes deep convolution and point-by-point convolution, it seeks to minimise the number of convolution operations by around 1/9 th when compared with standard convolutions. This innovation also allows one to reduce memory usage while maintaining a good accuracy of the model. This approach processes the image into a compact, low-dimensional representation, which is then expanded to a higher dimensionality and  
Figure 4: Development pipeline for DFU classification and explainability. convoluted in a lightweight manner, followed by a projection to a low dimension. MobileNetV2 is composed of two blocks, one with stride = [1 1] and another with stride = [2 2], which downsizes the input. This structural efficiency makes this network a popular option for implementation on devices with limited resources while maintaining good performance, as described by [PERSON] et al. (2018) [46]. Figure 6 illustrates the MobileNetV2 architecture and its building blocks, highlighting its key components.