CN110570384A - method and device for carrying out illumination equalization processing on scene image, computer equipment and computer storage medium - Google Patents

method and device for carrying out illumination equalization processing on scene image, computer equipment and computer storage medium Download PDF

Info

Publication number
CN110570384A
CN110570384A CN201910871988.1A CN201910871988A CN110570384A CN 110570384 A CN110570384 A CN 110570384A CN 201910871988 A CN201910871988 A CN 201910871988A CN 110570384 A CN110570384 A CN 110570384A
Authority
CN
China
Prior art keywords
scene image
color space
image
brightness
pixel
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201910871988.1A
Other languages
Chinese (zh)
Inventor
邓豪
张华�
刘桂华
徐锋
邓鑫
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Southwest University of Science and Technology
Original Assignee
Southwest University of Science and Technology
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Southwest University of Science and Technology filed Critical Southwest University of Science and Technology
Priority to CN201910871988.1A priority Critical patent/CN110570384A/en
Publication of CN110570384A publication Critical patent/CN110570384A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/77Retouching; Inpainting; Scratch removal
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/40Image enhancement or restoration using histogram techniques
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/90Dynamic range modification of images or parts thereof
    • G06T5/92Dynamic range modification of images or parts thereof based on global image properties
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/90Determination of colour characteristics
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N9/00Details of colour television systems
    • H04N9/64Circuits for processing colour signals
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10024Color image
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20004Adaptive image processing
    • G06T2207/20008Globally adaptive
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/30Subject of image; Context of image processing
    • G06T2207/30168Image quality inspection

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Image Processing (AREA)

Abstract

the invention relates to the technical field of image processing, and discloses a method and a device for performing illumination equalization processing on a scene image, computer equipment and a computer storage medium. The invention provides a scheme for carrying out self-adaptive correction and improvement on pixel point brightness on the basis of a classical Gamma correction method, can carry out self-adaptive equalization processing on illumination of a scene image on the whole situation and the local situation, namely can self-adaptively improve the contrast of the image according to the contrast relation between the local situation and the whole situation, can realize the purposes of effectively solving the problems of uneven illumination, shadow and the like in the image, and is convenient for practical application and popularization.

Description

method and device for carrying out illumination equalization processing on scene image, computer equipment and computer storage medium
Technical Field
The invention belongs to the technical field of image processing, and particularly relates to a method and a device for performing illumination equalization processing on a scene image, computer equipment and a computer storage medium.
background
at present, the application fields of mobile robots are very wide, and most of the application fields are located in outdoor scenes, so that scene images which are obtained by an imaging system carried by the mobile robots and contain targets generally have various problems of image overall over-brightness, overall over-darkness, partial over-brightness and over-darkness, local unevenness and the like caused by factors such as backlight, sidelight, light path shielding and the like, and the problems have adverse effects on feature point extraction, target representation and subsequent target identification and tracking. Therefore, before the target recognition and tracking are performed on the scene image, the illumination equalization processing needs to be performed on the scene image firstly.
Although there are many ways to improve the illumination balance and contrast of an image, the most common and effective method is Gamma correction. The method has low calculation complexity and obvious contrast improvement, but also has the problems of poor local adjustment effect, difficult shadow elimination and the like.
disclosure of Invention
In order to solve the problems of poor local adjustment effect and difficult shadow elimination of the current image illumination equalization method, the invention aims to provide a method, a device, computer equipment and a computer storage medium for performing illumination equalization processing on a scene image.
The technical scheme adopted by the invention is as follows:
A method for carrying out illumination equalization processing on a scene image comprises the following steps:
s101, obtaining a scene image to be processed;
S102, calculating the brightness average value mu of the scene image according to the following formula:
In the formula, M is the total number of horizontal pixels of the scene image, N is the total number of vertical pixels of the scene image, I (x, y) is the input brightness value of the pixel (x, y), x is the abscissa of the pixel (x, y), and y is the ordinate of the pixel (x, y);
S103, aiming at each pixel point (x, y) of the scene image, calculating a corresponding correction coefficient gamma (x, y) according to the following formula:
Wherein epsilon is (mu/k) a normalized coefficient, and k is a natural number between 120 and 136;
S104, aiming at each pixel point (x, y) of the scene image, correcting the corresponding brightness value according to the following formula:
in the formula, O (x, y) is an output brightness value of a pixel point (x, y), and c is a scale factor for controlling global brightness change and is a positive real number not greater than 1;
and S105, outputting the corrected scene image.
Optimally, when the color description mode of the scene image is RGB color space, before the step S102, the scene image is further converted from RGB color space to Lab color space, then for the L-channel component of the scene image, the illumination balance correction is implemented by performing the steps S102 to S104, and finally for the scene image, the corrected L-channel component is converted into RGB color space together with the original color component a and the color component b.
Further optimally, the scene image is converted from the RGB color space to the Lab color space as follows: firstly, converting from an RGB color space to an XYZ color space, and then converting from the XYZ color space to a Lab color space;
And converting the scene image from the Lab color space to the RGB color space as follows: the conversion from the Lab color space to the XYZ color space is performed first, and then the conversion from the XYZ color space to the RGB color space is performed.
Preferably, after the scene image is converted from the RGB color space to the Lab color space and before the step S102 is executed, for each pixel point (x, y) of the scene image, the corresponding input brightness value is calculated according to 255: a scale of 100 maps to a range of values between 0 and 255;
And after step S104 is executed and before the scene image is converted from the Lab color space to the RGB color space, for each pixel point (x, y) of the scene image, the corresponding input brightness value is calculated according to a ratio of 100: a scale of 255 maps to a range of values between 0 and 100.
further optimally, the histogram equalization process is performed on the scene image after the scene image is converted from the RGB color space to the Lab color space and before the step S102 is performed or after the step S104 is performed and before the scene image is converted from the Lab color space to the RGB color space.
preferably, in the step S103, k is 128.
optimally, before the step S104, the scale factor c is calculated according to the following formula:
the other technical scheme adopted by the invention is as follows:
a device for carrying out illumination equalization processing on a scene image comprises an image acquisition module, a brightness mean value calculation module, a correction coefficient calculation module, a brightness correction processing module and an image output module which are sequentially communicated and connected;
the image acquisition module is used for acquiring a scene image to be processed;
the brightness mean value calculating module is used for calculating the brightness mean value mu of the scene image according to the following formula:
in the formula, M is the total number of horizontal pixels of the scene image, N is the total number of vertical pixels of the scene image, I (x, y) is the input brightness value of the pixel (x, y), x is the abscissa of the pixel (x, y), and y is the ordinate of the pixel (x, y);
The correction coefficient calculation module is configured to calculate, for each pixel point (x, y) of the scene image, a corresponding correction coefficient γ (x, y) according to the following formula:
wherein epsilon is (mu/k) a normalized coefficient, and k is a natural number between 120 and 136;
the brightness correction processing module is configured to correct, for each pixel point (x, y) of the scene image, a corresponding brightness value according to the following formula:
In the formula, O (x, y) is an output brightness value of a pixel point (x, y), and c is a scale factor for controlling global brightness change and is a positive real number not greater than 1;
And the image output module is used for outputting the corrected scene image.
The other technical scheme adopted by the invention is as follows:
A computer device comprising a memory and a processor communicatively coupled, wherein the memory is configured to store a computer program and the processor is configured to execute the computer program to perform the method steps of performing illumination equalization processing on an image of a scene as previously described.
The other technical scheme adopted by the invention is as follows:
a computer storage medium having stored thereon a computer program which, when executed by a processor, carries out the method steps of illumination equalization processing of an image of a scene as previously described.
The invention has the beneficial effects that:
(1) The invention provides a scheme for carrying out self-adaptive correction and improvement on pixel point brightness on the basis of a classical Gamma correction method, can carry out self-adaptive equalization processing on illumination of a scene image on the whole situation and the local situation, namely can self-adaptively improve the contrast of the image according to the contrast relation between the local situation and the whole situation, can realize the purposes of effectively solving the problems of uneven illumination, shadow and the like in the image, and is convenient for practical application and popularization.
drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
Fig. 1 is a schematic flow chart of a method for performing illumination equalization processing on a scene image according to the present invention.
FIG. 2 is a schematic diagram of Gamma responses of different correction coefficients provided by the present invention.
Fig. 3 is a schematic structural diagram of an apparatus for performing illumination equalization processing on a scene image according to the present invention.
fig. 4 is a schematic structural diagram of a computer device provided by the present invention.
Detailed Description
the invention is further described with reference to the following figures and specific embodiments. It should be noted that the description of the embodiments is provided to help understanding of the present invention, but the present invention is not limited thereto. Specific structural and functional details disclosed herein are merely illustrative of example embodiments of the invention. This invention may, however, be embodied in many alternate forms and should not be construed as limited to the embodiments set forth herein.
It should be understood that in some of the flows described herein, operations are included in a particular order, but may be performed out of order or in parallel with the order in which they appear herein, with the order of the operations, e.g., S101, S102, etc., merely used to distinguish between various operations, and the order itself does not represent any order of execution. Additionally, the flows may include more or fewer operations, and the operations may likewise be performed sequentially or in parallel.
It will be understood that, although the terms first, second, etc. may be used herein to describe various elements, these elements should not be limited by these terms. These terms are only used to distinguish one element from another. For example, a first element could be termed a second element, and, similarly, a second element could be termed a first element, without departing from the scope of example embodiments of the present invention.
It should be understood that the term "and/or" herein is merely one type of association relationship that describes an associated object, meaning that three relationships may exist, e.g., a and/or B may mean: a exists alone, B exists alone, and A and B exist at the same time, and the term "/and" is used herein to describe another association object relationship, which means that two relationships may exist, for example, A/and B, may mean: a alone, and both a and B alone, and further, the character "/" in this document generally means that the former and latter associated objects are in an "or" relationship.
It will be understood that when an element is referred to as being "connected," "connected," or "coupled" to another element, it can be directly connected or coupled to the other element or intervening elements may be present. In contrast, when an element is referred to as being "directly adjacent" or "directly coupled" to another element, there are no intervening elements present. Other words used to describe relationships between elements (e.g., "between … …" versus "directly between … …", "adjacent" versus "directly adjacent", etc.) should be interpreted in a similar manner.
the terminology used herein is for the purpose of describing particular embodiments only and is not intended to be limiting of example embodiments of the invention. As used herein, the singular forms "a", "an" and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It will be further understood that the terms "comprises," "comprising," "includes" and/or "including," when used herein, specify the presence of stated features, integers, steps, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, numbers, steps, operations, elements, components, and/or groups thereof.
It should also be noted that, in some alternative implementations, the functions/acts noted may occur out of the order noted in the figures. For example, two figures shown in succession may, in fact, be executed substantially concurrently, or the figures may sometimes be executed in the reverse order, depending upon the functionality/acts involved.
In the following description, specific details are provided to facilitate a thorough understanding of example embodiments. However, it will be understood by those of ordinary skill in the art that the example embodiments may be practiced without these specific details. For example, systems may be shown in block diagrams in order not to obscure the examples in unnecessary detail. In other instances, well-known processes, structures and techniques may be shown without unnecessary detail in order to avoid obscuring example embodiments.
example one
As shown in fig. 1 to 2, the method for performing illumination equalization processing on a scene image according to this embodiment may include, but is not limited to, the following steps S101 to S105.
s101, obtaining a scene image to be processed.
In the step S101, the scene image may be, but is not limited to, a live image obtained by mounting an imaging system and including a target, and the obtaining manner may be, but is not limited to, a conventional manner such as importing.
s102, calculating the brightness average value mu of the scene image according to the following formula:
in the formula, M is the total number of horizontal pixels of the scene image, N is the total number of vertical pixels of the scene image, I (x, y) is the input brightness value of the pixel (x, y), x is the abscissa of the pixel (x, y), and y is the ordinate of the pixel (x, y).
in step S102, the input luminance value is a luminance parameter value before processing, and each pixel has a corresponding luminance parameter.
S103, aiming at each pixel point (x, y) of the scene image, calculating a corresponding correction coefficient gamma (x, y) according to the following formula:
Wherein epsilon ═ (mu/k) is a normalized coefficient, and k is a natural number between 120 and 136.
in step S103, the correction coefficient γ is a key parameter in the classical Gamma correction method: when Gamma is more than 1, the Gamma correction method has stretching effect on the brightness histogram in the image (even if the brightness extends to the high brightness value); whereas when γ < 1, the Gamma correction method has a shrinking effect on the luminance histogram in the image (i.e., the luminance shrinks toward a low luminance value). As shown in fig. 2, the effect of different correction coefficients on the correction of the scene image is illustrated. Therefore, the core of Gamma correction is to achieve the enhancement of the details of the lower part or the higher part of the image brightness by selecting a proper correction coefficient Gamma. Usually, the correction coefficient γ is an ideal value artificially selected after multiple experimental comparisons.
However, for a scene image obtained by imaging the motion of an object in the real world, different illumination conditions exist in different images, and different illumination distributions such as partial uneven illumination and shadows also exist in the same image, so that it is difficult to obtain an ideal correction coefficient through artificial setting. Therefore, in step S103, the correction coefficient γ can be adapted according to the luminance information of different pixel points by a specific formula, so as to implement the subsequent adaptive Gamma correction: when the illumination is relatively low, gamma approaches to 0, and the contrast of a low-illumination part can be improved to a large extent; on the contrary, when the illumination is relatively high, the contrast enhancement effect of the high illumination part is obvious. In addition, the present inventors have studied the relationship between the image average value and the visual characteristic, and have found that when the luminance average value μ > 128 indicates that the image as a whole is brighter, and when the luminance average value μ ≦ 128 indicates that the image as a whole is darker, the visual characteristic of the image having a uniform luminance distribution is the best when the average value is around 128, that is, k is preferably 128.
S104, aiming at each pixel point (x, y) of the scene image, correcting the corresponding brightness value according to the following formula:
in the formula, O (x, y) is an output brightness value of the pixel (x, y), and c is a scale factor for controlling global brightness change and is a positive real number not greater than 1.
in step S104, since adaptive correction and improvement of pixel luminance are performed based on the classical Gamma correction method, adaptive equalization processing can be performed on the illumination of the scene image in global and local areas, that is, the contrast of the image can be adaptively improved according to the local and global contrast relationship, and the purpose of effectively solving the problems of uneven illumination and shadows in the image can be achieved. In addition, considering that for a completely dark or extremely bright scene image, the partial adjustment is not perfect for improving the visual characteristics of the scene image, so before the step S104, the scale factor c may be calculated according to the following formula:Namely, when the brightness average value mu is smaller, namely the overall brightness of the scene image is darker, the scale factor c is larger, and the image brightness is improved more obviously; conversely, when the brightness average value μ is larger, that is, the overall brightness of the scene image is brighter, the scale factor c is smaller, and the image brightness suppression is more obvious.
optimally, considering that the target image collected by the imaging system is usually an RGB (Red, Green, Blue, Red, Green, Blue) three-color image, although the luminance information is contained in three color spaces, if the luminance information is directly processed, not only the operation complexity is additionally increased, but also the color distortion of the scene image is caused because the size difference of the color components of the same pixel point undergoes adaptive equalization of different scales, therefore, when the color description mode of the scene image is an RGB color space, before the step S102, the scene image is further converted from the RGB color space to a Lab color space (i.e., a CIE Lab color space whose color is independent of luminance, a Commission internationale' Eclairage Lab color space, an Commission internationale color-opponent space), and then, for the L channel component of the scene image, the illumination equalization correction is realized by executing steps S102 to S104, and finally, converting the corrected L channel component, the original color component a and the original color component b into an RGB color space together aiming at the scene image to obtain the scene image with balanced illumination. Because the L channel in the Lab color space is an independent brightness channel, the a channel represents the color range from green to red, and the b channel represents the color range from blue to yellow, the L channel does not have any color information and closely matches the brightness perception in human visual characteristics, and the L channel component is independently subjected to self-adaptive equalization, so that the excellent color fidelity effect can be achieved while the illumination equalization of a scene image is completed.
further optimized, considering that an image with an RGB color space cannot be directly converted into an Lab color space, and an image of the Lab color space cannot be directly converted into the RGB color space, the scene image is converted from the RGB color space into the Lab color space as follows: firstly, converting from an RGB color space to an XYZ color space, and then converting from the XYZ color space to a Lab color space; and converting the scene image from the Lab color space to the RGB color space as follows: the conversion from the Lab color space to the XYZ color space is performed first, and then the conversion from the XYZ color space to the RGB color space is performed. The XYZ color space, also known as SML (Short, Middle, long) color space, is a color description method based on light stimuli of the human eye to Short (420-440nm wavelength), medium (530-540nm wavelength) and long (560-580nm wavelength).
Specifically, the RGB color space and the XYZ color space have the following conventional mapping relationship:
specifically, from the XYZ color space to the Lab color space and from the Lab color space to the XYZ color space, can be calculated by the following general formulas, respectively:
in the formula, Xn=0.950456、Yn=1.0、Zn1.088754 is a correction coefficient so that the XYZ color space converted by the above equation has a map in the same range as the Lab color space.
In addition, considering that the value range of the L channel in the Lab space is 0 to 100, after the scene image is converted from the RGB color space to the Lab color space and before the step S102 is executed, for each pixel point (x, y) of the scene image, the corresponding input brightness value is set to 255: a scale of 100 maps to a range of values between 0 and 255; and after step S104 is executed and before the scene image is converted from the Lab color space to the RGB color space, for each pixel point (x, y) of the scene image, the corresponding input brightness value is calculated according to a ratio of 100: a scale of 255 maps to a range of values between 0 and 100. In addition, since adaptive illumination equalization is to adjust all the pixels of the scene image one by one, abrupt illumination changes and highlights in the scene usually cause severe response, and overshoot occurs, so that after the scene image is converted from the RGB color space to the Lab color space and before step S102 is executed, or after step S104 is executed and before the scene image is converted from the Lab color space to the RGB color space, histogram equalization processing may be performed on the scene image, so as to make the adjustment result smoother and more natural.
And S105, outputting the corrected scene image.
In summary, the method for performing illumination equalization processing on a scene image provided by this embodiment has the following technical effects:
(1) The embodiment provides a scheme for adaptively correcting and improving the pixel brightness on the basis of a classical Gamma correction method, which can perform adaptive equalization processing on the illumination of a scene image in the global and local aspects, namely can adaptively improve the contrast of the image according to the contrast relationship between the local and global aspects, can effectively solve the problems of uneven illumination, shadow and the like in the image, and is convenient for practical application and popularization.
Example two
As shown in fig. 3, the present embodiment provides a device for performing illumination equalization processing on a scene image according to the first embodiment, including an image obtaining module, a luminance average value calculating module, a correction coefficient calculating module, a luminance correction processing module, and an image output module, which are sequentially connected in a communication manner;
The image acquisition module is used for acquiring a scene image to be processed;
the brightness mean value calculating module is used for calculating the brightness mean value mu of the scene image according to the following formula:
In the formula, M is the total number of horizontal pixels of the scene image, N is the total number of vertical pixels of the scene image, I (x, y) is the input brightness value of the pixel (x, y), x is the abscissa of the pixel (x, y), and y is the ordinate of the pixel (x, y);
The correction coefficient calculation module is configured to calculate, for each pixel point (x, y) of the scene image, a corresponding correction coefficient γ (x, y) according to the following formula:
Wherein epsilon is (mu/k) a normalized coefficient, and k is a natural number between 120 and 136;
The brightness correction processing module is configured to correct, for each pixel point (x, y) of the scene image, a corresponding brightness value according to the following formula:
In the formula, O (x, y) is an output brightness value of a pixel point (x, y), and c is a scale factor for controlling global brightness change and is a positive real number not greater than 1;
and the image output module is used for outputting the corrected scene image.
The working process, working details and technical effects of the apparatus provided in this embodiment may be referred to in embodiment one, and are not described herein again.
EXAMPLE III
As shown in fig. 4, this embodiment provides a computer device to which the method for performing illumination equalization processing on a scene image according to the first embodiment is applied, and the computer device includes a memory and a processor, which are communicatively connected, where the memory is used to store a computer program, and the processor is used to execute the computer program to implement the method steps for performing illumination equalization processing on a scene image according to the first embodiment.
For the working process, the working details, and the technical effects of the computer device provided in this embodiment, reference may be made to embodiment one, which is not described herein again.
example four
the present embodiment provides a computer storage medium storing a computer program including the method for performing illumination equalization processing on a scene image according to the first embodiment, that is, a computer program is stored on the computer storage medium, and when the computer program is executed by a processor, the computer program implements the method steps for performing illumination equalization processing on a scene image according to the first embodiment. The computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices, or may be a mobile intelligent device (such as a smart phone, a PAD, or an ipad).
For the working process, the working details, and the technical effects of the computer storage medium provided in this embodiment, reference may be made to embodiment one, which is not described herein again.
The embodiments described above are merely illustrative, and the units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment. One of ordinary skill in the art can understand and implement it without inventive effort.
Through the above description of the embodiments, those skilled in the art will clearly understand that each embodiment can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware. With this understanding in mind, the above-described technical solutions may be embodied in the form of a software product, which can be stored in a computer-readable storage medium, such as ROM/RAM, magnetic disk, optical disk, etc., and includes instructions for causing a computer device to perform the methods described in the embodiments or some portions of the embodiments.
The above examples are only intended to illustrate the technical solution of the present invention, but not to limit it; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: modifications of the technical solutions described in the embodiments or equivalent replacements of some technical features may still be made. And such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present invention.
Finally, it should be noted that the present invention is not limited to the above alternative embodiments, and that various other forms of products can be obtained by anyone in light of the present invention. The above detailed description should not be taken as limiting the scope of the invention, which is defined in the claims, and which the description is intended to be interpreted accordingly.

Claims (10)

1. a method for performing illumination equalization processing on a scene image is characterized by comprising the following steps:
s101, obtaining a scene image to be processed;
s102, calculating the brightness average value mu of the scene image according to the following formula:
in the formula, M is the total number of horizontal pixels of the scene image, N is the total number of vertical pixels of the scene image, I (x, y) is the input brightness value of the pixel (x, y), x is the abscissa of the pixel (x, y), and y is the ordinate of the pixel (x, y);
S103, aiming at each pixel point (x, y) of the scene image, calculating a corresponding correction coefficient gamma (x, y) according to the following formula:
Wherein epsilon is (mu/k) a normalized coefficient, and k is a natural number between 120 and 136;
s104, aiming at each pixel point (x, y) of the scene image, correcting the corresponding brightness value according to the following formula:
In the formula, O (x, y) is an output brightness value of a pixel point (x, y), and c is a scale factor for controlling global brightness change and is a positive real number not greater than 1;
and S105, outputting the corrected scene image.
2. The method as claimed in claim 1, wherein when the color description manner of the scene image is RGB color space, before the step S102, the scene image is further converted from RGB color space to Lab color space, then the illumination balance correction is implemented by performing the steps S102 to S104 for the L channel component of the scene image, and finally the corrected L channel component is converted into RGB color space together with the original color component a and the original color component b for the scene image.
3. The method of claim 2, wherein the scene image is transformed from RGB color space to Lab color space as follows: firstly, converting from an RGB color space to an XYZ color space, and then converting from the XYZ color space to a Lab color space;
and converting the scene image from the Lab color space to the RGB color space as follows: the conversion from the Lab color space to the XYZ color space is performed first, and then the conversion from the XYZ color space to the RGB color space is performed.
4. The method as claimed in claim 2, wherein after the converting the scene image from RGB color space to Lab color space and before performing step S102, for each pixel point (x, y) of the scene image, the corresponding input luminance value is calculated as 255: a scale of 100 maps to a range of values between 0 and 255;
And after step S104 is executed and before the scene image is converted from the Lab color space to the RGB color space, for each pixel point (x, y) of the scene image, the corresponding input brightness value is calculated according to a ratio of 100: a scale of 255 maps to a range of values between 0 and 100.
5. The method as claimed in claim 2, wherein the histogram equalization processing is performed on the scene image after the conversion from RGB color space to Lab color space and before the step S102 is performed or after the step S104 is performed and before the conversion from Lab color space to RGB color space.
6. The method as claimed in claim 1, wherein in step S103, k is 128.
7. the method of claim 1, wherein before step S104, the scale factor c is calculated according to the following formula:
8. A device for carrying out illumination equalization processing on a scene image is characterized by comprising an image acquisition module, a brightness mean value calculation module, a correction coefficient calculation module, a brightness correction processing module and an image output module which are sequentially communicated and connected;
the image acquisition module is used for acquiring a scene image to be processed;
the brightness mean value calculating module is used for calculating the brightness mean value mu of the scene image according to the following formula:
In the formula, M is the total number of horizontal pixels of the scene image, N is the total number of vertical pixels of the scene image, I (x, y) is the input brightness value of the pixel (x, y), x is the abscissa of the pixel (x, y), and y is the ordinate of the pixel (x, y);
The correction coefficient calculation module is configured to calculate, for each pixel point (x, y) of the scene image, a corresponding correction coefficient γ (x, y) according to the following formula:
Wherein epsilon is (mu/k) a normalized coefficient, and k is a natural number between 120 and 136;
the brightness correction processing module is configured to correct, for each pixel point (x, y) of the scene image, a corresponding brightness value according to the following formula:
in the formula, O (x, y) is an output brightness value of a pixel point (x, y), and c is a scale factor for controlling global brightness change and is a positive real number not greater than 1;
and the image output module is used for outputting the corrected scene image.
9. A computer device comprising a memory and a processor communicatively coupled, wherein the memory is configured to store a computer program and the processor is configured to execute the computer program to perform the method steps of performing illumination equalization processing on an image of a scene according to any one of claims 1-7.
10. a computer storage medium, having a computer program stored thereon, which, when being executed by a processor, carries out the method steps of illumination equalization of a scene image according to any one of claims 1 to 7.
CN201910871988.1A 2019-09-16 2019-09-16 method and device for carrying out illumination equalization processing on scene image, computer equipment and computer storage medium Pending CN110570384A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910871988.1A CN110570384A (en) 2019-09-16 2019-09-16 method and device for carrying out illumination equalization processing on scene image, computer equipment and computer storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910871988.1A CN110570384A (en) 2019-09-16 2019-09-16 method and device for carrying out illumination equalization processing on scene image, computer equipment and computer storage medium

Publications (1)

Publication Number Publication Date
CN110570384A true CN110570384A (en) 2019-12-13

Family

ID=68780116

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910871988.1A Pending CN110570384A (en) 2019-09-16 2019-09-16 method and device for carrying out illumination equalization processing on scene image, computer equipment and computer storage medium

Country Status (1)

Country Link
CN (1) CN110570384A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111028181A (en) * 2019-12-25 2020-04-17 歌尔股份有限公司 Image enhancement processing method, device, equipment and storage medium
CN111915523A (en) * 2020-08-04 2020-11-10 深圳蓝韵医学影像有限公司 Self-adaptive adjustment method and system for DR image brightness
CN113256503A (en) * 2020-02-13 2021-08-13 北京小米移动软件有限公司 Image optimization method and device, mobile terminal and storage medium
CN117346657A (en) * 2023-10-07 2024-01-05 上海勃傲自动化系统有限公司 Event triggering method and system based on 5G camera

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160239945A1 (en) * 2015-02-17 2016-08-18 Adobe Systems Incorporated Image haze removal using fast constrained transmission estimation
CN106251300A (en) * 2016-07-26 2016-12-21 华侨大学 A kind of quick night of based on Retinex Misty Image restored method
JP2017069666A (en) * 2015-09-29 2017-04-06 京セラドキュメントソリューションズ株式会社 Calibration system, calibration method, image forming apparatus, and calibration program
CN108846802A (en) * 2018-01-25 2018-11-20 湖南省自兴人工智能研究院 A kind of removal chromosomal G-banding mid-term gray level image Noise Method

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160239945A1 (en) * 2015-02-17 2016-08-18 Adobe Systems Incorporated Image haze removal using fast constrained transmission estimation
JP2017069666A (en) * 2015-09-29 2017-04-06 京セラドキュメントソリューションズ株式会社 Calibration system, calibration method, image forming apparatus, and calibration program
CN106251300A (en) * 2016-07-26 2016-12-21 华侨大学 A kind of quick night of based on Retinex Misty Image restored method
CN108846802A (en) * 2018-01-25 2018-11-20 湖南省自兴人工智能研究院 A kind of removal chromosomal G-banding mid-term gray level image Noise Method

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
张晶: "《多媒体信息与通信》", 30 November 2017 *
王殿伟等: ""一种光照不均匀图像的自适应校正算法"", 《系统工程与电子技术》 *

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111028181A (en) * 2019-12-25 2020-04-17 歌尔股份有限公司 Image enhancement processing method, device, equipment and storage medium
CN111028181B (en) * 2019-12-25 2023-07-14 歌尔股份有限公司 Image enhancement processing method, device, equipment and storage medium
CN113256503A (en) * 2020-02-13 2021-08-13 北京小米移动软件有限公司 Image optimization method and device, mobile terminal and storage medium
CN113256503B (en) * 2020-02-13 2024-03-08 北京小米移动软件有限公司 Image optimization method and device, mobile terminal and storage medium
CN111915523A (en) * 2020-08-04 2020-11-10 深圳蓝韵医学影像有限公司 Self-adaptive adjustment method and system for DR image brightness
CN117346657A (en) * 2023-10-07 2024-01-05 上海勃傲自动化系统有限公司 Event triggering method and system based on 5G camera
CN117346657B (en) * 2023-10-07 2024-03-19 上海勃傲自动化系统有限公司 Event triggering method and system based on 5G camera

Similar Documents

Publication Publication Date Title
CN107680056B (en) Image processing method and device
CN110570384A (en) method and device for carrying out illumination equalization processing on scene image, computer equipment and computer storage medium
US10530995B2 (en) Global tone mapping
CN112752023B (en) Image adjusting method and device, electronic equipment and storage medium
JP6111336B2 (en) Image processing method and apparatus
CN107909553B (en) Image processing method and device
CN107820069B (en) Video monitoring equipment ISP debugging method
US8781225B2 (en) Automatic tone mapping method and image processing device
CN110248170B (en) Image color adjusting method and device
CN103268596B (en) A kind of method for reducing picture noise and making color be near the mark
CN107895350B (en) HDR image generation method based on self-adaptive double gamma transformation
Jang et al. Adaptive color enhancement based on multi-scaled Retinex using local contrast of the input image
CN102340673A (en) White balance method for video camera aiming at traffic scene
WO2019104047A1 (en) Global tone mapping
CN108629738B (en) Image processing method and device
CN113706393B (en) Video enhancement method, device, equipment and storage medium
CN110807735A (en) Image processing method, image processing device, terminal equipment and computer readable storage medium
CN108377372B (en) A kind of white balancing treatment method, device, terminal device and storage medium
CN102377911B (en) Image processing apparatus, image processing method, and camera module
CN111209775A (en) Signal lamp image processing method, device, equipment and storage medium
CN105791710B (en) A kind of signal lamp image enhancement processing method
CN115239578A (en) Image processing method and device, computer readable storage medium and terminal equipment
CN108564633B (en) Gray scale image compression method and device and computer equipment
CN113284062B (en) Lens shading correction method, device, medium and terminal
CN114037641A (en) Low-illumination image enhancement method, device, equipment and medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20191213