Image complexity evaluation method, device and equipment and readable storage medium
By comprehensively calculating the local background, target saliency and texture features, the complexity evaluation of infrared small target images is achieved, which solves the problem of poor performance of the infrared small target detection algorithm in complex scenes and improves the quality and accuracy of the detection algorithm.
Patent Information
- Application Number
- CN202410701234.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-31
- Publication Date
- 2024-08-23
AI Technical Summary
Existing infrared small target detection algorithms have poor application results in complex scenes, mainly due to the low contrast and low signal-to-noise ratio of infrared images, and the lack of effective image complexity evaluation methods, resulting in poor quality and accuracy of detection algorithms.
An image complexity evaluation method is proposed to achieve comprehensive and accurate quantification of image complexity through the comprehensive calculation of local background measurement values, global target saliency measurement values, global image grayscale statistical measurement values and global image texture feature measurement values. evaluate. Specific steps include calculating local contrast, global target saliency and texture features, combined with normalization processing to obtain image complexity.
It effectively improves the training quality and prediction accuracy of the infrared small target detection algorithm, accurately reflects the complexity of the image and the difficulty of detection, helps to screen out difficult high-quality data sets, and improves the performance of the detection algorithm.
Smart Images

Figure CN118537274A
Abstract
Description
Technical Field
[0001] The present application relates to the field of target detection technology, and in particular to an image complexity evaluation method, device, equipment and readable storage medium. Background Art
[0002] Infrared small target detection is an important technology, which is widely used in military, security, astronomy and other fields. However, due to the complexity of infrared images, such as low contrast, low signal-to-noise ratio and other problems, the infrared small target detection algorithm has poor application effect in some complex scenes. In addition, with the enrichment of infrared small target data sets, infrared small target detection algorithms based on deep learning have been supported by a large number of samples; and in the field of deep learning, high-quality data sets can often improve the quality of model training and the accuracy of prediction. Specifically, the development process of infrared small target detection requires complex data sets that match the difficulty of actual application scenarios to reduce the training participation of overly simple data sets; therefore, in order to obtain an effective infrared small target detection algorithm with low missed detection and false alarm rates, it is necessary to improve the development process, and then effectively screen out difficult infrared small target images to meet the detection needs in real and complex scenes. It can be seen that accurately evaluating the complexity of infrared small target images to screen difficult training samples has become a key task.
[0003] In the related art, when developing infrared small target detection algorithms, data cleaning and other preprocessing are usually performed, but the complexity evaluation and screening of data samples are not performed during the development process, resulting in poor quality and prediction accuracy of the constructed infrared small target detection algorithm. Therefore, how to effectively implement the evaluation of image complexity is an urgent problem to be solved. Summary of the invention
[0004] The present application provides an image complexity evaluation method, apparatus, device and readable storage medium, which can effectively realize comprehensive and accurate quantitative evaluation of image complexity.
[0005] In a first aspect, an embodiment of the present application provides an image complexity evaluation method, comprising the following steps:
[0006] Determine the local background metric value according to the pixels of the target area in the image to be evaluated and the pixels of the corresponding neighborhood window;
[0007] The global target saliency metric of the image to be evaluated is calculated by a preset target confusion algorithm;
[0008] Determine the global image grayscale statistical measurement value of the image to be evaluated based on the unary grayscale entropy;
[0009] Calculate the global image texture feature measurement value of the image to be evaluated according to the preset gray level co-occurrence matrix analysis algorithm;
[0010] The complexity of the image to be evaluated is determined based on the local background measurement value, the global target saliency measurement value, the global image grayscale statistical measurement value and the global image texture feature measurement value.
[0011] In combination with the first aspect, in one implementation, determining the local background metric value based on pixels of the target area in the image to be evaluated and pixels of the corresponding neighborhood window includes:
[0012] For each target in the image to be evaluated, the local contrast of the target is calculated based on the pixels in the target area and the average value of the pixels in the neighborhood window corresponding to the target area;
[0013] The minimum local contrast is screened out from all local contrasts, and the minimum local contrast is normalized to obtain a local background measurement value.
[0014] In combination with the first aspect, in one implementation, the normalizing the minimum local contrast to obtain a local background metric value includes:
[0015] The minimum local contrast is normalized based on a first normalization function to obtain a local background measurement value, wherein the first normalization function is:
[0016] LC=e -C1 / 2
[0017] Where LC represents the local background metric and C1 represents the minimum local contrast.
[0018] In combination with the first aspect, in one implementation, calculating the global target saliency metric of the image to be evaluated by using a preset target confusion algorithm includes:
[0019] Performing top hat transformation and bottom hat transformation on the image to be evaluated respectively, and performing image fusion based on the transformation results and the image to be evaluated to generate a target image;
[0020] Performing threshold segmentation on the target image based on the maximum inter-class variance method to generate a binary image;
[0021] The number of suspected targets in the binary image is determined according to the four-connectivity rule, and the number of suspected targets is normalized to obtain a global target saliency measure.
[0022] In combination with the first aspect, in one implementation, determining the number of suspected targets in the binary image according to the four-connectivity rule includes:
[0023] Determine all target connected regions existing in the binary image based on the four-connectivity rule;
[0024] For each target connected area, determining whether the pixel value of the target connected area is less than or equal to a preset suspected target pixel threshold;
[0025] If yes, the number of suspected targets corresponding to the target connected area is 1;
[0026] If not, the ratio between the suspected target pixel threshold and the pixel value of the target connected area is used as the number of suspected targets corresponding to the target connected area;
[0027] The sum of the number of suspected targets corresponding to all target connected regions is taken as the number of suspected targets existing in the binary image.
[0028] In combination with the first aspect, in one implementation, normalizing the number of suspected targets to obtain a global target saliency measure value includes:
[0029] The number of suspected targets is normalized based on a second normalization function to obtain a global target saliency measure value, wherein the second normalization function is:
[0030] DTC = 1 – e -m / 2
[0031] Where DTC represents the global target saliency measure, and m represents the number of suspected targets.
[0032] In combination with the first aspect, in one implementation, calculating the global image texture feature metric value of the image to be evaluated according to a preset gray level co-occurrence matrix analysis algorithm includes:
[0033] Calculate the contrast of the image to be evaluated according to the preset gray level co-occurrence matrix analysis algorithm;
[0034] The contrast of the image to be evaluated is normalized according to a third normalization function to obtain a global image texture feature metric value, wherein the third normalization function is:
[0035] CON=1–e -C2 / 30
[0036] Where CON represents the global image texture feature metric, and C2 represents the contrast of the image to be evaluated.
[0037] In a second aspect, an embodiment of the present application provides an image complexity evaluation device, comprising:
[0038] A first processing module, which is used to determine a local background metric value based on pixels of a target area in an image to be evaluated and pixels of a corresponding neighborhood window;
[0039] A second processing module, which is used to calculate the global target saliency measurement value of the image to be evaluated by using a preset target confusion algorithm;
[0040] A third processing module, which is used to determine the global image grayscale statistical measurement value of the image to be evaluated based on the unary grayscale entropy;
[0041] A fourth processing module, which is used to calculate the global image texture feature measurement value of the image to be evaluated according to a preset gray level co-occurrence matrix analysis algorithm;
[0042] The complexity evaluation module is used to determine the complexity of the image to be evaluated based on the local background measurement value, the global target saliency measurement value, the global image grayscale statistical measurement value and the global image texture feature measurement value.
[0043] In conjunction with the second aspect, in one implementation, the first processing module is specifically configured to:
[0044] For each target in the image to be evaluated, the local contrast of the target is calculated based on the pixels in the target area and the average value of the pixels in the neighborhood window corresponding to the target area;
[0045] The minimum local contrast is screened out from all local contrasts, and the minimum local contrast is normalized to obtain a local background measurement value.
[0046] In conjunction with the second aspect, in one implementation, the first processing module is further configured to:
[0047] The minimum local contrast is normalized based on a first normalization function to obtain a local background measurement value, wherein the first normalization function is:
[0048] LC=e -C1 / 2
[0049] Where LC represents the local background metric and C1 represents the minimum local contrast.
[0050] In conjunction with the second aspect, in one implementation, the second processing module is specifically configured to:
[0051] Performing top hat transformation and bottom hat transformation on the image to be evaluated respectively, and performing image fusion based on the transformation results and the image to be evaluated to generate a target image;
[0052] Performing threshold segmentation on the target image based on the maximum inter-class variance method to generate a binary image;
[0053] The number of suspected targets in the binary image is determined according to the four-connectivity rule, and the number of suspected targets is normalized to obtain a global target saliency measure.
[0054] In conjunction with the second aspect, in one implementation, the second processing module is further configured to:
[0055] Determine all target connected regions existing in the binary image based on the four-connectivity rule;
[0056] For each target connected area, determining whether the pixel value of the target connected area is less than or equal to a preset suspected target pixel threshold;
[0057] If yes, the number of suspected targets corresponding to the target connected area is 1;
[0058] If not, the ratio between the suspected target pixel threshold and the pixel value of the target connected area is used as the number of suspected targets corresponding to the target connected area;
[0059] The sum of the number of suspected targets corresponding to all target connected regions is taken as the number of suspected targets existing in the binary image.
[0060] In conjunction with the second aspect, in one implementation, the second processing module is further configured to:
[0061] The number of suspected targets is normalized based on a second normalization function to obtain a global target saliency measure value, wherein the second normalization function is:
[0062] DTC = 1 – e -m / 2
[0063] Where DTC represents the global target saliency measure, and m represents the number of suspected targets.
[0064] In conjunction with the second aspect, in one implementation, the fourth processing module is specifically configured to:
[0065] Calculate the contrast of the image to be evaluated according to the preset gray level co-occurrence matrix analysis algorithm;
[0066] The contrast of the image to be evaluated is normalized according to a third normalization function to obtain a global image texture feature metric value, wherein the third normalization function is:
[0067] CON=1–e -C2 / 30
[0068] Where CON represents the global image texture feature metric, and C2 represents the contrast of the image to be evaluated.
[0069] In a third aspect, an embodiment of the present application provides an image complexity evaluation device, which includes a processor, a memory, and an image complexity evaluation program stored in the memory and executable by the processor, wherein when the image complexity evaluation program is executed by the processor, the steps of the image complexity evaluation method as described above are implemented.
[0070] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, on which an image complexity evaluation program is stored, wherein when the image complexity evaluation program is executed by a processor, the steps of the image complexity evaluation method as described above are implemented.
[0071] The beneficial effects brought by the technical solution provided in the embodiments of the present application include:
[0072] The size of the local background measurement value is used to characterize the relative measurement of the target area of the image and the background area adjacent to the target, which to a certain extent reflects the difficulty of the algorithm in extracting the target in the area of interest; the degree of similarity between the features and the target in the entire image is evaluated based on the size of the global target saliency measurement value to reflect the possibility of false alarm in target detection; the complexity is evaluated from the perspective of grayscale distribution through the global image grayscale statistical measurement value, and the complexity can be evaluated from the perspective of texture features according to the global image texture feature measurement value, which can effectively reflect the details, repeatability and irregularity of the image; therefore, the local background measurement value, the global target saliency measurement value, the global image grayscale statistical measurement value and the global image texture feature measurement value can effectively realize a comprehensive and accurate quantitative evaluation of image complexity, thereby providing a data basis for screening difficult high-quality data sets to improve the training quality and prediction accuracy of infrared small target detection algorithms. BRIEF DESCRIPTION OF THE DRAWINGS
[0073] Figure 1 This is a flow chart of an embodiment of the image complexity evaluation method of the present application;
[0074] Figure 2 This is a conceptual diagram of local contrast involved in the embodiment of the present application;
[0075] Figure 3 A schematic diagram of a method for calculating target confusion involved in an embodiment of the present application;
[0076] Figure 4 The XDU886 image in the IRSTD-1k data set involved in the embodiment of the present application;
[0077] Figure 5 The XDU320 image in the IRSTD-1k data set involved in the embodiment of the present application;
[0078] Figure 6 The XDU387 image in the IRSTD-1k data set involved in the embodiment of the present application;
[0079] Figure 7 The XDU309 image in the IRSTD-1k data set involved in the embodiment of the present application;
[0080] Figure 8 This is a schematic diagram of the hardware structure of the image complexity evaluation device involved in the embodiment of the present application. DETAILED DESCRIPTION
[0081] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0082] In order to make the objectives, technical solutions and advantages of the present application clearer, the implementation methods of the present application will be further described in detail below with reference to the accompanying drawings.
[0083] In a first aspect, an embodiment of the present application provides an image complexity evaluation method.
[0084] In one embodiment, referring to Figure 1 , Figure 1 This is a flow chart of an embodiment of the image complexity evaluation method of this application. Figure 1 As shown, the image complexity evaluation method includes:
[0085] Step S10: Determine the local background measurement value according to the pixels of the target area in the image to be evaluated and the pixels of the corresponding neighborhood window.
[0086] For example, it is understandable that there is no unified definition of image complexity at present, and it is generally considered to be related to the chaos, disorder, and fractal of the image; and there are few studies on the complexity of infrared images and the complexity of infrared small target images, and there are some problems, such as: only theoretical research, lack of feasible quantitative strategies; single evaluation angle, incomplete information leads to high risk of misjudgment; complexity classification using methods such as support vector machines requires training samples, troublesome parameter adjustment, and weak explanatory power. It is understandable that the complexity evaluation method of infrared small target images should comprehensively consider multiple aspects to comprehensively and accurately evaluate the characteristics and information content of the image, while being easy to use and universal, so as to better meet the needs of practical applications. Based on this, this embodiment will provide a comprehensive, stable, and easy-to-use evaluation method for the complexity of infrared small target images.
[0087] In this embodiment, for the image to be evaluated, the local background measurement value is first determined based on the pixels of the target area in the image to be evaluated and the pixels of the neighborhood window corresponding to the target area, so as to evaluate the relative measurement of the target area and the background area adjacent to the target through the local background measurement, which can reflect the difficulty of the detection algorithm to extract the target in the region of interest to a certain extent.
[0088] It should be noted that the image to be evaluated in this embodiment may be a small target image, an infrared small target image, an infrared target image, etc., which may be determined according to actual needs and is not limited here.
[0089] Furthermore, in one embodiment, determining the local background metric value based on the pixels of the target area in the image to be evaluated and the pixels of the corresponding neighborhood window includes:
[0090] For each target in the image to be evaluated, the local contrast of the target is calculated based on the pixels in the target area and the average value of the pixels in the neighborhood window corresponding to the target area;
[0091] The minimum local contrast is selected from all local contrasts, and the minimum local contrast is normalized to obtain a local background measurement value. The normalization of the minimum local contrast to obtain the local background measurement value includes:
[0092] The minimum local contrast is normalized based on a first normalization function to obtain a local background measurement value, wherein the first normalization function is:
[0093] LC=e -C1 / 2
[0094] Where LC represents the local background metric and C1 represents the minimum local contrast.
[0095] For example, it should be understood that each object in the image to be evaluated has a corresponding object area. Figure 2 As shown in the figure, the target area u is a rectangular box close to the edge of the small target truth value, and the eight-neighborhood window with the same size as it constitutes the local background area v; for each target, the maximum value of the pixels in the corresponding target area u is recorded as L 0 , and calculate the pixel average m of the 8 neighborhood windows around the target area u i (i=1,2…8); then calculate the ratio L of the maximum pixel value of the target area u to the average pixel value of each neighborhood window 0 / m i , and then the minimum value among the 8 ratios is taken as the local contrast of the target.
[0096] It can be understood that the larger the local contrast, the brighter the target, that is, the more obvious it is in the local background, and the easier it is to detect, especially for traditional local-based target detection methods; and the smaller the local contrast, the less obvious the target brightness is compared to the background, which increases the difficulty of detection and the local complexity; therefore, if there are multiple targets in the image to be evaluated, it is necessary to select the small target with the highest judgment difficulty to calculate the local background metric value, that is, to take the minimum value of the local contrasts corresponding to all targets as the local contrast of the image to be evaluated.
[0097] It should be noted that this embodiment requires composite local background measurement, global target saliency measurement, global image grayscale statistical measurement and global image texture feature measurement when implementing image complexity evaluation. However, due to the large difference in the value range of each measurement, it is necessary to normalize each measurement to between [0,1] according to the data characteristics. Among them, the principle of normalization in this embodiment is that the normalized indicators on multiple public data sets are evenly distributed and reasonable. Therefore, the normalization function LC=e -C1 / 2 The minimum local contrast C1 is normalized, and the normalized result is used as the local background measurement value LC. At this time, the local background measurement value LC is positively correlated with the local complexity of the image to be evaluated, and the value range is between (0,1).
[0098] Step S20: Calculate the global target saliency measurement value of the image to be evaluated by using a preset target confusion algorithm.
[0099] Exemplarily, it can be understood that target confusion refers to the situation in target detection or classification tasks where the model has difficulty accurately distinguishing targets due to their high similarity in appearance, shape or features; and the calculation process of target confusion is similar to the filtering-based method in traditional detection algorithms.
[0100] Due to factors such as complex background and noise interference during infrared small target detection, the infrared small target detection algorithm is prone to misjudge non-target areas as targets. Therefore, this embodiment can calculate the global target saliency metric of the image to be evaluated through a preset target confusion algorithm, so as to evaluate the degree of similarity between the features in the entire image and the target through the global target saliency metric, thereby reflecting the possibility of false alarm in target detection.
[0101] Furthermore, in one embodiment, the calculating of the global target saliency metric of the image to be evaluated by using a preset target confusion algorithm includes:
[0102] Performing top hat transformation and bottom hat transformation on the image to be evaluated respectively, and performing image fusion based on the transformation results and the image to be evaluated to generate a target image;
[0103] Performing threshold segmentation on the target image based on the maximum inter-class variance method to generate a binary image;
[0104] The number of suspected targets in the binary image is determined according to the four-connectivity rule, and the number of suspected targets is normalized to obtain a global target saliency measurement value. The normalization of the number of suspected targets to obtain a global target saliency measurement value includes:
[0105] The number of suspected targets is normalized based on a second normalization function to obtain a global target saliency measure value, wherein the second normalization function is:
[0106] DTC = 1 – e -m / 2
[0107] Where DTC represents the global target saliency measure, and m represents the number of suspected targets.
[0108] For example, see Figure 3 As shown, the image to be evaluated is first subjected to Top-Hat transformation (i.e., top hat transformation) and Bottom-Hat transformation (i.e., bottom hat transformation) respectively; then, the pixels of the image to be evaluated are added to the pixels after the Top-Hat transformation, and the target image is obtained after the addition result and the pixels after the Bottom-Hat transformation are subtracted, thereby screening out the brighter areas in the image and isolating the areas that may introduce false alarms. It should be noted that the pixels of the image to be evaluated and the pixels after the Bottom-Hat transformation can also be added first, and then the summation result and the pixels after the Top-Hat transformation are subtracted to obtain the target image.
[0109] Subsequently, the maximum inter-class variance method (i.e., Otsu's threshold segmentation) is used to perform threshold segmentation on the processed target image to generate a binary image. It should be noted that Otsu's threshold segmentation is an adaptive threshold segmentation, which can automatically find the value between the two peaks of the grayscale histogram as the threshold to obtain a binary image. Then, the connected domain of the binary image is calibrated using the four-connection rule to determine the number of suspected targets m in the binary image. Finally, the normalization function is DTC=1–e -m / 2 After normalizing the number of suspected targets m, we obtain the target confusion degree with a value range between (0, 1), and use the target confusion degree as the global target saliency measure DTC.
[0110] Further, in one embodiment, determining the number of suspected targets in the binary image according to the four-connectivity rule includes:
[0111] Determine all target connected regions existing in the binary image based on the four-connectivity rule;
[0112] For each target connected area, determining whether the pixel value of the target connected area is less than or equal to a preset suspected target pixel threshold;
[0113] If yes, the number of suspected targets corresponding to the target connected area is 1;
[0114] If not, the ratio between the suspected target pixel threshold and the pixel value of the target connected area is used as the number of suspected targets corresponding to the target connected area;
[0115] The sum of the number of suspected targets corresponding to all target connected regions is taken as the number of suspected targets existing in the binary image.
[0116] Exemplarily, in this embodiment, the specific value of the suspected target pixel threshold can be determined according to actual needs and is not limited here; for example, the size of a small target in an infrared small target image is usually less than 9×9 pixels, so for the infrared small target image, the suspected target pixel threshold can be set to 9×9 pixels.
[0117] In this embodiment, the connected areas in the binary image that meet the four-connectivity rule are marked to determine all target connected areas in the binary image. It should be noted that only pixels connected in the horizontal direction or the vertical direction can be regarded as the same object, that is, as a target connected area; in addition, in this embodiment, if there is only one pixel in a region, the region is also regarded as a target connected area.
[0118] When counting the number of suspected targets, assuming that the threshold of suspected target pixels is set to 9×9 pixels, the target connected area less than or equal to 9×9 pixels is considered as a suspected target for counting, that is, the number is 1; and for the target connected area of n×n (n>9) pixels, the corresponding number of suspected targets is (9×9) / (n×n). Finally, the number of all suspected targets in the image to be evaluated is counted as m. It should be understood that the more suspected targets there are, the more false alarms there may be in the detection results of the method based on manual features, and the corresponding image detection is difficult and complex.
[0119] Step S30: determining a global image grayscale statistical measurement value of the image to be evaluated based on the unary grayscale entropy.
[0120] For example, in this embodiment, the unary grayscale entropy is used to measure the grayscale complexity of the global image, and then the grayscale entropy h is obtained; since the distribution of grayscale entropy in each data set is uniform, the grayscale entropy can be processed by deviation normalization to obtain a global image grayscale statistical measurement value H between [0,1], so as to evaluate the complexity from the perspective of grayscale distribution through the global image grayscale statistical measurement. Wherein, the deviation normalization is defined as: (hhmin ) / (h max -h min ), where h represents the grayscale entropy of the image to be evaluated, h max Represents the maximum gray entropy of a set of data, h min It represents the minimum gray entropy of a set of data sets; it can be understood that h max and h min The value of is related to the sampling size of the image to be evaluated. Its specific value can be determined according to actual needs. For example, in order to achieve objective evaluation on a single image, if the sampling size of the image to be evaluated is 256*256, then h min Take 0 and h max If we take 8, the formula for calculating the standard deviation becomes: h / 8.
[0121] It should be noted that how to solve grayscale entropy through univariate grayscale entropy is common knowledge in the art and is not limited here for the sake of brevity of description. In addition, this embodiment does not introduce target information in the measurement of global image grayscale statistical metrics to ensure the integrity of the evaluation, fully understand the characteristics and structure of the image, and provide more references for complexity judgment.
[0122] Among them, this embodiment selects grayscale entropy as the evaluation indicator of the global image grayscale statistical measurement value. When the grayscale entropy is higher, it means that the distribution of pixel values in the image is more uniform, the information contained in the image is richer, and the complexity is higher; on the contrary, the lower the grayscale entropy is, the more concentrated the distribution of pixel values in the image is, the simpler the information contained in the image is, and the complexity is lower.
[0123] Step S40: Calculate the global image texture feature measurement value of the image to be evaluated according to a preset gray level co-occurrence matrix analysis algorithm.
[0124] Exemplarily, it can be understood that grayscale co-occurrence matrix analysis is a method for describing image texture features, and texture refers to repeated patterns or some regular structures presented in an image, which can be used to describe image detail information, such as roughness, smoothness, granularity, etc. This embodiment will use the contrast of the grayscale co-occurrence matrix to evaluate the global image texture feature metric of the image to be evaluated, so as to evaluate the complexity from the perspective of texture features through the global image texture feature metric, and thus effectively reflect the details, repeatability and irregularity of the image. It should be noted that when implementing the measurement of the global image texture feature metric, target information is not introduced to ensure the integrity of the evaluation, fully understand the characteristics and structure of the image, and provide more references for complexity judgment.
[0125] Furthermore, in one embodiment, the global image texture feature metric value of the image to be evaluated is calculated according to a preset gray level co-occurrence matrix analysis algorithm, including:
[0126] Calculate the contrast of the image to be evaluated according to the preset gray level co-occurrence matrix analysis algorithm;
[0127] The contrast of the image to be evaluated is normalized according to a third normalization function to obtain a global image texture feature metric value, wherein the third normalization function is:
[0128] CON=1–e -C2 / 30
[0129] Where CON represents the global image texture feature metric, and C2 represents the contrast of the image to be evaluated.
[0130] For example, it should be understood that the gray level co-occurrence matrix quantifies the texture information in the image by counting the spatial relationship and distribution between the gray levels of pixels in the image to be evaluated. Among them, there are multiple characteristic parameters such as energy, contrast, entropy, inverse difference, correlation, etc. in the gray feature matrix. This embodiment only selects the contrast in the gray feature matrix as the measurement basis, that is, the image with a large contrast has a more complex texture than the image with a small contrast; then use the normalization function CON = 1-e -C2 / 30 The contrast C2 of the gray level co-occurrence matrix in the texture feature is normalized to obtain the global image texture feature metric CON with a value range between (0,1).
[0131] Step S50: Determine the complexity of the image to be evaluated based on the local background measurement value, the global target saliency measurement value, the global image grayscale statistical measurement value and the global image texture feature measurement value.
[0132] Exemplarily, in this embodiment, the importance weights of the above-mentioned local background measurement value LC, global target saliency measurement value DTC, global image grayscale statistical measurement value H and global image texture feature measurement value CON are all 1, and are all positively correlated with the image complexity. Therefore, by summing the above-mentioned four measurement values, the final complexity evaluation of the image to be evaluated I=LC+DTC+H+CON can be obtained, and its value range is between (0, 4). The larger the value of I, the higher the complexity of the image to be evaluated, and the higher the corresponding detection difficulty.
[0133] The image complexity evaluation results of this embodiment are shown using the IRSTD-1k dataset as an example: Figure 4 The corresponding complexity evaluation I of the image to be evaluated is only 0.067, while the result of human eye recognition is that it is an image with very low complexity; Figure 5 The corresponding complexity evaluation I of the image to be evaluated is 1.013, while the result of human eye recognition is Figure 4 The screen information is richer, but it is also relatively simple data; Figure 6The corresponding complexity evaluation I of the image to be evaluated is 2.545, and the result of human eye recognition is that the texture of the picture is diverse, which causes some interference in the judgment of small targets; Figure 7 The corresponding complexity evaluation I of the image to be evaluated is 3.458, while the result of human eye recognition is that the picture is chaotic, the texture is complex, and the small target is in the second bright area of the picture, so it is not obvious, and it is difficult to judge the small target. It can be seen that when the complexity evaluation index in this embodiment is implemented in a specific data set, its complexity judgment result is consistent with human eye recognition; therefore, when this embodiment is applied to a real data set, the complexity evaluation size can accurately reflect the complexity of the image and the difficulty of detection, and then can accurately reflect the complexity judgment of the human eye on the data and the difficulty of the algorithm on the image detection.
[0134] In addition, this embodiment can also evaluate the complexity of the image to be evaluated through a specific target metric, wherein the specific target metric is used to characterize the target shape, texture and other features. It should be understood that due to the long imaging distance, infrared targets are generally very small. Usually, the size of the small target in the image is only 2×2 to 9×9 pixels, accounting for less than 0.15% of the entire image, and the shape characteristics of the small infrared target are limited, resulting in the target metric being of little significance. Therefore, in the application scenario of infrared small target detection, the calculation of the specific target metric may not be performed. As for non-infrared small targets, their size in the image is relatively large, so the specific target metric can be used as one of the factors for the complexity evaluation of the image where the non-infrared small target is located, so as to further improve the comprehensiveness and accuracy of the complexity evaluation.
[0135] The specific target metric value can be determined by calculating the average brightness value or grayscale entropy of the image, that is, the specific target metric value is obtained by normalizing the calculated average brightness value or grayscale entropy; and then the specific target metric value is used as the calculation object of the complexity evaluation I. It should be noted that the calculation method and principle of the average brightness value and grayscale entropy are common knowledge in the art, and for the sake of brevity of description, they are not repeated here.
[0136] In summary, this embodiment can make a comprehensive and accurate quantitative evaluation of the complexity of infrared small target images, that is, consider the image features from five angles, and comprehensively examine from the local to the overall, and reasonably normalize the initial calculation data with different value ranges to obtain indicators with uniform distribution and discrimination; and the complexity obtained by quantitative evaluation can accurately evaluate the data set to further understand the difficulty of the data set, so as to preliminarily judge the detection algorithm capability applied to the data set; at the same time, according to data requirements, the required difficulty data set can be screened and integrated for application in subsequent model training, testing, etc., which plays an auxiliary role in the application of deep learning in this field.
[0137] It can be understood that the image complexity evaluation method provided in this embodiment can determine the difficulty of the infrared small target data set to assist in the development of the detection algorithm. It can quickly and comprehensively determine the detection difficulty of the infrared small target image through the composite calculation of indicators from multiple angles, and then can perform difficulty assessment on the data set or a certain application scenario, thereby screening out data that is conducive to network learning for the development process.
[0138] In order to optimize the common target detection algorithm development process and make up for the lack of work on the data set, this embodiment also proposes a new deep model algorithm development process, which uses image complexity evaluation as an aid to improve the performance of algorithms that are sensitive to data complexity: first, collect data and perform preprocessing, that is, collect data sets related to the problem, and perform preprocessing operations such as cleaning, labeling, and partitioning on the data; then perform complexity judgment on all data (that is, perform complexity judgment through the image complexity evaluation method provided in this embodiment) and screening to obtain training data sets and test data sets. It should be noted that the data set used for the training process needs to reduce the proportion of low-complexity data to avoid the result of weak algorithm generalization ability; then select and design a deep network model, that is, select a deep learning model structure suitable for solving the problem (such as a convolutional neural network, a recurrent neural network, etc.), and design the specific structure of the model (such as including the setting of network layers, the selection of activation functions, the definition of loss functions, etc.); after the model is built, perform conventional model training through the training data set, that is, use the labeled data set to train the model, and continuously adjust the model parameters through the back propagation algorithm to optimize it to obtain the target model.
[0139] The target model performance is then evaluated through the screened test data set. The evaluation indicators include accuracy, precision, recall, etc., which can intuitively show whether the algorithm is capable of processing difficult data, so as to estimate in advance whether it is suitable for the target application scenario; finally, the expected model is output and deployed according to the evaluation results. If it does not meet the requirements, it returns to the model selection and design stage, re-optimizes the model and trains it. It can be seen that the deep model development process proposed in this embodiment introduces the determination of data complexity, and its importance is reflected in the training and testing process, that is, by improving the development process of the infrared small target detection algorithm, the accuracy of the algorithm is improved and the missed detection rate is reduced.
[0140] It can be understood that this embodiment introduces data complexity judgment in the development process of deep learning algorithms to evaluate and screen data sets, thereby avoiding ineffective repetitive simple training to improve training efficiency and enhance the generalization performance of the model; and in the testing phase, it can accurately determine whether the model is capable of processing difficult data, and what type of difficult data the data that cannot be accurately processed belongs to (the target is too weak, the background is cluttered, or there is interference information, etc.); in addition, the development process provided by this implementation is easy to use, that is, the image complexity evaluation method is not difficult to calculate and the calculation is fast, and does not involve manual marking, training, and adjustment of parameters of difficulty. After the indicators are calculated, the threshold value of the difficulty data set can be divided by itself. Compared with the clustering method, it is more flexible and has a certain fault tolerance, and is therefore suitable for all infrared small target data sets.
[0141] In summary, this embodiment provides a quantitative evaluation method for image complexity, which can not only realize comprehensive, accurate and rapid judgment of the complexity of infrared small target image data, but also can be applied to the target detection algorithm development process to more efficiently train deep learning network models and improve model performance. At the same time, more information reflecting the model's data processing capabilities can be obtained when testing new models.
[0142] In a second aspect, an embodiment of the present application also provides an image complexity evaluation device.
[0143] In one embodiment, the image complexity evaluation device includes:
[0144] A first processing module, which is used to determine a local background metric value based on pixels of a target area in an image to be evaluated and pixels of a corresponding neighborhood window;
[0145] A second processing module, which is used to calculate the global target saliency measurement value of the image to be evaluated by using a preset target confusion algorithm;
[0146] A third processing module, which is used to determine the global image grayscale statistical measurement value of the image to be evaluated based on the unary grayscale entropy;
[0147] A fourth processing module, which is used to calculate the global image texture feature measurement value of the image to be evaluated according to a preset gray level co-occurrence matrix analysis algorithm;
[0148] The complexity evaluation module is used to determine the complexity of the image to be evaluated based on the local background measurement value, the global target saliency measurement value, the global image grayscale statistical measurement value and the global image texture feature measurement value.
[0149] Furthermore, in one embodiment, the first processing module is specifically configured to:
[0150] For each target in the image to be evaluated, the local contrast of the target is calculated based on the pixels in the target area and the average value of the pixels in the neighborhood window corresponding to the target area;
[0151] The minimum local contrast is screened out from all local contrasts, and the minimum local contrast is normalized to obtain a local background measurement value.
[0152] Furthermore, in one embodiment, the first processing module is further configured to:
[0153] The minimum local contrast is normalized based on a first normalization function to obtain a local background measurement value, wherein the first normalization function is:
[0154] LC=e -C1 / 2
[0155] Where LC represents the local background metric and C1 represents the minimum local contrast.
[0156] Furthermore, in one embodiment, the second processing module is specifically configured to:
[0157] Performing top hat transformation and bottom hat transformation on the image to be evaluated respectively, and performing image fusion based on the transformation results and the image to be evaluated to generate a target image;
[0158] Performing threshold segmentation on the target image based on the maximum inter-class variance method to generate a binary image;
[0159] The number of suspected targets in the binary image is determined according to the four-connectivity rule, and the number of suspected targets is normalized to obtain a global target saliency measure.
[0160] Furthermore, in one embodiment, the second processing module is further configured to:
[0161] Determine all target connected regions existing in the binary image based on the four-connectivity rule;
[0162] For each target connected area, determining whether the pixel value of the target connected area is less than or equal to a preset suspected target pixel threshold;
[0163] If yes, the number of suspected targets corresponding to the target connected area is 1;
[0164] If not, the ratio between the suspected target pixel threshold and the pixel value of the target connected area is used as the number of suspected targets corresponding to the target connected area;
[0165] The sum of the number of suspected targets corresponding to all target connected regions is taken as the number of suspected targets existing in the binary image.
[0166] Furthermore, in one embodiment, the second processing module is further configured to:
[0167] The number of suspected targets is normalized based on a second normalization function to obtain a global target saliency measure value, wherein the second normalization function is:
[0168] DTC = 1 – e -m / 2
[0169] Where DTC represents the global target saliency measure, and m represents the number of suspected targets.
[0170] Furthermore, in one embodiment, the fourth processing module is specifically used for:
[0171] Calculate the contrast of the image to be evaluated according to the preset gray level co-occurrence matrix analysis algorithm;
[0172] The contrast of the image to be evaluated is normalized according to a third normalization function to obtain a global image texture feature metric value, wherein the third normalization function is:
[0173] CON=1–e -C2 / 30
[0174] Where CON represents the global image texture feature metric, and C2 represents the contrast of the image to be evaluated.
[0175] Among them, the functional implementation of each module in the above-mentioned image complexity evaluation device corresponds to the various steps in the above-mentioned image complexity evaluation method embodiment, and its functions and implementation processes will not be repeated here one by one.
[0176] In a third aspect, an embodiment of the present application provides an image complexity evaluation device, which may be a personal computer (PC), a laptop computer, a server, or other device with data processing capabilities.
[0177] Reference Figure 8 , Figure 8 Schematic diagram of the hardware structure of the image complexity evaluation device involved in the embodiment of the present application. In the embodiment of the present application, the image complexity evaluation device may include a processor, a memory, a communication interface and a communication bus.
[0178] The communication bus may be of any type and is used to interconnect the processor, the memory, and the communication interface.
[0179] The communication interface includes input / output (I / O) interface, physical interface and logical interface, etc., which are used to realize the interconnection of devices inside the image complexity evaluation device, and the interface used to realize the interconnection of the image complexity evaluation device with other devices (such as other computing devices or user devices). The physical interface can be an Ethernet interface, an optical fiber interface, an ATM interface, etc.; the user device can be a display, a keyboard, etc.
[0180] The memory can be various types of storage media, such as random access memory (RAM), read-only memory (ROM), non-volatile RAM (NVRAM), flash memory, optical storage, hard disk, programmable ROM (PROM), erasable PROM (EPROM), electrically erasable PROM (EEPROM), etc.
[0181] The processor may be a general-purpose processor, and the general-purpose processor may call the image complexity evaluation program stored in the memory and execute the image complexity evaluation method provided in the embodiment of the present application. For example, the general-purpose processor may be a central processing unit (CPU). The method executed when the image complexity evaluation program is called may refer to the various embodiments of the image complexity evaluation method of the present application, and will not be repeated here.
[0182] Those skilled in the art will understand that Figure 8 The hardware structure shown in the figure does not constitute a limitation on the present application, and may include more or less components than shown in the figure, or combine certain components, or arrange the components differently.
[0183] In a fourth aspect, an embodiment of the present application also provides a computer-readable storage medium.
[0184] An image complexity evaluation program is stored on the readable storage medium of the present application, wherein when the image complexity evaluation program is executed by a processor, the steps of the image complexity evaluation method as described above are implemented.
[0185] Among them, the method implemented when the image complexity evaluation program is executed can refer to the various embodiments of the image complexity evaluation method of the present application, and will not be repeated here.
[0186] It should be noted that the serial numbers of the above-mentioned embodiments of the present application are only for description and do not represent the advantages or disadvantages of the embodiments.
[0187] The terms "including" and "having" and any variations thereof in the specification and claims of this application and the above-mentioned drawings are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not limited to the listed steps or units, but optionally includes steps or units that are not listed, or optionally includes other steps or units inherent to these processes, methods, products or devices. The terms "first", "second" and "third" are used to distinguish different objects, etc., and do not represent a sequence, nor do they limit "first", "second" and "third" to different types.
[0188] In the description of the embodiments of the present application, "exemplary", "for example" or "for example" are used to indicate examples, illustrations or descriptions. Any embodiment or design described as "exemplary", "for example" or "for example" in the embodiments of the present application should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplary", "for example" or "for example" is intended to present related concepts in a specific way.
[0189] In the description of the embodiments of the present application, unless otherwise specified, “ / ” means or, for example, A / B can mean A or B; the “and / or” in the text is merely a description of the association relationship of associated objects, indicating that three relationships may exist, for example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone. In addition, in the description of the embodiments of the present application, “multiple” refers to two or more than two.
[0190] In some processes described in the embodiments of the present application, multiple operations or steps that appear in a specific order are included, but it should be understood that these operations or steps may not be executed in the order in which they appear in the embodiments of the present application or in parallel, and the sequence number of the operation is only used to distinguish the different operations, and the sequence number itself does not represent any execution order. In addition, these processes may include more or fewer operations, and these operations or steps may be executed in sequence or in parallel, and these operations or steps may be combined.
[0191] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application is essentially or the part that contributes to the prior art can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, disk, CD) as described above, and includes a number of instructions for a terminal device to execute the methods described in each embodiment of the present application.
[0192] The above are only preferred embodiments of the present application, and are not intended to limit the patent scope of the present application. Any equivalent structure or equivalent process transformation made using the contents of the present application specification and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present application.
Claims
1. A method for evaluating image complexity, It is characterized in that The following steps are involved: Determine the local background metric value according to the pixels of the target area in the image to be evaluated and the pixels of the corresponding neighborhood window; The global target saliency metric of the image to be evaluated is calculated by a preset target confusion algorithm; Determine the global image grayscale statistical measurement value of the image to be evaluated based on the unary grayscale entropy; Calculate the global image texture feature measurement value of the image to be evaluated according to the preset gray level co-occurrence matrix analysis algorithm; The complexity of the image to be evaluated is determined based on the local background measurement value, the global target saliency measurement value, the global image grayscale statistical measurement value and the global image texture feature measurement value.
2. The image complexity evaluation method according to claim 1, It is characterized in that Determining the local background metric value according to the pixels of the target area in the image to be evaluated and the pixels of the corresponding neighborhood window includes: For each target in the image to be evaluated, the local contrast of the target is calculated based on the pixels in the target area and the average value of the pixels in the neighborhood window corresponding to the target area; The minimum local contrast is screened out from all local contrasts, and the minimum local contrast is normalized to obtain a local background measurement value.
3. The image complexity evaluation method according to claim 2, It is characterized in that The normalizing the minimum local contrast to obtain a local background measurement value includes: The minimum local contrast is normalized based on a first normalization function to obtain a local background measurement value, wherein the first normalization function is: LC=e -C1 / 2 Where LC represents the local background metric and C1 represents the minimum local contrast.
4. The image complexity evaluation method according to claim 1, It is characterized in that The method of calculating the global target saliency measurement value of the image to be evaluated by using a preset target confusion algorithm includes: Performing top hat transformation and bottom hat transformation on the image to be evaluated respectively, and performing image fusion based on the transformation results and the image to be evaluated to generate a target image; Performing threshold segmentation on the target image based on the maximum inter-class variance method to generate a binary image; The number of suspected targets in the binary image is determined according to the four-connectivity rule, and the number of suspected targets is normalized to obtain a global target saliency measure.
5. The image complexity evaluation method according to claim 4, It is characterized in that Determining the number of suspected targets in the binary image according to the four-connection rule includes: Determine all target connected regions existing in the binary image based on the four-connectivity rule; For each target connected area, determining whether the pixel value of the target connected area is less than or equal to a preset suspected target pixel threshold; If yes, the number of suspected targets corresponding to the target connected area is 1; If not, the ratio between the suspected target pixel threshold and the pixel value of the target connected area is used as the number of suspected targets corresponding to the target connected area; The sum of the number of suspected targets corresponding to all target connected regions is taken as the number of suspected targets existing in the binary image.
6. The image complexity evaluation method according to claim 4, It is characterized in that The normalizing the number of suspected targets to obtain a global target saliency measurement value includes: The number of suspected targets is normalized based on a second normalization function to obtain a global target saliency measure value, wherein the second normalization function is: DTC=1–e -m / 2 Where DTC represents the global target saliency measure, and m represents the number of suspected targets.
7. The image complexity evaluation method according to claim 1, It is characterized in that The method of calculating the global image texture feature metric value of the image to be evaluated according to a preset gray level co-occurrence matrix analysis algorithm includes: Calculate the contrast of the image to be evaluated according to the preset gray level co-occurrence matrix analysis algorithm; The contrast of the image to be evaluated is normalized according to a third normalization function to obtain a global image texture feature metric value, wherein the third normalization function is: WITH=1–e -C2 / 30 Where CON represents the global image texture feature metric, and C2 represents the contrast of the image to be evaluated.
8. An image complexity evaluation device, It is characterized in that include: A first processing module, which is used to determine a local background metric value based on pixels of a target area in an image to be evaluated and pixels of a corresponding neighborhood window; A second processing module, which is used to calculate the global target saliency measurement value of the image to be evaluated by using a preset target confusion algorithm; A third processing module, which is used to determine the global image grayscale statistical measurement value of the image to be evaluated based on the unary grayscale entropy; A fourth processing module, which is used to calculate the global image texture feature measurement value of the image to be evaluated according to a preset gray level co-occurrence matrix analysis algorithm; The complexity evaluation module is used to determine the complexity of the image to be evaluated based on the local background measurement value, the global target saliency measurement value, the global image grayscale statistical measurement value and the global image texture feature measurement value.
9. An image complexity evaluation device, It is characterized in that The image complexity evaluation device includes a processor, a memory, and an image complexity evaluation program stored in the memory and executable by the processor, wherein when the image complexity evaluation program is executed by the processor, the steps of the image complexity evaluation method as described in any one of claims 1 to 7 are implemented.
10. A computer-readable storage medium, It is characterized in that The computer-readable storage medium stores an image complexity evaluation program, wherein when the image complexity evaluation program is executed by a processor, the steps of the image complexity evaluation method according to any one of claims 1 to 7 are implemented.
Citation Information
Patent Citations
Evaluation model for image complexity of target and background
CN104392209A
Infrared weak and small target detection algorithm adopting local feature contrast
CN113516187A
Real-time Small Target Detection Method using Local Contrast Difference Measure
KR101827889B1
Cited By
Image contrast evaluation method and device, equipment and storage medium
CN121169771A
