The application discloses a face segmentation model training method and a face image segmentation method. The method comprises the following steps: obtaining a training sample set; the training sample set comprises a plurality of sample images; inputting the training sample set into a face segmentation model for encoding processing and decoding processing to obtain a plurality of predicted images; performing Hungarian matching on at least one to-be-segmented face region marked in the plurality of sample images and at least one predicted face region included in the plurality of predicted images to obtain at least one unmatched face region; determining a global loss value based on the plurality of sample images and the plurality of predicted images; determining a local loss value based on the regions of the at least one unmatched face region in the plurality of sample images and the plurality of predicted images; determining a target loss value based on the global loss value and the local loss value; adjusting the parameters of the face segmentation model based on the target loss value until a preset training condition is reached to obtain a trained face segmentation model.
This invention discloses a self-noise suppression method for ship sonar platforms based on the Transformer model, belonging to the field of underwater acoustic signalprocessing technology. The self-noise suppression method for ship sonar platforms based on the Transformer model includes the following steps: S100, establishing a training dataset for the self-noise suppression model; S200, establishing a ship sonar platform self-noise suppression model based on the Transformer model according to the training dataset. This invention can suppress different frequency band components of ship sonar platform self-noise in signals acquired by the sonar system to varying degrees, effectively improving the signal-to-noise ratio of the acquired signal and effectively enhancing the detection performance and detection range of the sonar system.