Neural network training method and device, electronic equipment and storage medium

By employing parameter-sharing convolutional layers and multi-scale convolutional modules in remote sensing target detection tasks, and adjusting the weights of the loss function by combining normalized four-dimensional inter-frame distance and confidence threshold, the training of the detection head network was optimized, solving the problems of large number of parameters and slow convergence speed of the detection head network, and improving detection accuracy and robustness.

CN119294459APending Publication Date: 2025-01-10CHONGQING INST OF INTEGRATED CIRCUIT INNOVATION XIDIAN UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411326374.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-23
Publication Date
2025-01-10

AI Technical Summary

Technical Problem

In existing remote sensing target detection tasks, the detection head network has a large number of parameters, many redundant parameters, slow convergence speed, and difficulty in effectively handling small targets and occluded targets in complex backgrounds.

Method used

We employ parameter-shared convolutional layers and multi-scale convolutional modules, and combine normalized four-dimensional inter-frame distance and confidence threshold to adjust the weights of the loss function, thereby optimizing the training process of the detection head network.

Benefits of technology

The number of parameters in the detection head has been reduced, improving convergence speed and detection accuracy, especially when dealing with small targets and occluded targets in complex backgrounds.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119294459A_ABST
    Figure CN119294459A_ABST
Patent Text Reader

Abstract

The invention relates to a neural network training method and device, electronic equipment and a storage medium, and the method is characterized in that the method comprises the steps: obtaining a prediction positive sample according to an output feature map of a target detection neural network; wherein the target detection neural network is used for remote sensing target detection; a detection head network of the target detection neural network comprises a parameter sharing convolutional layer; obtaining a confidence coefficient threshold value according to the normalized four-dimensional frame distance between the predicted positive sample and the corresponding real labeled object; adjusting the weight of a loss function corresponding to the predicted positive sample according to a confidence coefficient threshold value; and training the target detection neural network by using the loss function after weight adjustment. Through the above technical scheme, the parameter quantity of the detection head is reduced through the parameter-shared convolutional layer, the weight of the loss function is adjusted by using the confidence threshold, and the weight of the loss function corresponding to the predicted positive sample needing to be emphatically processed is improved, so that the target detection neural network is trained, and the convergence speed and the detection precision can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of target detection technology, and in particular to a neural network training method, device, electronic equipment and storage medium. Background Art

[0002] The network structure of remote sensing target detection tasks based on neural networks is generally divided into feature extraction networks and detection heads. The role of the detection head is to locate and classify the target based on the feature map extracted by the feature extraction network. It is usually composed of multiple convolutional layers and fully connected layers, which classify these areas to determine the type of target and regress the precise position of the target. The parameters of each detection head of the modern target detection algorithm are not shared, and independent detection heads need to be set for effective feature layers of different scales. The detection head is generally divided into Cls (classification) branch, Reg (positioning) branch and IoU (intersection over union) branch, and these three branches have their own separate neural network structures. In other words: there is no interaction between different detection heads and between the branches of the detection head. This leads to a huge amount of parameters and a large amount of back propagation calculations, and it often takes many rounds of training to achieve accuracy convergence. The original intention of the design of this detection head is to achieve good detection accuracy in multi-target detection tasks, without considering other task requirements. This design has led to a large number of invalid parameters in most of the current detection head networks, which has led to bloated detection heads, many redundant parameters and slow convergence. At the same time, there are many challenges in remote sensing target detection tasks, such as small targets, complex backgrounds, and occluded targets. Summary of the invention

[0003] In order to solve the above problems existing in the prior art, the present invention provides a neural network training method, device, electronic device and storage medium.

[0004] According to a first aspect of an embodiment of the present invention, a neural network training method is provided, the method comprising:

[0005] A predicted positive sample is obtained according to an output feature map of a target detection neural network; wherein the target detection neural network is used for remote sensing target detection; and a detection head network of the target detection neural network includes a parameter-sharing convolutional layer;

[0006] Obtaining a confidence threshold according to a normalized four-dimensional box distance between the predicted positive sample and the corresponding real labeled object;

[0007] Adjusting the weight of the loss function corresponding to the predicted positive sample according to the confidence threshold;

[0008] The target detection neural network is trained using the weight-adjusted loss function.

[0009] Optionally, before obtaining a predicted positive sample according to the output feature map of the target detection neural network, the method further includes:

[0010] Obtain a feature map of the target object;

[0011] The feature map is adjusted using a convolution kernel of a set scale to obtain a feature map with a uniform number of channels;

[0012] An output feature map is obtained according to the feature map with unified channel number.

[0013] Optionally, obtaining the output feature map according to the feature map with a unified number of channels includes:

[0014] Dividing the feature maps with a uniform number of channels into a first group of feature maps and a second group of feature maps;

[0015] dividing the first group of feature maps into a third group of feature maps and a fourth group of feature maps;

[0016] Using convolution kernels of different scales to perform convolution operations on the second group of feature maps, the third group of feature maps, and the fourth group of feature maps, respectively, to obtain feature maps of different scales;

[0017] Performing batch normalization processing on the feature maps of different scales to obtain effective feature layers;

[0018] After the effective feature layer is processed by the parameter-sharing convolutional layer, the scale is adjusted using a scaling parameter to obtain the output feature map.

[0019] Optionally, the normalized four-dimensional box distance between the predicted positive sample and the corresponding real labeled object is defined as follows:

[0020]

[0021] Where D represents the normalized four-dimensional box distance between the predicted positive sample and the corresponding real labeled object, M represents the average scale of the real labeled object, e is the natural exponent, (x a ,y a ) is the center coordinate of the predicted positive sample bounding box, w a is the width of the predicted positive sample bounding box, h a is the height of the predicted positive sample bounding box, (x b ,y b ) is the center coordinate of the real labeled object bounding box, w b is the width of the bounding box of the real labeled object, h b is the height of the bounding box of the real labeled object.

[0022] Optionally, the average scale of the real annotated object is obtained by referring to the following formula:

[0023]

[0024] Among them, P is the number of pixels occupied by real annotations in each training batch, and batch represents the number of batches.

[0025] Optionally, adjusting the weight of the loss function corresponding to the predicted positive sample according to the confidence threshold includes:

[0026] Obtain a weight function by combining the confidence of the predicted positive sample and the confidence threshold;

[0027] The weight of the loss function corresponding to the predicted positive sample is adjusted according to the weight function.

[0028] Optionally, the weight function is represented as follows:

[0029]

[0030] Wherein, f(x) represents the weight function, x represents the confidence of the predicted positive sample, and μ represents the confidence threshold.

[0031] According to a second aspect of an embodiment of the present invention, a neural network training device is provided, the device comprising:

[0032] A positive sample acquisition module, used to obtain predicted positive samples according to the output feature map of the target detection neural network; wherein the target detection neural network is used for remote sensing target detection; the detection head network of the target detection neural network includes a parameter-sharing convolutional layer;

[0033] A threshold acquisition module, used to obtain a confidence threshold according to the normalized four-dimensional box distance between the predicted positive sample and the corresponding real annotated object;

[0034] A weight adjustment module, used to adjust the weight of the loss function corresponding to the predicted positive sample according to the confidence threshold;

[0035] The training module is used to train the target detection neural network using the weight-adjusted loss function.

[0036] According to a third aspect of an embodiment of the present disclosure, there is provided a neural network training device, comprising: a processor; a memory for storing instructions executable by the processor;

[0037] The processor is configured to: execute the executable instructions to implement the steps of the neural network training method described in any implementation of the first aspect above.

[0038] According to a fourth aspect of an embodiment of the present invention, there is provided a computer-readable storage medium having computer program instructions stored thereon, wherein the program instructions, when executed by a processor, implement the steps of the neural network training method described in the first aspect of the present invention.

[0039] The technical solution provided by the present invention may include the following beneficial effects:

[0040] Through the above technical scheme, the number of parameters of the detection head in the target detection network is reduced through the parameter-sharing convolutional layer in the detection head network, and the confidence threshold is obtained by normalizing the distance between four-dimensional boxes. The weight of the loss function is adjusted using the confidence threshold, which can reduce the weight of the loss function corresponding to the predicted positive samples that do not need to be processed emphatically, and increase the weight of the loss function corresponding to the predicted positive samples that need to be processed emphatically, thereby training the target detection neural network to improve the convergence speed and detection accuracy.

[0041] Other features and advantages of the present invention will be described in detail in the following detailed description. BRIEF DESCRIPTION OF THE DRAWINGS

[0042] The accompanying drawings are used to provide a further understanding of the present invention and constitute a part of the specification. Together with the following specific embodiments, they are used to explain the present invention but do not constitute a limitation of the present invention. In the accompanying drawings:

[0043] Figure 1 is a flow chart of a neural network training method according to an exemplary embodiment.

[0044] Figure 2 is a schematic diagram of a lightweight detection head according to an exemplary embodiment.

[0045] Figure 3 is a schematic diagram of a multi-scale convolution module according to an exemplary embodiment.

[0046] Figure 4 is a schematic diagram of a normalized four-dimensional inter-frame distance according to an exemplary embodiment.

[0047] Figure 5 is a schematic diagram of a weight function according to an exemplary embodiment.

[0048] Figure 6 is a block diagram of a neural network training device according to an exemplary embodiment.

[0049] Figure 7 The invention is a block diagram of an electronic device for a neural network training method according to an exemplary embodiment.

[0050] Figure 8is a block diagram of another electronic device for a neural network training method according to an exemplary embodiment. DETAILED DESCRIPTION

[0051] Figure 1 is a flowchart of a neural network training method according to an exemplary embodiment. Figure 1 As shown, the method comprises the following steps:

[0052] S1. Obtain predicted positive samples according to the output feature map of the target detection neural network; wherein the target detection neural network is used for remote sensing target detection; the detection head network of the target detection neural network includes a parameter-sharing convolutional layer.

[0053] Optionally, before S1, the method further includes:

[0054] Obtain a feature map of the target object;

[0055] The feature map is adjusted using a convolution kernel of a set scale to obtain a feature map with a uniform number of channels;

[0056] The output feature map is obtained according to the feature map with unified channel number.

[0057] Understandably, Figure 2 is a schematic diagram of a lightweight detection head according to an exemplary embodiment. The lightweight detection head first receives n feature map inputs of a target object extracted from a feature extraction network ( Figure 2 Taking n=3 as an example), the input feature map is first adjusted to a feature map with a uniform number of channels through a Conv convolution layer with a convolution kernel size of 1×1. The number of channels can be determined according to the situation. If it is for lightweight, the number of channels can be reduced. If it is for accuracy, the number of channels can be appropriately increased.

[0058] Optionally, an output feature map is obtained according to a feature map with a uniform number of channels, including:

[0059] The feature maps with the same number of channels are divided into a first group of feature maps and a second group of feature maps;

[0060] Dividing the first group of feature maps into a third group of feature maps and a fourth group of feature maps;

[0061] Using convolution kernels of different scales to perform convolution operations on the second set of feature maps, the third set of feature maps, and the fourth set of feature maps, respectively, to obtain feature maps of different scales;

[0062] Perform batch normalization on feature maps of different scales to obtain effective feature layers;

[0063] After the effective feature layer is processed by the parameter-sharing convolutional layer, the scale is adjusted using the scaling parameter to obtain the output feature map.

[0064] It can be understood that after obtaining the feature maps of the same channel, they are simultaneously passed into the multi-scale convolution module. Figure 3 is a schematic diagram of a multi-scale convolution module according to an exemplary embodiment. Figure 3 As shown in the figure, the multi-scale convolution module can divide the input feature map into two parts, the first group of feature maps and the second group of feature maps. The first group of feature maps is divided into two again to obtain the third group of feature maps and the fourth group of feature maps. Convolution operations with different convolution kernel scales are performed on each group to extract multi-scale convolution features; the second group of feature maps are subjected to cheap operations and no processing is performed. Finally, the third group of feature maps and the fourth group of feature maps after convolution processing are connected, and then the connected feature maps and the second group of feature maps are shuffled and output. In the multi-scale convolution module, multi-scale features of feature maps are extracted by using convolution kernels of different sizes (such as 3x3 and 5x5). This design can capture target objects of different scales in the image and enhance the model's detection ability for targets of different sizes. For targets of different sizes with huge scale differences in remote sensing images, this multi-scale feature extraction is particularly important because it can simultaneously identify the detailed features of large and small targets. By splitting the input feature map into different parts and processing them with different convolution kernels, the multi-scale convolution module (MSConv) can enrich the feature representation. It can make the model more flexible and accurate in dealing with targets of different types and scales. The diversity of features also increases the expressiveness of the model. This fusion strategy helps improve the performance of the model in complex background and multi-scale target detection tasks. For remote sensing images, the background is usually complex and the target objects are of different sizes. Feature fusion can significantly improve detection accuracy and robustness. At the same time, a part of the input feature map is directly passed to the input as a cheap processing part. This method maintains efficient computing performance, which is very beneficial, especially when processing large-scale remote sensing images.

[0065] Further, such as Figure 2 As shown in the figure, the feature maps of different scales obtained after the multi-scale convolution module are subjected to Batch Normalization processing to obtain an effective feature layer. It is worth mentioning that the parameters of the batch normalization processing are separated from each other, because the features are different at different feature map scales. The performance of detection head positioning and classification can be improved through the parameter-separated BatchNormalization operation.

[0066] Furthermore, after the effective feature layer is processed by the parameter-sharing convolutional layer, the scale is adjusted using the scaling parameter to obtain the output feature map. Specifically, each effective feature layer after batch normalization will enter Convreg, Convcls and Convobj respectively, and then obtain the corresponding multiple outputs. For each output, a trainable scaling parameter is multiplied. This parameter can meet the output requirements of different scales. If the data set has many small objects, the scaling parameter (scale) will adaptively amplify the information from the shallow feature layer. For example, if the task of the model is to have many small objects, the scaling parameter will automatically amplify the feature map output from the shallow layer and reduce the features from the deep layer.

[0067] S2. Obtain a confidence threshold based on the normalized four-dimensional box distance between the predicted positive sample and the corresponding true labeled object.

[0068] It is understandable that the average value of the normalized four-dimensional box distance between the predicted positive sample and the corresponding true labeled object can be selected as the confidence threshold.

[0069] Optionally, the normalized four-dimensional box distance between the predicted positive sample and the corresponding true labeled object is defined as follows:

[0070]

[0071] Where D represents the normalized four-dimensional box distance between the predicted positive sample and the corresponding real labeled object, M represents the average scale of the real labeled object, e is the natural exponent, (x a ,y a ) is the center coordinate of the predicted positive sample bounding box, w a is the width of the predicted positive sample bounding box, h a To predict the height of the positive sample bounding box, (x b ,y b ) is the center coordinate of the bounding box of the real labeled object, w b is the width of the bounding box of the real labeled object, h b is the height of the bounding box of the real labeled object.

[0072] Optionally, the average scale of the real annotated object is obtained by referring to the following formula:

[0073]

[0074] Among them, P is the number of pixels occupied by real annotations in each training batch, and batch represents the number of batches.

[0075] It can be understood that the normalized 4D box distance has the following advantages in detecting tiny objects: (1) it is insensitive to the size of the object; (2) the value changes smoothly after the position changes; and (3) it can distinguish between non-overlapping or mutually contained bounding boxes.

[0076] However, the traditional IoU has huge differences in numerical sensitivity when calculating objects of different scales. For tiny objects, such as objects with smaller pixels, a slight deviation will lead to a significant drop in IoU. Figure 4 is a schematic diagram of a normalized four-dimensional inter-frame distance according to an exemplary embodiment. Figure 4 As shown in the figure, for the same pixel offset, the IoU values ​​of large and small targets and the normalized four-dimensional box distance are compared as follows:

[0077]

[0078]

[0079] Among them, NFBD refers to the method of normalizing the distance between four-dimensional boxes. It can be seen that for the offset of large target (big) and small target (small) boxes, the data calculated by the normalized four-dimensional box distance is smoother and more reasonable than IoU; under the same offset, the IoU value of tiny objects dropped from 0.58 to 0.13, which is obviously unreasonable, while the normalized four-dimensional box distance value of tiny objects dropped from 0.7 to 0.58.

[0080] S3. Adjust the weight of the loss function corresponding to the predicted positive sample according to the confidence threshold.

[0081] Optionally, S3 may include:

[0082] The confidence and confidence threshold of the predicted positive sample are used to obtain the weight function;

[0083] Adjust the weight of the loss function corresponding to the predicted positive sample according to the weight function.

[0084] It can be understood that the confidence threshold μ is calculated based on the average value of the normalized four-dimensional box distance between the predicted positive sample and the real labeled object, and then compared with the predicted category confidence to distinguish "easy to distinguish samples", "fuzzy samples" and "small probability samples". The weight function is expressed as follows:

[0085]

[0086] Among them, f(x) represents the weight function, x represents the confidence of the predicted positive sample, and μ represents the confidence threshold.

[0087] Understandably, Figure 5is a schematic diagram of a weight function according to an exemplary embodiment. Figure 5 As shown in the figure, when the predicted confidence is less than the confidence threshold μ minus 0.2, the sample is considered to be a "low probability sample", and the weight of its loss function will be reduced; when the confidence is greater than the average value of the normalized four-dimensional box distance, the sample is considered to be an "easy to distinguish sample", and the weight of its loss function will also be reduced; when the confidence is between the two, these targets are "fuzzy samples" that need to be processed in detail, and their loss weight can be increased.

[0088] S4. Use the weight-adjusted loss function to train the target detection neural network.

[0089] It can be understood that using the weight-adjusted loss function to train the target detection neural network can make the trained neural network adaptively focus on samples that need to be processed emphatically, thereby improving the performance of the neural network in detecting small targets, occluded targets, etc.

[0090] In one embodiment, on the remote sensing target detection dataset DOTA, the YOLOV8 detection head and training strategy are replaced by the method of the present invention for network training. The results show that under the same training rounds, the accuracy is better than the original YOLOV8 model. At the same time, the number of detection head parameters is reduced from 800K to less than 100K.

[0091] Table 1

[0092]

[0093] The results in Table 1 fully demonstrate that the present invention can improve the average accuracy of target detection based on the original model under the same number of training rounds.

[0094] In another embodiment, the method of the present invention is used on the mainstream remote sensing target detection network. When performing remote sensing target detection, not only the parameter amount and the amount of calculation are far lower than other mainstream methods, but also an objective improvement in accuracy is brought about. Using the remote sensing target detection data set DOTA, the application of the method of the present invention has brought about a decrease in the parameter amount and an improvement in detection accuracy. After using the inventive method, the parameter amount of the YOLOv5n network has dropped from 1.67M to 1.05M, and the accuracy has increased from 56.2% to 59.0%. The method of the present invention is combined with the self-developed EtinyNet network, which not only has a parameter amount of 0.74M, but also a detection accuracy of 67.2%. Compared with the mainstream networks that have achieved this accuracy, the parameter amounts of the mainstream networks are all above 20M.

[0095] Figure 6 is a block diagram of a neural network training device according to an exemplary embodiment. Figure 6 As shown, the apparatus 600 may include:

[0096] A positive sample acquisition module 601 is used to obtain a predicted positive sample according to an output feature map of a target detection neural network; wherein the target detection neural network is used for remote sensing target detection; and a detection head network of the target detection neural network includes a parameter-sharing convolutional layer;

[0097] A threshold acquisition module 602 is used to obtain a confidence threshold according to a normalized four-dimensional box distance between a predicted positive sample and a corresponding real labeled object;

[0098] A weight adjustment module 603 is used to adjust the weight of the loss function corresponding to the predicted positive sample according to the confidence threshold;

[0099] The training module 604 is used to train the target detection neural network using the weight-adjusted loss function.

[0100] Regarding the device in the above embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.

[0101] Figure 7 is a block diagram of an electronic device for a neural network training method according to an exemplary embodiment. Figure 7 As shown, the electronic device 700 may include: a processor 701 and a memory 702 .

[0102] The processor 701 is used to control the overall operation of the electronic device 700 to complete all or part of the steps in the above-mentioned neural network training method. The memory 702 is used to store various types of data to support the operation of the electronic device 700, and these data may include, for example, instructions for any application or method used to operate on the electronic device 700, and application-related data, such as contact data, sent and received messages, pictures, audio, video, etc. The memory 702 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (Static Random Access Memory, referred to as SRAM), electrically erasable programmable read-only memory (Electrically Erasable Programmable Read-Only Memory, referred to as EEPROM), erasable programmable read-only memory (Erasable Programmable Read-Only Memory, referred to as EPROM), programmable read-only memory (Programmable Read-Only Memory, referred to as PROM), read-only memory (Read-Only Memory, referred to as ROM), magnetic memory, flash memory, magnetic disk or optical disk.

[0103] In an exemplary embodiment, the electronic device 700 can be implemented by one or more application specific integrated circuits (ASIC), digital signal processors (DSP), digital signal processing devices (DSPD), programmable logic devices (PLD), field programmable gate arrays (FPGA), controllers, microcontrollers, microprocessors or other electronic components to execute the above-mentioned neural network training method.

[0104] In another exemplary embodiment, a computer-readable storage medium including program instructions is also provided, and when the program instructions are executed by a processor, the steps of the above-mentioned neural network training method are implemented. For example, the computer-readable storage medium can be the above-mentioned memory 702 including program instructions, and the above-mentioned program instructions can be executed by the processor 701 of the electronic device 700 to complete the above-mentioned neural network training method.

[0105] Figure 88 is a block diagram of another electronic device for a neural network training method according to an exemplary embodiment. For example, the electronic device 800 may be provided as a server. Figure 8 The electronic device 800 includes a processor 822, which may be one or more, and a memory 832 for storing a computer program executable by the processor 822. The computer program stored in the memory 832 may include one or more modules each corresponding to a set of instructions. In addition, the processor 822 may be configured to execute the computer program to perform the above-mentioned neural network training method.

[0106] In another exemplary embodiment, a computer-readable storage medium including program instructions is also provided, and when the program instructions are executed by the processor, the steps of the above-mentioned neural network training method are implemented. For example, the non-transitory computer-readable storage medium can be the above-mentioned memory 832 including program instructions, and the above-mentioned program instructions can be executed by the processor 822 of the electronic device 800 to complete the above-mentioned neural network training method.

[0107] In another exemplary embodiment, a computer program product is also provided. The computer program product includes a computer program that can be executed by a programmable device. The computer program has a code portion for executing the above-mentioned neural network training method when executed by the programmable device.

[0108] The preferred embodiments of the present invention are described in detail above in conjunction with the accompanying drawings. However, the present invention is not limited to the specific details in the above embodiments. Within the technical concept of the present invention, a variety of simple modifications can be made to the technical solution of the present invention, and these simple modifications all belong to the protection scope of the present invention.

[0109] It should also be noted that the various specific technical features described in the above specific embodiments can be combined in any suitable manner without contradiction. In order to avoid unnecessary repetition, the present invention will not further describe various possible combinations.

[0110] In addition, various embodiments of the present invention may be arbitrarily combined, and as long as they do not violate the concept of the present invention, they should also be regarded as the contents disclosed by the present invention.

Claims

1. A neural network training method, characterized in that: The method comprises: A predicted positive sample is obtained according to an output feature map of a target detection neural network; wherein the target detection neural network is used for remote sensing target detection; and a detection head network of the target detection neural network includes a parameter-sharing convolutional layer; Obtaining a confidence threshold according to a normalized four-dimensional box distance between the predicted positive sample and the corresponding real labeled object; Adjusting the weight of the loss function corresponding to the predicted positive sample according to the confidence threshold; The target detection neural network is trained using the weight-adjusted loss function.

2. The neural network training method according to claim 1, characterized in that: Before obtaining a predicted positive sample according to the output feature map of the target detection neural network, the method further includes: Obtain a feature map of the target object; The feature map is adjusted using a convolution kernel of a set scale to obtain a feature map with a uniform number of channels; An output feature map is obtained according to the feature map with unified channel number.

3. The neural network training method according to claim 2, characterized in that: The step of obtaining an output feature map according to the feature map with unified channel number includes: Dividing the feature maps with a uniform number of channels into a first group of feature maps and a second group of feature maps; dividing the first group of feature maps into a third group of feature maps and a fourth group of feature maps; Using convolution kernels of different scales to perform convolution operations on the second group of feature maps, the third group of feature maps, and the fourth group of feature maps, respectively, to obtain feature maps of different scales; Performing batch normalization processing on the feature maps of different scales to obtain effective feature layers; After the effective feature layer is processed by the parameter-sharing convolutional layer, the scale is adjusted using a scaling parameter to obtain the output feature map.

4. The neural network training method according to claim 1, characterized in that: The normalized four-dimensional box distance between the predicted positive sample and the corresponding real labeled object is defined as follows: Where D represents the normalized four-dimensional box distance between the predicted positive sample and the corresponding real labeled object, M represents the average scale of the real labeled object, e is the natural exponent, (x a ,y a ) is the center coordinate of the predicted positive sample bounding box, w a is the width of the predicted positive sample bounding box, h a is the height of the predicted positive sample bounding box, (x b ,y b ) is the center coordinate of the real labeled object bounding box, w b is the width of the bounding box of the real labeled object, h b is the height of the bounding box of the real labeled object.

5. The neural network training method according to claim 4, characterized in that: The average scale of the real annotated object is obtained by referring to the following formula: Among them, P is the number of pixels occupied by real annotations in each training batch, and batch represents the number of batches.

6. The neural network training method according to claim 1, characterized in that: The adjusting the weight of the loss function corresponding to the predicted positive sample according to the confidence threshold comprises: Obtain a weight function by combining the confidence of the predicted positive sample and the confidence threshold; The weight of the loss function corresponding to the predicted positive sample is adjusted according to the weight function.

7. The neural network training method according to claim 6, characterized in that: The weight function is represented as follows: Wherein, f(x) represents the weight function, x represents the confidence of the predicted positive sample, and μ represents the confidence threshold.

8. A neural network training device, characterized in that: The device comprises: A positive sample acquisition module, used to obtain predicted positive samples according to the output feature map of the target detection neural network; wherein the target detection neural network is used for remote sensing target detection; the detection head network of the target detection neural network includes a parameter-sharing convolutional layer; A threshold acquisition module, used to obtain a confidence threshold according to the normalized four-dimensional box distance between the predicted positive sample and the corresponding real labeled object; A weight adjustment module, used to adjust the weight of the loss function corresponding to the predicted positive sample according to the confidence threshold; The training module is used to train the target detection neural network using the weight-adjusted loss function.

9. An electronic device, characterized in that: include: processor; a memory for storing processor-executable instructions; The processor is configured to execute the executable instructions to implement the steps of the neural network training method according to any one of claims 1 to 7.

10. A computer-readable storage medium having computer program instructions stored thereon, characterized in that: When the program instructions are executed by a processor, the steps of the neural network training method according to any one of claims 1 to 7 are implemented.