An image processing method based on local maximum

By using Hilbert fractal curve sequence and local window optimization layout in image processing, the problem of high complexity of local maximum extraction calculation in the prior art is solved, and the effect of rapid calculation is achieved.

CN118506022BActive Publication Date: 2024-11-19EHIWAY MICROELECTRONIC SCI & TECH (SUZHOU) CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202410979144.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-07-22
Publication Date
2024-11-19
Estimated Expiration
2044-07-22

AI Technical Summary

Technical Problem

The prior art is used to extract local maximum values ​​in image processing, and the calculation complexity is high. As the image size increases, the processing time increases significantly, and the requirements of rapid processing cannot be met.

Method used

One-dimensional traversal is performed by Hilbert fractal curve sequence, combining threshold detection and local window optimization layout, reducing the calculation amount through one-dimensional paper traversal and improving the calculation speed.

Benefits of technology

Without reducing the local maximum extraction effect, the calculation time is significantly reduced, the calculation speed of local maximum value in the image is improved, and rapid calculation is achieved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118506022B_ABST
    Figure CN118506022B_ABST
Patent Text Reader

Abstract

A local maximum-based image processing method includes: traversing all local windows in an image to be processed; setting a pixel amplitude threshold of the image to be processed and comparing it with the pixel amplitude of the local window; traversing all pixel windows in the local window, comparing the pixel amplitude values ​​of all pixel windows, saving and outputting the pixel window position information with the largest pixel amplitude value; when the next local window of the local window position starts to be traversed, the pixel window position with the largest pixel amplitude value is used as the starting position. The present application provides an image processing method based on local maximum values, which utilizes the continuity feature of local energy of an image to reduce the operation time without reducing the effect of local maximum extraction, significantly improves the calculation speed of extracting local maximum values ​​in an image, and achieves the purpose of fast calculation.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the field of image processing, and in particular relates to an image processing method based on local maximum. Background Art

[0002] Local maximum extraction is widely used in the field of image processing because it is simple to implement and can extract energy-significant image regions. In the design of the local maximum extraction module, in order to traverse each pixel in the image and each pixel in the local window, many schemes adopt a quadruple loop approach, which has high computational complexity and takes a long time to process as the image size increases.

[0003] like Figure 1 The figure shows a flow chart of a local maximum value extraction method in the prior art. The prior art adopts a nested structure of an image two-dimensional loop and a local window two-dimensional loop. It is necessary to traverse the sliding window in the entire image range and determine in each local window whether the central pixel is the maximum value in the window. When the image size increases, the calculation time will increase exponentially, which cannot meet the time requirements for fast processing. Summary of the invention

[0004] The present application provides an image processing method based on local maximum, which utilizes the continuity characteristics of local energy of the image to reduce the operation time without reducing the local maximum extraction effect, significantly improves the calculation speed of extracting local maximum in the image, and achieves the purpose of fast calculation.

[0005] Other purposes and advantages of the present invention can be further understood from the technical features disclosed in the present invention.

[0006] To achieve one, part or all of the above purposes or other purposes, the present invention provides an image processing method based on local maximum.

[0007] An image processing method based on local maximum, comprising:

[0008] Image traversal: obtaining an image to be processed, dividing the image to be processed into a plurality of local windows, and sliding the window to traverse all the local window positions of the image to be processed;

[0009] Threshold detection: setting a pixel amplitude threshold of the image to be processed and comparing it with the pixel amplitude of the local window during the sliding window traversal process; if the pixel amplitude of the local window is greater than the pixel amplitude threshold, performing local window traversal; otherwise, returning to the image traversal process;

[0010] Local window traversal: traverse all pixel windows within the local window, compare the pixel amplitude values ​​of all pixel windows, save and output the position information of the pixel window with the largest pixel amplitude value, and complete the traversal of the local window.

[0011] After completing a local window traversal, the next local window traversal starts with the pixel window position with the largest pixel amplitude value.

[0012] The sliding window has the same shape and size as the local window, and the image traversal is performed by moving the sliding window;

[0013] The image traversal process uses a Hilbert fractal curve sequence to traverse all local window positions in the image to be processed.

[0014] During the threshold detection process, if the pixel amplitude of the local window is less than the pixel amplitude threshold, the image traversal process is returned to perform threshold detection on the next local window at the position of the local window.

[0015] The local window traversal also includes:

[0016] The local window is equally divided into a central detection pixel window and a plurality of peripheral pixel windows;

[0017] The pixel window layout in the local window is optimized, and a one-dimensional traversal is performed according to the optimized pixel window layout.

[0018] The optimization method is:

[0019] With the central detection pixel window as the center, other peripheral pixel windows are sequentially arranged around the central detection pixel window in a quasi-circular layout manner, and the peripheral pixel windows farther away are discarded.

[0020] The specific process of one-dimensional traversal according to the optimized pixel window layout includes:

[0021] Taking the central detection pixel window as the central position, a circular traversal is performed from inside to outside according to the optimized layout of other peripheral pixel windows and the order of other peripheral pixel windows.

[0022] The local window traversal process also includes:

[0023] When the amplitude value of the central detection pixel window is greater than the amplitude values ​​of all other surrounding pixel windows, the position information of the central detection pixel window is saved and output, and the traversal of the local window is completed;

[0024] When the amplitude value of the central detection pixel window is smaller than the amplitude value of the peripheral pixel window, the position information of the peripheral pixel window whose amplitude value is larger than the central detection pixel window is recorded and output, and the traversal of the local window is completed.

[0025] After the local window traversal process is completed, the next local window of the local window position starts to traverse, and the pixel window position with the largest pixel amplitude value is used as the starting position to start the circular traversal until all local windows are traversed and the image traversal process is completed.

[0026] The pixel window position information includes the position coordinates of the pixel window, and the position coordinates of the pixel window are saved to a queue and output as a result.

[0027] Compared with the prior art, the beneficial effects of the present invention mainly include:

[0028] The present application provides an image processing method based on local maximum, which performs one-dimensional traversal on all local windows in the processed image based on the Hilbert fractal curve sequence; accelerates the cyclic calculation through the threshold detection module; optimizes the pixel window layout in the local window, performs a circular traversal according to the optimized pixel window layout, compares the pixel amplitude values ​​of all pixel windows, saves and outputs the pixel window position information with the largest pixel amplitude value; when the next local window of the local window position starts to traverse, the pixel window position with the largest pixel amplitude value is used as the starting position, and the traversal starting point is adjusted. The present application utilizes the continuity feature of the local energy of the image to reduce the operation time without reducing the local maximum extraction effect, significantly improves the calculation speed of extracting local maxima in the image, and achieves the purpose of fast calculation.

[0029] In order to make the above and other purposes, features and advantages of the present invention more obvious and easy to understand, preferred embodiments are given below and described in detail with reference to the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS

[0030] In order to more clearly illustrate the technical solutions in the specific embodiments of the present invention, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0031] Figure 1 It is a flowchart of the local maximum extraction method in the prior art.

[0032] Figure 2 A flowchart of an image processing method based on local maximum provided in an embodiment of the present application.

[0033] Figure 3 A schematic diagram of the module flow of an image processing method based on local maximum provided in an embodiment of the present application.

[0034] Figure 4A schematic diagram of an image traversal method provided in an embodiment of the present application.

[0035] Figure 5 A schematic diagram of a local window traversal method provided in an embodiment of the present application. DETAILED DESCRIPTION

[0036] The above and other technical contents, features and effects of the present invention will be clearly presented in the following detailed description of a preferred embodiment with reference to the drawings. The directional terms mentioned in the following embodiments, such as up, down, left, right, front or back, etc., are only referenced to the directions of the attached drawings. Therefore, the directional terms used are used to illustrate and not to limit the present invention.

[0037] The present application provides an image processing method based on local maximum, which utilizes the continuity characteristics of local energy of the image to reduce the operation time without reducing the local maximum extraction effect, significantly improves the calculation speed of extracting local maximum in the image, and achieves the purpose of fast calculation.

[0038] The following will describe the various embodiments of the present application in detail with reference to the accompanying drawings. However, it will be appreciated by those skilled in the art that in the various embodiments of the present application, many technical details are provided in order to enable the reader to better understand the present application. However, even without these technical details and various changes and modifications based on the following embodiments, the technical solution claimed in the present application can be implemented. Example

[0039] Figure 2 The figure is a schematic flow chart of an image processing method based on local maximum provided in an embodiment of the present application.

[0040] like Figure 2 As shown, an image processing method based on local maximum includes: an image traversal step, a threshold detection step and a local window traversal step.

[0041] Figure 3 The figure shows a module flow diagram of an image processing method based on local maximum provided in an embodiment of the present application.

[0042] like Figure 3 As shown, the image traversal step is mainly implemented through the image one-dimensional loop traversal module; the threshold detection step is mainly implemented through the image pixel amplitude over-threshold detection module; the local window traversal step is implemented through the local window one-dimensional loop traversal module, the comparison module, the exit position memory module and the local maximum position storage module.

[0043] The image traversal step is mainly implemented through the one-dimensional image loop traversal module. The image to be processed is divided into multiple local windows. The sliding window has the same shape and size as the local window. All local window positions in the image to be processed are traversed by moving the sliding window. All local window positions in the image to be processed are traversed in one dimension according to the Hilbert fractal curve sequence.

[0044] Figure 4 Shown is a schematic diagram of an image traversal method provided in an embodiment of the present application.

[0045] like Figure 4 As shown, Figure 4 The 4-A in the equation represents a two-dimensional traditional traversal. Figure 4 4-B in the figure represents one-dimensional fractal traversal of Hilbert fractal curve sequence. Compared with two-dimensional traditional traversal, one-dimensional traversal of Hilbert fractal curve sequence reduces the two-dimensional loop to one-dimensional loop to reduce the traversal time, while avoiding position jump during traversal. Adjacent pixels are adjacent in the traversal order as much as possible, which can better utilize the continuous characteristics of energy in the image to be processed.

[0046] The threshold detection step is mainly implemented through the image pixel amplitude over-threshold detection module. The pixel amplitude threshold T of the image to be processed is set and compared with the pixel amplitude of the local window during the sliding window traversal process; if the pixel amplitude of the local window is less than the pixel amplitude threshold T, the subsequent local window traversal is not performed, indicating that its significance in the image to be tested is not high, and it is not meaningful to continue the local window traversal. The image traversal process is returned to continue the comparison of the next local window pixel amplitude at the local window position with the pixel amplitude threshold T. Therefore, the threshold T can be appropriately adjusted to save calculation amount; if the pixel amplitude of the local window is greater than the pixel amplitude threshold T, the subsequent local window traversal process is performed.

[0047] The local window traversal step is implemented through a local window one-dimensional loop traversal module, a comparison module, an exit position memory module, and a local maximum position storage module.

[0048] The local window is equally divided into a central detection pixel window and multiple peripheral pixel windows. When traversing all pixel windows in the local window, the pixel window layout in the local window is first optimized. The optimization method includes taking the central detection pixel window as the center, and arranging other peripheral pixel windows in a circular layout in sequence around the central detection pixel window, and discarding the farther peripheral pixel windows.

[0049] Figure 5 Shown is a schematic diagram of a local window traversal method provided in an embodiment of the present application.

[0050] like Figure 5 As shown, Figure 55-A in the figure represents a traditional pixel window. Taking a local window of 5x5 pixel window as an example, the central detection pixel window is taken as the center, and other peripheral pixel windows are arranged in a square layout in sequence around the central detection pixel window, and are traversed in a two-dimensional cycle in rows and columns.

[0051] Figure 5 5-B in the figure represents the optimized pixel window. Taking the local window of 5x5 pixel window as an example, according to the optimized pixel window layout, with the central detection pixel window as the center position, a one-dimensional circular traversal is performed from the inside to the outside according to the optimized layout of other surrounding pixel windows and the order of other surrounding pixel windows.

[0052] Figure 5 5-A and Figure 5 The difference between the two traversal methods in 5-B is:

[0053] Figure 5 In 5-B of the paper, the pixel window layout in the optimized local window is adopted, and a circular local window is used instead. Figure 5 The square layout of 5-A in the above effectively reduces the number of comparisons and saves the amount of calculation. At the same time, discarding the window comparison operation of the distant surrounding pixels has little effect on the effect of maximum value extraction.

[0054] In addition, this application also optimizes the traversal order. Figure 5 The 5-A square layout in the example needs to be traversed in two dimensions by row and column. Figure 5 The pixel window layout in the optimized local window of 5-B is traversed in a zigzag traversal from the inside to the outside. Based on the local energy continuity of the image, it is assumed that the central detection pixel is a point on the target and can meet the pixel amplitude threshold T. Then the amplitude value of the adjacent pixels has a greater probability of exceeding the amplitude value of the central detection pixel, while the peripheral pixel window of the outer circle of the local window has a relatively small probability of exceeding the amplitude value of the central detection pixel. Therefore, the adjacent inner circle peripheral pixel window is traversed first, and then the outer circle peripheral pixel window is traversed. The peripheral pixel windows with larger amplitude values ​​can be traversed first, which can accelerate the local window traversal speed and reduce the number of comparisons between the amplitude value of the central detection pixel window and the amplitude values ​​of all other peripheral pixel windows.

[0055] After the traversal process of all pixel windows in the local window is completed, the pixel amplitude values ​​of all pixel windows are compared through the comparison module. When the amplitude value of the central detection pixel window is greater than the amplitude values ​​of all other surrounding pixel windows, the local maximum condition is met, and the position coordinates of the central detection pixel window are saved to the queue through the local maximum position saving module and output as the result, completing the traversal of the local window and continuing the traversal of the next local window of the local window position;

[0056] When the amplitude value of the central detection pixel window is smaller than the amplitude value of the peripheral pixel window, the position of the peripheral pixel window whose amplitude value is larger than the central detection pixel window is recorded and output by exiting the position memory module, and outputted as the local window traversal result, thereby completing the traversal of the local window;

[0057] After the local window traversal process is completed, the traversal of the next local window position is started, and the pixel window position with the largest pixel amplitude value is used as the starting position to start the circular traversal until all local windows are traversed and the image traversal process is completed;

[0058] like Figure 5 As shown in 5-B, if the amplitude value of the position 6 of the surrounding pixel window is found to be greater than the amplitude value of the central detection pixel window, the position 6 is recorded, and when the next local window starts to traverse at the local window position, the circular traversal is started with the position 6 as the starting position. The local texture and edge shape of the image have certain similarities. The exit position determined in the exit position memory module has guiding significance for the traversal order of the next local window adjacent to the local window position. Therefore, the priority traversal from the last recorded exit position has a higher probability of exiting the current cycle in advance, reducing the number of comparisons in the comparison module, and playing the effect of accelerating the calculation.

[0059] The present application provides an image processing method based on local maximum, which performs one-dimensional traversal on all local windows in the processed image based on the Hilbert fractal curve sequence; accelerates the cyclic calculation through the threshold detection module; optimizes the pixel window layout in the local window, performs a circular traversal according to the optimized pixel window layout, compares the pixel amplitude values ​​of all pixel windows, saves and outputs the pixel window position information with the largest pixel amplitude value; when the next local window of the local window position starts to traverse, the pixel window position with the largest pixel amplitude value is used as the starting position, and the traversal starting point is adjusted. The present application utilizes the continuity feature of the local energy of the image to reduce the operation time without reducing the local maximum extraction effect, significantly improves the calculation speed of extracting local maxima in the image, and achieves the purpose of fast calculation.

[0060] In order to facilitate the description, some common English nouns or letters used in the present invention are only used for exemplary reference rather than restrictive interpretation or specific usage, and the protection scope of the present invention should not be limited by their possible Chinese translations or specific letters.

[0061] It should also be noted that, in this document, relational terms such as "first" and "second" are merely used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations.

Claims

1. An image processing method based on local maximum, characterized in that: include: Image traversal: obtaining an image to be processed, dividing the image to be processed into a plurality of local windows, and sliding the window using a Hilbert fractal curve sequence to traverse all the local window positions of the image to be processed; Threshold detection: setting a pixel amplitude threshold of the image to be processed and comparing it with the pixel amplitude of the local window during the sliding window traversal process; if the pixel amplitude of the local window is greater than the pixel amplitude threshold, performing local window traversal; otherwise, returning to the image traversal process; Local window traversal: traverse all pixel windows within the local window, compare the pixel amplitude values ​​of all pixel windows, save and output the position information of the pixel window with the largest pixel amplitude value, and complete the traversal of the local window.

2. The image processing method based on local maximum according to claim 1, characterized in that: After completing a local window traversal, the traversal of the next local window takes the pixel window position with the largest pixel amplitude value as the starting position.

3. The image processing method based on local maximum according to claim 2, characterized in that: The sliding window has the same shape and size as the local window, and the image traversal is performed by moving the sliding window.

4. The image processing method based on local maximum according to claim 1, characterized in that: During the threshold detection process, if the pixel amplitude of the local window is less than the pixel amplitude threshold, the image traversal process is returned to perform threshold detection on the next local window at the position of the local window.

5. The image processing method based on local maximum according to claim 1, characterized in that: The local window traversal also includes: The local window is equally divided into a central detection pixel window and a plurality of peripheral pixel windows; The pixel window layout in the local window is optimized, and a one-dimensional traversal is performed according to the optimized pixel window layout.

6. The image processing method based on local maximum according to claim 5, characterized in that: The way to optimize the pixel window layout within the local window is: With the central detection pixel window as the center, other peripheral pixel windows are sequentially arranged around the central detection pixel window in a quasi-circular layout manner, and the peripheral pixel windows farther away are discarded.

7. The image processing method based on local maximum according to claim 6, characterized in that: The specific process of one-dimensional traversal according to the optimized pixel window layout includes: Taking the central detection pixel window as the central position, a circular traversal is performed from inside to outside according to the optimized layout of other peripheral pixel windows and the order of other peripheral pixel windows.

8. The image processing method based on local maximum according to claim 7, characterized in that: The local window traversal process also includes: When the amplitude value of the central detection pixel window is greater than the amplitude values ​​of all other surrounding pixel windows, the position information of the central detection pixel window is saved and output, and the traversal of the local window is completed; When the amplitude value of the central detection pixel window is smaller than the amplitude value of the peripheral pixel window, the position information of the peripheral pixel window whose amplitude value is larger than the central detection pixel window is recorded and output, and the traversal of the local window is completed.

9. The image processing method based on local maximum according to claim 8, characterized in that: After the local window traversal process is completed, the next local window of the local window position starts to traverse, and the pixel window position with the largest pixel amplitude value is used as the starting position to start the circular traversal until all local windows are traversed and the image traversal process is completed.

10. The image processing method based on local maximum according to claim 8, characterized in that: The pixel window position information includes the position coordinates of the pixel window, and the position coordinates of the pixel window are saved to a queue and output as a result.

Citation Information

Patent Citations

  • Image dithering processing method and image dithering processing device

    CN105224538A

  • Recognizer for white line on road

    JP2003331295A

  • Single image contrast enhancement method using the adaptive wiener filter

    US9349170B1