# YOLO-PWSL-Enhanced Robotic Fish: An Integrated Object Detection System for Underwater Monitoring
## 2 Materials and Methods
### Yolo-Pwsl
#### 2.3.4 PConv Module  
(1) Conv  
The conventional convolution operation is a basic operation in convolutional neural networks. The basic principle is to apply one or more convolutional kernels to the input image or feature map to perform a sliding-window operation to extract local features. As shown in Figure 8, assume that the input layer is a 3-channel color image. After passing through a convolution layer containing 4 filters, the final output is 4 feature maps with the same dimensions as the input layer. At this point, the convolution layer has a total of 4 filters, each filter contains 3 kernels, and each kernel is 3 \(\times\) 3 in size. Therefore, the number of parameters in the convolution layer is 108. At each position, the convolution kernel performs an element-by-element multiplication and summation operation with the local region of the input. For each output channel, a separate convolution kernel is used to perform a convolution operation with the corresponding regions of all the input channels to obtain an output channel. In conventional convolution, each convolution kernel is convolved with each local region across all input channels, making the convolution operation computationally intensive.  
(2) DWConv consists of two parts: deep convolution and point-by-point convolution (Figure 9). Similarly, when inputting a 3-channel color image, perform channel-wise convolution first. Three single-channel convolution kernels perform convolution calculations separately, outputting three single-channel feature maps. Therefore, the final output consists of three feature maps. One filter contains only a single 3 \(\times\) 3 kernel; so, the number of parameters in the convolution layer is 27. Next, perform pointwise convolution using four 1 \(\times\) 1 \(\times\) 3 convolution kernels to convolve the feature maps obtained in the previous step, producing four new feature maps. Thus, the number of parameters in the convolution layer is 12. Therefore, the total number of parameters is 39. Deep convolution means that a separate convolution kernel is used for the convolution operation for each input channel,  
Figure 8: Conv structure.  
instead of using the same convolution kernel for all input channels. This significantly reduces the number of parameters in the convolution operation. Point-by-point convolution is a \(1\times 1\) convolution kernel that performs a convolution operation on the feature map after deep convolution and is usually used to combine different types of channel information, thus increasing the number of output channels. It is used to linearly combine the feature maps of the individual channels generated by the deep convolution.  
3. PConv:  
The core idea of PConv is to perform better restoration by considering only valid pixel regions in a convolution operation and ignoring invalid regions (e.g., missing parts of images) [42]. In a standard convolution operation, the convolution kernel processes the entire input region, regardless of which regions are valid, and which are missing. In contrast, the convolution operation of PConv distinguishes between valid and missing pixels by introducing a mask. When convolution is performed, only the valid portion of the mask is used to compute the convolutional output. Therefore, the convolution kernel of PConv only weighs and sums the valid pixel regions, and the missing regions do not affect the convolution result.