# Satellite Image Compression Guided by Regions of Interest
## 2 Materials and Methods
### Baseline Algorithm for Vessel Detection  
The world merchant fleet alone counted over 99800 ships of more than 100 gross tons in 2021 [20]. This amount of vessels demands detection, classification, or identification, in satellite images, since carrying an Automatic Identification System (AIS) or Long-Range Identification and Tracking (LRIT) system is not required for vessels weighing less than 300 tons [21]. In addition, fishing vessels do not carry a Vessel Monitoring System (VMS), depending on the region. Furthermore, illegally operating vessels can spoof their mandatory position reports, and as a consequence, the cooperative systems to provide comprehensive MDA can not be considered sufficient.  
An overview of 119 selected publications on vessel detection from optical satellite imagery can be found in [21]. Strategies exploit different features on images to perform the vessel detection, and their effectiveness depends on image resolution and other image properties. In [21], methodologies are classified as: threshold-based, statistical methods, transform domain methods, computer vision methods, deep learning methods, and shape and texture methods, among others.  
The threshold-based algorithm proposed in [12] was used in this study. The algorithm makes use of the constant false alarm rate (CFAR) normalization described in [22] as a part of the change detection algorithm for VHF UWB SAR images. The normalization is carried out to allow finding an appropriate threshold that can be applied globally to give a constant probability of false alarms. The normalized image is produced by centering the filter at each pixel of the image and estimating the mean and standard deviation for the pixels lying within a background window (BG), as illustrated by Figure 4.  
The outer kernel and inner kernel sizes were set to, respectively, 31 by 31 pixels, and 19 by 19 pixels, as in [22]. The pixels of the output CFAR image are computed by  
Figure 3: ForSyDe model for the change detection algorithm using the synchronous model of computation. In (**1**), the tiles are padded to allow the application of the low-pass filter in (**2**). Then, the resulting values of the reference image are subtracted from the values of the surveillance image in (**3**). In (**4**), the absolute values of the pixels are calculated, and in the sequence, one threshold operation is performed (with the value \(\tau_{3}\)) in (**5**). Morphological operations are performed in (**6**).  
\[p_{o}=\frac{p_{c}-mean(\text{BG})}{std(\text{BG})}\, \tag{1}\]  
where \(p_{o}\) and \(p_{c}\) denote the output and central pixel values, respectively.  
The diagram containing all the processing steps of the vessel detection algorithm is shown in Figure 5. As pointed out by Figure 5, the algorithm makes use of the NIR band as input signal (\(I_{NIR}\)), since the reflectance of water in NIR band makes the contrast between vessels and water greater than in the other available bands [23]. First, the padding operation (1) is performed in the input image (tile) to avoid missing detection on the edges, where the amount of padded pixels relies on the size of the CFAR filter window. Then, the CFAR normalization is performed (2), followed by a threshold operation with a value \(\tau_{4}\) (3). Next, similarly to what is done by the change detection algorithm, morphological operations are applied (4) to the binary output with the objective of reducing the false alarms related to single pixels. For the vessel detection algorithm, one operation of erosion, followed by one operation of dilation, are applied. Finally, the tile is labeled as containing vessels if the binary output matrix \(I_{bin}\) contains at least one value equal to one.