Image classification storage device with sea-sky background based on visibility grading
By using an image classification and storage device based on visibility grading, the problem of decreased infrared image detection accuracy under strong clutter interference in the marine environment is solved, achieving stable and effective sea-line extraction and visibility judgment, thus improving the accuracy and convenience of ship target detection.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- BEIJING HUAHANG RADIO MEASUREMENT & RES INST
- Filing Date
- 2022-01-27
- Publication Date
- 2026-04-28
AI Technical Summary
In marine environments, strong clutter or fish scale light interference degrades the performance of infrared image detection algorithms, affecting the accuracy of ship target detection. Existing technologies struggle to effectively address the impact of weather visibility on detection results.
Design an image classification and storage device based on visibility grading. Through a buffer, a grading processor, a first memory, a second memory, and a third memory, use processing methods such as resolution reduction, target gradient feature extraction, edge point extraction, and sea-sky line extraction to perform visibility grading storage of images. Improve the Canny algorithm for sea-sky background visibility judgment.
It achieves stable and effective sea-line extraction and visibility judgment under different visibility conditions, improving the convenience and accuracy of subsequent ship target detection.
Smart Images

Figure CN116563086B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of image processing and target detection technology, specifically relating to an image classification and storage device with a sea and sky background based on visibility grading. Background Technology
[0002] In recent years, ship target detection has been a research hotspot in the field of target detection. As the most important mode of transportation in international logistics, maritime transport has seen a rapid increase in the number of ships entering and leaving ports with the rapid development of my country's maritime trade. Therefore, ship target detection is increasingly important for improving maritime traffic order and maintaining maritime safety. When sea surface clutter or fish scale light is strong, the gray intensity of many wave peaks in infrared images is close to, or even equal to, or greater than the maximum gray value of the target pixel, significantly degrading the performance of detection algorithms.
[0003] Considering that weather visibility has a significant impact on the results of ship inspection, the accuracy of inspection can be improved by judging the weather visibility. Classifying and storing target images according to visibility levels will bring great convenience to subsequent ship inspections. Summary of the Invention
[0004] Based on the above analysis, the present invention aims to disclose a classification and storage device for images including sea and sky backgrounds based on visibility classification, thereby solving the problem of visibility classification storage of sea and sky background images.
[0005] This invention discloses an image classification and storage device with a sea and sky background based on visibility grading, comprising: a cache, a grading processor, a first memory, a second memory, and a third memory;
[0006] The buffer is used to buffer consecutive frames of sea observation images output from the optical detector; the sea observation images include a sea and sky background;
[0007] The hierarchical processor is connected to the buffer and is used to read each frame of sea observation image from the buffer. The image is processed including resolution reduction, target gradient feature extraction, edge point extraction and sea-line length extraction. Based on the image's gray-scale mean features, gradient features, edge point number features and sea-line length features, the visibility of the image is divided into poor, average and good.
[0008] The first memory is connected to the classification processor and is used to store the sea observation images with visibility classified as good and their corresponding frame numbers.
[0009] The second memory is connected to the classification processor and is used to store sea observation images with visibility classified as general and their corresponding frame numbers.
[0010] The third memory is connected to the classification processor and is used to store sea observation images with poor visibility and their corresponding frame numbers.
[0011] Furthermore, the hierarchical processor includes a resolution reduction module, a first hierarchical module, a target gradient feature extraction module, a second hierarchical module, an edge point extraction module, a third hierarchical module, a sea-line extraction module, a fourth hierarchical module, a fifth hierarchical module, and an output module;
[0012] The resolution reduction module is used to perform a resolution reduction operation on the input image to obtain a reduced resolution image;
[0013] The first grading module is used to determine the average gray level of the down-resolution image. When the average gray level is less than a threshold, the visibility of the image is graded as poor.
[0014] The target gradient feature extraction module is used to filter the down-resolution image with an average gray level not less than a threshold, and then calculate the horizontal gradient, vertical gradient, average gradient, and maximum gradient of the image.
[0015] The second grading module is used to classify the visibility of the image as poor based on whether the maximum gradient of the down-resolution image is less than a first gradient threshold.
[0016] The edge point extraction module is used to extract edge points from a down-resolution image whose maximum gradient is not less than a first gradient threshold, and obtain an edge map.
[0017] The third grading module is used to determine the number of extracted edge points. When the number of points is less than the threshold, the visibility of the image is graded as poor.
[0018] The sea-line extraction module is used to obtain sea-line information within a specified angle range from the edge map of a down-resolution image with a number of edge points not less than a threshold.
[0019] The fourth grading module is used to determine the length of the sea surface line. When the length of the sea surface line is less than a threshold, the visibility of the image is graded as poor.
[0020] The fifth grading module is used to further determine the maximum value of the image gradient for a down-resolution image with a sea-line length not less than a threshold. When the maximum gradient value is not less than the third gradient threshold, the visibility of the image is graded as good; when it is not less than the second gradient threshold but less than the third gradient threshold, the visibility of the image is graded as average; when it is less than the second gradient threshold, the visibility of the image is graded as poor.
[0021] The output module, based on the visibility classification results, outputs the sea observation images with good visibility and their corresponding frame numbers to the first memory, the sea observation images with moderate visibility and their corresponding frame numbers to the second memory, and the sea observation images with poor visibility and their corresponding frame numbers to the third memory.
[0022] Furthermore, the target gradient feature extraction module includes an adaptive filtering module and a gradient calculation module;
[0023] The adaptive filtering module includes a Gaussian filter to perform Gaussian filtering on the down-resolution image;
[0024] The gradient calculation module calculates the horizontal gradient, vertical gradient, intermediate gradient value, and maximum gradient of the image after adaptive Gaussian filtering.
[0025] Furthermore, the Gaussian filter is an n*n matrix. Combining this with the sigma parameter of the Canny operator, the Gaussian filter is: dgau2D=-x·*exp(-(x·*x+x) T ·*x T ) / (2*canny_sigma)) / (2*π*canny_sigma 2 );
[0026] The horizontal gradient set and the vertical gradient set dx and dy are:
[0027] The intermediate value of the image gradient is: value = sqrt(dx.*dx + dy.*dy);
[0028] The maximum gradient is: max_grad = max(value);
[0029] I represents the pixel matrix of the image after downscaling.
[0030] Furthermore, the sea line extraction module uses Hough transform to extract sea lines; images whose number and range of sea lines do not meet the conditions are identified as images of sea lines that cannot be extracted, and the visibility is classified as poor.
[0031] Furthermore, the edge point extraction module includes a gradient normalization module, a histogram module, an extraction module, and a labeling module;
[0032] The gradient normalization module is used to perform segmented normalization based on the magnitude of the maximum gradient value of the image to obtain the normalized gradient result.
[0033] The histogram module is used to build a histogram based on the gradient normalization result;
[0034] The extraction module is used to extract edge points using the Canny algorithm. When extracting edge points, non-maximum suppression in the Canny algorithm is performed by adaptive horizontal and vertical gradient sets. The module also uses histograms to extract gradient high thresholds and gradient low thresholds that meet the conditions.
[0035] The labeling module is used to obtain the edge map of the image by obtaining the number of points and length information of each edge through eight-neighbor labeling.
[0036] Furthermore, the gradient normalization module includes a first gradient value comparison module, a first normalization module, a second gradient value comparison module, a second normalization module, a third gradient value comparison module, a third normalization module, a fourth gradient value comparison module, a fourth normalization module, and a fifth normalization module;
[0037] The first gradient value comparison module is used to determine whether the maximum gradient value of the input image is greater than the first gradient grading threshold; if so, the gradient of the image is normalized by the first normalization factor in the first normalization module; otherwise, the process proceeds to the second gradient comparison module.
[0038] The second gradient value comparison module is used to determine whether the maximum gradient value of the input image is greater than the second gradient grading threshold; if so, the gradient of the image is normalized by the second normalization factor in the second normalization module; otherwise, the process proceeds to the third gradient comparison module.
[0039] The third gradient value comparison module is used to determine whether the maximum gradient value of the input image is greater than the third gradient grading threshold; if so, the gradient of the image is normalized by the third normalization factor in the third normalization module; otherwise, it proceeds to the fourth gradient comparison module.
[0040] The fourth gradient value comparison module is used to determine whether the maximum gradient value of the input image is greater than the fourth gradient grading threshold; if so, the fourth normalization factor is used to normalize the gradient of the image in the fourth normalization module; otherwise, the fifth normalization factor is used to normalize the gradient of the image in the fifth normalization module.
[0041] Furthermore, the first normalization factor is value1 = value / min(va1*max_grad,va2);
[0042] The second normalization factor is value2 = value / max(va1*max_grad,va3);
[0043] The third normalization factor is value3 = value / max(va2*max_grad,va2);
[0044] The fourth normalization factor is value4 = value / va4;
[0045] The fifth normalization factor is value5 = value / va5;
[0046] In the formula, the grading constants are va1 < va2 < va3 < va4 < va5; value is the median value of the image gradient; and max_grad is the maximum gradient.
[0047] Furthermore, the histogram module establishes a histogram based on a normalized gradient, divided into 16 equal parts, according to the principle of proportion.
[0048] Furthermore, the extraction module utilizes histograms to extract gradient high thresholds and gradient low thresholds that meet the conditions.
[0049] The gradient high threshold high_thresold = find(add(counts)>canny_higth*Δrow*Δline,1,first);
[0050] Gradient low threshold low_thresold = canny_lowth * high_thresold;
[0051] Here, counts represents the normalized gradient histogram, canny_higth and canny_lowth represent the preset high and low gradient thresholds, respectively, and Δrow and Δline refer to the pixel width and height of the image after removing boundaries such as black and white edges, respectively.
[0052] This invention can achieve at least one of the following beneficial effects:
[0053] This invention categorizes and stores visibility levels, greatly facilitating subsequent target detection. Furthermore, it establishes an adaptive gradient planning method based on maximum gradient calculation and weighted texture of the acquired image using an improved Canny algorithm to determine visibility against a sea-sky background. Engineering practice and experiments have demonstrated that this sea-sky background visibility grading method can meet the requirements for judging weather conditions against a sea-sky background in the field, achieving more stable and effective sea-sky line extraction and visibility assessment. Attached Figure Description
[0054] The accompanying drawings are for illustrative purposes only and are not intended to limit the invention. Throughout the drawings, the same reference numerals denote the same parts.
[0055] Figure 1 This is a block diagram of a classification and storage device for images including sea and sky backgrounds based on visibility grading, as described in an embodiment of the present invention.
[0056] Figure 2 This is a block diagram of the hierarchical processor in an embodiment of the present invention;
[0057] Figure 3 This is a block diagram of the gradient normalization module in an embodiment of the present invention. Detailed Implementation
[0058] Preferred embodiments of the present invention will now be described in detail with reference to the accompanying drawings, which form part of this application and, together with the embodiments of the present invention, serve to illustrate the principles of the present invention.
[0059] One embodiment of the present invention discloses an image classification and storage device with a sea and sky background based on visibility grading, such as... Figure 1 As shown, it includes: a cache, a hierarchical processor, a first memory, a second memory, and a third memory;
[0060] The buffer is used to buffer consecutive frames of sea observation images output from the optical detector; the sea observation images include a sea and sky background;
[0061] The hierarchical processor is connected to the buffer and is used to read each frame of sea observation image from the buffer, and perform processing on the image including resolution reduction, target gradient feature extraction, edge point extraction and sea-line length extraction. Based on the gray-scale mean feature, gradient feature, edge point number feature and sea-line length feature of the image, the visibility of the image is divided into poor, average and good.
[0062] The first memory is connected to the classification processor and is used to store the sea observation images with visibility classified as good and their corresponding frame numbers.
[0063] The second memory is connected to the classification processor and is used to store sea observation images with visibility classified as general and their corresponding frame numbers.
[0064] The third memory is connected to the classification processor and is used to store sea observation images with poor visibility and their corresponding frame numbers.
[0065] Preferably, the buffer can be in the form of RAM (random access memory) or VRAM (video random access memory) to cache the marine observation images.
[0066] The first, second, and third memories can be solid-state memories, including flash memory, and their capacity can be determined based on the amount of data of the sea observation images to be stored.
[0067] The hierarchical processor can be implemented using FPGA+DSP or FPGA+ARM.
[0068] Specifically, such as Figure 2As shown, the hierarchical processor includes a resolution reduction module, a first hierarchical module, a target gradient feature extraction module, a second hierarchical module, an edge point extraction module, a third hierarchical module, a sea-line extraction module, a fourth hierarchical module, a fifth hierarchical module, and an output module;
[0069] The resolution reduction module is used to perform a resolution reduction operation on the input image to obtain a reduced resolution image;
[0070] Specifically, in the down-resolution module, the original input image (image resolution of 640*480) is down-resolution processed to obtain a down-resolution image (image resolution of 320*240), thereby reducing the amount of computation.
[0071] The first grading module is used to determine the average gray level of the down-resolution image. When the average gray level is less than the threshold Gray_TH, the visibility of the image is graded as poor.
[0072] The target gradient feature extraction module is used to filter the down-resolution image with an average gray level not less than a threshold, and then calculate the horizontal gradient, vertical gradient, average gradient, and maximum gradient of the image.
[0073] The second grading module is used to determine whether the maximum gradient of the down-resolution image is less than the first gradient threshold; when it is less than the first gradient threshold, the visibility of the image is graded as poor.
[0074] The edge point extraction module is used to extract edge points from a down-resolution image whose maximum gradient is not less than a first gradient threshold, and obtain an edge map.
[0075] The third grading module is used to determine the number of extracted edge points. When the number of points is less than the threshold, the visibility of the image is graded as poor.
[0076] The sea-line extraction module is used to obtain sea-line information within a specified angle range from the edge map of a down-resolution image with a number of edge points not less than a threshold.
[0077] Specifically, the sea-line extraction module uses Hough transform to extract straight line segments within a specified angle range as the sea-line.
[0078] The fourth grading module is used to determine the length of the sea surface line. When the length of the sea surface line is less than a threshold, the visibility of the image is graded as poor.
[0079] The fifth grading module is used to further determine the maximum value of the image gradient for a down-resolution image with a sea-line length not less than a threshold. When the maximum gradient value is not less than the third gradient threshold, the visibility of the image is graded as good; when it is not less than the second gradient threshold but less than the third gradient threshold, the visibility of the image is graded as average; when it is less than the second gradient threshold, the visibility of the image is graded as poor.
[0080] The output module, based on the visibility classification results, outputs the sea observation images with good visibility and their corresponding frame numbers to the first memory, the sea observation images with moderate visibility and their corresponding frame numbers to the second memory, and the sea observation images with poor visibility and their corresponding frame numbers to the third memory.
[0081] Specifically, the target gradient feature extraction module includes an adaptive filtering module and a gradient calculation module;
[0082] The adaptive filtering module includes a Gaussian filter to perform Gaussian filtering on the down-resolution image;
[0083] The gradient calculation module calculates the horizontal gradient, vertical gradient, intermediate gradient value, and maximum gradient of the image after adaptive Gaussian filtering.
[0084] More specifically, the Gaussian filter is an n*n matrix. Combining this with the sigma parameter of the Canny operator, the Gaussian filter is: dgau2D=-x·*exp(-(x·*x+x) T ·*x T ) / (2*canny_sigma)) / (2*π*canny_sigma 2 ); where x is the input data of the Gaussian filter, a two-dimensional n*n vector.
[0085] The horizontal gradient set and the vertical gradient set dx and dy are:
[0086] The intermediate value of the image gradient is: value = sqrt(dx.*dx + dy.*dy);
[0087] The maximum gradient is: max_grad = max(value);
[0088] I represents the pixel matrix of the image after downscaling.
[0089] Specifically, the edge point extraction module includes a gradient normalization module, a histogram module, an extraction module, and a labeling module;
[0090] The gradient normalization module is used to perform segmented normalization based on the magnitude of the maximum gradient value of the image to obtain the normalized gradient result.
[0091] The histogram module is used to build a histogram based on the gradient normalization result;
[0092] Specifically, the histogram module establishes a histogram based on a normalized gradient, divided into 16 equal parts, according to the principle of proportion.
[0093] The extraction module is used to extract edge points using the Canny algorithm. When extracting edge points, non-maximum suppression in the Canny algorithm is performed by adaptive horizontal and vertical gradient sets. The module also uses histograms to extract gradient high thresholds and gradient low thresholds that meet the conditions.
[0094] When using the Canny algorithm for image edge point extraction, the algorithm is improved by applying the obtained gradient normalization results, thus completing the non-maximum suppression and double threshold detection included in the adaptive Canny algorithm. During edge point extraction, non-maximum suppression in the Canny algorithm is performed using adaptive horizontal and vertical gradient sets, thereby preserving points with the largest local gradients and achieving edge refinement.
[0095] Specifically, the gradient high threshold and gradient low threshold that meet the conditions are extracted using histograms:
[0096] The gradient high threshold high_thresold = find(add(counts)>canny_higth*Δrow*Δline,1,first);
[0097] Gradient low threshold low_thresold = canny_lowth * high_thresold;
[0098] Here, `counts` represents the normalized gradient histogram, `canny_higth` and `canny_lowth` represent the preset high and low gradient thresholds, respectively, and `Δrow` and `Δline` refer to the pixel width and height after removing image boundaries such as black and white borders, respectively. `find()` is a MATLAB function used for searching; `add()` is a MATLAB function for summing.
[0099] The labeling module is used to obtain the edge map of the image by obtaining the number of points and length information of each edge through eight-neighbor labeling.
[0100] More specifically, such as Figure 3As shown, the gradient normalization module includes a first gradient value comparison module, a first normalization module, a second gradient value comparison module, a second normalization module, a third gradient value comparison module, a third normalization module, a fourth gradient value comparison module, a fourth normalization module, a fifth normalization module, and a normalization result output module;
[0101] The first gradient value comparison module is used to determine whether the maximum gradient value of the input image is greater than the first gradient grading threshold th1; if so, the gradient of the image is normalized by the first normalization factor in the first normalization module; otherwise, the process proceeds to the second gradient comparison module.
[0102] The second gradient value comparison module is used to determine whether the maximum gradient value of the input image is greater than the second gradient grading threshold th2; if so, the gradient of the image is normalized by the second normalization factor in the second normalization module; otherwise, the process proceeds to the third gradient comparison module.
[0103] The third gradient value comparison module is used to determine whether the maximum gradient value of the input image is greater than the third gradient grading threshold th3; if so, the gradient of the image is normalized by the third normalization factor in the third normalization module; otherwise, it proceeds to the fourth gradient comparison module.
[0104] The fourth gradient value comparison module is used to determine whether the maximum gradient value of the input image is greater than the fourth gradient grading threshold th4; if so, the fourth normalization factor is used to normalize the gradient of the image in the fourth normalization module; otherwise, the fifth normalization factor is used to normalize the gradient of the image in the fifth normalization module.
[0105] The normalization result output module is used to output the normalization results of the first normalization module, the second normalization module, the third normalization module, the fourth normalization module, or the fifth normalization module.
[0106] in,
[0107] The first normalization factor is value1 = value / min(va1*max_grad,va2);
[0108] The second normalization factor is value2 = value / max(va1*max_grad,va3);
[0109] The third normalization factor is value3 = value / max(va2*max_grad,va2);
[0110] The fourth normalization factor is value4 = value / va4;
[0111] The fifth normalization factor is value5 = value / va5;
[0112] In the formula, the grading constants are va1 < va2 < va3 < va4 < va5; value is the median value of the image gradient; and max_grad is the maximum gradient.
[0113] In summary, the embodiments of this invention greatly facilitate subsequent target detection by classifying and storing visibility levels. Furthermore, an improved Canny algorithm is used to establish a gradient adaptive planning method based on maximum gradient calculation of acquired images and weighted texture to determine visibility against a sea-sky background. Engineering practice and experiments have demonstrated that the sea-sky background visibility classification method of this invention can meet the requirements for judging weather conditions against a sea-sky background in the field, achieving more stable and effective sea-sky line extraction and visibility assessment.
[0114] The above description is only a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any changes or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in the present invention should be included within the scope of protection of the present invention.
Claims
1. An image classification and storage device with a sea and sky background based on visibility grading, characterized in that, include: The system consists of a cache, a hierarchical processor, a first memory, a second memory, and a third memory. The buffer is used to buffer consecutive frames of sea observation images output from the optical detector; The sea observation images include a sea and sky background; The hierarchical processor is connected to the buffer and is used to read each frame of sea observation image from the buffer, perform processing on the image including resolution reduction, target gradient feature extraction, edge point extraction and sea-line length extraction, and classify the visibility of the image into poor, average and good based on the gray-scale mean features, gradient features, edge point number features and sea-line length features. The first memory is connected to the classification processor and is used to store the sea observation images with visibility classified as good and their corresponding frame numbers. The second memory is connected to the classification processor and is used to store sea observation images with visibility classified as general and their corresponding frame numbers. The third memory is connected to the classification processor and is used to store the sea observation images with poor visibility and their corresponding frame numbers. The hierarchical processor includes a resolution reduction module, a first hierarchical module, a target gradient feature extraction module, a second hierarchical module, an edge point extraction module, a third hierarchical module, a sea-line extraction module, a fourth hierarchical module, a fifth hierarchical module, and an output module; The resolution reduction module is used to perform a resolution reduction operation on the input image to obtain a reduced resolution image; The first grading module is used to determine the average gray level of the down-resolution image. When the average gray level is less than a threshold, the visibility of the image is graded as poor. The target gradient feature extraction module is used to filter the down-resolution image with an average gray level not less than a threshold, and then calculate the horizontal gradient, vertical gradient, average gradient, and maximum gradient of the image. The second grading module is used to determine whether the maximum gradient of the down-resolution image is less than the first gradient threshold; when it is less than the first gradient threshold, the visibility of the image is graded as poor. The edge point extraction module is used to extract edge points from a down-resolution image whose maximum gradient is not less than a first gradient threshold, and obtain an edge map. The third grading module is used to determine the number of extracted edge points. When the number of points is less than the threshold, the visibility of the image is graded as poor. The sea-line extraction module is used to obtain sea-line information within a specified angle range from the edge map of a down-resolution image with a number of edge points not less than a threshold. The fourth grading module is used to determine the length of the sea surface line. When the length of the sea surface line is less than a threshold, the visibility of the image is graded as poor. The fifth grading module is used to further determine the maximum value of the image gradient for a down-resolution image with a sea-line length not less than a threshold. When the maximum gradient value is not less than the third gradient threshold, the visibility of the image is graded as good; when it is not less than the second gradient threshold and less than the third gradient threshold, the visibility of the image is graded as average; when it is less than the second gradient threshold, the visibility of the image is graded as poor. The output module, based on the visibility classification results, outputs the sea observation images with good visibility and their corresponding frame numbers to the first memory, the sea observation images with moderate visibility and their corresponding frame numbers to the second memory, and the sea observation images with poor visibility and their corresponding frame numbers to the third memory.
2. The classification storage device according to claim 1, characterized in that, The target gradient feature extraction module includes an adaptive filtering module and a gradient calculation module; The adaptive filtering module includes a Gaussian filter to perform Gaussian filtering on the down-resolution image; The gradient calculation module calculates the horizontal gradient, vertical gradient, intermediate gradient value, and maximum gradient of the image after adaptive Gaussian filtering.
3. The classification storage device according to claim 2, characterized in that... The Gaussian filter is an n*n matrix. Combining this with the sigma parameter of the Canny operator, the Gaussian filter is obtained as follows: ; in, The input data for the Gaussian filter is a two-dimensional n*n vector; Horizontal gradient set and vertical gradient set and for: ; The median value of the image gradient is: ; The maximum gradient is: ; I This is the pixel matrix of the image after downscaling.
4. The classification storage device according to claim 1, characterized in that, The sea line extraction module uses Hough transform to extract sea lines; images whose number and range of sea lines do not meet the conditions are identified as images of sea lines that cannot be extracted, and the visibility is classified as poor.
5. The classification storage device according to claim 1, characterized in that, The edge point extraction module includes a gradient normalization module, a histogram module, an extraction module, and a labeling module; The gradient normalization module is used to perform segmented normalization based on the magnitude of the maximum gradient value of the image to obtain the normalized gradient result. The histogram module is used to build a histogram based on the gradient normalization result; The extraction module is used to extract edge points using the Canny algorithm. When extracting edge points, non-maximum suppression in the Canny algorithm is performed by adaptive horizontal and vertical gradient sets. The module also uses histograms to extract gradient high thresholds and gradient low thresholds that meet the conditions. The labeling module is used to obtain the edge map of the image by obtaining the number of points and length information of each edge through eight-neighbor labeling.
6. The classification storage device according to claim 5, characterized in that, The gradient normalization module includes a first gradient value comparison module, a first normalization module, a second gradient value comparison module, a second normalization module, a third gradient value comparison module, a third normalization module, a fourth gradient value comparison module, a fourth normalization module, and a fifth normalization module; The first gradient value comparison module is used to determine whether the maximum gradient value of the input image is greater than the first gradient grading threshold; if so, in the first normalization module, the gradient of the image is normalized using the first normalization factor. Otherwise, proceed to the second gradient comparison module; The second gradient value comparison module is used to determine whether the maximum gradient value of the input image is greater than the second gradient grading threshold; if so, in the second normalization module, the gradient of the image is normalized using the second normalization factor. Otherwise, proceed to the third gradient comparison module; The third gradient value comparison module is used to determine whether the maximum gradient value of the input image is greater than the third gradient grading threshold; if so, the third normalization module uses the third normalization factor to normalize the gradient of the image. Otherwise, proceed to the fourth gradient comparison module; The fourth gradient value comparison module is used to determine whether the maximum gradient value of the input image is greater than the fourth gradient grading threshold; if so, the fourth normalization module uses the fourth normalization factor to normalize the gradient of the image. Otherwise, in the fifth normalization module, the gradient of the image is normalized using the fifth normalization factor.
7. The classification storage device according to claim 6, characterized in that, The first normalization factor is ; The second normalization factor is ; The third normalization factor is ; The fourth normalization factor is ; The fifth normalization factor is ; In the formula, the grading constant ; This represents the median value of the image gradient. This represents the maximum gradient.
8. The classification storage device according to claim 7, characterized in that, The histogram module establishes a histogram based on a normalized gradient, divided into 16 equal parts, according to the principle of proportion.
9. The classification storage device according to claim 8, characterized in that, The extraction module uses histograms to extract gradient high thresholds and gradient low thresholds that meet the conditions. Gradient High Threshold ; Gradient low threshold ; in, counts Represents the normalized gradient histogram. and These represent the preset high and low threshold values for the gradient, respectively. and These refer to the pixel width and height after removing black and white borders from the image, respectively. This is a function in MATLAB used to implement the search function; This is the summation function in MATLAB.
Citation Information
Patent Citations
Image processing method and device, computer equipment and storage medium
CN108830197A
Visibility detection method and device, computer equipment and storage medium
CN111145120A