## 3 Feature Extraction  
The application of the SOM network for clustering requires a data preprocessing phase. To effectively preprocess data, it is important to identify the features which characterize the seismic signals of our interest. Feature extraction allows to remove unnecessary information, reduce the size and provide a compact and robust representation of data. Choosing which features to use to describe the data is fundamental because this can affect the clustering result and therefore the performance of the neural network. Based on the information that experts use to visually recognize seismic signals of interest, we set up a parametrization method that uses the characteristics of the waveform and the spectral content. In particular, we developed a novel ad hoc procedure to extract the features from the signals that allows us to distinguish the seismic fumarolic tremor into two main categories: that with and that without Short Duration Events. First, we split our 20-day dataset (2 days of 2018 and 18 days of 2020) into 1 min signal windows (vertical component of CPIS station sampled at 100 Hz). Then, to remove components at frequencies outside the range of interest, we filtered each 1 min signal segment in the 2-20 Hz frequency band, which contains the signal generated via the  
Figure 2: Seismic signals recorded at Pisciarelli (vertical component of CPIS station) and their spectrograms. (**a**) The signal that was recorded on 1 December 2018 (from 23:00 UTC to 23:01 UTC), shows the presence of Short Duration Events (SDEs). (**b**) Typical signal of fumarolic tremor recorded on 15 November 2018 (from 00:00 UTC to 00:01 UTC). Pisciarelli fumarole-mud pool system [22]. To parameterize the waveform of our signals, we calculated the envelope of each 1 min signal segment (Figure 3a,c). To overcome the possible effects introduced by the random cutting of the 1 min signal segment, we rearranged the obtained values in ascending order (Figure 3b,d). Finally, we downsampled the sorted envelope to reduce the size of the data from 6000 to 18 parameters. The choice of the number of parameters to be used for the envelope representation is empirical and it is aimed at obtaining a good representation of the signal with the minimum number of parameters. We carried out several tests and we found that this number of parameters (18) represents a good compromise between a compact but significant data encoding. To perform the downsampling, we adopted a variable pitch to sample more densely in the inflections of the curves obtained from the sorting of the seismogram envelopes and less densely in the quasi-linear sections (blue dots in Figure 3b,d). The effectiveness of the 18 discrete points to represent the solid line on the plots of Figure 3b,d shows the goodness of this encoding of the waveform envelope. Figure 3e shows the plot of the 18 coefficients for each 1 min signal segment of three hours of signal (180 min from 21:00 UTC to midnight) recorded on 15 November (SDE tremor) and 1 December (typical tremor), 2018. In this plot, the separation between the features obtained from the signals with SDEs and those of the typical fumarolic tremor (without SDEs) is evident for the higher values (in counts) of the tremor with SDEs and lower for the typical fumarolic tremor, and for the shapes of the curves. These observations show that this encoding allows separating the examples belonging to the two different typologies of tremor. To obtain the spectral features we calculated the spectrum of each 1 min segment, then we smoothed it by applying a filter, and finally we downsampled the smoothed spectrum to encode the spectral content into 34 coefficients. As for the waveform envelope, also for the spectral feature representation, the choice of the number of parameters is empirical: after several tests, we found that this number allows for obtaining a good compact and significant encoding. Figure 3: Waveform parameterization.