Foggy day illegal sand dredger identification method and system based on deep learning

By improving the combination of the generative adversarial network and the YOLOv8 network, the problem of difficulty in identifying illegal sand mining ships in foggy environments is solved, real-time and efficient identification of ships in foggy waters is achieved, and monitoring accuracy and regulatory enforcement level are improved.

CN119169500AInactive Publication Date: 2024-12-20NANJING FOREST POLICE COLLEGE

Patent Information

Application Number
CN202411191708.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-28
Publication Date
2024-12-20
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

Illegal sand mining ships are difficult to identify in foggy environments, and traditional methods have low recognition accuracy and cannot meet the monitoring speed and accuracy requirements.

Method used

Using a deep learning-based method, image defog processing is performed by improving the generative adversarial network, combined with improved YOLOv8 network for ship identification, fog is removed and Improve recognition accuracy.

Benefits of technology

Real-time and efficient identification of ships in foggy waters has been achieved, the accuracy of monitoring and supervision and law enforcement of illegal sand mining has been improved, and the accuracy and speed of detection have been improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119169500A_ABST
    Figure CN119169500A_ABST
Patent Text Reader

Abstract

The invention discloses a foggy day illegal sand dredger identification method and system based on deep learning, and the method comprises the steps: building an image defogging algorithm based on an improved generative adversarial network, and training the image defogging algorithm based on the improved generative adversarial network through constructing a data set; and establishing a ship identification algorithm based on the improved YOLOv8 network, and training the ship identification algorithm based on the improved YOLOv8 network through the data set. Removing fog on a to-be-identified foggy day sand excavation ship photo through a trained image defogging algorithm based on an improved generative adversarial network to obtain a defogged sand excavation ship photo; and through a trained ship identification algorithm based on an improved YOLOv8 network, identifying the demisted sand excavation ship photo to obtain an illegal sand excavation ship. According to the invention, real-time, automatic and accurate identification of the illegal sand dredger under the foggy weather condition is realized, and the problems that the traditional method is not suitable for the foggy weather, the identification is difficult, the monitoring efficiency is low, the precision is poor and the like are solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of artificial intelligence technology, and in particular relates to a method and system for identifying illegal sand mining vessels in foggy weather based on deep learning. Background Art

[0002] With the advancement of urbanization, the demand for sand and gravel as the main raw materials for construction has increased dramatically. Illegal sand mining has low costs and large profit margins. The phenomenon of illegal sand mining is becoming increasingly rampant, seriously affecting the stability of the river, endangering flood control, water supply, shipping and infrastructure safety, and harming the ecological environment. At present, underwater voiceprint listeners and thermal infrared cameras are usually used to establish underwater and above-water three-dimensional monitoring networks for the detection of illegal sand mining vessels in waters. Voiceprint and thermal infrared imaging technology are used to monitor and identify the characteristics of sand mining vessels' engines, propellers, sand suction pipes, audio, and appearance, thereby realizing the monitoring and early warning management of illegal sand mining vessels. However, the equipment required for such traditional methods is expensive, difficult to use on a large scale, and prone to missed detection and wrong detection, and cannot meet the requirements for monitoring speed and accuracy.

[0003] The rapid development of computer vision has brought new ideas to the governance of illegal sand mining. By detecting target ships in surveillance videos, determining the location of ships and effectively identifying them, illegal sand mining can be precisely cracked down. However, haze weather is frequent in the Yangtze River Basin, making it difficult to identify illegal sand mining ships. Therefore, it is necessary to first remove the fog in the images collected in foggy environments in a targeted manner, and then identify illegal sand mining ships in real time and efficiently. Summary of the invention

[0004] Purpose of the invention: To address the problem of difficulty in identifying illegal sand mining vessels in foggy weather and low recognition accuracy, the present invention provides a method for identifying illegal sand mining vessels in foggy weather based on deep learning.

[0005] Technical solution: To achieve the above purpose, the technical solution adopted by the present invention is:

[0006] A method for identifying illegal sand mining vessels in foggy weather based on deep learning, comprising the following steps:

[0007] Step S10: Collect photos of illegal sand mining vessels and ordinary vessels on foggy and non-foggy days, annotate them, and construct a data set.

[0008] Step S20: Establish an image defogging algorithm based on an improved generative adversarial network, train the image defogging algorithm based on the improved generative adversarial network through a data set, and obtain a trained image defogging algorithm based on the improved generative adversarial network.

[0009] Step S30: Establish a ship identification algorithm based on the improved YOLOv8 network, train the ship identification algorithm based on the improved YOLOv8 network through the data set, and obtain a trained ship identification algorithm based on the improved YOLOv8 network.

[0010] Step S40: Collect photos of ships in foggy waters to be identified, remove fog from the photos of ships in foggy waters using a trained image defogging algorithm based on an improved generative adversarial network, and obtain photos of ships in the waters after defogging. Use a trained ship identification algorithm based on an improved YOLOv8 network to identify the photos of ships in the waters after defogging, and identify illegal sand mining ships.

[0011] Preferably: the improved generative adversarial network includes a generator integrating feature attention mechanism, a discriminator based on spectral normalization, and a perceptual cycle consistency loss function, wherein the generator integrating feature attention mechanism is divided into a generator-G and a generator-F, wherein the generator-G is used to convert a foggy image into a fog-free image, and the generator-F is used to convert a fog-free image into a foggy image, wherein a spectral normalization operation is added to the discriminator, and the discriminator is divided into a discriminator-D a and discriminator D b , the discriminator D a The discriminator D is used to determine whether the foggy image generated by the generator F is a real image or a generated image. b It is used to determine whether the fog-free image generated by the generator G is a real image or a generated image. The perceptual cycle consistency loss function extracts features between the real image and the generated image from the VGG19 network, calculates the cycle loss and the perceptual loss, and ensures the structural consistency between the generated image and the original image.

[0012] Preferably: the generator of the fusion feature attention mechanism includes an encoder, a feature attention module, and a decoder. The encoder includes the first convolution layer 1, the first ReLU activation layer 1, the first convolution layer 2, the first average pooling layer 1, the first ReLU activation layer 2, and the first convolution layer 3 connected in sequence. The feature attention module includes the second convolution layer 1, the second ReLU activation layer 1, the second element summation module 1, the second convolution layer 2, the channel attention submodule, the pixel attention submodule, and the second element summation module 2 connected in sequence. The output of the first convolution layer 3 is connected to the input of the second element summation module 1, and the output of the first convolution layer 3 is connected to the input of the second element summation module 2. The channel attention submodule includes the third average pooling layer 1, the third convolution layer 1, the third ReLU activation layer 1, the third convolution layer 2, the third Sigmod activation function 1, and the third element product module 1 connected in sequence, and the output of the second convolution layer 2 is connected to the input of the third element product module 1. The pixel attention submodule includes a fourth convolutional layer 1, a fourth ReLU activation layer 1, a fourth convolutional layer 2, a fourth Sigmod activation function 2, and a fourth element product module 1 which are connected in sequence.

[0013] The decoder includes a fifth convolutional layer one, a fifth convolutional layer two, and a fifth convolutional layer three which are connected in sequence.

[0014] Preferred: Perceptual cycle consistency loss function is:

[0015]

[0016] Among them, L GAN represents the total loss, the mapping function G:A->B, A represents the foggy image dataset, B represents the fog-free image dataset, a is the image in set A, b is the image in set B, a~p(a) represents the data distribution of foggy images, b~p(b) represents the data distribution of fog-free images, E b~p(b) represents the expectation of a haze-free image, E a~p(a) represents the expectation of the foggy image, D b (·) represents the discriminator D b The output of G(·) represents the haze-free image generated by the generator G, and the mapping function F: B->A, D a (·) represents the discriminator D a The output of F(·) represents the foggy image generated by generator 2 F. represents the cycle image, c represents the original image, ||·|| L1 represents the L1 norm between the original image and the cycle image, φ(·) represents the feature extractor of the second and fifth pooling layers of VGG16, ||·||2 represents the L2 norm between the original image and the cycle image, α represents the adversarial loss hyperparameter, and β represents the cycle consistency loss hyperparameter.

[0017] Preferably: the discriminator includes the sixth convolutional layer one, the sixth spectral normalization layer one, the sixth ReLU activation layer one, the sixth convolutional layer two, the sixth spectral normalization layer two, the sixth ReLU activation layer two, the sixth convolutional layer three, the sixth spectral normalization layer three, the sixth ReLU activation layer three, the sixth convolutional layer four, the sixth spectral normalization layer four, the sixth ReLU activation layer four, the sixth average pooling layer one, the sixth spectral normalization layer five, and the sixth Sigmod activation function one, which are connected in sequence.

[0018] Preferred: The channel attention submodule first uses global average pooling to encapsulate the global spatial information of the channel dimension into a channel descriptor. The formula of global average pooling is as follows:

[0019]

[0020] Among them, f c Indicates the channel descriptor, H indicates the height, W indicates the width, X c (i,j) represents the value of the c-th channel at position (i,j).

[0021] Secondly, the channel features are processed through two convolutional layers and connected to the Sigmoid function after the ReLU activation layer to obtain the channel attention weight, the formula is as follows:

[0022] CA=σ(Conv(δ(Conv(f c ))).

[0023] Among them, CA represents the channel attention weight, σ is the Sigmod function, δ is the ReLU function, and Conv represents the convolution result.

[0024] Finally, enter F c Multiply element-wise with the channel attention weight, and the formula is as follows:

[0025]

[0026] in, is the output of the channel attention submodule, Represents element-wise multiplication.

[0027] The pixel attention submodule feeds the output of the channel attention submodule into two convolutional layers and uses the ReLU and Sigmoid activation functions. The formula is as follows:

[0028]

[0029] Among them, PA represents pixel attention weight, σ is the Sigmod function, δ is the ReLU function, and Conv represents the convolution result.

[0030] Enter Perform element-wise multiplication with PA to obtain the output of the pixel attention submodule The formula is as follows:

[0031]

[0032] in, represents the output of the pixel attention submodule, represents the output of the channel attention submodule, PA represents the pixel attention weight, Represents element-wise multiplication.

[0033] The Lipschitz constraint for spectral normalization is:

[0034] ||D(x)-D(y)||≤K*||xy||;

[0035] Where D is the discriminator, x and y are any two points in the image space, ||*|| is the 2-norm, and K is the Lipschitz constant.

[0036] Perform singular value decomposition on the parameter matrix W of each layer of the neural network of the discriminator to satisfy 1-Lipschitz, and divide it by the maximum singular value of W every time the weight is updated.

[0037]

[0038] in, represents the parameter matrix that satisfies 1-Lipschitz, W represents the parameter matrix, and σ(W) represents the maximum singular value of the parameter matrix.

[0039] Preferably: the improved YOLOv8 network includes a feature extraction backbone network, a feature splicing enhancement network and a head network, wherein the feature extraction backbone network includes the first CBS layer one, the first CBS layer two, the first C2f layer one, the first CBS layer three, the first C2f layer two, the first CBS layer four, the first C2f layer three, the first CBS layer five, the first C2f layer four, and the first SPPF layer one connected in sequence. The feature splicing enhancement network includes the second UpSample layer 1, the second Concat layer 1, the second C2f layer 1, the second UpSample layer 2, the second Concat layer 2, the second C2f layer 2, the second attention mechanism module, the second CBS layer 1, the second Concat layer 3, the second C2f layer 3, the second CBS layer 2, the second Concat layer 4, and the second C2f layer 4, which are connected in sequence. The output of the first C2f layer 2 is connected to the input of the second Concat layer 2, the output of the first C2f layer 3 is connected to the input of the second Concat layer 1, the output of the first SPPF layer 1 is respectively connected to the input of the second UpSample layer 1 and the second Concat layer 4, and the output of the second C2f layer 1 is connected to the input of the second Concat layer 3. The outputs of the second C2f layer 2, the second C2f layer 3, and the second C2f layer 4 are respectively connected to the input of the head network.

[0040] Preferred: The calculation formulas for channel attention and spatial attention are:

[0041] M c (F)=σ(MLP(AvgPool(F))+MLP(MaxPool(F)));

[0042] M s (F) = σ(f 7*7 ([AvgPool(F);MaxPool(F)]));

[0043] Among them, M c (F) represents the output of the channel attention module, M s (F) represents the output of the spatial attention module, σ represents the Sigmod activation function, MLP represents the multi-layer perceptron, AvgPool represents the average pooling layer, F represents the input feature map, and f 7*7 represents a 7×7 convolution, MaxPool represents the maximum pooling layer, and [AvgPool(F); MaxPool(F)] means concatenating the results of average pooling and maximum pooling along the channel axis.

[0044] Another object of the present invention is to provide a system for identifying illegal sand mining vessels in foggy weather based on deep learning, which is used to implement the method for identifying illegal sand mining vessels in foggy weather based on deep learning, including an input unit, an improved generative adversarial network unit, an improved YOLOv8 network unit and an output unit, wherein:

[0045] The input unit is used to input photos of ships in foggy waters to be identified.

[0046] The improved generative adversarial network-based unit is used to remove fog on photos of ships in foggy waters through a trained improved generative adversarial network-based image defogging algorithm to obtain photos of ships in foggy waters after defogging.

[0047] The improved YOLOv8 network unit is used to identify photos of ships in the water area after defogging through a trained ship recognition algorithm based on the improved YOLOv8 network, and identify illegal sand mining ships.

[0048] The output unit is used to output illegal sand mining vessels.

[0049] Another object of the present invention is to provide a computer system, comprising a memory and a processor, wherein the memory is used to store a computer program / instruction. The processor is used to execute the computer program / instruction to implement the method for identifying illegal sand mining vessels in foggy weather based on deep learning.

[0050] Compared with the prior art, the present invention has the following beneficial effects:

[0051] In the image preprocessing stage, an image defogging algorithm based on an improved generative adversarial network is proposed to mine the features of foggy images, reduce image noise and achieve defogging. For the clear images after defogging, the YOLOv8 algorithm integrated with the CBAM mechanism is used to efficiently identify illegal sand mining vessels, so as to achieve real-time and accurate monitoring of illegal sand mining activities. BRIEF DESCRIPTION OF THE DRAWINGS

[0052] Figure 1 A processing flow chart of a method for identifying illegal sand mining vessels in foggy weather based on deep learning provided by an embodiment of the present invention;

[0053] Figure 2 An improved image defogging algorithm network framework provided by an embodiment of the present invention;

[0054] Figure 3 An improved generator structure provided by an embodiment of the present invention;

[0055] Figure 4 An improved discriminator structure provided by an embodiment of the present invention;

[0056] Figure 5A diagram of the YOLOv8 network structure integrating CBAM provided in an embodiment of the present invention;

[0057] Figure 6 This is a comparison chart of the defogging effects of various algorithms provided in the embodiments of the present invention, where Figure 6 (a) is a foggy image. Figure 6 (b) is the dehazing effect of Cycle GAN. Figure 6 (c) is the dehazing effect of GC-GAN. Figure 6 (d) is the defogging effect of the present invention;

[0058] Figure 7 This is a rendering of the illegal sand mining vessel identification effect for scenario 1 according to an embodiment of the present invention. Figure 7 (a) is a foggy image of scene 1 according to the present invention; Figure 7 (b) is a rendering of the present invention for identifying illegal sand mining vessels in scenario 1, wherein sand stealing boats represent sand stealing boats;

[0059] Figure 8 This is a rendering of the illegal sand mining vessel identification effect for scenario 1 according to an embodiment of the present invention. Figure 8 (a) is a foggy image of scene 2 according to the present invention; Figure 8 (b) is a rendering of the illegal sand mining vessel identification for scenario 2 of the present invention, where sand stealing boats represent sand stealing boats and ordinary boats represent ordinary boats;

[0060] Fig. 9 This is a rendering of the illegal sand mining vessel identification effect for scenario 1 according to an embodiment of the present invention. Fig. 9 (a) is a foggy image of scene 3 according to the present invention; Fig. 9 (b) is an effect diagram of the present invention for identifying illegal sand mining vessels in scenario three, wherein sand stealing boats represent sand stealing boats. DETAILED DESCRIPTION

[0061] The present invention is further explained below in conjunction with the accompanying drawings and specific embodiments. It should be understood that these examples are only used to illustrate the present invention and are not used to limit the scope of the present invention. After reading the present invention, various equivalent forms of modifications to the present invention by those skilled in the art all fall within the scope defined by the claims attached to this application.

[0062] A method for identifying illegal sand mining vessels in foggy weather based on deep learning. Figure 1 As shown, the following steps are included:

[0063] Step S10: Collect photos of illegal sand mining vessels and ordinary vessels on foggy and non-foggy days, annotate them, and construct a data set.

[0064] Step S20: Establish an image defogging algorithm based on an improved generative adversarial network, train the image defogging algorithm based on the improved generative adversarial network through a data set, and obtain a trained image defogging algorithm based on the improved generative adversarial network.

[0065] The image dehazing algorithm based on the improved generative adversarial network (GAN) mainly improves the existing GAN algorithm in three aspects: a generator integrating the feature attention mechanism is proposed, and the feature attention (FA) module from the FFA-net model is introduced between the encoder and the decoder; a discriminator based on spectral normalization is proposed, and the parameter matrix of each convolution layer in the discriminator is spectrally normalized; a perceptual cycle consistency loss function is proposed to ensure the structural consistency between the generated image and the original image.

[0066] Step S30: Establish a ship identification algorithm based on the improved YOLOv8 network, train the ship identification algorithm based on the improved YOLOv8 network through the data set, obtain a trained ship identification algorithm based on the improved YOLOv8 network, and identify illegal sand mining vessels and ordinary vessels.

[0067] The ship recognition algorithm based on the improved YOLOv8 network adds an attention mechanism module (CBAM) to the Neck structure of the original YOLOv8 algorithm. It obtains the importance of each feature space through learning and suppresses unimportant features, thereby enhancing the network's ability to extract important features of the image. This step is a necessary condition for the network to identify illegal sand mining vessels.

[0068] Step S40: Collect photos of ships in foggy waters to be identified, remove fog from the photos of ships in foggy waters using a trained image defogging algorithm based on an improved generative adversarial network, and obtain photos of ships in the waters after defogging. Use a trained ship identification algorithm based on an improved YOLOv8 network to identify the photos of ships in the waters after defogging, and identify illegal sand mining ships.

[0069] By processing the on-site surveillance video frame by frame, each frame of the water area image is obtained, and the blurred water area image is defogged using the image defogging algorithm to obtain a clear water area image; the illegal sand mining vessels in the clear water area image are located and identified using the ship recognition algorithm, thereby realizing the function of real-time, automatic and accurate identification of illegal sand mining vessels in the water area.

[0070] like Figure 2As shown in the figure, in order to solve the problem of unclear water images collected on foggy days, the Generative adversarial network (GAN) is improved in three aspects to improve the network's ability to extract fuzzy texture features and better defog the image. First, a generator that integrates the feature attention mechanism is proposed, and the feature attention mechanism is integrated into the generator so that the network can extract the texture features of ships under the foggy background. Secondly, the spectral normalization operation is added to the discriminator to solve the problem of gradient disappearance in network training and enhance the stability of network training. Finally, based on the pre-trained VGG19 network, a perceptual cycle consistency loss function is proposed to improve the network's ability to distinguish between foggy and non-foggy features of images. The improved image defogging algorithm is used to defog the fuzzy images of the water area, and the ship recognition algorithm is used to locate and identify the illegal sand mining ships in the clear water area images. The function of real-time, automatic and accurate identification of illegal sand mining ships in the water area can be realized, effectively improving the level of informationization, intelligent supervision and law enforcement of illegal sand mining.

[0071] In another embodiment, if Figure 3 As shown, the improved generative adversarial network includes a generator integrating feature attention mechanism, a discriminator based on spectral normalization, and a perceptual cycle consistency loss function. The discriminator adds a spectral normalization operation. The generator integrating feature attention mechanism is divided into a generator G and a generator F. The generator G is used to convert a foggy image into a fog-free image. The generator F is used to convert a fog-free image into a foggy image. The discriminator adds a spectral normalization operation. The discriminator is divided into a discriminator D. a and discriminator D b , the discriminator D a The discriminator D is used to determine whether the foggy image generated by the generator F is a real image or a generated image. b It is used to determine whether the fog-free image generated by the generator G is a real image or a generated image. The perceptual cycle consistency loss function calculates the cycle loss and perceptual loss from the features between the real image and the generated image extracted from the VGG19 network to ensure the structural consistency between the generated image and the original image.

[0072] The generator of the fusion feature attention mechanism includes an encoder, a feature attention module, and a decoder. The encoder includes the first convolution layer 1, the first ReLU activation layer 1, the first convolution layer 2, the first average pooling layer 1, the first ReLU activation layer 2, and the first convolution layer 3 connected in sequence. The feature attention module includes the second convolution layer 1, the second ReLU activation layer 1, the second element summation module 1, the second convolution layer 2, the channel attention submodule, the pixel attention submodule, and the second element summation module 2 connected in sequence. The output of the first convolution layer 3 is connected to the input of the second element summation module 1, and the output of the first convolution layer 3 is connected to the input of the second element summation module 2; the channel attention submodule includes the third average pooling layer 1, the third convolution layer 1, the third ReLU activation layer 1, the third convolution layer 2, the third Sigmod activation function 1, and the third element product module 1 connected in sequence. The output of the second convolution layer 2 is connected to the input of the third element product module 1. The pixel attention submodule includes a fourth convolutional layer 1, a fourth ReLU activation layer 1, a fourth convolutional layer 2, a fourth Sigmod activation function 2, and a fourth element product module 1 connected in sequence. The decoder includes a fifth convolutional layer 1, a fifth convolutional layer 2, and a fifth convolutional layer 3 connected in sequence.

[0073] like Figure 3 As shown in Figure 1, the proposed improved image defogging network mainly includes two autoencoder generators G and F, which convert foggy images into fog-free images and fog-free images into foggy images respectively. a and D b , which are used to distinguish whether the foggy image generated by the generator F is a real image or a generated image, and whether the fog-free image generated by the generator G is a real image or a generated image. The interaction process between the generator and the discriminator is as follows: Figure 2 First, the foggy image is input into the generator G, which generates the corresponding fog-free image, which is then input into the discriminator D. b , training D b Distinguish true and false fog-free images. Secondly, pass the fog-free image to the generator F to generate a foggy image, and use the features between the real image and the generated image extracted by the VCG19 network to calculate the cycle loss and perceptual loss, and further improve the generation quality of the generator from the aspects of texture details and structural features to maintain cycle consistency. Finally, the cycle is carried out in the opposite direction to train D a Distinguish between real and fake foggy images, and maintain cycle consistency between the original fog-free image and the generated foggy image.

[0074] By proposing a generator that integrates the feature attention mechanism, the feature attention (FA) module from the FFA-net model is introduced between the encoder and the decoder; a discriminator based on spectral normalization is proposed, and the parameter matrix of each convolution layer in the discriminator is spectrally normalized; a perceptual cycle consistency loss function is proposed to ensure the structural consistency between the generated image and the original image.

[0075] (1) Generator integrating feature attention mechanism

[0076] In order to preserve image texture details while removing haze, the generator of the image dehazing network is structurally improved, such as Figure 3 . The improved generator consists of an encoder, a feature attention module, and a decoder. The encoder first uses a convolution with a convolution kernel of 7*7 and a step size of 1. After the convolution, a LeakyReLU rectified linear unit is introduced to prevent the gradient from disappearing. Subsequently, a convolution with a convolution kernel of 3*3 and a step size of 2 is used, and an average pooling layer is added to achieve effective downsampling while minimizing information loss and protecting the overall characteristics of the image. After that, LeakyReLU is introduced, followed by a convolution with a convolution kernel of 3*3 and a step size of 2. The entire encoder ensures the network's ability to capture complex image features. The decoder is responsible for upsampling the transformed features four times to reconstruct a clear, fog-free image.

[0077] Since fog is unevenly distributed in the image and can cause distortion of ship information, a feature attention (FA) module from the FFA-net model is introduced between the encoder and decoder, which includes channel attention and pixel attention submodules. The former solves the problem of ship information distortion caused by fog by weighting feature information of different channels, while the latter makes the network pay more attention to fog-concentrated areas and solves the problem of uneven fog distribution.

[0078] The channel attention submodule focuses on the different weighted information of different channel features. First, global average pooling is used to encapsulate the global spatial information of the channel dimension into a channel descriptor, as shown in formula (1).

[0079]

[0080] Among them, fc represents the channel descriptor, H represents the height, W represents the width, and X c (i, j) represents the value of the c-th channel at position (i, j), H p is the global pooling function. The feature map size is from C×H×W to C×1×1. Subsequently, the channel features are processed by two convolutional layers and connected to the Sigmoid function after the ReLU activation layer to obtain the channel attention weight. The channel attention weight is shown in formula (2).

[0081] CA=σ(Conv(δ(Conv(fc ))) (2)

[0082] Among them, CA represents the channel attention weight, Conv represents the convolution result, σ is the Sigmod function, and δ is the ReLU function. c Multiply element-wise by the channel attention weight, and the output of the channel attention submodule is

[0083]

[0084] in, is the output of the channel attention submodule, Represents element-wise multiplication.

[0085] The pixel attention submodule feeds the output of the channel attention submodule into two convolutional layers and uses ReLU and Sigmoid activation functions to scale the feature size from C×H×W to 1×H×W. The pixel attention is shown in Equation (4).

[0086]

[0087] Among them, PA represents pixel attention weight, σ is Sigmod function, δ is ReLU function, Conv represents convolution result, Represents the output of the channel attention submodule.

[0088] Enter Perform element-wise multiplication with PA to obtain the output of the pixel attention submodule As shown in formula (5).

[0089]

[0090] in, represents the output of the pixel attention submodule, represents the output of the channel attention submodule, PA represents the pixel attention weight, Represents element-wise multiplication.

[0091] (2) Discriminator based on spectral normalization

[0092] The discriminator mainly judges and predicts whether the image is a real image or a generated image from the overall level of the image. In order to make the discriminator satisfy the Lipschitz continuity, the parameter matrix of each layer of convolution in the discriminator is spectrally normalized to ensure the stability of network training and avoid gradient disappearance. The Lipschitz constraint condition is as follows:

[0093] ||D(x)-D(y)||≤K*||xy|| (6)

[0094] Where D is the discriminator, x and y are any two points in the image space. ||*|| is the 2-norm, and K is the Lipschitz constant. The Lipschitz condition is limited to a certain local area, and the change value of the function will not be greater than the Lipschitz constant. For a neural network, if its function satisfies the Lipschitz condition, the corresponding gradient change will not exceed the corresponding Lipschitz constant, and there will be no gradient explosion. Therefore, the parameter matrix W of each layer of the discriminator neural network is decomposed by singular value to satisfy 1-Lipschitz, and the maximum singular value of W is divided every time the weight is updated, which can ensure the stability and convergence of the network training.

[0095]

[0096] in, represents the parameter matrix that satisfies 1-Lipschitz, W represents the parameter matrix, and σ(W) represents the maximum singular value of the parameter matrix.

[0097] The discriminator includes the sixth convolution layer 1, the sixth spectral normalization layer 1, the sixth ReLU activation layer 1, the sixth convolution layer 2, the sixth spectral normalization layer 2, the sixth ReLU activation layer 2, the sixth convolution layer 3, the sixth spectral normalization layer 3, the sixth ReLU activation layer 3, the sixth convolution layer 4, the sixth spectral normalization layer 4, the sixth ReLU activation layer 4, the sixth average pooling layer 1, the sixth spectral normalization layer 5, and the sixth Sigmod activation function 1, which are connected in sequence. Figure 4 As shown in the figure, the network is downsampled by 4 convolution kernels 4*4 and a step size of 2, and spectral normalization is performed on each convolution layer, followed by a LeakyReLU activation function. Finally, after a global average pooling layer and spectral normalization operation, followed by a Sigmod activation function, the discrimination probability between 0 and 1 is output.

[0098] (3) Perceptual loss based on image features

[0099] The original GAN ​​uses two loss functions, namely adversarial loss and cycle consistency loss. Adversarial loss is used to represent the process of adversarial learning, making the generated images closer to the target images in terms of distribution. For the mapping function G:A->B and the discriminator D b , and its objective function is:

[0100] L adv (G,D b ,A,B)=E b~p(b) [logD b (b)]+E a~p(a) [1-logD b (G(a))] (8)

[0101] Where A and B represent the foggy and fog-free image datasets, respectively. a and b are images in the sets A and B, a~p(a) and b~p(b) represent the data distribution, and E is the expected value of the loss function. G attempts to generate a fog-free image G(a) similar to the B dataset, minimizing the adversarial loss, while D b The purpose is to distinguish the generated sample G(a) from the real sample b, and try to maximize the adversarial loss. The process of network learning and optimization is to find the Nash equilibrium between the two. Similarly, the mapping function F:B->A is as shown in formula (9).

[0102] L adv (F,D a ,B,A)=E a~p(a) [logD a(a) ]+E b~p(b) [1-logD a (F(b))] (9)

[0103] The cycle consistency loss calculates the L1 norm between the original image and the cycle image for the unpaired image-to-image translation task, as shown in Equation (10).

[0104]

[0105] Since foggy images of Changsha River Basin usually have severe blurring, relying solely on the loss value between the original image and the cyclically reconstructed image is not enough to recover comprehensive texture information. The cycle consistency-aware loss maintains the structural integrity of the original image by utilizing a combination of high-level and low-level features extracted from the second and fifth pooling layers of the VGG19 architecture, as shown in Equation (11).

[0106] L per (G,F)=||φ(a)-φ(F(G(a)))||2+||φ(b)-φ(F(G(b)))||2 (11)

[0107] Within this framework, the cycle consistency loss helps ensure a high peak signal-to-noise ratio (PSNR) value. Meanwhile, the perceptual loss maintains the sharpness and clarity of the image, ensuring that image details and textures are more carefully and effectively preserved after reconstruction.

[0108] The perceptual cycle consistency loss function is:

[0109] L GAN =L adv (G,D b ,A,B)+L adv (F,D a ,B,A)+αL cycle (G,F)+βL per (G,F) (12)

[0110] Then the perceptual cycle consistency loss function is:

[0111]

[0112] Among them, L GAN represents the total loss, the mapping function G:A->B, A represents the foggy image dataset, B represents the fog-free image dataset, a is an image in set A, b is an image in set B, p(a) represents the probability distribution that a obeys, p(b) represents the probability distribution that b obeys, a~p(a) represents the data distribution of foggy images, b~p(b) represents the data distribution of fog-free images, E b~p(b) represents the expectation of a haze-free image, E a~p(a) represents the expectation of the foggy image, D b (·) represents the discriminator D b The output of G(·) represents the haze-free image generated by the generator G, and the mapping function F: B->A, D a (·) represents the discriminator D a The output of F(·) represents the foggy image generated by generator 2 F. represents the cycle image, c represents the original image, ||·|| L1 represents the L1 norm between the original image and the cycle image, φ(·) represents the feature extractor of the second and fifth pooling layers of VGG16, ||·||2 represents the L2 norm between the original image and the cycle image, α represents the adversarial loss hyperparameter, and β represents the cycle consistency loss hyperparameter.

[0113] Specifically, the above step S20 includes: adding an attention mechanism module (CBAM) to the Neck structure of the original YOLOv8 algorithm, including:

[0114] YOLOv8 is an updated version based on YOLOv5. The main improvement is to modularize the various parts of the algorithm so that modules can be added as needed for improvement or optimization. In terms of network structure, YOLOv8 continues to use the network structure of YOLOv5, and divides the network into three parts: feature extraction backbone network (backbone), feature splicing enhancement network (neck), and detection head network (head). Among them, the Backbone layer is mainly composed of five Conv convolution modules, four C2f modules, and one SPFF module, which will extract features from the input image. The Neck layer is mainly responsible for feature extraction and feature upsampling and feature fusion, fusing multi-scale feature maps, and thus better extracting information from objects of different scales. The Head layer is mainly responsible for information fusion of the three feature maps T1, T2, and T3 output by the Neck layer to form a more comprehensive and accurate description of the target task. The attention mechanism module (CBAM) is added to the Neck structure of the original YOLOv8 algorithm. Through learning, the importance of each feature space is obtained, and unimportant features are suppressed, thereby enhancing the network's ability to extract important features of the image. The YOLOv8 algorithm structure integrating the CBAM mechanism is as follows Figure 5 As shown, the improved YOLOv8 network includes a feature extraction backbone network, a feature splicing enhancement network and a head network. The feature extraction backbone network includes the first CBS layer one, the first CBS layer two, the first C2f layer one, the first CBS layer three, the first C2f layer two, the first CBS layer four, the first C2f layer three, the first CBS layer five, the first C2f layer four, and the first SPPF layer one connected in sequence. The feature splicing enhancement network includes the second UpSample layer 1, the second Concat layer 1, the second C2f layer 1, the second UpSample layer 2, the second Concat layer 2, the second C2f layer 2, the second attention mechanism module, the second CBS layer 1, the second Concat layer 3, the second C2f layer 3, the second CBS layer 2, the second Concat layer 4, and the second C2f layer 4, which are connected in sequence. The output of the first C2f layer 2 is connected to the input of the second Concat layer 2, the output of the first C2f layer 3 is connected to the input of the second Concat layer 1, the output of the first SPPF layer 1 is respectively connected to the input of the second UpSample layer 1 and the second Concat layer 4, and the output of the second C2f layer 1 is connected to the input of the second Concat layer 3. The outputs of the second C2f layer 2, the second C2f layer 3, and the second C2f layer 4 are respectively connected to the input of the head network.

[0115] The calculation formulas for channel attention and spatial attention are as shown in equations (13) and (14), respectively.

[0116] M c(F)=σ(MLP(AvgPool(F))+MLP(MaxPool(F))) (13)

[0117] M s (F) = σ(f 7*7 ([AvgPool(F);MaxPool(F)])) (14)

[0118] Among them, M c (F) represents the output of the channel attention module, M s (F) represents the output of the spatial attention module, σ represents the Sigmod activation function, MLP represents the multi-layer perceptron, AvgPool represents the average pooling layer, F represents the input feature map, and f 7*7 represents a 7×7 convolution, MaxPool represents the maximum pooling layer, and [AvgPool(F); MaxPool(F)] means concatenating the results of average pooling and maximum pooling along the channel axis.

[0119] In another embodiment, a system for identifying illegal sand mining vessels in foggy weather based on deep learning is provided, which is used to implement the method for identifying illegal sand mining vessels in foggy weather based on deep learning, including an input unit, an improved generative adversarial network unit, an improved YOLOv8 network unit, and an output unit, wherein:

[0120] The input unit is used to input photos of sand mining vessels in foggy weather to be identified.

[0121] The improved generative adversarial network-based unit is used to remove fog on the photo of the sand mining vessel on a foggy day through a trained improved generative adversarial network-based image defogging algorithm to obtain the defogged photo of the sand mining vessel.

[0122] The improved YOLOv8 network unit is used to identify the defogging sand mining vessel photos through the trained improved YOLOv8 network-based vessel identification algorithm to obtain illegal sand mining vessels.

[0123] The output unit is used to output illegal sand mining vessels.

[0124] In another embodiment, a computer system is provided, including a memory and a processor, wherein the memory is used to store a computer program / instruction, and the processor is used to execute the computer program / instruction to implement the method for identifying illegal sand mining vessels in foggy weather based on deep learning.

[0125] Simulation experiment

[0126] (1) Experimental environment and dataset construction

[0127] The experiment uses the Linux operating system, version Ubuntu 20.04, the deep learning framework PyTorch2.0.0, the CPU is 15*Xeon(R)Platinum 8474C, the memory is 80G, the GPU is NVIDIA GeForce RTX 4090D, and the video memory is 24G. The training images are randomly cropped to 256*256 resolution to complete data enhancement, and the Adam optimizer is used to optimize the network parameters.

[0128] The training hyperparameters are set as follows: epoch is set to 200, batch size is 4, initial learning rate is 0.0002, and linear decay begins after 100 epochs. The initial value of the smooth L1 loss weight is set to 0.5, and the initial value of the perceptual cycle loss weight is set to 0.001.

[0129] A data set was constructed using 5280 images of illegal sand mining vessels and ordinary ships obtained from a certain bureau’s video surveillance and the Internet. Among them, 3884 were clear images, and 1396 were real foggy images and foggy images generated using the fuzzy image generation method, which were used for network training.

[0130] (2) Experimental evaluation indicators

[0131] ①Peak signal-to-noise ratio

[0132] The peak signal-to-noise ratio (PSNR) is defined by the mean square error. The difference between the foggy image and the defogged image is compared to measure the performance of the defogging algorithm. It is defined as follows:

[0133]

[0134] Where n is the number of pixel bits, MSE is the difference between the hazy image and the dehazed image, and the mean square error is defined as follows:

[0135]

[0136] Among them, X(i,j) and Y(i,j) represent the pixel values ​​of the foggy and non-foggy images at position (i,j) respectively. The larger the PSNR, the better the defogging effect of the algorithm.

[0137] ②Structural similarity

[0138] Structural similarity SSIM evaluates the brightness, contrast, and structural information features between foggy and non-foggy images to measure the similarity between the two images. The calculation result is between [0, 1]. The closer it is to 1, the more similar the two images are, and the better the defogging effect of the algorithm. The SSIM calculation formula is as follows:

[0139]

[0140] Among them, (x, y) are two fixed windows, μ and σ are the mean and variance respectively, and σ xy is the covariance between x and y. a1 and a2 are non-zero constants.

[0141] ③Detection accuracy and speed evaluation indicators

[0142] In order to evaluate the performance of the recognition model in terms of accuracy and speed, two evaluation indicators, multi-category average precision (mAP) and frames per second (FPS), are used to evaluate the performance of the target detection model in terms of accuracy and speed.

[0143]

[0144] (3) Analysis of defogging effect

[0145] In order to verify the superiority of the dehazing algorithm proposed in the present invention, two currently common dehazing algorithms, CycleGAN and GC-GAN, are selected for comparison. Among them, the PSNR and SSIM indicators of the CycleGAN algorithm are 28.17 and 0.41 respectively; the PSNR and SSIM indicators of the GCGAN algorithm are 30.76 and 0.61 respectively; the PSNR and SSIM indicators of the improved image dehazing algorithm of the present invention are 31.86 and 0.64 respectively. Compared with Cycle GAN and GC-GAN, the algorithm proposed in the present invention has an improvement of 13.1% and 3.6% in PSNR, and an improvement of 56.1% and 4.9% in SSIM, respectively. Comparison of visual effects Figure 6 ,The algorithm proposed in this paper can better preserve the characteristic details of the ship, and the defogging effect is more ,complete.

[0146] (4) Analysis of recognition effect

[0147] For the dehazed image, the YOLOv8 algorithm integrated with CBAM is used to identify illegal sand mining vessels. The results are as follows: Figure 7-Figure 9 .exist Figure 7 In the case of , the algorithm shows a low recognition confidence of only 0.37, which reaches 0.86 after dehazing; Figure 8 In the figure, the algorithm cannot identify the ship in the upper right corner of the image. After defogging, the algorithm successfully identifies the smaller ship in the upper right corner. Fig. 9 In the image, the algorithm made an error in recognition. After defogging, the algorithm successfully identified two illegal sand mining vessels. Therefore, after the defogging algorithm proposed in the present invention, the target detection accuracy is significantly improved, the mAP is increased from 78.3% to 89.6%, and the detection speed reaches 36 frames / second.

[0148] The complete illegal sand mining vessel identification process includes two modules: image defogging network, which proposes an image defogging algorithm based on improved GAN, captures the characteristics of river foggy images at multiple scales, and effectively reduces the noise of on-site images in the image preprocessing stage; illegal sand mining vessel identification network, which proposes a YOLOv8 algorithm integrated with CBAM, combines the improved ship identification algorithm with the proposed image defogging network to improve the recognition accuracy of illegal sand mining vessels under fog interference.

[0149] The overall framework of the algorithm is as follows:

[0150] ① The original image is processed by the proposed dehazing network to generate a new clear image without fog interference;

[0151] ② Input the processed image data into the illegal sand mining vessel identification network for detection;

[0152] ③ Output the detection results of the ship to achieve real-time and accurate identification of illegal sand mining ships in foggy days.

[0153] In summary, the present invention aims at the key problems of difficulty in identifying illegal sand mining vessels and low recognition accuracy in foggy environment, and proposes a method for identifying illegal sand mining vessels in foggy environment based on deep learning. Aiming at the problem of fog interference in images in foggy environment, an image defogging algorithm based on an improved generative adversarial network is proposed to achieve clear processing of blurred images. Compared with the commonly used Cycle GAN and GC-GAN algorithms, the algorithm has better defogging effect. The features of the target ship in the defogged image are more obvious, and the defogging effect is better. Afterwards, the YOLOv8 network with fusion attention mechanism is used to identify the ships in the defogged image. The results show that the defogged image can still efficiently identify all targets in the image when multiple ships exist at the same time, meeting the needs.

[0154] The above is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principle of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.

Claims

1. A method for identifying illegal sand mining vessels in foggy weather based on deep learning. It is characterized in that The following steps are involved: step S10: Collect photos of illegal sand mining vessels and ordinary vessels in foggy and non-foggy days, annotate them, and construct a dataset; Step S20: establishing an image defogging algorithm based on an improved generative adversarial network, training the image defogging algorithm based on the improved generative adversarial network through a data set, and obtaining a trained image defogging algorithm based on the improved generative adversarial network; Step S30: establishing a ship identification algorithm based on the improved YOLOv8 network, training the ship identification algorithm based on the improved YOLOv8 network through the data set, and obtaining a trained ship identification algorithm based on the improved YOLOv8 network; Step S40: Collect photos of ships in foggy waters to be identified, remove fog on the photos of ships in foggy waters by using a trained image defogging algorithm based on an improved generative adversarial network, and obtain photos of ships in the waters after defogging; identify the photos of ships in the waters after defogging by using a trained ship identification algorithm based on an improved YOLOv8 network to identify illegal sand mining ships.

2. According to the method for identifying illegal sand mining vessels in foggy weather based on deep learning according to claim 1, Features: The improved generative adversarial network includes a generator fused with a feature attention mechanism, a discriminator based on spectral normalization, and a perceptual cycle consistency loss function. The generator fused with the feature attention mechanism is divided into a generator-G and a generator-F. The generator-G is used to convert a foggy image into a fog-free image. The generator-F is used to convert a fog-free image into a foggy image. A spectral normalization operation is added to the discriminator. The discriminator is divided into a discriminator-D. a and discriminator D b , the discriminator D a The discriminator D is used to determine whether the foggy image generated by the generator F is a real image or a generated image. b Used to determine whether the fog-free image generated by generator G is a real image or a generated image; the perceptual cycle consistency loss function extracts features between the real image and the generated image from the VGG19 network, calculates the cycle loss and the perceptual loss, and ensures the structural consistency between the generated image and the original image.

3. According to the method for identifying illegal sand mining vessels in foggy weather based on deep learning in claim 2, Features: The generator of the fusion feature attention mechanism includes an encoder, a feature attention module, and a decoder. The encoder includes a first convolution layer 1, a first ReLU activation layer 1, a first convolution layer 2, a first average pooling layer 1, a first ReLU activation layer 2, and a first convolution layer 3 connected in sequence; the feature attention module includes a second convolution layer 1, a second ReLU activation layer 1, a second element summation module 1, a second convolution layer 2, a channel attention submodule, a pixel attention submodule, and a second element summation module 2 connected in sequence; the output of the first convolution layer 3 is connected to the output of the second element summation module 1. The output of the first convolution layer three is connected to the input of the second element summation module two; the channel attention submodule includes a third average pooling layer one, a third convolution layer one, a third ReLU activation layer one, a third convolution layer two, a third Sigmod activation function one, and a third element product module one connected in sequence, and the output of the second convolution layer two is connected to the input of the third element product module one; the pixel attention submodule includes a fourth convolution layer one, a fourth ReLU activation layer one, a fourth convolution layer two, a fourth Sigmod activation function two, and a fourth element product module one connected in sequence; The decoder includes a fifth convolutional layer one, a fifth convolutional layer two, and a fifth convolutional layer three which are connected in sequence.

4. According to the method for identifying illegal sand mining vessels in foggy weather based on deep learning in claim 3, Features: The perceptual cycle consistency loss function is: Among them, L GAN represents the total loss, the mapping function G:A->B, A represents the foggy image dataset, B represents the fog-free image dataset, a is an image in set A, b is an image in set B, p(a) represents the probability distribution that a obeys, p(b) represents the probability distribution that b obeys, a~p(a) represents the data distribution of foggy images, b~p(b) represents the data distribution of fog-free images, E b~p(b) represents the expectation of a haze-free image, E a~p(a) represents the expectation of the foggy image, D b (·) represents the discriminator D b The output of G(·) represents the haze-free image generated by the generator G, and the mapping function F: B->A, D a (·) represents the discriminator D a The output of F(·) represents the foggy image generated by generator 2 F. represents the cycle image, c represents the original image, ||·|| L1 represents the L1 norm between the original image and the cycled image, φ(·) represents the feature extractor of the second and fifth pooling layers of VGG16, ||·|| 2 represents the L2 norm between the original image and the cycle image, α represents the adversarial loss hyperparameter, and β represents the cycle consistency loss hyperparameter.

5. According to the method for identifying illegal sand mining vessels in foggy weather based on deep learning according to claim 4, Features: The discriminator includes the sixth convolution layer 1, the sixth spectral normalization layer 1, the sixth ReLU activation layer 1, the sixth convolution layer 2, the sixth spectral normalization layer 2, the sixth ReLU activation layer 2, the sixth convolution layer 3, the sixth spectral normalization layer 3, the sixth ReLU activation layer 3, the sixth convolution layer 4, the sixth spectral normalization layer 4, the sixth ReLU activation layer 4, the sixth average pooling layer 1, the sixth spectral normalization layer 5, and the sixth Sigmod activation function 1, which are connected in sequence.

6. According to the method for identifying illegal sand mining vessels in foggy weather based on deep learning according to claim 5, Features: The channel attention submodule first uses global average pooling to encapsulate the global spatial information of the channel dimension into a channel descriptor. The formula of global average pooling is as follows: Among them, f c Indicates the channel descriptor, H indicates the height, W indicates the width, X c (i,j) represents the value of the cth channel at position (i,j); Secondly, the channel features are processed through two convolutional layers and connected to the Sigmoid function after the ReLU activation layer to obtain the channel attention weight, the formula is as follows: CA=σ(Conv(δ(Conv(f c ))); Among them, CA represents the channel attention weight, σ is the Sigmod function, δ is the ReLU function, and Conv represents the convolution result; Finally, enter F c Multiply element-wise with the channel attention weight, and the formula is as follows: in, is the output of the channel attention submodule, Represents element-wise multiplication; The pixel attention submodule feeds the output of the channel attention submodule into two convolutional layers and uses the ReLU and Sigmoid activation functions. The formula is as follows: Among them, PA represents pixel attention weight, σ is Sigmod function, δ is ReLU function, and Conv represents convolution result; Enter Perform element-wise multiplication with PA to obtain the output of the pixel attention submodule The formula is as follows: in, represents the output of the pixel attention submodule, represents the output of the channel attention submodule, PA represents the pixel attention weight, Represents element-wise multiplication; The Lipschitz constraint for spectral normalization is: ||D(x)-D(y)||≤K*||xy||; Where D is the discriminator, x and y are any two points in the image space, ||*|| is the 2-norm, and K is the Lipschitz constant; Perform singular value decomposition on the parameter matrix W of each layer of the neural network of the discriminator to satisfy 1-Lipschitz, and divide it by the maximum singular value of W every time the weight is updated; in, represents the parameter matrix that satisfies 1-Lipschitz, W represents the parameter matrix, and σ(W) represents the maximum singular value of the parameter matrix.

7. According to the method for identifying illegal sand mining vessels in foggy weather based on deep learning according to claim 6, Features: The improved YOLOv8 network includes a feature extraction backbone network, a feature splicing enhancement network and a head network, wherein the feature extraction backbone network includes the first CBS layer one, the first CBS layer two, the first C2f layer one, the first CBS layer three, the first C2f layer two, the first CBS layer four, the first C2f layer three, the first CBS layer five, the first C2f layer four, and the first SPPF layer one connected in sequence; the feature splicing enhancement network includes the second UpSample layer one, the second Concat layer one, the second C2f layer one, the second UpSample layer two, the second Concat layer two, the second C2f layer two, the second attention mechanism module, The second CBS layer one, the second Concat layer three, the second C2f layer three, the second CBS layer two, the second Concat layer four, and the second C2f layer four, the output of the first C2f layer two is connected to the input of the second Concat layer two, the output of the first C2f layer three is connected to the input of the second Concat layer one, the output of the first SPPF layer one is respectively connected to the input of the second UpSample layer one and the second Concat layer four, and the output of the second C2f layer one is connected to the input of the second Concat layer three; the outputs of the second C2f layer two, the second C2f layer three, and the second C2f layer four are respectively connected to the head network input.

8. According to the method for identifying illegal sand mining vessels in foggy weather based on deep learning according to claim 7, Features: The calculation formulas for channel attention and spatial attention are: M c (F)=σ(MLP(AvgPool(F))+MLP(MaxPool(F))); M s (F)=σ(f 7*7 ([AvgPool(F);MaxPool(F)])); Among them, M c (F) represents the output of the channel attention module, M s (F) represents the output of the spatial attention module, σ represents the Sigmod activation function, MLP represents the multi-layer perceptron, AvgPool represents the average pooling layer, F represents the input feature map, and f 7*7 represents a 7×7 convolution, MaxPool represents the maximum pooling layer, and [AvgPool(F); MaxPool(F)] means concatenating the results of average pooling and maximum pooling along the channel axis.

9. A system for identifying illegal sand mining vessels in foggy weather based on deep learning. Features: The method for identifying illegal sand mining vessels in foggy weather based on deep learning according to any one of claims 1 to 8 comprises an input unit, an improved generative adversarial network unit, an improved YOLOv8 network unit and an output unit, wherein: The input unit is used to input photos of ships in foggy waters to be identified; The improved generative adversarial network-based unit is used to remove fog from the photo of ships in foggy waters by using a trained improved generative adversarial network-based image defogging algorithm to obtain a defogged photo of ships in the waters; The improved YOLOv8 network unit is used to identify the photos of ships in the water area after defogging through the trained ship identification algorithm based on the improved YOLOv8 network, and identify illegal sand mining ships; The output unit is used to output illegal sand mining vessels.

10. A computer system, It is characterized in that It includes a memory and a processor, the memory is used to store computer programs / instructions; the processor is used to execute the computer programs / instructions to implement the method for identifying illegal sand mining vessels in foggy days based on deep learning as described in any one of claims 1-6.

Citation Information

Patent Citations

  • Traffic image defogging method based on improved generative adversarial network

    CN112801902A

  • Small target fault identification method for power transmission line in foggy day scene

    CN117115617A

Cited By

  • Improved fishery illegal fishing behavior distinguishing system, method and equipment based on YOLOv10 algorithm and medium

    CN120217036A

  • Meteorological disaster weather intelligent identification method based on AI image identification

    CN121010802A

  • Landslide identification method and system for collapsible loess slope, terminal and storage medium

    CN121170569A