Method and device for specifying histogram of information content
Through the information histogram specification method, the gray-level mapping relationship is established, which solves the problem of excessive contrast enhancement in image processing, achieves contrast enhancement and detail retention, and significantly improves the image processing effect.
Patent Information
- Application Number
- CN202410820166.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-24
- Publication Date
- 2024-09-17
AI Technical Summary
The probability-based histogram equalization algorithm in image processing in the existing technology will lead to the merging of gray levels with small probability, resulting in the loss of details and unnatural excessive enhancement of contrast, which is especially obvious in peak images.
By designing an information content histogram specification method, based on the cumulative distribution function of the original image and the cumulative distribution function of the specified information content histogram, a gray level mapping relationship is established and the image is transformed to reduce gray level merging and suppression. Contrast is excessively enhanced.
It effectively improves the contrast of the image, retains detailed information, avoids unnatural and excessive enhancement of contrast, and significantly improves the quality of image processing.
Smart Images

Figure CN118657665A
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of image processing, and in particular to a method and device for regulating an information volume histogram. Background Art
[0002] The so-called histogram regulation is to transform the original grayscale histogram into the desired histogram through a grayscale mapping function. The information volume histogram regulation is to transform the original information volume histogram into the desired information volume histogram. The probability-based histogram equalization algorithm will merge the grayscales with low probability, reduce the grayscale, and some details will disappear. It may also cause pseudo contours. For some images with high peaks in the histogram, the contrast will be unnaturally enhanced after the histogram equalization. In digital images, those grayscale pixels with low probability of occurrence (usually the edge of the image) often contain important detail information, while those grayscale pixels with high probability of occurrence (usually the background of the image or the non-edge part of the target) often contain less information. Therefore, compared with the traditional probability-based histogram, the information volume-based histogram counts the information volume of each grayscale in the statistical process, and it takes into account the role of each grayscale in describing the image information. When using the information volume histogram for histogram equalization, compared with the probability-based histogram equalization, the number of grayscale combinations with low probability will be reduced, and the over-enhancement phenomenon will be suppressed at the high probability histogram peak (for related content, see the inventor's other patent application "Information volume histogram equalization method, electronic device and medium based on parabola adjustment"). However, when the image has a very high peak, the information volume histogram equalization algorithm will suppress the unnatural over-enhancement of contrast, but this over-enhancement still exists. In order to solve this problem, the inventor proposes a method of regulating the amount of information histogram to eliminate this unnatural over-enhancement. It needs to design a specified normalized amount of information histogram. First, analyze the normalized amount of information histogram of the original image to see which gray levels the peak of its amount of information histogram is at; if the gray levels where the peak is located are scattered, only the amount of information of these gray levels needs to be retained and the remaining amount of information needs to be evenly distributed, so as to obtain the normalized normalized amount of information histogram; and if the gray levels where the peak is located are concentrated, for example, near the gray level 0 or the gray level 255, the amount of information of the gray levels with large amount of information can be retained, and these gray levels need to be mapped apart, and the remaining amount of information needs to be evenly distributed to the remaining gray levels. The specified normalized amount of information histogram is obtained through the above process, and then the specified amount of information histogram is used to normalize the amount of information histogram of the original image to be enhanced, so that the contrast of the image can be improved without causing over-enhancement.
[0003] Based on this technical background, the present invention studies a method and device for regulating an information volume histogram. Summary of the invention
[0004] In view of the shortcomings of the prior art, the present invention provides a method and device for regulating an information amount histogram. The method establishes a mapping relationship between the grayscale level of the original image and the specified grayscale level based on the cumulative distribution function of the information amount histogram of the original image and the cumulative distribution function of the specified information amount histogram, and performs image transformation based on the mapping relationship. Compared with the existing histogram equalization algorithm, the method can effectively eliminate the over-enhancement phenomenon.
[0005] In order to achieve the above object, a first aspect of the present invention provides a method for specifying an information amount histogram, comprising:
[0006] Based on the information amount histogram of each gray level pixel of the original image to be enhanced, the cumulative distribution function of the information amount histogram of the original image is calculated;
[0007] According to the effect to be achieved by the original image to be enhanced, a prescribed information amount histogram of each gray level pixel is designed, and a cumulative distribution function of the prescribed information amount histogram is calculated based on the prescribed information amount histogram of each gray level pixel;
[0008] Based on the cumulative distribution function of the original image information amount histogram and the cumulative distribution function of the specified information amount histogram, a mapping relationship between the original image grayscale and the specified grayscale is established;
[0009] Image transformation is performed based on the mapping relationship.
[0010] A second aspect of the present invention provides an information volume histogram specification device, comprising:
[0011] The original image information volume establishing module is used to calculate the cumulative distribution function of the original image information volume histogram based on the information volume histogram of each gray level pixel of the original image to be enhanced;
[0012] A prescribed information volume establishing module is used to design a prescribed information volume histogram of each grayscale pixel according to the effect to be achieved by the original image to be enhanced, and calculate a cumulative distribution function of the prescribed information volume histogram based on the prescribed information volume histogram of each grayscale pixel;
[0013] A mapping relationship establishing module, used to establish a mapping relationship between the original image grayscale and the specified grayscale based on the cumulative distribution function of the original image information amount histogram and the cumulative distribution function of the specified information amount histogram;
[0014] An image transformation module is used to perform image transformation based on the mapping relationship.
[0015] The beneficial effects of the present invention include:
[0016] (1) The information content histogram specification method proposed in the present invention establishes a mapping relationship between the grayscale level of the original image and the specified grayscale level based on the cumulative distribution function of the information content histogram of the original image and the cumulative distribution function of the specified information content histogram, and performs image transformation based on the mapping relationship, which can effectively improve the contrast of the grayscale image and significantly improve the brightness of the dark image.
[0017] (2) The information histogram normalization method proposed in the present invention can not only reduce the merging of image gray levels and retain certain detail information like the existing information histogram equalization algorithm, but also suppress and eliminate the over-enhancement phenomenon compared with the existing information histogram equalization algorithm.
[0018] (3) The information amount histogram normalization method proposed in the present invention obtains an information amount histogram by counting the number of pixels of each gray level of the original image to be enhanced, normalizes the information amount histogram, and calculates the cumulative distribution function of the information amount histogram; designs a prescribed information amount histogram according to the effect to be achieved by the image, counts its information amount histogram, and then normalizes it to calculate the cumulative distribution function of the prescribed information amount histogram; searches for the cumulative distribution value of the prescribed information amount histogram that is closest to the cumulative distribution value of each gray level of the original image, and establishes a mapping relationship between the gray level of the original image and the prescribed gray level; effectively improves the quality of image processing and broadens the idea of image processing.
[0019] Other features and advantages of the present invention will be described in detail in the following detailed description. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] The above and other objects, features and advantages of the present invention will become more apparent through a more detailed description of exemplary embodiments of the present invention with reference to the accompanying drawings.
[0021] Figure 1 The figure is a flow chart of the information volume histogram specification method proposed in the present invention.
[0022] Figure 2 This is a schematic diagram comparing the original image, the image after histogram equalization, the image after information histogram equalization, and the image after information histogram normalization of the present application in a specific implementation of the information histogram normalization method proposed in the present invention.
[0023] Figure 3 A schematic diagram comparing the original image information amount histogram, the image information amount histogram after histogram equalization, the image information amount histogram after information amount histogram equalization, and the image information amount histogram after information amount histogram normalization of the present application in a specific implementation manner of the information amount histogram normalization method proposed in the present invention.
[0024] Figure 4It is a schematic diagram for comparing an information amount histogram specified in a specific implementation of the information amount histogram specification method proposed in the present invention and an image information amount histogram after the information amount histogram is specified. DETAILED DESCRIPTION
[0025] The preferred embodiments of the present invention will be described in more detail below. Although the preferred embodiments of the present invention are described below, it should be understood that the present invention can be implemented in various forms and should not be limited to the embodiments set forth herein.
[0026] The present invention provides a method for specifying an information volume histogram, such as Figure 1 As shown, including:
[0027] Based on the information amount histogram of each gray level pixel of the original image to be enhanced, the cumulative distribution function of the information amount histogram of the original image is calculated;
[0028] According to the effect to be achieved by the original image to be enhanced, a prescribed information amount histogram of each gray level pixel is designed, and a cumulative distribution function of the prescribed information amount histogram is calculated based on the prescribed information amount histogram of each gray level pixel;
[0029] Based on the cumulative distribution function of the original image information amount histogram and the cumulative distribution function of the specified information amount histogram, a mapping relationship between the original image grayscale and the specified grayscale is established;
[0030] Perform image transformation based on the mapping relationship.
[0031] In the present invention, based on the cumulative distribution function of the original image information amount histogram and the cumulative distribution function of the specified information amount histogram, a mapping relationship between the original image grayscale and the specified grayscale is established, and image transformation is performed based on the mapping relationship, which can effectively improve the contrast of the grayscale image and significantly enhance the brightness of the dark image.
[0032] In the present invention, not only can the merging of image gray levels be reduced and certain detail information be retained as in the existing information histogram equalization algorithm, but also, compared with the existing information histogram equalization algorithm, the over-enhancement phenomenon can be suppressed and eliminated.
[0033] According to the present invention, based on the information amount histogram of each gray level pixel of the original image to be enhanced, the cumulative distribution function of the information amount histogram of the original image is calculated, which includes:
[0034] Count the number of pixels of each gray level of the original image to be enhanced, and calculate the information amount histogram of each gray level pixel;
[0035] The information amount histogram of each gray level pixel is normalized and the cumulative distribution function of the information amount histogram of the original image is calculated.
[0036] According to the present invention, the information amount of each gray level pixel is calculated as follows:
[0037] -n i log2p i ;
[0038] Among them, n i is the number of grayscale pixels of the i-th level, p i is the probability of the i-th grayscale pixel appearing;
[0039] The calculation formula for the probability of the i-th grayscale pixel appearing is:
[0040]
[0041] Among them, n is the total number of pixels in the image.
[0042] According to the present invention, the information amount histogram of each gray level pixel is normalized, and the cumulative distribution function of the information amount histogram of the original image is calculated, including:
[0043] The information amount of each gray level pixel is divided by the total information amount of the image to obtain a normalized information amount histogram of each gray level pixel;
[0044] Based on the normalized information amount histogram of each gray level pixel, the cumulative distribution function of the information amount histogram of the original image is calculated.
[0045] Preferably, the total information content of the image is calculated as follows:
[0046]
[0047] Among them, H is the total information content of the image;
[0048] The expression of the cumulative distribution function of the original image information histogram is:
[0049]
[0050] Among them, S is the cumulative distribution function of the original image information histogram, and k is the image grayscale.
[0051] According to the present invention, the cumulative distribution function of the prescribed information amount histogram calculated based on the prescribed information amount histogram of each gray level pixel includes:
[0052] The specified information amount of each gray level pixel is divided by the total specified information amount of the image to obtain a normalized specified information amount histogram of each gray level pixel;
[0053] Based on the normalized prescribed information volume histogram of each gray level pixel, a cumulative distribution function of the prescribed information volume histogram is calculated.
[0054] Preferably, the calculation formula for the total specified information amount of the image is:
[0055]
[0056] Among them, H g is the total amount of information required for the image, h i is the specified information amount of the i-th gray level.
[0057] According to the present invention, the expression of the cumulative distribution function of the information content histogram is specified as:
[0058]
[0059] Among them, G n is the cumulative distribution function of the histogram of the specified information volume, and n is the specified gray level.
[0060] According to the present invention, based on the cumulative distribution function of the original image information amount histogram and the cumulative distribution function of the specified information amount histogram, establishing the mapping relationship between the original image grayscale and the specified grayscale includes:
[0061] Based on the cumulative distribution value of the original image information amount histogram, the cumulative distribution value of the specified information amount histogram closest to it is found, and the mapping relationship between the original image grayscale and the specified grayscale is established.
[0062] In the present invention, an information amount histogram is obtained by counting the number of pixels of each gray level of the original image to be enhanced, the information amount histogram is normalized, and the cumulative distribution function of the information amount histogram is calculated; a prescribed information amount histogram is designed according to the effect to be achieved by the image, the information amount histogram is counted, and then normalized, and the cumulative distribution function of the prescribed information amount histogram is calculated; the cumulative distribution value of the prescribed information amount histogram closest to the cumulative distribution value of each gray level of the original image is searched, and a mapping relationship between the gray level of the original image and the prescribed gray level is established; the quality of image processing is effectively improved, and the idea of image processing is broadened.
[0063] The present invention will be described in more detail below by way of examples.
[0064] Embodiment 1:
[0065] This embodiment proposes a method for regulating an information volume histogram, and the specific implementation steps are as follows:
[0066] Step 1: Count the number of pixels of each gray level in the original image to be enhanced, and calculate the amount of information of each gray level - n i log2p i , get the information amount histogram, and calculate the total information amount of the image Among them, ni is the number of pixels of the i-th gray level, pi is the probability of each gray level appearing, n is the total number of pixels in the image;
[0067] Step 2: Divide the information amount histogram by the total information amount of the image to obtain the normalized information amount histogram, and calculate the cumulative distribution function of the information amount histogram
[0068] Step 3: Design a specified information volume histogram based on the desired image effect, and specify the information volume of each gray level as h i , the total amount of information in the specified histogram is Calculate the cumulative distribution function of the specified information amount histogram
[0069] Step 4: Cumulative distribution value S of each gray level of the original image k Find the cumulative distribution value G of the specified information amount histogram that is closest to it n , establish the mapping relationship between the original image gray level k and the specified gray level n;
[0070] Step 5: Map each gray level k of the original image to gray level n, and perform image transformation based on this mapping relationship.
[0071] from Figure 2 It can be seen that the original image is a dark image. After histogram equalization, the unnatural over-enhancement of the image contrast is very obvious; after information histogram equalization, this unnatural over-enhancement of the contrast is partially suppressed, but the image still has obvious unnatural over-enhancement of the contrast; after information histogram normalization, the contrast of the image is effectively improved, and the image does not have unnatural over-enhancement of the contrast, that is, the unnatural over-enhancement of the image contrast is eliminated.
[0072] from Figure 3 It can be seen that there is a peak of concentrated information near the gray level of 0. At this time, after histogram equalization, the unnatural over-enhancement phenomenon will be very serious. The grayscale of the image after histogram equalization is concentrated in the high grayscale area, and a whitish image will be obtained; the information histogram equalization algorithm will weaken this over-enhancement phenomenon, and its grayscale will move to the low grayscale area, but at this time there is only one grayscale within the grayscale level of 100, and then there is grayscale 138, and there is obvious over-enhancement at this time; and the image after the information histogram is standardized will retain the information of those grayscale levels with large information and map these grayscale levels apart, so that the grayscale is no longer so concentrated, but it is still mapped to the low grayscale value area, which can not only improve the contrast of the image but also will not cause excessive enhancement.
[0073] from Figure 4 It can be seen that the information amount histogram of the original image has a concentrated peak near 0, and the normalized information amount of the five gray levels 0, 3, 6, 9, and 11 are 0.24197, 0.29912, 0.1382, 0.07829, and 0.050506 respectively. We retain the information amount of these gray levels and map these five gray levels to five gray levels 0, 16, 32, 48, and 64 respectively, that is, map these gray levels concentrated near 0 to enhance the contrast of these gray levels; then distribute the remaining normalized information amount 0.19191 evenly to the 180 gray levels 76-255. Through the above process, the specified information amount histogram is obtained, as shown Figure 4 As shown in the left figure; the image information histogram after the information histogram is standardized is as follows Figure 4 As shown in the figure on the right, by comparing the two figures, we find that the two figures are very similar, and the five gray levels of 0, 16, 32, 48, and 64 are exactly the same; that is, the information histogram after histogram standardization will be transformed into a histogram similar to the desired information histogram (the specified information histogram).
[0074] The average amount of information of a single pixel in the image, that is, the entropy of the image, is shown in Table 1.
[0075] Table 1
[0076] Entropy of the original image 1.5570 Entropy after histogram equalization 1.5133 Entropy after information histogram equalization 1.5487 Entropy after normalization of information histogram 1.5487
[0077] As can be seen from Table 1, the entropy of the original image is the largest. At this time, there is no grayscale merging, so its entropy is the largest; and according to information theory, grayscale merging will reduce the entropy of the source; compared with the histogram equalization algorithm, the information histogram normalization method is the same as the information histogram equalization algorithm. They can both reduce the merging of image grayscales and retain some detail information. Therefore, the entropy values after information histogram equalization and normalization are larger than the entropy values after histogram equalization, and their entropy values are close to the entropy values of the original image.
[0078] Embodiment 2:
[0079] This embodiment provides a method for specifying an information volume histogram. Figure 1 As shown, including:
[0080] Based on the information amount histogram of each gray level pixel of the original image to be enhanced, the cumulative distribution function of the information amount histogram of the original image is calculated;
[0081] According to the effect to be achieved by the original image to be enhanced, a prescribed information amount histogram of each gray level pixel is designed, and a cumulative distribution function of the prescribed information amount histogram is calculated based on the prescribed information amount histogram of each gray level pixel;
[0082] Based on the cumulative distribution function of the original image information amount histogram and the cumulative distribution function of the specified information amount histogram, a mapping relationship between the original image grayscale and the specified grayscale is established;
[0083] Perform image transformation based on mapping relationship;
[0084] Based on the information amount histogram of each gray level pixel of the original image to be enhanced, the cumulative distribution function of the information amount histogram of the original image is calculated, including:
[0085] Count the number of pixels of each gray level of the original image to be enhanced, and calculate the information amount histogram of each gray level pixel;
[0086] Normalize the information amount histogram of each gray level pixel and calculate the cumulative distribution function of the information amount histogram of the original image;
[0087] In this embodiment, the information amount of each gray level pixel is calculated as follows:
[0088] -n i log2p i ;
[0089] Among them, n i is the number of grayscale pixels of the i-th level, p i is the probability of the i-th grayscale pixel appearing;
[0090] The calculation formula for the probability of the i-th grayscale pixel appearing is:
[0091]
[0092] Where n is the total number of pixels in the image;
[0093] The information amount histogram of each gray level pixel is normalized, and the cumulative distribution function of the original image information amount histogram is calculated, including:
[0094] The information amount of each gray level pixel is divided by the total information amount of the image to obtain a normalized information amount histogram of each gray level pixel;
[0095] Based on the normalized information amount histogram of each gray level pixel, the cumulative distribution function of the information amount histogram of the original image is calculated;
[0096] In this embodiment, the calculation formula for the total information amount of the image is:
[0097]
[0098] Among them, H is the total information content of the image;
[0099] The expression of the cumulative distribution function of the original image information histogram is:
[0100]
[0101] Among them, S is the cumulative distribution function of the original image information histogram, and k is the image grayscale;
[0102] In this embodiment, the cumulative distribution function of the prescribed information amount histogram calculated based on the prescribed information amount histogram of each gray level pixel includes:
[0103] The specified information amount of each gray level pixel is divided by the total specified information amount of the image to obtain a normalized specified information amount histogram of each gray level pixel;
[0104] Based on the normalized prescribed information amount histogram of each gray level pixel, a cumulative distribution function of the prescribed information amount histogram is calculated;
[0105] The calculation formula for the total specified information volume of the image is:
[0106]
[0107] Among them, H g is the total amount of information required for the image, h i is the specified information amount of the i-th gray level;
[0108] According to the present invention, the expression of the cumulative distribution function of the information content histogram is specified as:
[0109]
[0110] Among them, G n is the cumulative distribution function of the histogram of the specified information content, and n is the specified gray level;
[0111] In this embodiment, based on the cumulative distribution function of the original image information amount histogram and the cumulative distribution function of the specified information amount histogram, establishing the mapping relationship between the original image grayscale and the specified grayscale includes:
[0112] Based on the cumulative distribution value of the original image information amount histogram, the cumulative distribution value of the specified information amount histogram closest to it is found, and the mapping relationship between the original image grayscale and the specified grayscale is established.
[0113] Embodiment three:
[0114] This embodiment provides an information volume histogram specification device, including:
[0115] The original image information volume establishing module is used to calculate the cumulative distribution function of the original image information volume histogram based on the information volume histogram of each gray level pixel of the original image to be enhanced;
[0116] A prescribed information volume establishment module is used to design a prescribed information volume histogram of each gray level pixel according to the effect to be achieved by the original image to be enhanced, and calculate the cumulative distribution function of the prescribed information volume histogram based on the prescribed information volume histogram of each gray level pixel;
[0117] A mapping relationship establishing module, used for establishing a mapping relationship between the original image grayscale and the specified grayscale based on the cumulative distribution function of the original image information amount histogram and the cumulative distribution function of the specified information amount histogram;
[0118] An image transformation module, used for performing image transformation based on a mapping relationship;
[0119] Based on the information amount histogram of each gray level pixel of the original image to be enhanced, the cumulative distribution function of the information amount histogram of the original image is calculated, including:
[0120] Count the number of pixels of each gray level of the original image to be enhanced, and calculate the information amount histogram of each gray level pixel;
[0121] Normalize the information amount histogram of each gray level pixel and calculate the cumulative distribution function of the information amount histogram of the original image;
[0122] In this embodiment, the information amount of each gray level pixel is calculated as follows:
[0123] -n i log2p i ;
[0124] Among them, ni is the number of grayscale pixels of the i-th level, and pi is the probability of the i-th grayscale pixel appearing;
[0125] The calculation formula for the probability of the i-th grayscale pixel appearing is:
[0126]
[0127] Where n is the total number of pixels in the image;
[0128] The information amount histogram of each gray level pixel is normalized, and the cumulative distribution function of the original image information amount histogram is calculated, including:
[0129] The information amount of each gray level pixel is divided by the total information amount of the image to obtain a normalized information amount histogram of each gray level pixel;
[0130] Based on the normalized information amount histogram of each gray level pixel, the cumulative distribution function of the information amount histogram of the original image is calculated;
[0131] In this embodiment, the calculation formula for the total information amount of the image is:
[0132]
[0133] Among them, H is the total information content of the image;
[0134] The expression of the cumulative distribution function of the original image information histogram is:
[0135]
[0136] Among them, S is the cumulative distribution function of the original image information histogram, and k is the image grayscale;
[0137] In this embodiment, the cumulative distribution function of the prescribed information amount histogram calculated based on the prescribed information amount histogram of each gray level pixel includes:
[0138] The specified information amount of each gray level pixel is divided by the total specified information amount of the image to obtain a normalized specified information amount histogram of each gray level pixel;
[0139] Based on the normalized prescribed information amount histogram of each gray level pixel, a cumulative distribution function of the prescribed information amount histogram is calculated;
[0140] The calculation formula for the total specified information volume of the image is:
[0141]
[0142] Among them, H g is the total amount of information required for the image, h i is the specified information amount of the i-th gray level;
[0143] According to the present invention, the expression of the cumulative distribution function of the information content histogram is specified as:
[0144]
[0145] Among them, G n is the cumulative distribution function of the histogram of the specified information content, and n is the specified gray level;
[0146] In this embodiment, based on the cumulative distribution function of the original image information amount histogram and the cumulative distribution function of the specified information amount histogram, establishing the mapping relationship between the original image grayscale and the specified grayscale includes:
[0147] Based on the cumulative distribution value of the original image information amount histogram, the cumulative distribution value of the specified information amount histogram closest to it is found, and the mapping relationship between the original image grayscale and the specified grayscale is established.
[0148] The information amount histogram normalization method proposed in the embodiment of the present invention establishes a mapping relationship between the grayscale level of the original image and the specified grayscale level based on the cumulative distribution function of the information amount histogram of the original image and the cumulative distribution function of the specified information amount histogram, and performs image transformation based on the mapping relationship. It can effectively improve the contrast of the grayscale image and significantly enhance the brightness of the dark image. Compared with the existing histogram equalization algorithm, it can effectively eliminate the over-enhancement phenomenon.
[0149] The embodiments of the present invention have been described above, and the above description is exemplary, not exhaustive, and is not limited to the disclosed embodiments. Many modifications and changes will be apparent to those skilled in the art without departing from the scope and spirit of the described embodiments.
Claims
1. A method for regulating an information amount histogram, characterized in that: include: Based on the information amount histogram of each gray level pixel of the original image to be enhanced, the cumulative distribution function of the information amount histogram of the original image is calculated; According to the effect to be achieved by the original image to be enhanced, a prescribed information amount histogram of each gray level pixel is designed, and a cumulative distribution function of the prescribed information amount histogram is calculated based on the prescribed information amount histogram of each gray level pixel; Based on the cumulative distribution function of the original image information amount histogram and the cumulative distribution function of the specified information amount histogram, a mapping relationship between the original image grayscale and the specified grayscale is established; Image transformation is performed based on the mapping relationship.
2. The method according to claim 1, characterized in that Based on the information amount histogram of each gray level pixel of the original image to be enhanced, the cumulative distribution function of the information amount histogram of the original image is calculated, including: Counting the number of pixels of each gray level of the original image to be enhanced, and calculating the information amount histogram of each gray level pixel; The information amount histogram of each gray level pixel is normalized to calculate the cumulative distribution function of the information amount histogram of the original image.
3. The method according to claim 2, characterized in that The information calculation formula for each grayscale pixel is: -n i log2p i ; Where ni is the number of i-th grayscale pixels, and pi is the probability of the i-th grayscale pixel appearing; The calculation formula for the probability of the i-th grayscale pixel appearing is: Among them, n is the total number of pixels in the image.
4. The method according to claim 3, characterized in that Normalizing the information amount histogram of each gray level pixel to calculate the cumulative distribution function of the information amount histogram of the original image includes: Dividing the information amount of each grayscale pixel by the total information amount of the image to obtain a normalized information amount histogram of each grayscale pixel; Based on the normalized information amount histogram of each gray level pixel, the cumulative distribution function of the information amount histogram of the original image is calculated.
5. The method according to claim 4, characterized in that The calculation formula of the total information amount of the image is: Among them, H is the total information content of the image; The expression of the cumulative distribution function of the original image information amount histogram is: Among them, S is the cumulative distribution function of the original image information histogram, and k is the image grayscale.
6. The method according to claim 1, characterized in that The cumulative distribution function of the prescribed information amount histogram calculated based on the prescribed information amount histogram of each gray level pixel includes: Dividing the prescribed information amount of each grayscale pixel by the total prescribed information amount of the image to obtain a normalized prescribed information amount histogram of each grayscale pixel; Based on the normalized prescribed information volume histogram of each gray level pixel, a cumulative distribution function of the prescribed information volume histogram is calculated.
7. The method according to claim 6, characterized in that The calculation formula for the total specified information volume of the image is: Among them, H g is the total information content of the image, h i is the specified information amount of the i-th gray level.
8. The method according to claim 7, characterized in that The expression of the cumulative distribution function of the prescribed information amount histogram is: Among them, G n is the cumulative distribution function of the histogram of the specified information volume, and n is the specified gray level.
9. The method according to claim 1, characterized in that: Based on the cumulative distribution function of the original image information amount histogram and the cumulative distribution function of the specified information amount histogram, establishing a mapping relationship between the original image grayscale and the specified grayscale includes: Based on the cumulative distribution value of the original image information amount histogram, the cumulative distribution value of the prescribed information amount histogram closest to it is found, and a mapping relationship between the original image grayscale and the prescribed grayscale is established.
10. An information volume histogram specification device, characterized in that: include: The original image information volume establishing module is used to calculate the cumulative distribution function of the original image information volume histogram based on the information volume histogram of each gray level pixel of the original image to be enhanced; A prescribed information volume establishment module is used to design a prescribed information volume histogram of each grayscale pixel according to the effect to be achieved by the original image to be enhanced, and calculate a cumulative distribution function of the prescribed information volume histogram based on the prescribed information volume histogram of each grayscale pixel; A mapping relationship establishing module, used to establish a mapping relationship between the original image grayscale and the specified grayscale based on the cumulative distribution function of the original image information amount histogram and the cumulative distribution function of the specified information amount histogram; An image transformation module is used to perform image transformation based on the mapping relationship.
Citation Information
Patent Citations
Construction method for gray-level information content histogram
CN101937562A
Image enhancement method based on space domain
CN105139366A
Image enhancement method and apparatus based on compressed perception
CN107730476A
A remote sensing image enhancement method based on fusion of gradient and gray information
CN109345491A
Information amount histogram equalization method based on parabola adjustment, electronic equipment and medium
CN117974463A
