# Self-Training Can Reduce Detection False Alarm Rate of High-Resolution Imaging Sonar +
## 3 Materials and Methods
### Training Strategy for Detector Based on Divided Classification Datasets  
In the field of image recognition, detection tasks are often considered more complex than classification tasks, which not only require discriminating the target but also localizing it. To enable the detection model to learn the features of various targets and backgrounds better, thereby reducing the false alarm rate of the detector on real-world data, this paper sets the proxy task as a classification task. This is because classification tasks are relatively simpler compared to detection tasks, and in classification tasks, the background can be separately categorized as a class, allowing the deep learning network to better learn the feature differences between the background and different targets. To avoid introducing new external datasets and ensure that the training of the classification task is a self-training process, datasets used to train the classification task will be derived from the detection datasets. The training strategy for such a sonar image target detector based on classification proxy tasks is shown in Figure 3.  
The training strategy for a deep learning object detector based on proxy classification tasks mainly consists of the following three steps:  
Figure 3: The training strategy of Detectors based on proxy classification tasks. Figure 2: Comparison diagram of this paper’s training framework and traditional training frameworks. To ensure the validity of the detector's testing, the sonar images in the training and validation sets of the derived dataset both come from the training set portion of the detection dataset. There is no fixed standard ratio for splitting the training set and validation set. However, in deep learning, the training set typically accounts for 60% to 80% of the dataset. A larger training set can help the model better learn the features and patterns of the data. Considering that the proxy task is set up to better learn the target features, when dividing the derived dataset for proxy task training, we set the proportion of the training set to 80%.The training and validation sets of the derived dataset are used for the training and validation of the backbone network, which ensures that when using the derived classification dataset for self-training of the backbone network, the weights of the backbone network are learned directly from the samples in the detection dataset. In addition, if testing of the proxy task is needed, the validation set of the detection dataset can be used as the test set for the classification task. 2. Pre-train the backbone network of the deep learning detector using the proxy classification task. A deep learning model typically consists of many layers, each with its own function and task. In deep learning, models are usually divided into three parts: the backbone, the neck, and the head. The backbone is the main component of the model, responsible for extracting features from the input image for subsequent processing and analysis. The neck is the intermediate layer connecting the backbone and the head. The main role of the neck is to reduce the dimensionality or adjust the features coming from the backbone to better suit the task requirements. The head is the final layer of the model, which takes as input the features processed by the neck. The structure of the head varies depending on the task; for object detection tasks, it is typically a bounding box regressor and a classifier. Therefore, the backbone network parameters obtained from the proxy task can be used to train the detector, allowing it to inherit the object features learned during the proxy task. Load the pre-trained model of the detector, replace the parameters of the backbone network with those from the backbone network of the classification network trained in the proxy task, and freeze the parameters of a certain number of layers in the backbone network. 3. Fine-tune the detector. Fine-tune the weights of the detector on the detection dataset to ultimately train a detector with a lower false alarm rate.