A balanced loss-based target detection method, system, device and medium

By introducing a composite loss function of Balance Loss and Dice Loss into the Octave convolutional neural network, the problem of foreground-background imbalance in small object detection is solved, improving detection accuracy and reducing the waste of computational resources.

CN116563700BActive Publication Date: 2026-04-10JIANGSU IND INNOVATION CENT OF INTELLIGENT EQUIP CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-03-31
Publication Date
2026-04-10

AI Technical Summary

Technical Problem

In existing technologies, the cross-entropy loss function lacks generalization ability, which easily leads to the phenomenon of complete black when detecting small objects. Especially in computer vision tasks where the foreground and background are unbalanced, the detection model has difficulty effectively distinguishing small objects from the background.

Method used

We employ the Balance Loss function based on Octave convolutional neural networks. By constructing a composite loss function combining the Balance Loss and Dice Loss functions, we adjust the number of targets in each category and set different weights to balance the foreground and background, thus building an object detection model.

Benefits of technology

It effectively reduces the impact of input and result imbalance, avoids the situation of completely black objects in object detection, improves the accuracy of the detection model, and reduces the waste of computing resources.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116563700B_ABST
    Figure CN116563700B_ABST
Patent Text Reader

Abstract

The application discloses a target detection method and system based on balance loss, equipment and a medium, the method comprises the following steps: constructing a first network structure based on an Octave convolutional neural network; constructing a Balance Loss loss function for the first network structure; constructing a first target detection model based on the first network structure and the Balance Loss loss function; confirming a to-be-detected image, and performing target detection on the to-be-detected image based on the first target detection model; and the application can regard all pixels of one category as a whole in a visual detection task of a small target in a large background, avoid the case that target detection appears black, and effectively reduce the influence of input imbalance and result imbalance.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of artificial intelligence technology, specifically to the field of target detection, and particularly to a target detection method, system, device, and medium based on balance loss. Background Technology

[0002] In the field of artificial intelligence, object detection technology is widely used in industry and daily life. Among them, small object detection technology aims to accurately detect objects with extremely small visual features in images, which is a difficult point in object detection technology. However, small object detection technology plays a very important role in autonomous driving, smart healthcare, aerial imaging, and defect detection.

[0003] In actual detection, small targets usually lack sufficient appearance information, making it difficult to distinguish them from background pixels. In addition, due to the complexity of real scenes, the influence of external lighting and the changes in the scale of the target further increase the difficulty of detecting small targets.

[0004] Current solutions typically employ detection models for small object detection. To address the aforementioned issues, loss functions are often used to improve the performance of these models, thereby enhancing detection accuracy. The impact of different loss functions on model performance varies significantly. Among existing technologies, cross-entropy loss is one of the most commonly used category-based probabilistic loss functions, widely applied in computer vision tasks such as object detection and image segmentation. To improve the performance of this type of loss function, numerous optimization algorithms have been proposed:

[0005] For example, the Binary Cross-Entropy Loss (BCE) function first normalizes the vector into a probability distribution and then uses the cross-entropy function to calculate the loss. However, in the training of segmentation tasks, if the number of foreground pixels is much smaller than the number of background pixels, it will cause the detection model to be severely biased towards the background, and the segmentation result will be completely black.

[0006] For example, the Weighted Cross-Entropy Loss function adds weighting parameters to the positive samples of each class, based on the Binary Cross-Entropy Loss function. Similarly, the Balanced Cross-Entropy Loss function weights the negative samples. In addition to weighting positive and negative samples, there is the Focal Loss function, which focuses on difficult samples by assigning greater weights to samples that are hard to classify. For positive samples, it increases attention to difficult samples by making the loss function of easy samples smaller and the loss function of difficult samples larger.

[0007] Therefore, the above loss function can adjust the class balance by weighting the samples, thereby adjusting the ratio of false positives in the background and false negatives in the foreground. However, in the case of class imbalance, the detection network will tend to learn simple samples during training, which will reduce the feature extraction ability of difficult samples, ultimately leading to a completely black detection result. Moreover, the direction of loss function reduction is inconsistent with the direction of network optimization. In order to make up for the above shortcomings, existing technologies have designed composite loss functions, such as the Combo Loss function, which is composed of the cross-entropy loss function and the Dice Loss function. When the data is relatively balanced, this loss function can make up for the shortcomings of a single function. However, in the case of extremely imbalanced data, after several rounds of training, the cross-entropy loss function will be much smaller than the Dice Loss function, which will affect the training effect.

[0008] In summary, based on existing research findings, current improvements to the cross-entropy loss function mainly focus on discriminative studies of visual feature learning, while lacking improvements in generalization. In particular, in computer vision tasks, there is a widespread problem of foreground-background imbalance, which can easily lead to completely black objects when detecting small targets. Summary of the Invention

[0009] The purpose of this invention is to address the aforementioned problems in the prior art by providing a target detection method, system, device, and medium based on balanced loss, thereby solving the problems of the lack of generalization improvement of the cross-entropy loss function in the prior art, the widespread existence of foreground and background imbalance in computer vision tasks, and the tendency to produce completely black targets when detecting small targets.

[0010] To solve the above-mentioned technical problems, the specific technical solution of the present invention is as follows:

[0011] On the one hand, the present invention provides a target detection method based on balance loss, comprising the following steps:

[0012] Construct the first network structure based on the Octave convolutional neural network;

[0013] Construct a Balance Loss function for the first network structure;

[0014] Construct a first object detection model based on the first network structure and the Balance Loss function; identify the image to be detected, and perform object detection on the image based on the first object detection model.

[0015] As an improved approach, the Balance Loss function is:

[0016]

[0017] In the Balance Loss function, N represents the set of pixels in the image to be detected, and x... n To input an instance identifier, For input instance x n The standard pixel value, For input instance x n The background prediction probability value, β is the weight added to the pixels in the foreground category, and ω is the background prediction probability value. x γ represents the weight of the corresponding instance x, γ is the function contribution value; β is calculated from the background probability ratio formula and the background category formula; ω x It is calculated using the weighting formula.

[0018] As an improved approach, the background probability ratio formula is:

[0019] In the background probability ratio formula The probability and value of pixels predicted as background;

[0020] In the background probability ratio formula The probability and value of a pixel being predicted as a foreground element;

[0021] In the background probability ratio formula, n is the number of instances x.

[0022] As an improved approach, the background category formula is β + ξ = 1;

[0023] In the background category formula, ξ is the background category corresponding to instance x, and the background category includes: background and foreground.

[0024] As an improved solution, the weighting formula is as follows:

[0025] As an improved approach, the function contribution value is the contribution value of each function factor in the Balance Loss function to the Balance Loss function.

[0026] As an improved approach, the target detection method based on equilibrium loss further includes:

[0027] When the first object detection model is constructed based on the first network structure and a composite loss function that includes the BalanceLoss loss function, the second loss function in the composite loss function is confirmed;

[0028] If the second loss function is the Dice Loss loss function, then let the Balance Loss loss function be used as the regularization term of the Dice Loss loss function.

[0029] On the other hand, the present invention also provides a target detection system based on balance loss, comprising:

[0030] The first structure construction module, function construction module, and target detection module;

[0031] The first structure construction module is used to construct a first network structure based on the Octave convolutional neural network;

[0032] The function construction module is used to construct a Balance Loss function for the first network structure;

[0033] The target detection module is used to construct a first target detection model based on the first network structure and the Balance Loss function; the target detection module confirms the image to be detected, and the target detection module performs target detection on the image to be detected based on the first target detection model.

[0034] On the other hand, the present invention also provides a computer-readable storage medium storing a computer program, which, when executed by a processor, implements the steps of the target detection method based on balance loss.

[0035] On the other hand, the present invention also provides a computer device, the computer device including a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other through the communication bus; wherein:

[0036] The memory is used to store computer programs;

[0037] The processor is configured to execute the steps of the target detection method based on balance loss by running a program stored in the memory.

[0038] The beneficial effects of the technical solution of this invention are:

[0039] 1. The target detection method based on balanced loss described in this invention adds a foreground-aware optimized loss function to the Octave convolutional network. The detection model built based on the Octave convolutional network and the foreground-aware optimized loss function can adjust the number of targets in each category by setting different weights, thus avoiding the impact of category imbalance. In actual target detection operations, this effectively reduces the impact of input imbalance and result imbalance. Furthermore, this invention can treat all pixels of a category as a whole, avoiding the occurrence of completely black targets. Moreover, the Octave convolutional network structure on which this invention is based is easy to use, and this structure can significantly improve the accuracy of the detection model and reduce the waste of computational resources.

[0040] 2. The target detection system based on balanced loss described in this invention can achieve the addition of a foreground-aware optimized loss function to the Octave convolutional network through the cooperation of the first structure construction module, function construction module, and target detection module. The detection model built based on the Octave convolutional network and the foreground-aware optimized loss function can adjust the number of targets in each category by setting different weights, thus avoiding the impact of category imbalance. In actual target detection operations, this can effectively reduce the impact of input imbalance and result imbalance. Furthermore, this invention can treat all pixels of a category as a whole, avoiding the occurrence of completely black targets. Moreover, the Octave convolutional network structure on which this invention is based is easy to use, and this structure can significantly improve the accuracy of the detection model and reduce the waste of computational resources.

[0041] 3. The computer-readable storage medium of the present invention can guide the first structure construction module, the function construction module and the target detection module to cooperate, thereby realizing the target detection method based on balance loss of the present invention. The computer-readable storage medium of the present invention also effectively improves the operability of the target detection method based on balance loss.

[0042] 4. The computer device described in this invention can store and execute the computer-readable storage medium, thereby realizing the target detection method based on balance loss described in this invention. Attached Figure Description

[0043] To more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the specific embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.

[0044] Figure 1 This is a flowchart illustrating the target detection method based on balance loss as described in Embodiment 1 of the present invention;

[0045] Figure 2 This is a schematic diagram showing the actual comparative effect of the target detection method based on balance loss described in Embodiment 1 of the present invention;

[0046] Figure 3 This is a schematic diagram of the target detection system based on balanced loss as described in Embodiment 2 of the present invention;

[0047] Figure 4 This is a schematic diagram of the structure of the computer device described in Embodiment 4 of the present invention;

[0048] The markings in the attached diagram are explained as follows:

[0049] 1501. Processor; 1502. Communication interface; 1503. Memory; 1504. Communication bus. Detailed Implementation

[0050] The preferred embodiments of the present invention will now be described in detail with reference to the accompanying drawings, so that the advantages and features of the present invention can be more easily understood by those skilled in the art, thereby providing a clearer and more explicit definition of the scope of protection of the present invention.

[0051] In the description of this invention, it should be noted that the embodiments described in this invention are only some embodiments of this invention, not all embodiments; based on the embodiments of this invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this invention.

[0052] The terms "first," "second," etc., used in this specification, claims, and accompanying drawings are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, apparatus, product, or device that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or devices.

[0053] It should be noted that this invention is mainly applied in small target detection scenarios, such as signal detection, fundus blood vessel segmentation, and road crack detection.

[0054] In the description of this invention, it should be noted that:

[0055] CFD (CrackForest-dataset) is an open-source crack dataset;

[0056] True Positive (TP) is a correct prediction that is considered a positive example.

[0057] FP (False Positive) is when a false prediction is made as a positive example;

[0058] TN (True Negative) indicates that a correct prediction is a negative example.

[0059] Acc (Accuracy) is the accuracy rate;

[0060] Precision (Precision) is the accuracy rate;

[0061] Rec (Recall) is the recall rate.

[0062] Example 1

[0063] This embodiment provides a target detection method based on balance loss, such as Figure 1 and Figure 2 As shown, it includes the following steps:

[0064] S100. Constructing the first network structure based on the Octave convolutional neural network, specifically including: In this method, the Octave convolutional structure of the Octave convolutional neural network is a plug-and-play structure. In practical applications, the Octave convolutional neural network can decompose the input natural image into two parts: low spatial frequency and high spatial frequency. The output map of its convolutional layer can also be decomposed and grouped according to its spatial frequency. Furthermore, the Octave convolutional neural network can also store the smoothly changing low-frequency mapping in a low-resolution tensor, thereby reducing spatial redundancy. The Octave convolutional neural network can also directly operate on the decomposed feature map. Therefore, using the Octave convolutional structure as the basic network structure of the neural network in this method is beneficial to improving the detection accuracy of the model and reducing the waste of computing resources.

[0065] S200. Construct a Balance Loss function (i.e., a balanced loss function) for the first network structure, specifically including:

[0066] In one embodiment of the present invention, the Balance Loss function is a foreground-aware optimization function. This function was independently developed and designed to solve the task of detecting small targets in a large background. In order to perform target detection more accurately and in a balanced manner, the formula of the Balance Loss function is as follows:

[0067]

[0068] Where N is the set value of pixels in the image to be detected, and the set value of pixels refers to the set of all pixels in the image to be detected, x n To input an instance identifier, For input instance x n The standard pixel value, For input instance x n The background prediction probability value; in the above formula, β is the weight added to the pixels in the foreground category. The actual meaning of β represents the ratio of the sum of probabilities of all pixels predicted as background to the sum of probabilities of all pixels predicted as foreground in the predicted probability map during the object detection process. It is specifically calculated by the background probability ratio formula and the background category formula; specifically, the background probability ratio formula is,

[0069]

[0070] The background probability is higher than that in the formula. Let be the probability and value of a pixel predicted as background. Let n be the probability and value of a pixel predicted as foreground, and n be the number of instances x. Specifically, based on the same principle, the background category formula is β + ξ = 1, where ξ is the background category corresponding to instance x, and the background category includes: background and foreground.

[0071] Furthermore, in the formula for the Balance Loss function, ω x ω represents the weight of the corresponding instance x. x It is mainly used to maintain the invariance of attributes across different label sets and to balance the contributions of various target regions and background types to the Balance Loss function, while ω x The weighting formula is calculated from the weighting formula, specifically, the weighting formula is:

[0072]

[0073] The factor part has the same definition as the factor in the above formula;

[0074] Furthermore, in the formula of the Balance Loss function, γ is the function contribution value, which specifically refers to the contribution value of each function factor part to the Balance Loss function.

[0075] S300. Construct a first object detection model based on the first network structure and the Balance Loss function; confirm the image to be detected, and perform object detection on the image to be detected based on the first object detection model, specifically including:

[0076] As one embodiment of the present invention, considering the case of constructing a detection model using a composite loss function, when the first target detection model is constructed based on the first network structure and a composite loss function including the Balance Loss loss function, the second loss function in the composite loss function is identified. The second loss function is the other loss function in the composite loss function besides the Balance Loss loss function. If the second loss function is the Dice Loss loss function (i.e., the generalized dice loss function), then the Balance Loss loss function is used as the regularization term of the Dice Loss loss function, thereby avoiding instability and overfitting during model training.

[0077] In this embodiment, to demonstrate that the proposed method effectively overcomes the class imbalance problem and the imbalance in the number of classes in the large background small target detection task, the CFD and AigleRN datasets are used to compare and verify the model built in this method, and the following comparative experimental results are shown in Table 1:

[0078] Table 1. Comparison of experimental results:

[0079]

[0080] Furthermore, in this embodiment, to compare the performance differences between the balanced loss and existing generalized loss (GDL) and balanced cross-entropy (BCE), ACC, F1, and Pre were used as test metrics on the CDF and AigleRN datasets. The test results are as follows: Figure 2 As shown, in conjunction with Table 1 and Figure 2 It can be clearly observed that the Balance Loss function performs best in both CFD and AigleRN. Therefore, the target detection method based on the Balance Loss in this invention can not only make full use of the advantages of the generalized loss function, but also effectively reduce the impact of input imbalance and result imbalance.

[0081] Example 2

[0082] This embodiment is based on the same inventive concept as the target detection method based on balance loss described in Embodiment 1, and provides a target detection system based on balance loss, such as... Figure 3 As shown, it includes: a first structure construction module, a function construction module, and a target detection module;

[0083] The first structure construction module is used to construct a first network structure based on the Octave convolutional neural network;

[0084] The function construction module is used to construct a Balance Loss function for the first network structure;

[0085] As one embodiment of the present invention, the Balance Loss function is:

[0086]

[0087] In the Balance Loss function, N represents the set of pixels in the image to be detected, and x... n To input an instance identifier, For input instance x n The standard pixel value, For input instance x n The background prediction probability value, β is the weight added to the pixels in the foreground category, and ω is the background prediction probability value. x γ represents the weight of the corresponding instance x, γ is the function contribution value; β is calculated from the background probability ratio formula and the background category formula; ω x It is calculated using the weighting formula.

[0088] In one embodiment of the present invention, the background probability ratio formula is:

[0089] In the background probability ratio formula The probability and value of pixels predicted as background;

[0090] In the background probability ratio formula The probability and value of a pixel being predicted as a foreground element;

[0091] In the background probability ratio formula, n is the number of instances x.

[0092] In one embodiment of the present invention, the background category formula is β+ξ=1;

[0093] In the background category formula, ξ is the background category corresponding to instance x, and the background category includes: background and foreground.

[0094] As one embodiment of the present invention, the weighting formula is:

[0095]

[0096] In one embodiment of the present invention, the function contribution value is the contribution value of each function factor in the Balance Loss function to the Balance Loss function.

[0097] The target detection module is used to construct a first target detection model based on the first network structure and the Balance Loss function; the target detection module confirms the image to be detected, and the target detection module performs target detection on the image to be detected based on the first target detection model.

[0098] As one embodiment of the present invention, when the first target detection model is constructed based on the first network structure and a composite loss function including the Balance Loss loss function, the second loss function in the composite loss function is confirmed;

[0099] If the second loss function is the Dice Loss loss function, then let the Balance Loss loss function be used as the regularization term of the Dice Loss loss function.

[0100] Example 3

[0101] This embodiment provides a computer-readable storage medium, including:

[0102] The storage medium is used to store computer software instructions for implementing the target detection method based on balance loss as described in Embodiment 1 above. It includes a program for executing the target detection method based on balance loss described above. Specifically, the executable program can be built into the target detection system based on balance loss described in Embodiment 2. In this way, the target detection system based on balance loss can implement the target detection method based on balance loss described in Embodiment 1 by executing the built-in executable program.

[0103] Furthermore, the computer-readable storage medium in this embodiment can be any combination of one or more readable storage media, wherein the readable storage medium includes an electrical, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof.

[0104] Example 4

[0105] This embodiment provides an electronic device, such as... Figure 4 As shown, the electronic device may include: a processor 1501, a communication interface 1502, a memory 1503, and a communication bus 1504, wherein the processor 1501, the communication interface 1502, and the memory 1503 communicate with each other through the communication bus 1504.

[0106] Memory 1503 is used to store computer programs;

[0107] When the processor 1501 executes the computer program stored in the memory 1503, it implements the steps of the target detection method based on balance loss described in Embodiment 1 above.

[0108] As one embodiment of the present invention, the communication bus mentioned in the terminal above can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. This communication bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 4 The bus is represented by a single thick line, but this does not mean that there is only one bus or one type of bus.

[0109] As one embodiment of the present invention, the communication interface is used for communication between the aforementioned terminal and other devices.

[0110] In one embodiment of the present invention, the memory may include random access memory (RAM) or non-volatile memory, such as at least one disk storage device. Optionally, the memory may also be at least one storage device located remotely from the aforementioned processor.

[0111] As one embodiment of the present invention, the processor described above may be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it may also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components.

[0112] Unlike existing technologies, the target detection method, system, device, and medium based on balanced loss proposed in this application add a foreground-aware optimized loss function to the Octave convolutional network. The detection model built based on the Octave convolutional network and the foreground-aware optimized loss function can adjust the number of targets in each category by setting different weights, thus avoiding the impact of category imbalance. In actual target detection operations, this effectively reduces the impact of input imbalance and result imbalance. Furthermore, this invention can treat all pixels of a category as a whole, avoiding the occurrence of completely black targets. Moreover, the Octave convolutional network structure on which this invention is based is easy to use, and this structure can significantly improve the accuracy of the detection model and reduce the waste of computational resources.

[0113] It should be understood that in the various embodiments of this document, the sequence number of each process does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this document.

[0114] It should also be understood that, in the embodiments herein, the term "and / or" is merely a description of the relationship between associated objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, and B existing alone. Additionally, the character " / " in this document generally indicates that the preceding and following associated objects have an "or" relationship.

[0115] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this document.

[0116] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.

[0117] In the embodiments provided herein, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the couplings or direct couplings or communication connections shown or discussed may be indirect couplings or communication connections through some interfaces, devices, or units, or they may be electrical, mechanical, or other forms of connection.

[0118] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of the embodiments described herein, depending on actual needs.

[0119] Furthermore, the functional units in the various embodiments of this document can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.

[0120] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this paper, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this paper. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0121] The above description is merely an embodiment of the present invention and does not limit the patent scope of the present invention. Any equivalent structural or procedural transformations made based on the content of the present invention's specification and drawings, or direct or indirect applications in other related technical fields, are similarly included within the patent protection scope of the present invention.

Claims

1. A balanced loss-based object detection method, characterized in that, The method comprises the following steps: constructing a first network structure based on an Octave convolutional neural network; constructing a Balance Loss loss function for the first network structure; constructing a first target detection model based on the first network structure and the Balance Loss loss function; confirming a to-be-detected image, and performing target detection on the to-be-detected image based on the first target detection model; The Balance Loss loss function is: ; In the Balance Loss loss function, N is the pixel set value in the image to be detected, is the input instance identification, is the input instance pixel standard value, is the input instance background prediction probability value, is the weight added to the foreground category pixel, is the weight corresponding to the instance x, is the function contribution value; calculated by the background probability ratio formula and the background category formula; calculated by the weight formula.

2. The target detection method based on a Balance Loss according to claim 1, wherein: in the background probability ratio formula, n is the number of instances x. The background probability ratio formula is, ; The background probability ratio formula is is the probability and value of a pixel predicted as background. The background probability ratio formula is is the probability and value of a pixel predicted as foreground.

3. The target detection method based on a Balance Loss according to claim 1, wherein:

4. The target detection method based on a Balance Loss according to claim 1, wherein: The background category formula is, ; The background class formula includes: The background class corresponding to the instance x includes: background and foreground.

5. The target detection method based on a Balance Loss according to claim 1, wherein: the function contribution value is the contribution value of each function factor to the Balance Loss loss function in the Balance Loss loss function. The weight formula is, .

6. The target detection method based on a Balance Loss according to claim 1, wherein: The target detection method based on a Balance Loss further comprises: when the first target detection model is constructed based on the first network structure and a composite loss function containing the Balance Loss loss function, confirming a second loss function in the composite loss function; if the second loss function is a Dice Loss loss function, the Balance Loss loss function is used as a regularization term of the Dice Loss loss function. The system comprises a first structure construction module, a function construction module and a target detection module; The first structure construction module is configured to construct a first network structure based on an Octave convolutional neural network; 7. A balanced loss-based object detection system based on the balanced loss-based object detection method according to any one of claims 1-6, characterized in that, The function construction module is configured to construct a Balance Loss loss function for the first network structure; The target detection module is configured to construct a first target detection model based on the first network structure and the Balance Loss loss function; the target detection module confirms a to-be-detected image, and the target detection module performs target detection on the to-be-detected image based on the first target detection model. The computer readable storage medium stores a computer program, and the computer program is executed by a processor to implement the steps of the target detection method based on a Balance Loss in any one of claims 1-6. The system comprises a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory complete mutual communication through the communication bus; wherein:

8. A computer-readable storage medium, characterized in that, The memory is configured to store a computer program; 9. A computer device, comprising: The processor is configured to execute the steps of the target detection method based on a Balance Loss in any one of claims 1-6 by running the program stored in the memory. ​ ​

Citation Information

Patent Citations

  • Spatial spectrum attention hyperspectral image classification method based on Octave convolution

    CN110516596A