## 2 Materials and Methods
### Classification Task
#### 2.3.2 HSI1 and HSI2 Classification  
Deep learning models were used to classify HSI1 and HSI2, as they are able to learn nonlinear features of hyperspectral data compared to traditional machine learning algorithms [50; 51; 52]. The classification of the PRISMA image was performed using a convolutional neural network (CNN) model with a structure that has been shown to be particularly suitable for land cover studies [53; 54; 55].  
Specifically, the classification procedure used the plugin AVHYAS in the open-source software Qgis 3.14. The AVHYAS plugin proposes various models of CNN; in this study, the model proposed by [PERSON] et al. was chosen for its good results working with hyperspectral data [53; 56]. It consists of five layers: the first layer represents the pixel spectral vector; followed by a convolutional layer; the max pooling layer; the fully connected layer; and the output layer.  
\begin{table}
\begin{tabular}{c c} \hline \hline
**Species** & **GTPs** \\ \hline _Pinus pinea_ & 424 \\ _Tilia \(\times\) europaea_ & 310 \\ _Platanus \(\times\) accerifolia_ & 103 \\ _Quercus lex_ & 51 \\ _Eucalyptus_ spp. & 50 \\ \hline Total & 938 \\ \hline \hline \end{tabular}
\end{table}
Table 1: This table contains the number of GTPs within the ROI used as reference data for the classification task.  
The GT points were divided into three groups with different percentages. Thirty percent of the 938 points were reserved for the final classification test and separated from the remaining 70%, which was further divided into 70% for CNN training and 30% for model validation. The random selection of points for each of the three groups was repeated in a five-fold process assigning points to the training, validation and testing phases for both HSI1 and HSI2, corresponding to ten separate classification trials. The experimentation phase was conducted in successive iterations, where, under the same conditions, different points were selected for the training, validation, and test groups, alternating the two input HSIs.  
In AVHYAS, the learning rate and the number of epochs were the only parameters that were changed during CNN tuning, while the other parameters were left at their default settings. Choosing the learning rate is important because if it is too small, it can slow down the process of adjusting the network weights to find the best solution, and there is a risk of ending up in a local minimum with a non-ideal solution. Conversely, if the learning rate is too high, a search for the minimum gradient that reduces the error rate may skip the ideal solution. An ideal learning rate of 0.001 was chosen, which is one of the most widely used values in the literature [57], based on the accuracy of the obtained results. The number of epochs was set to 200, which was empirically found to be an optimal number based on the accuracy achieved during validation. However, this number sometimes turned out to be lower due to an automatic arrest of the process to avoid overfitting the data. Both HSI1 and HSI2 images were classified using the same set of GTPs in each trial.  
The quality of the classification was evaluated using some of the most common accuracy metrics: Overall Accuracy (OA), Kappa Coefficient (K), User Accuracy (UA), and Producer Accuracy (PA) [58]. Additionally, the F1 score (F1) was calculated, which is a metric derived from the harmonic mean between UA and PA and is more suitable in the case of an unbalanced label dataset among the various classes [59; 60].