CN112116542A - Image contrast enhancement method, device, electronic equipment and storage medium - Google Patents

Image contrast enhancement method, device, electronic equipment and storage medium Download PDF

Info

Publication number
CN112116542A
CN112116542A CN202011018981.4A CN202011018981A CN112116542A CN 112116542 A CN112116542 A CN 112116542A CN 202011018981 A CN202011018981 A CN 202011018981A CN 112116542 A CN112116542 A CN 112116542A
Authority
CN
China
Prior art keywords
image
enhanced
color cast
color
point
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.)
Granted
Application number
CN202011018981.4A
Other languages
Chinese (zh)
Other versions
CN112116542B (en
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.)
Xi'an Yu Vision Mdt Infotech Ltd
Original Assignee
Xi'an Yu Vision Mdt Infotech Ltd
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 Xi'an Yu Vision Mdt Infotech Ltd filed Critical Xi'an Yu Vision Mdt Infotech Ltd
Priority to CN202011018981.4A priority Critical patent/CN112116542B/en
Publication of CN112116542A publication Critical patent/CN112116542A/en
Application granted granted Critical
Publication of CN112116542B publication Critical patent/CN112116542B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • G06T5/90
    • G06T5/70
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/90Determination of colour characteristics
    • 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

Abstract

The embodiment of the invention discloses an image contrast enhancement method, an image contrast enhancement device, electronic equipment and a storage medium. The image contrast enhancement method comprises the following steps: determining color cast point information in the image to be enhanced according to pixel point information of the image to be enhanced; performing color cast correction on the image to be enhanced according to the color cast point information; and carrying out contrast enhancement on the image to be enhanced after the color cast correction is carried out so as to obtain an enhanced image. The method and the device realize the enhancement of the contrast of the image to be enhanced, simultaneously keep the color of the image, and improve the quality of the image after the contrast enhancement and the scene adaptability of the contrast enhancement of the image.

Description

Image contrast enhancement method, device, electronic equipment and storage medium
Technical Field
The embodiment of the invention relates to the technical field of image processing, in particular to an image contrast enhancement method and device, electronic equipment and a storage medium.
Background
Due to the influences of factors such as poor lighting conditions of shooting environments, limitation of image acquisition equipment and the like, the problems of low overall gray value and unsatisfactory contrast of actually acquired images generally exist, and the visual effect of the images is influenced. The contrast of the image needs to be improved by using an image contrast enhancement technology, and the image quality is improved. The image contrast enhancement technology is usually performed in a spatial domain or a frequency domain, and common methods in the spatial domain include a linear stretching algorithm, a histogram equalization processing or an exponential transformation processing, and the like, wherein the histogram equalization algorithm and the linear stretching algorithm are common, and have the characteristics of low complexity, small operand, and capability of obviously improving the image quality.
However, in some scene images (such as low-illumination images), there may be some areas in which the illumination is insufficient or in shadow areas, so that some pixel points in these areas often lose information along with difficulty in acquiring information, for example, a value of 0 for one or two channels of a color image. If contrast enhancement is directly performed on the low-illumination image, a color distortion phenomenon occurs in an information loss area of the image after the contrast enhancement, and the quality of the image is affected.
Disclosure of Invention
The embodiment of the invention provides an image contrast enhancement method, an image contrast enhancement device, electronic equipment and a storage medium, and aims to solve the problem of color distortion caused by contrast enhancement of a color image.
In a first aspect, an embodiment of the present invention provides an image contrast enhancement method, including:
determining color cast point information in the image to be enhanced according to pixel point information of the image to be enhanced;
performing color cast correction on the image to be enhanced according to the color cast point information;
and carrying out contrast enhancement on the image to be enhanced after the color cast correction is carried out so as to obtain an enhanced image.
In a second aspect, an embodiment of the present invention further provides an image contrast enhancement apparatus, including:
the color cast point determining module is used for determining color cast point information in the image to be enhanced according to pixel point information of the image to be enhanced;
the color cast correction module is used for performing color cast correction on the image to be enhanced according to the color cast point information;
and the image enhancement module is used for carrying out contrast enhancement on the image to be enhanced after the color cast correction is carried out so as to obtain an enhanced image.
In a third aspect, an embodiment of the present invention further provides an electronic device, including:
one or more processors;
a storage device for storing one or more programs,
when executed by the one or more processors, cause the one or more processors to implement a method of image contrast enhancement as in any embodiment of the present invention.
In a fourth aspect, the present invention further provides a computer-readable storage medium, on which a computer program is stored, where the computer program is executed by a processor to implement the image contrast enhancement method according to any embodiment of the present invention.
The embodiment of the invention is based on the determination of the color cast point information in the image to be enhanced, performs color cast correction on the color cast point in the image to be enhanced, and performs image contrast enhancement on the basis of the color cast correction so as to solve the problem of color distortion of the color image when performing contrast enhancement, thereby realizing the purposes of enhancing the contrast of the image to be enhanced, simultaneously maintaining the color of the image, and improving the quality of the image after the contrast enhancement and the scene adaptability of the image contrast enhancement.
Drawings
FIG. 1 is a flow chart of a method for enhancing image contrast according to a first embodiment of the present invention;
FIG. 2 is a flowchart of an image contrast enhancement method according to a second embodiment of the present invention;
FIG. 3 is a schematic structural diagram of an image contrast enhancement apparatus according to a third embodiment of the present invention;
fig. 4 is a schematic structural diagram of an electronic device in a fourth embodiment of the present invention.
Detailed Description
The present invention will be described in further detail with reference to the accompanying drawings and examples. It is to be understood that the specific embodiments described herein are merely illustrative of the invention and are not limiting of the invention. It should be further noted that, for the convenience of description, only some of the structures related to the present invention are shown in the drawings, not all of the structures.
Example one
Fig. 1 is a flowchart of an image contrast enhancement method in a first embodiment of the present invention, and this embodiment is applicable to a case where contrast enhancement is performed on a color image under a condition that colors of the color image are maintained. The method may be performed by an image contrast enhancement apparatus, which may be implemented in software and/or hardware, and may be configured in an electronic device, for example, the electronic device may be a device with communication and computing capabilities, such as a background server. As shown in fig. 1, the method specifically includes:
step 101, determining color cast point information in the image to be enhanced according to pixel point information of the image to be enhanced.
Due to the influences of factors such as poor lighting conditions of shooting surrounding environment, limitation of image acquisition equipment and the like, the problems of low overall gray value and unsatisfactory contrast of an actually acquired image generally exist, and the visual effect of the image is influenced. And the contrast ratio can describe the contrast between different brightness layers in the bright and dark areas of the image, wherein the larger the difference range is, the higher the contrast ratio is, and the smaller the difference range is, the lower the contrast ratio is. The contrast of the image can be improved by utilizing the contrast enhancement technology, the quality of the image is improved, the target object in the originally dark image can be obviously distinguished, the details are clear and distinguishable, the region of interest can be easily identified, the observation and judgment of human eyes are facilitated, and the required information is acquired.
The image needing contrast enhancement is the image to be enhanced, when the image to be enhanced is a color image and the acquisition scene is a low-illumination scene, a part of regions possibly exist in the image due to insufficient illumination or in shadow regions, some pixel points in the regions often lose information along with difficulty in information acquisition, for example, the value of one or two channels of the pixel points losing the information is 0. After contrast enhancement is performed on the color images, the color distortion problem of the images can occur, and particularly, the visual effect of the images is influenced at the pixel points with lost information. And regarding the point losing information in the image to be enhanced as the color bias point.
Specifically, the pixel information of the image to be enhanced can represent the loss condition of the channel value of the pixel, whether the pixel is a color cast point can be determined according to the loss condition of the channel value of the pixel, if any pixel has the channel value loss condition, the pixel is the color cast point, and the information of the pixel, such as position information or channel value information, is determined.
In one possible embodiment, the pixel information includes three channel component values of the pixel;
accordingly, step 101 includes:
determining the minimum value of three-channel component values of a target pixel point in an image to be enhanced;
and if the minimum value is smaller than the preset threshold value, determining that the target pixel point is a color cast point, and determining the position information of the color cast point.
And determining the condition of channel value loss of the pixel point according to the size of the component value of the three channels of the pixel point in the pixel point information. Specifically, the minimum value of the component values of the three channels of each pixel point in the image to be enhanced is determined, and the minimum value can reflect the color condition of the pixel point, so that whether the corresponding pixel point is a color cast point can be determined according to the comparison result of the minimum value and a preset threshold value. The size of the preset threshold may be determined according to the actual scene of the image, and is not limited herein. For example, as can be seen from the foregoing description, if the value of one or both of the channels of the pixel point with lost information is 0, the preset threshold is set to 1, and when the minimum value of the component values of the three channels in the image to be enhanced is smaller than 1, the value of at least one channel of the pixel point is 0, the pixel point is determined to be a color bias point, and the coordinate information of the pixel point is marked.
In a possible embodiment, if the minimum value is smaller than the preset threshold, determining that the target pixel point is a color cast point includes:
and if the minimum value is smaller than the preset threshold value and at least one of the three-channel component values of the target pixel point is not equal to 0, determining that the target pixel point is a color cast point.
The image to be enhanced has pixel points with three channel values of 0, but the pixel points belong to normal points in the image to be enhanced. For example, a black region in the acquisition scene corresponds to a pixel point region with three channel values all equal to 0 in the image to be enhanced. Therefore, the pixel points with three channel values of 0 in the image to be enhanced cannot be regarded as color bias points. And when the judgment is carried out simply according to the comparison result of the minimum value and the preset threshold value, the pixel point with three channels of 0 is certainly mistaken for the color cast point, so that whether the three channel values of the pixel point are all equal to 0 or not is determined, and if the three channel values are all equal to 0, the pixel point is not the color cast point.
By comparing the component values of the three channels with the preset threshold value and combining the overall judgment of the component values of the three channels, the accuracy of determining the color cast points is improved, and the influence on the color cast correction of the image caused by the fact that the normal pixel points in the image to be enhanced are judged to be the color cast points by mistake is avoided.
Illustratively, each pixel point of the image to be enhanced is subjected to line-by-line traversal operation, the minimum value of R, G, B three-channel color component gray scale of each pixel point is calculated, pixel points with three channels smaller than a preset threshold value and with three channel values not equal to 0 are detected, and coordinates of the pixel points which possibly cause color cast are marked for guiding subsequent color cast correction processing.
And 102, performing color cast correction on the image to be enhanced according to the color cast point information.
And marking and positioning pixel points which can cause color cast in the image to be enhanced according to the color cast point information, adjusting according to the pixel information of the color cast points, and estimating the information lost by a certain channel of the color cast points.
In one possible embodiment, the color cast point information includes color cast point coordinates;
accordingly, step 102 includes:
determining a reference neighborhood of the target color bias point according to the coordinates of the target color bias point;
and correcting the target color bias point according to the pixel point information of the reference neighborhood to obtain the corrected pixel point information of the target color bias point.
Specifically, the lost information of the target color bias point is estimated and adjusted according to the pixel information of the pixel points around the target color bias point. Illustratively, pixel points within a certain size around a target bias color point are used as a reference neighborhood of the target bias color point, and the gray value of each channel of the current target bias color point is adjusted according to the gray value of the pixel in the reference neighborhood, so that the information lost by a certain channel is estimated. For example, the size of the reference neighborhood may be determined according to the actual color cast condition of the image, for example, and without limitation, the size of the range of the color cast region in the image capturing scene may be adjusted.
In a feasible embodiment, the correcting the target color bias point according to the pixel point information of the reference neighborhood to obtain the corrected pixel point information of the target color bias point includes:
obtaining a correction component value of the target color cast point target channel by adopting a linear smoothing algorithm to the component value of each pixel point target channel in the reference neighborhood; the target channel is any one of three channels.
Since the number of channels whose information is lost is not determined for the target color cast point, a correction process needs to be performed for each channel of the target color cast point. Specifically, a linear smoothing algorithm is adopted for component values of R channels of all pixel points in a reference neighborhood to obtain correction component values of the R channels of the target color bias points, and similarly, the G channels and the B channels are corrected in the same manner. For example, the linear smoothing algorithm may use average filtering as an example, and calculate by the following formula:
Figure BDA0002700047800000071
wherein, IC(x ', y') is the pixel point information in the image to be enhanced, DC(x ', y') is the corrected color image, L is the set of pixel points of the reference neighborhood of the target bias color point, and T is the total number of pixels in the reference neighborhood (9 in the case of 3 x 3 neighborhoods). And sequentially determining the correction value of three channels of the target color cast point through the formula.
And 103, performing contrast enhancement on the image to be enhanced after the color cast correction is performed to obtain an enhanced image.
Based on the image to be enhanced after color cast correction, contrast enhancement is carried out by adopting a contrast enhancement algorithm, so that the enhanced image not only meets the requirement of contrast enhancement, but also can keep the color of the image. Illustratively, the contrast enhancement algorithm includes histogram equalization and its modification algorithm, linear stretching transformation, exponential transformation, and the like.
The embodiment of the invention determines the information of the color cast points in the image to be enhanced based on the dark channel prior thought, thereby performing color cast correction on the color cast points in the image to be enhanced, and performing image contrast enhancement on the basis of the color cast correction so as to solve the problem of color distortion caused by contrast enhancement of a color image, thereby realizing the purposes of maintaining the image color while enhancing the image contrast to be enhanced, and improving the quality of the image after the contrast enhancement and the scene adaptability of the image contrast enhancement.
Example two
Fig. 2 is a flowchart of an image contrast enhancement method in the second embodiment of the present invention, and the second embodiment is further optimized based on the first embodiment. As shown in fig. 2, the method includes:
step 201, determining color cast point information in the image to be enhanced according to the pixel point information of the image to be enhanced.
And 202, performing color cast correction on the image to be enhanced according to the color cast point information.
And step 203, converting the image to be enhanced after the color cast correction into a gray image.
If contrast enhancement processing is directly performed on the RGB three channels of the color image, since there is a correlation between the RGB three channels of the image (i.e., the RGB values jointly determine the color of a certain point of the image), if contrast enhancement is performed on the three channels, there will be a phenomenon that the enhancement degree of the three channels is not well controlled, resulting in color distortion of the color image after enhancement.
Therefore, the color image after color cast correction is converted into a gray image, then the contrast of the gray image is enhanced, and finally the gray image is restored into the color image, so that the problem that the enhancement degree of three channels of the color image is not easy to control is solved, and the color distortion phenomenon of the image is avoided.
The color image may be converted into a gray image by using an average value of three channels of RGB, or by using a color space conversion method. Illustratively, the grayscale image conversion is performed using the following formula:
Gin(x′,y′)=0.299×IR(x′,y′)+0.587×IG(x′,y′)+0.114×IB(x′,y′);
wherein, IR(x′,y′)、IG(x′,y′)、IB(x ', y') are R, G, B three-channel color components, G, respectively, of the image to be enhanced after the color cast correctionin(x ', y') is the converted grayscale image.
And step 204, carrying out contrast enhancement on the gray level image.
And stretching the brightness levels in the gray level image by using a contrast enhancement algorithm, widening the gray level distribution range of the input gray level image and improving the overall contrast of the image. Common contrast enhancement methods are histogram equalization and its modified algorithms, linear stretch transforms, exponential transforms, etc.
In one possible embodiment, contrast enhancement is performed on a grayscale image, comprising:
determining a contrast interval of the gray level image as an interval to be stretched;
determining an enhancement parameter according to the interval to be stretched and the target stretching interval;
and carrying out contrast enhancement on the gray-scale image according to the image information and the enhancement parameters of the gray-scale image.
The interval to be stretched refers to a contrast range determined according to the brightness level in the gray level image; the target stretching interval refers to a contrast range in the final enhanced image; the enhancement parameter is a parameter that needs to stretch the contrast in the grayscale image, such as a stretch ratio.
Illustratively, the input grayscale image is contrast enhanced using a linear stretching function. Contrast enhancement is performed using the following formula:
Figure BDA0002700047800000091
wherein, [ Ti ]L,TiR]In the zone to be stretched, Gout(x ', y') is an output gray image,Gin(x ', y') is an input gray image, a is a stretching multiple, b is a brightness gain, and a and b can be specifically calculated by the following formula:
Figure BDA0002700047800000092
Figure BDA0002700047800000093
wherein [ ToR,ToL]As a target stretching interval, if the input gray image is 8 bits, the value range is [0, 255 ]]。
Step 205, converting the grayscale image after contrast enhancement into a color image to obtain an enhanced image.
And converting the gray level image subjected to the contrast enhancement processing into a color image, and recovering the color information of the image.
Illustratively, the image conversion is performed using the following formula:
Figure BDA0002700047800000094
wherein, OutCThe (x ', y') restored color image, i.e. the enhanced image, C e { R, G, B), S is a saturation parameter of 0.8, and can be set according to the actual scene, which is not limited herein. I isC(x ', y') is the image to be enhanced, Gin(x ', y') is the input grayscale image with contrast enhancement performed in step 204, Gout(x ', y') is the output grayscale image for contrast enhancement. Finally, the contrast-enhanced color image Out is outputC(x′,y′)。
The embodiment of the invention enhances the contrast of the image on the basis of color cast correction, and when the contrast is enhanced, the color image subjected to the color cast correction is converted into the gray image, the contrast of the gray image is enhanced, and finally the gray image subjected to the contrast enhancement is converted into the color image, so that the contrast enhancement of the color image to be enhanced is completed. The color image contrast enhancement method based on the color image contrast enhancement algorithm has the advantages that the color distortion problem after the contrast of certain scene images is enhanced is avoided while the color image contrast under different scenes is enhanced, the overall visual effect of the images is improved, and the scene adaptability of the color image contrast enhancement algorithm is improved.
EXAMPLE III
Fig. 3 is a schematic structural diagram of an image contrast enhancement apparatus in a third embodiment of the present invention, and this embodiment is applicable to a case where contrast enhancement is performed on a color image under a condition that the color of the color image is maintained. As shown in fig. 3, the apparatus includes:
the color cast point determining module 310 is configured to determine color cast point information in the image to be enhanced according to pixel point information of the image to be enhanced;
the color cast correction module 320 is configured to perform color cast correction on the image to be enhanced according to the color cast point information;
the image enhancement module 330 is configured to perform contrast enhancement on the image to be enhanced after the color cast correction is performed, so as to obtain an enhanced image.
The embodiment of the invention is based on the determination of the color cast point information in the image to be enhanced, performs color cast correction on the color cast point in the image to be enhanced, and performs image contrast enhancement on the basis of the color cast correction so as to solve the problem of color distortion of the color image when performing contrast enhancement, thereby realizing the purposes of enhancing the contrast of the image to be enhanced, simultaneously maintaining the color of the image, and improving the quality of the image after the contrast enhancement and the scene adaptability of the image contrast enhancement.
Optionally, the pixel information includes component values of three channels of the pixel;
accordingly, the color cast point determining module 310 includes:
the component value determining unit is used for determining the minimum value of the three-channel component values of the target pixel points in the image to be enhanced;
and the component value judging unit is used for determining the target pixel point as a color cast point and determining the position information of the color cast point if the minimum value is smaller than a preset threshold value.
The component value determining unit may be specifically configured to:
and if the minimum value is smaller than a preset threshold value and at least one of the three-channel component values of the target pixel point is not equal to 0, determining that the target pixel point is a color cast point.
Optionally, the color cast point information includes color cast point coordinates;
accordingly, the color cast correction module 320 includes:
the reference neighborhood determining unit is used for determining a reference neighborhood of the target color bias point according to the coordinates of the target color bias point;
and the color bias point correction unit is used for correcting the target color bias point according to the pixel point information of the reference neighborhood to obtain the corrected pixel point information of the target color bias point.
Optionally, the color cast point correcting unit is specifically configured to:
obtaining a correction component value of the target color cast point target channel by adopting a linear smoothing algorithm to the component value of each pixel point target channel in the reference neighborhood; the target channel is any one of three channels.
Optionally, the image enhancement module 330 includes:
the first image conversion unit is used for converting the image to be enhanced after color cast correction into a gray image;
a contrast enhancement unit for performing contrast enhancement on the grayscale image;
and the second image conversion unit is used for converting the gray-scale image subjected to contrast enhancement into a color image so as to obtain an enhanced image.
Optionally, the contrast enhancement unit is specifically configured to:
determining a contrast interval of the gray level image as an interval to be stretched;
determining enhancement parameters according to the to-be-stretched interval and the target stretching interval;
and carrying out contrast enhancement on the gray-scale image according to the image information of the gray-scale image and the enhancement parameter.
The image contrast enhancement device provided by the embodiment of the invention can execute the image contrast enhancement method provided by any embodiment of the invention, and has corresponding functional modules and beneficial effects for executing the image contrast enhancement method.
Example four
Fig. 4 is a schematic structural diagram of an electronic device according to a fourth embodiment of the present invention. FIG. 4 illustrates a block diagram of an exemplary electronic device 12 suitable for use in implementing embodiments of the present invention. The electronic device 12 shown in fig. 4 is only an example and should not bring any limitation to the function and the scope of use of the embodiment of the present invention.
As shown in FIG. 4, electronic device 12 is embodied in the form of a general purpose computing device. The components of electronic device 12 may include, but are not limited to: one or more processors or processing units 16, a system memory device 28, and a bus 18 that couples various system components including the system memory device 28 and the processing unit 16.
Bus 18 represents one or more of any of several types of bus structures, including a memory device bus or memory device controller, a peripheral bus, an accelerated graphics port, and a processor or local bus using any of a variety of bus architectures. By way of example, such architectures include, but are not limited to, Industry Standard Architecture (ISA) bus, micro-channel architecture (MAC) bus, enhanced ISA bus, Video Electronics Standards Association (VESA) local bus, and Peripheral Component Interconnect (PCI) bus.
Electronic device 12 typically includes a variety of computer system readable media. Such media may be any available media that is accessible by electronic device 12 and includes both volatile and nonvolatile media, removable and non-removable media.
The system storage 28 may include computer system readable media in the form of volatile storage, such as Random Access Memory (RAM)30 and/or cache storage 32. The electronic device 12 may further include other removable/non-removable, volatile/nonvolatile computer system storage media. By way of example only, storage system 34 may be used to read from and write to non-removable, nonvolatile magnetic media (not shown in FIG. 4, and commonly referred to as a "hard drive"). Although not shown in FIG. 4, a magnetic disk drive for reading from and writing to a removable, nonvolatile magnetic disk (e.g., a "floppy disk") and an optical disk drive for reading from or writing to a removable, nonvolatile optical disk (e.g., a CD-ROM, DVD-ROM, or other optical media) may be provided. In these cases, each drive may be connected to bus 18 by one or more data media interfaces. Storage 28 may include at least one program product having a set (e.g., at least one) of program modules that are configured to carry out the functions of embodiments of the invention.
A program/utility 40 having a set (at least one) of program modules 42 may be stored, for example, in storage 28, such program modules 42 including, but not limited to, an operating system, one or more application programs, other program modules, and program data, each of which examples or some combination thereof may comprise an implementation of a network environment. Program modules 42 generally carry out the functions and/or methodologies of the described embodiments of the invention.
Electronic device 12 may also communicate with one or more external devices 14 (e.g., keyboard, pointing device, display 24, etc.), with one or more devices that enable a user to interact with device 12, and/or with any devices (e.g., network card, modem, etc.) that enable device 12 to communicate with one or more other computing devices. Such communication may be through an input/output (I/O) interface 22. Also, the electronic device 12 may communicate with one or more networks (e.g., a Local Area Network (LAN), a Wide Area Network (WAN), and/or a public network, such as the Internet) via the network adapter 20. As shown in FIG. 4, the network adapter 20 communicates with the other modules of the electronic device 12 via the bus 18. It should be appreciated that although not shown in FIG. 4, other hardware and/or software modules may be used in conjunction with electronic device 12, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems, among others.
The processing unit 16 executes various functional applications and data processing by running a program stored in the system storage device 28, for example, to implement the image contrast enhancement method provided by the embodiment of the present invention, including:
determining color cast point information in the image to be enhanced according to pixel point information of the image to be enhanced;
performing color cast correction on the image to be enhanced according to the color cast point information;
and carrying out contrast enhancement on the image to be enhanced after the color cast correction is carried out so as to obtain an enhanced image.
EXAMPLE five
The fifth embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements the image contrast enhancement method provided in the fifth embodiment of the present invention, where the computer program includes:
determining color cast point information in the image to be enhanced according to pixel point information of the image to be enhanced;
performing color cast correction on the image to be enhanced according to the color cast point information;
and carrying out contrast enhancement on the image to be enhanced after the color cast correction is carried out so as to obtain an enhanced image.
Computer storage media for embodiments of the invention may employ any combination of one or more computer-readable media. The computer readable medium may be a computer readable signal medium or a computer readable storage medium. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples (a non-exhaustive list) of the computer readable storage medium would include the following: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the context of this document, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.
A computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device.
Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
Computer program code for carrying out operations for aspects of the present invention may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, Smalltalk, C + +, or the like, as well as conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or the connection may be made to an external computer (for example, through the Internet using an Internet service provider).
It is to be noted that the foregoing is only illustrative of the preferred embodiments of the present invention and the technical principles employed. It will be understood by those skilled in the art that the present invention is not limited to the particular embodiments described herein, but is capable of various obvious changes, rearrangements and substitutions as will now become apparent to those skilled in the art without departing from the scope of the invention. Therefore, although the present invention has been described in greater detail by the above embodiments, the present invention is not limited to the above embodiments, and may include other equivalent embodiments without departing from the spirit of the present invention, and the scope of the present invention is determined by the scope of the appended claims.

Claims (10)

1. An image contrast enhancement method, comprising:
determining color cast point information in the image to be enhanced according to pixel point information of the image to be enhanced;
performing color cast correction on the image to be enhanced according to the color cast point information;
and carrying out contrast enhancement on the image to be enhanced after the color cast correction is carried out so as to obtain an enhanced image.
2. The method of claim 1, wherein said pixel information comprises three channel component values of a pixel;
correspondingly, the determining the color cast point information in the image to be enhanced according to the pixel point information of the image to be enhanced includes:
determining the minimum value of three-channel component values of a target pixel point in the image to be enhanced;
and if the minimum value is smaller than a preset threshold value, determining that the target pixel point is a color cast point, and determining the position information of the color cast point.
3. The method of claim 2, wherein determining that the target pixel point is a color cast point if the minimum value is smaller than a preset threshold comprises:
and if the minimum value is smaller than a preset threshold value and at least one of the three-channel component values of the target pixel point is not equal to 0, determining that the target pixel point is a color cast point.
4. The method of claim 1, wherein the color cast point information comprises color cast point coordinates;
correspondingly, the performing color cast correction on the image to be enhanced according to the color cast point information includes:
determining a reference neighborhood of a target color bias point according to the coordinates of the target color bias point;
and correcting the target color bias point according to the pixel point information of the reference neighborhood to obtain the corrected pixel point information of the target color bias point.
5. The method of claim 4, wherein the correcting the target color bias point according to the pixel point information of the reference neighborhood to obtain corrected pixel point information of the target color bias point comprises:
obtaining a correction component value of the target color cast point target channel by adopting a linear smoothing algorithm to the component value of each pixel point target channel in the reference neighborhood; the target channel is any one of three channels.
6. The method according to claim 1, wherein the contrast enhancement of the image to be enhanced after the color cast correction is performed to obtain an enhanced image, comprises:
converting the image to be enhanced after color cast correction into a gray image;
performing contrast enhancement on the gray-scale image;
and converting the gray level image subjected to contrast enhancement into a color image to obtain an enhanced image.
7. The method of claim 6, wherein the contrast enhancing the grayscale image comprises:
determining a contrast interval of the gray level image as an interval to be stretched;
determining enhancement parameters according to the to-be-stretched interval and the target stretching interval;
and carrying out contrast enhancement on the gray-scale image according to the image information of the gray-scale image and the enhancement parameter.
8. An image contrast enhancement device, comprising:
the color cast point determining module is used for determining color cast point information in the image to be enhanced according to pixel point information of the image to be enhanced;
the color cast correction module is used for performing color cast correction on the image to be enhanced according to the color cast point information;
and the image enhancement module is used for carrying out contrast enhancement on the image to be enhanced after the color cast correction is carried out so as to obtain an enhanced image.
9. An electronic device, comprising:
one or more processors;
a storage device for storing one or more programs,
when executed by the one or more processors, cause the one or more processors to implement the image contrast enhancement method of any of claims 1-7.
10. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the method of image contrast enhancement according to any one of claims 1 to 7.
CN202011018981.4A 2020-09-24 2020-09-24 Image contrast enhancement method, device, electronic equipment and storage medium Active CN112116542B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011018981.4A CN112116542B (en) 2020-09-24 2020-09-24 Image contrast enhancement method, device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011018981.4A CN112116542B (en) 2020-09-24 2020-09-24 Image contrast enhancement method, device, electronic equipment and storage medium

Publications (2)

Publication Number Publication Date
CN112116542A true CN112116542A (en) 2020-12-22
CN112116542B CN112116542B (en) 2024-03-08

Family

ID=73801681

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011018981.4A Active CN112116542B (en) 2020-09-24 2020-09-24 Image contrast enhancement method, device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN112116542B (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112967208A (en) * 2021-04-23 2021-06-15 北京恒安嘉新安全技术有限公司 Image processing method and device, electronic equipment and storage medium
CN112967207A (en) * 2021-04-23 2021-06-15 北京恒安嘉新安全技术有限公司 Image processing method and device, electronic equipment and storage medium
WO2022228033A1 (en) * 2021-04-27 2022-11-03 青岛海尔电冰箱有限公司 Image color cast detection and correction method, device, and refrigerator
WO2023123927A1 (en) * 2021-12-30 2023-07-06 上海闻泰信息技术有限公司 Image enhancement method and apparatus, and device and storage medium
CN112967207B (en) * 2021-04-23 2024-04-12 北京恒安嘉新安全技术有限公司 Image processing method and device, electronic equipment and storage medium

Citations (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5552825A (en) * 1994-11-08 1996-09-03 Texas Instruments Incorporated Color resolution enhancement by using color camera and methods
WO2013103184A1 (en) * 2012-01-03 2013-07-11 중앙대학교 산학협력단 Apparatus and method for improving image using color channels
EP2809013A1 (en) * 2013-05-31 2014-12-03 ST-Ericsson SA A radio receiver and a method therein
CN104299204A (en) * 2013-07-17 2015-01-21 王垒 Histogram local image contrast enhancing method and histogram local image contrast enhancing device
CN105654438A (en) * 2015-12-27 2016-06-08 西南技术物理研究所 Gray scale image fitting enhancement method based on local histogram equalization
CN106127823A (en) * 2016-06-24 2016-11-16 电子科技大学 A kind of coloured image dynamic range compression method
CN106886985A (en) * 2017-04-25 2017-06-23 哈尔滨工业大学 A kind of self adaptation enhancement method of low-illumination image for reducing colour cast
CN108416742A (en) * 2018-01-23 2018-08-17 浙江工商大学 Sand and dust degraded image Enhancement Method based on colour cast correction and information loss constraint
CN108470327A (en) * 2018-03-27 2018-08-31 成都西纬科技有限公司 Image enchancing method, device, electronic equipment and storage medium
CN108805829A (en) * 2018-05-25 2018-11-13 浙江科澜信息技术有限公司 Video data processing method, device, equipment and computer readable storage medium
CN110458803A (en) * 2019-07-04 2019-11-15 深圳市玩瞳科技有限公司 Frame image color cast and brightness detection method and device based on colored ribbon calibration
WO2019232945A1 (en) * 2018-06-08 2019-12-12 平安科技(深圳)有限公司 Image processing method and apparatus, computer device and storage medium
CN111028186A (en) * 2019-11-25 2020-04-17 泰康保险集团股份有限公司 Image enhancement method and device
CN111127359A (en) * 2019-12-19 2020-05-08 大连海事大学 Underwater image enhancement method based on selective compensation color and three-interval balance
CN111163268A (en) * 2020-01-09 2020-05-15 腾讯科技(深圳)有限公司 Image processing method and device and computer storage medium

Patent Citations (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5552825A (en) * 1994-11-08 1996-09-03 Texas Instruments Incorporated Color resolution enhancement by using color camera and methods
WO2013103184A1 (en) * 2012-01-03 2013-07-11 중앙대학교 산학협력단 Apparatus and method for improving image using color channels
EP2809013A1 (en) * 2013-05-31 2014-12-03 ST-Ericsson SA A radio receiver and a method therein
CN104299204A (en) * 2013-07-17 2015-01-21 王垒 Histogram local image contrast enhancing method and histogram local image contrast enhancing device
CN105654438A (en) * 2015-12-27 2016-06-08 西南技术物理研究所 Gray scale image fitting enhancement method based on local histogram equalization
CN106127823A (en) * 2016-06-24 2016-11-16 电子科技大学 A kind of coloured image dynamic range compression method
CN106886985A (en) * 2017-04-25 2017-06-23 哈尔滨工业大学 A kind of self adaptation enhancement method of low-illumination image for reducing colour cast
CN108416742A (en) * 2018-01-23 2018-08-17 浙江工商大学 Sand and dust degraded image Enhancement Method based on colour cast correction and information loss constraint
CN108470327A (en) * 2018-03-27 2018-08-31 成都西纬科技有限公司 Image enchancing method, device, electronic equipment and storage medium
CN108805829A (en) * 2018-05-25 2018-11-13 浙江科澜信息技术有限公司 Video data processing method, device, equipment and computer readable storage medium
WO2019232945A1 (en) * 2018-06-08 2019-12-12 平安科技(深圳)有限公司 Image processing method and apparatus, computer device and storage medium
CN110458803A (en) * 2019-07-04 2019-11-15 深圳市玩瞳科技有限公司 Frame image color cast and brightness detection method and device based on colored ribbon calibration
CN111028186A (en) * 2019-11-25 2020-04-17 泰康保险集团股份有限公司 Image enhancement method and device
CN111127359A (en) * 2019-12-19 2020-05-08 大连海事大学 Underwater image enhancement method based on selective compensation color and three-interval balance
CN111163268A (en) * 2020-01-09 2020-05-15 腾讯科技(深圳)有限公司 Image processing method and device and computer storage medium

Non-Patent Citations (8)

* Cited by examiner, † Cited by third party
Title
CHONG-YI LI 等,: "Underwater Image Enhancement by Dehazing With Minimum Information Loss and Histogram Distribution Prior", 《IEEE TRANSACTIONS ON IMAGE PROCESSING》 *
CHONG-YI LI 等,: "Underwater Image Enhancement by Dehazing With Minimum Information Loss and Histogram Distribution Prior", 《IEEE TRANSACTIONS ON IMAGE PROCESSING》, vol. 25, no. 12, 31 December 2016 (2016-12-31) *
刘鹏,: "基于图像处理的混凝土预制构件裂缝检测系统研究", 《中国优秀硕士学位论文全文数据库工程科技Ⅱ辑》 *
刘鹏,: "基于图像处理的混凝土预制构件裂缝检测系统研究", 《中国优秀硕士学位论文全文数据库工程科技Ⅱ辑》, vol. 2018, no. 2, 15 February 2018 (2018-02-15), pages 9 *
王雅婷 等,: "基于暗原色先验的单幅图像快速去雾算法", 《计算机应用》 *
王雅婷 等,: "基于暗原色先验的单幅图像快速去雾算法", 《计算机应用》, vol. 36, no. 12, 10 December 2016 (2016-12-10), pages 3407 - 3409 *
陈云,: "高动态范围图像的色调映射算法研究", 《中国优秀硕士学位论文全文数据库信息科技辑》 *
陈云,: "高动态范围图像的色调映射算法研究", 《中国优秀硕士学位论文全文数据库信息科技辑》, vol. 2016, no. 6, 15 June 2016 (2016-06-15) *

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112967208A (en) * 2021-04-23 2021-06-15 北京恒安嘉新安全技术有限公司 Image processing method and device, electronic equipment and storage medium
CN112967207A (en) * 2021-04-23 2021-06-15 北京恒安嘉新安全技术有限公司 Image processing method and device, electronic equipment and storage medium
CN112967207B (en) * 2021-04-23 2024-04-12 北京恒安嘉新安全技术有限公司 Image processing method and device, electronic equipment and storage medium
WO2022228033A1 (en) * 2021-04-27 2022-11-03 青岛海尔电冰箱有限公司 Image color cast detection and correction method, device, and refrigerator
WO2023123927A1 (en) * 2021-12-30 2023-07-06 上海闻泰信息技术有限公司 Image enhancement method and apparatus, and device and storage medium

Also Published As

Publication number Publication date
CN112116542B (en) 2024-03-08

Similar Documents

Publication Publication Date Title
CN112116542B (en) Image contrast enhancement method, device, electronic equipment and storage medium
CN109064426B (en) Method and device for suppressing glare in low-illumination image and enhancing image
CN111583223B (en) Defect detection method, defect detection device, computer equipment and computer readable storage medium
CN110189336B (en) Image generation method, system, server and storage medium
US10951843B2 (en) Adjusting confidence values for correcting pixel defects
CN108876742B (en) Image color enhancement method and device
JP5440241B2 (en) Image enhancement device, image enhancement method, and image enhancement program
WO2021218603A1 (en) Image processing method and projection system
CN110969046B (en) Face recognition method, face recognition device and computer-readable storage medium
CN115115554B (en) Image processing method and device based on enhanced image and computer equipment
CN107833189A (en) The Underwater Target Detection image enchancing method of the limited self-adapting histogram equilibrium of contrast
CN112348763A (en) Image enhancement method, device, electronic equipment and medium
CN111105371A (en) Low-contrast infrared image enhancement method
CN113222866A (en) Gray scale image enhancement method, computer readable medium and computer system
CN114298985B (en) Defect detection method, device, equipment and storage medium
KR101215666B1 (en) Method, system and computer program product for object color correction
CN114125280A (en) Camera exposure control method, device, equipment, storage medium and program product
CN112312001A (en) Image detection method, device, equipment and computer storage medium
CN107833185B (en) Image defogging method and device, storage medium and electronic equipment
CN113570507B (en) Image noise reduction method, device, equipment and storage medium
CN111833262A (en) Image noise reduction method and device and electronic equipment
KR102462265B1 (en) Directional scaling systems and methods
CN108961293B (en) Background subtraction method, device, equipment and storage medium
CN114374830B (en) Image white balance method, electronic device and computer readable storage medium
CN111476740B (en) Image processing method, device, storage medium and electronic equipment

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
GR01 Patent grant
GR01 Patent grant