CN117237248B - Exposure adjustment curve estimation method and device, electronic equipment and storage medium - Google Patents

Exposure adjustment curve estimation method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN117237248B
CN117237248B CN202311272977.4A CN202311272977A CN117237248B CN 117237248 B CN117237248 B CN 117237248B CN 202311272977 A CN202311272977 A CN 202311272977A CN 117237248 B CN117237248 B CN 117237248B
Authority
CN
China
Prior art keywords
original picture
curve
vector
picture
channel
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.)
Active
Application number
CN202311272977.4A
Other languages
Chinese (zh)
Other versions
CN117237248A (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.)
Sun Yat Sen University
Original Assignee
Sun Yat Sen University
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 Sun Yat Sen University filed Critical Sun Yat Sen University
Priority to CN202311272977.4A priority Critical patent/CN117237248B/en
Publication of CN117237248A publication Critical patent/CN117237248A/en
Application granted granted Critical
Publication of CN117237248B publication Critical patent/CN117237248B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Image Processing (AREA)

Abstract

The invention discloses an exposure adjustment curve estimation method, an exposure adjustment curve estimation device, electronic equipment and a storage medium, wherein the method comprises the following steps: acquiring an original picture to be processed; extracting the vector of the original picture to obtain a histogram vector; performing full connection processing on the histogram vector to obtain a predicted convolution kernel parameter; carrying out convolution processing on the original picture based on the prediction convolution kernel parameter to obtain a curve parameter; based on the curve parameters, acquiring an exposure adjustment curve by combining a sigmoid function; wherein the exposure adjustment curve is used for the exposure adjustment of the original picture. The exposure adjustment curve obtained by the embodiment of the invention can assist the picture to carry out accurate exposure adjustment, and can be widely applied to the technical field of picture processing.

Description

Exposure adjustment curve estimation method and device, electronic equipment and storage medium
Technical Field
The invention relates to the technical field of picture processing, in particular to an exposure adjustment curve estimation method, an exposure adjustment curve estimation device, electronic equipment and a storage medium.
Background
Dark image enhancement methods based on conventional image processing techniques dark image enhancement common methods based on conventional image processing techniques include histogram equalization based methods and retinex model based methods. The core idea of the histogram equalization-based method is to map pixel values such that the mapped pixel values follow a uniform distribution. Based on this idea, wang, chen et al in 1999 proposed a method of sub-histogram equalization. Subsequently, various methods of sub-histogram equalization are proposed. The histogram equalization-based method only considers the distribution variation, and the generated enhancement result often does not have the visual effect of the normal picture. The retinex model-based method utilizes retinex a priori to decompose the image into a reflected component and an illumination component, enhance its illumination component and finally combine the enhanced illumination component and the reflected component to produce an enhanced result. Such methods rely on retinex a priori manual designs, lack generalization, and do not produce good visual results.
Dark image enhancement methods based on deep learning techniques can be categorized into supervised and unsupervised methods. A deep learning model is trained on pairs of picture datasets based on a supervised approach to achieve predictions from dark to light images. Lore et al in 2017 proposed a first dark map enhancement method based on a deep learning technique using a neural network to fit the map from dark map to bright map. Subsequently, a series of supervised dark image enhancement methods based on deep learning are proposed. However, training of these methods not only relies on paired image datasets that are difficult to acquire, but also suffer from poor generalization, and it is difficult to produce normal enhancement results on datasets that differ from the brightness distribution of the training set. To circumvent the reliance on paired image datasets, some unsupervised approaches have been proposed. Jiang et al in 2021 proposed a darkness image enhancement method based on generating an countermeasure model. In 2022, li et al proposed a method for implementing dark map enhancement with a deep learning-based reference-free image curve estimation network. In the same year, ma et al propose to recursively perform dark map enhancement using a self-correcting illumination learning framework. Although these methods avoid reliance on the image dataset, they still fail to address multiple brightness inputs, yielding enhanced results that are prone to overexposure or underexposure.
Disclosure of Invention
In view of the above, the embodiments of the present invention provide a method, an apparatus, an electronic device, and a storage medium for estimating an exposure adjustment curve, which can assist a picture in performing accurate exposure adjustment.
In one aspect, an embodiment of the present invention provides an exposure adjustment curve estimation method, including:
acquiring an original picture to be processed;
extracting the vector of the original picture to obtain a histogram vector;
performing full connection processing on the histogram vector to obtain a predicted convolution kernel parameter;
carrying out convolution processing on the original picture based on the prediction convolution kernel parameter to obtain a curve parameter;
Based on curve parameters, acquiring an exposure adjustment curve by combining a sigmoid function; the exposure adjustment curve is used for the exposure adjustment of the original picture.
Optionally, vector extraction is performed on the original picture to obtain a histogram vector, including:
and extracting the vector of the original picture based on the picture specification and the channel parameter of the original picture to obtain a histogram vector.
Optionally, the picture specification includes a height and a width of the picture, and the channel parameter includes a channel pixel value and a channel component; extracting the vector of the original picture based on the specification and the channel parameter of the original picture to obtain a histogram vector, including:
based on the specification and channel parameters of the original picture, combining the smoothing factor and the column vector boundary value of the original picture, and extracting the vector of the original picture through a sigmoid function to obtain a histogram vector; wherein the column vector boundary values include left and right boundary values for each value in the column vector; the expression of the histogram vector is:
in the method, in the process of the invention, A value representing the ith dimension of the histogram vector for the c-channel, which includes three color channels r, g, b labeling the RGB picture; h, W respectively represent the height and width of the original picture; x c denotes the channel pixel value of the c-channel; x c represents the channel component of the c-channel; s (·) represents a sigmoid function; sigma represents a smoothing factor; l i,ri represents the left and right boundary values of the i-th value in the column vector of the original picture, respectively.
Optionally, performing full-connection processing on the histogram vector to obtain a predicted convolution kernel parameter, including:
inputting the histogram vector into the stacked full-connection layers for full-connection processing to obtain a prediction convolution kernel parameter;
wherein the fully connected layer has leakyReLU functions as the activation functions.
Optionally, performing convolution processing on the original picture based on the predicted convolution kernel parameter to obtain a curve parameter, including:
Inputting an original picture into a plurality of convolution layers for convolution treatment to obtain curve parameters;
Wherein the multi-layer convolution layers comprise a plurality of first convolution layers arranged based on the prediction convolution kernel parameters and a plurality of second convolution layers arranged conventionally; the curve parameters are constrained by the entropy of the histogram vector as a loss function.
Optionally, inputting the original picture into a plurality of convolution layers for convolution processing to obtain curve parameters, including:
performing feature extraction and feature processing on the original picture through a plurality of second convolution layers, performing self-adaptive feature processing through a plurality of first convolution layers, and obtaining curve parameters through an output layer; wherein the output layer is a second convolution layer.
Optionally, based on the curve parameters, obtaining the exposure adjustment curve in combination with the sigmoid function includes:
An S curve of the mapping between the hidden space and the pixel space is constructed through a sigmoid function, and then an exposure adjustment curve is obtained by combining curve parameters; wherein, the expression of the exposure adjustment curve is:
Wherein a and b represent normalization coefficients; x represents a pixel value; s represents a super parameter; alpha represents a curve parameter; e represents a natural constant.
In another aspect, an embodiment of the present invention provides an exposure adjustment curve estimation apparatus, including:
the first module is used for acquiring an original picture to be processed;
the second module is used for extracting the vector of the original picture to obtain a histogram vector;
The third module is used for carrying out full connection processing on the histogram vector to obtain a predicted convolution kernel parameter;
a fourth module, configured to perform convolution processing on the original picture based on the predicted convolution kernel parameter, to obtain a curve parameter;
A fifth module, configured to obtain an exposure adjustment curve based on the curve parameter and in combination with a sigmoid function; the exposure adjustment curve is used for the exposure adjustment of the original picture.
In another aspect, an embodiment of the present invention provides an electronic device, including a processor and a memory;
The memory is used for storing programs;
the processor executes a program to implement the method as before.
In another aspect, embodiments of the present invention provide a computer-readable storage medium storing a program for execution by a processor to perform a method as previously described.
Embodiments of the present invention also disclose a computer program product or computer program comprising computer instructions stored in a computer readable storage medium. The computer instructions may be read from a computer-readable storage medium by a processor of a computer device, and executed by the processor, to cause the computer device to perform the foregoing method.
Firstly, acquiring an original picture to be processed; extracting the vector of the original picture to obtain a histogram vector; performing full connection processing on the histogram vector to obtain a predicted convolution kernel parameter; carrying out convolution processing on the original picture based on the prediction convolution kernel parameter to obtain a curve parameter; based on curve parameters, acquiring an exposure adjustment curve by combining a sigmoid function; the exposure adjustment curve is used for the exposure adjustment of the original picture. The exposure adjustment curve obtained by the embodiment of the invention can assist the picture to carry out accurate exposure adjustment.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for the description of the embodiments will be briefly described below, and it is apparent that the drawings in the following description are only some embodiments of the present invention, and other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a schematic flow chart of an exposure adjustment curve estimation method according to an embodiment of the present invention;
FIG. 2 is a schematic diagram of an overall architecture of an exposure adjustment curve estimation according to an embodiment of the present invention;
FIG. 3 is a schematic diagram of an exposure adjustment curve according to an embodiment of the present invention;
Fig. 4 is a schematic structural diagram of an exposure adjustment curve estimation device according to an embodiment of the present invention;
fig. 5 is a schematic diagram of a frame of an electronic device according to an embodiment of the present invention.
Detailed Description
The present invention will be described in further detail with reference to the drawings and examples, in order to make the objects, technical solutions and advantages of the present invention more apparent. It should be understood that the specific embodiments described herein are for purposes of illustration only and are not intended to limit the scope of the invention.
In one aspect, as shown in fig. 1, an embodiment of the present invention provides an exposure adjustment curve estimation method, including:
s100, acquiring an original picture to be processed;
s200, extracting vectors from the original pictures to obtain histogram vectors;
It should be noted that, in some embodiments, step S200 may include: and extracting the vector of the original picture based on the picture specification and the channel parameter of the original picture to obtain a histogram vector.
In some embodiments, the picture specification includes a height and a width of the picture, and the channel parameter includes a channel pixel value and a channel component; vector extraction of the original picture is performed based on the picture specification and the channel parameter of the original picture, and a histogram vector is obtained, which may include: based on the specification and channel parameters of the original picture, combining the smoothing factor and the column vector boundary value of the original picture, and extracting the vector of the original picture through a sigmoid function to obtain a histogram vector; wherein the column vector boundary values include left and right boundary values for each value in the column vector; the expression of the histogram vector is:
in the method, in the process of the invention, A value representing the ith dimension of the histogram vector for the c-channel, which includes three color channels r, g, b labeling the RGB picture; h, W respectively represent the height and width of the original picture; x c denotes the channel pixel value of the c-channel; x c represents the channel component of the c-channel; s (·) represents a sigmoid function; sigma represents a smoothing factor; l i,ri represents the left and right boundary values of the i-th value in the column vector of the original picture, respectively.
In some embodiments, the smoothed histogram vector of the picture to be enhanced may be extracted by the following formula:
Wherein, The values of the ith dimension of the histogram vector representing the c-channel, H, W represent the height and width of the picture, respectively, X c represents the pixel value of the c-channel, X c represents the component of the c-channel of the input picture, S (·) represents the sigmoid function, σ represents the smoothing factor (artificially set hyper-parameter), l i=i/B,ri = (i+1)/B represents the left and right boundary values of the ith bin in the histogram of the total number B bins, respectively, r, g, B labeling the three color channels of the RGB picture, respectively. Each histogram may be generally represented by a column vector, where each value in the column vector is a bin, for example, 50 elements of the column vector, and 50 bins are represented. For color images, typically RGB images, 3-channels are used, each channel typically being 255 gray levels, i.e. 8 bins for each channel, then one RGB image corresponds to 8x8x8 = 512 bins.
S300, performing full connection processing on the histogram vector to obtain a predicted convolution kernel parameter;
it should be noted that, in some embodiments, step S300 may include: inputting the histogram vector into the stacked full-connection layers for full-connection processing to obtain a prediction convolution kernel parameter; wherein the fully connected layer has leakyReLU functions as the activation functions.
In some embodiments, as shown in fig. 2, the extracted histogram vector is fed into 4 fully connected layers (using leakyReLU functions as activation functions of the fully connected layers) in a stack, and the output of the last fully connected layer is divided into 3 parts, which are respectively used as parameters of 3 convolution layers in the backbone network. By adaptively predicting the convolutional layer parameters, the network can generate an adaptive convolutional layer for input pictures with different brightness distributions, so that correct enhancement results can be generated for various brightness inputs, and the generation of overexposure and underexposure enhancement results is avoided.
S400, carrying out convolution processing on the original picture based on the prediction convolution kernel parameter to obtain a curve parameter;
It should be noted that, in some embodiments, step S400 may include: inputting an original picture into a plurality of convolution layers for convolution treatment to obtain curve parameters; wherein the multi-layer convolution layers comprise a plurality of first convolution layers arranged based on the prediction convolution kernel parameters and a plurality of second convolution layers arranged conventionally; the curve parameters are constrained by the entropy of the histogram vector as a loss function.
In some embodiments, the step of inputting the original picture into the multi-layer convolution layer to perform convolution processing to obtain curve parameters includes: performing feature extraction and feature processing on the original picture through a plurality of second convolution layers, performing self-adaptive feature processing through a plurality of first convolution layers, and obtaining curve parameters through an output layer; wherein the output layer is a second convolution layer.
In some embodiments, as shown in fig. 2, an input picture is subjected to general feature extraction and feature processing by a fixed common convolution layer, then subjected to adaptive feature processing by a predicted convolution layer, and then subjected to an output layer to output a pixel-by-pixel channel-by-channel curve parameter (i.e. a graphic parameter map) for adjusting pixel values of the picture in an exposure adjustment curve, so as to generate a final enhancement result.
S500, based on curve parameters, acquiring an exposure adjustment curve by combining a sigmoid function; the exposure adjustment curve is used for the exposure adjustment of the original picture.
It should be noted that, in some embodiments, step S500 may include: an S curve of the mapping between the hidden space and the pixel space is constructed through a sigmoid function, and then an exposure adjustment curve is obtained by combining curve parameters; wherein, the expression of the exposure adjustment curve is:
Wherein a and b represent normalization coefficients; x represents a pixel value; s represents a super parameter; alpha represents a curve parameter; e represents a natural constant.
In some embodiments, based on the observed pixel distribution on the dark map, embodiments of the present invention propose an algorithm that uses an inverse S-curve to map pixel values to hidden space, define increments in hidden space, and then inverse map the translated hidden variables back to pixel space with the inverse function of the inverse S-curve, as shown in FIG. 3. First, a normalized sigmoid function is used as the S-curve in the upper graph, as follows:
Wherein the method comprises the steps of For the normalized coefficient, S is a manually adjustable hyper-parameter for controlling the shape of the S-curve, x is the pixel value, and z is the value of the pixel value corresponding to the value in the hidden space. Substituting f function into the following equation:
y=f(f-1(x)+α)
the final exposure adjustment curve formulation obtained by expansion is as follows:
wherein, alpha is a predicted value of the network, one alpha is predicted for each channel of each pixel, x is an input pixel value of the picture to be enhanced, and y is a corresponding pixel value of the enhancement result.
The following description of the embodiments of the present invention is provided for the purpose of illustrating the principles of the embodiments of the present invention in detail, and is not to be construed as limiting the invention.
Firstly, it should be noted that the invention innovatively provides a Zero-EACE non-reference exposure adjustment curve estimation method, which uses a data set containing multiple exposure degree pictures as a training set to train an exposure adjustment curve estimation network, thereby realizing the enhancement of low-illumination pictures and the correction of overexposure pictures. In experiments, the existing reference-curve-free estimation method lacks the whole brightness perception capability, so that overexposure is easy to generate and the method cannot adapt to the input of various brightnesses. And, its curve formula lacks adjustability and the lack of supervision of contrast in the loss function results in a lower contrast of the enhancement result. Therefore, the invention provides a convolution module guided by a histogram and a histogram equalization loss, and improves the original curve formula to effectively improve the adaptability of the model to multi-brightness input and enhance the contrast of the result.
In some embodiments, the flow of the method of the invention is shown in fig. 2, and mainly comprises a curve estimation network guided by a histogram and an exposure adjustment curve, and the auxiliary training is performed by using the histogram equalization loss. First, a histogram vector of a picture is extracted by one formula, and then a parameter of a convolution kernel is predicted from the extracted histogram vector using stacked full-connected layers. And generating a parameter map by convolving the picture. The formula of the exposure adjustment curve takes the picture and the parameter diagram as input, and the final enhancement result is calculated. Finally, a series of unsupervised-based loss functions are used to constrain the network predicted parameter map and the final enhancement results. Details of the parts of Zero-EACE are described in the following sections:
1. exposure adjustment curve:
Based on the pixel distribution observed on the dark graph, the embodiment of the invention proposes an algorithm that uses an inverse S-curve to map the pixel values to the hidden space, define the increments in the hidden space, and then inversely map the translated hidden variables back to the pixel space with the inverse function of the inverse S-curve, as shown in FIG. 3.
First, a normalized sigmoid function is used as the S-curve in the upper graph, as follows:
Wherein the method comprises the steps of For the normalized coefficient, S is a manually adjustable hyper-parameter for controlling the shape of the S-curve, x is the pixel value, and z is the value of the pixel value corresponding to the value in the hidden space. Substituting f function into the following equation:
y=f(f-1(x)+α)
the final exposure adjustment curve formulation obtained by expansion is as follows:
wherein, alpha is a predicted value of the network, one alpha is predicted for each channel of each pixel, x is an input pixel value of the picture to be enhanced, and y is a corresponding pixel value of the enhancement result.
2. Histogram guided curve estimation network:
firstly, extracting a smooth histogram vector of a picture to be enhanced by the following formula:
Wherein, The values of the ith dimension of the histogram vector representing the c-channel, H, W represent the height and width of the picture, respectively, X c represents the pixel value of the c-channel, X c represents the component of the c-channel of the input picture, S (·) represents the sigmoid function, σ represents the smoothing factor (artificially set hyper-parameter), l i=i/B,ri = (i+1)/B represents the left and right boundary values of the ith bin in the histogram of the total number B bins, respectively, r, g, B labeling the three color channels of the RGB picture, respectively. Each histogram may be generally represented by a column vector, where each value in the column vector is a bin, for example, 50 elements of the column vector, and 50 bins are represented. For color images, typically RGB images, 3-channels are used, each channel typically being 255 gray levels, i.e. 8 bins for each channel, then one RGB image corresponds to 8x8x8 = 512 bins.
The extracted histogram vector is then fed into the stacked 4 fully connected layers (leakyReLU functions are activation functions of the fully connected layers), and the output of the last fully connected layer is divided into 3 parts, which are respectively used as parameters of the 3 convolution layers in the backbone network, as shown in fig. 2.
By adaptively predicting the convolutional layer parameters, the network can generate an adaptive convolutional layer for input pictures with different brightness distributions, so that correct enhancement results can be generated for various brightness inputs, and the generation of overexposure and underexposure enhancement results is avoided.
The input picture is subjected to general feature extraction and feature processing through a fixed common convolution layer, then subjected to self-adaptive feature processing through a predicted convolution layer, and then subjected to an output layer to output a pixel-by-pixel channel-by-channel curve parameter for adjusting the pixel value of the picture in an exposure adjustment curve to generate a final enhancement result.
3. Histogram equalization loss:
Firstly, extracting a smooth histogram vector of the enhancement result by using a formula of a small section, and then calculating entropy of the smooth histogram vector as loss by using the following formula to monitor the enhancement result so that the contrast of the enhancement result is not collapsed:
Wherein L he is the obtained histogram equalization loss, p c is the histogram vector of the c channel extracted by the formula of the previous bar, p is the value of one dimension, and the entropy value of p of each bin of each color channel is calculated and then summed.
In summary, the invention constructs a non-reference exposure adjustment curve estimation method Zero-EACE, and the dark image is enhanced by using an exposure adjustment curve estimation model trained on various exposure image datasets to generate a picture with normal brightness. The exposure adjustment curve formula has adjustable parameters, so that balance between contrast adjustment and brightness adjustment is realized, and an enhancement result with proper contrast can be generated. The convolution module guided by the histogram can sense the global brightness of the picture to perform proper enhancement, and overexposure of an enhancement result is avoided. Through experimental comparison, our method calculates about 1.1dB higher index, up to about 21.06dB, on the dark picture enhanced paired picture test set than the current advanced method (top 1 PSNR about 19.96 dB). This is sufficient to demonstrate the effectiveness of the method of the present invention. The invention can be used in at least the following scenarios: 1. enhancing the underexposure picture shot in the low illumination scene; 2. overexposure suppression of overexposed pictures taken in bright scenes.
On the other hand, as shown in fig. 4, an embodiment of the present invention provides an exposure adjustment curve estimation apparatus 600, including: a first module 610, configured to obtain an original picture to be processed; a second module 620, configured to perform vector extraction on the original picture to obtain a histogram vector; a third module 630, configured to perform full-connection processing on the histogram vector to obtain a predicted convolution kernel parameter; a fourth module 640, configured to perform convolution processing on the original picture based on the predicted convolution kernel parameter, to obtain a curve parameter; a fifth module 650, configured to obtain an exposure adjustment curve based on the curve parameters and in combination with a sigmoid function; the exposure adjustment curve is used for the exposure adjustment of the original picture.
The content of the method embodiment of the invention is suitable for the device embodiment, the specific function of the device embodiment is the same as that of the method embodiment, and the achieved beneficial effects are the same as those of the method.
As shown in fig. 5, another aspect of an embodiment of the present invention further provides an electronic device 700, including a processor 710 and a memory 720;
The memory 720 is used for storing programs;
processor 710 executes a program to implement the method as before.
The content of the method embodiment of the invention is suitable for the electronic equipment embodiment, the functions of the electronic equipment embodiment are the same as those of the method embodiment, and the achieved beneficial effects are the same as those of the method.
Another aspect of the embodiments of the present invention also provides a computer-readable storage medium storing a program that is executed by a processor to implement a method as before.
The content of the method embodiment of the invention is applicable to the computer readable storage medium embodiment, the functions of the computer readable storage medium embodiment are the same as those of the method embodiment, and the achieved beneficial effects are the same as those of the method.
Embodiments of the present invention also disclose a computer program product or computer program comprising computer instructions stored in a computer readable storage medium. The computer instructions may be read from a computer-readable storage medium by a processor of a computer device, and executed by the processor, to cause the computer device to perform the foregoing method.
In some alternative embodiments, the functions/acts noted in the block diagrams may occur out of the order noted in the operational illustrations. For example, two blocks shown in succession may in fact be executed substantially concurrently or the blocks may sometimes be executed in the reverse order, depending upon the functionality/acts involved. Furthermore, the embodiments presented and described in the flowcharts of the present invention are provided by way of example in order to provide a more thorough understanding of the technology. The disclosed methods are not limited to the operations and logic flows presented herein. Alternative embodiments are contemplated in which the order of various operations is changed, and in which sub-operations described as part of a larger operation are performed independently.
Furthermore, while the invention is described in the context of functional modules, it should be appreciated that, unless otherwise indicated, one or more of the functions and/or features may be integrated in a single physical device and/or software module or may be implemented in separate physical devices or software modules. It will also be appreciated that a detailed discussion of the actual implementation of each module is not necessary to an understanding of the present invention. Rather, the actual implementation of the various functional modules in the apparatus disclosed herein will be apparent to those skilled in the art from consideration of their attributes, functions and internal relationships. Accordingly, one of ordinary skill in the art can implement the invention as set forth in the claims without undue experimentation. It is also to be understood that the specific concepts disclosed are merely illustrative and are not intended to be limiting upon the scope of the invention, which is to be defined in the appended claims and their full scope of equivalents.
The functions, if implemented in the form of software functional units and sold or used as a stand-alone product, may be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention may be embodied essentially or in a part contributing to the prior art or in a part of the technical solution in the form of a software product stored in a storage medium, comprising several instructions for causing a computer device (which may be a personal computer, a server, a network device, etc.) to perform all or part of the steps of the method of the embodiments of the present invention. And the aforementioned storage medium includes: a usb disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
Logic and/or steps represented in the flowcharts or otherwise described herein, e.g., a ordered listing of executable instructions for implementing logical functions, can be embodied in any computer-readable medium for use by or in connection with an instruction execution apparatus, device, or apparatus, such as a computer-based apparatus, processor-containing apparatus, or other apparatus that can fetch the instructions from the instruction execution apparatus, device, or apparatus and execute the instructions. For the purposes of this description, a "computer-readable medium" can be any means that can contain, store, communicate, propagate, or transport the program for use by or in connection with the instruction execution apparatus, device, or apparatus.
More specific examples (a non-exhaustive list) of the computer-readable medium would include the following: an electrical connection (electronic device) having one or more wires, a portable computer diskette (magnetic device), a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disc read-only memory (CDROM). Additionally, the computer-readable medium may even be paper or other suitable medium upon which the program is printed, as the program may be electronically captured, via, for instance, optical scanning of the paper or other medium, then compiled, interpreted or otherwise processed in a suitable manner, if necessary, and then stored in a computer memory.
It is to be understood that portions of the present invention may be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, the various steps or methods may be implemented in software or firmware stored in a memory and executed by a suitable instruction execution device. For example, if implemented in hardware, as in another embodiment, may be implemented using any one or combination of the following techniques, as is well known in the art: discrete logic circuits having logic gates for implementing logic functions on data signals, application specific integrated circuits having suitable combinational logic gates, programmable Gate Arrays (PGAs), field Programmable Gate Arrays (FPGAs), and the like.
In the description of the present specification, a description referring to terms "one embodiment," "some embodiments," "examples," "specific examples," or "some examples," etc., means that a particular feature, structure, material, or characteristic described in connection with the embodiment or example is included in at least one embodiment or example of the present invention. In this specification, schematic representations of the above terms do not necessarily refer to the same embodiments or examples. Furthermore, the particular features, structures, materials, or characteristics described may be combined in any suitable manner in any one or more embodiments or examples.
While embodiments of the present invention have been shown and described, it will be understood by those of ordinary skill in the art that: many changes, modifications, substitutions and variations may be made to the embodiments without departing from the spirit and principles of the invention, the scope of which is defined by the claims and their equivalents.
While the preferred embodiment of the present invention has been described in detail, the present invention is not limited to the embodiments, and those skilled in the art can make various equivalent modifications or substitutions without departing from the spirit of the present invention, and the equivalent modifications or substitutions are intended to be included in the scope of the present invention as defined in the appended claims.

Claims (7)

1. An exposure adjustment curve estimation method, comprising:
acquiring an original picture to be processed;
extracting the vector of the original picture to obtain a histogram vector;
the step of extracting the vector of the original picture to obtain a histogram vector comprises the following steps:
Extracting the vector of the original picture based on the picture specification and the channel parameter of the original picture to obtain a histogram vector;
The picture specification comprises the height and the width of a picture, and the channel parameters comprise channel pixel values and channel components; the extracting the vector of the original picture based on the picture specification and the channel parameter of the original picture to obtain a histogram vector comprises:
Based on the picture specification and channel parameters of the original picture, combining a smoothing factor and column vector boundary values of the original picture, and extracting vectors of the original picture through a sigmoid function to obtain a histogram vector; wherein the column vector boundary values include left and right boundary values for each value in the column vector; the expression of the histogram vector is:
in the method, in the process of the invention, A value representing the ith dimension of the histogram vector for the c-channel, which includes three color channels r, g, b labeling the RGB picture; h, W respectively represent the height and width of the original picture; x c denotes the channel pixel value of the c-channel; x c represents the channel component of the c-channel; s (·) represents a sigmoid function; sigma represents a smoothing factor; l i,ri represents the left boundary value and the right boundary value of the i-th value in the column vector of the original picture, respectively;
performing full connection processing on the histogram vector to obtain a predicted convolution kernel parameter;
carrying out convolution processing on the original picture based on the prediction convolution kernel parameter to obtain a curve parameter;
Based on the curve parameters, acquiring an exposure adjustment curve by combining a sigmoid function; the exposure adjustment curve is used for adjusting the exposure of the original picture;
based on the curve parameters, an exposure adjustment curve is obtained by combining a sigmoid function, and the method comprises the following steps:
An S curve of the mapping between the hidden space and the pixel space is constructed through a sigmoid function, and then an exposure adjustment curve is obtained by combining the curve parameters; wherein, the expression of the exposure adjustment curve is:
Wherein y represents an enhanced result pixel value; a, b represent normalization coefficients; x represents a pixel value; s represents a super parameter; alpha represents a curve parameter; e represents a natural constant.
2. The method for estimating an exposure adjustment curve according to claim 1, wherein said performing full-join processing on the histogram vectors to obtain predicted convolution kernel parameters comprises:
inputting the histogram vector into a stacked full-connection layer for full-connection processing to obtain a predicted convolution kernel parameter;
wherein the fully connected layer takes leakyReLU functions as activation functions.
3. The exposure adjustment curve estimation method according to claim 1, wherein the convolving the original picture based on the predicted convolution kernel parameter to obtain a curve parameter includes:
Inputting the original picture into a plurality of convolution layers for convolution treatment to obtain curve parameters;
Wherein the multi-layer convolution layers comprise a plurality of first convolution layers arranged based on the prediction convolution kernel parameters and a plurality of second convolution layers arranged conventionally; the curve parameters are constrained by the entropy of the histogram vector as a loss function.
4. The method for estimating an exposure adjustment curve according to claim 3, wherein said inputting the original picture into a multi-layer convolution layer for convolution processing to obtain curve parameters comprises:
Performing feature extraction and feature processing on the original picture through a plurality of second convolution layers, performing self-adaptive feature processing through a plurality of first convolution layers, and obtaining the curve parameters through an output layer; wherein the output layer is the second convolution layer.
5. An exposure adjustment curve estimation apparatus, comprising:
the first module is used for acquiring an original picture to be processed;
the second module is used for extracting the vector of the original picture to obtain a histogram vector;
the step of extracting the vector of the original picture to obtain a histogram vector comprises the following steps:
Extracting the vector of the original picture based on the picture specification and the channel parameter of the original picture to obtain a histogram vector;
The picture specification comprises the height and the width of a picture, and the channel parameters comprise channel pixel values and channel components; the extracting the vector of the original picture based on the picture specification and the channel parameter of the original picture to obtain a histogram vector comprises:
Based on the picture specification and channel parameters of the original picture, combining a smoothing factor and column vector boundary values of the original picture, and extracting vectors of the original picture through a sigmoid function to obtain a histogram vector; wherein the column vector boundary values include left and right boundary values for each value in the column vector; the expression of the histogram vector is:
in the method, in the process of the invention, A value representing the ith dimension of the histogram vector for the c-channel, which includes three color channels r, g, b labeling the RGB picture; h, W respectively represent the height and width of the original picture; x c denotes the channel pixel value of the c-channel; x c represents the channel component of the c-channel; s (·) represents a sigmoid function; sigma represents a smoothing factor; l i,ri represents the left boundary value and the right boundary value of the i-th value in the column vector of the original picture, respectively;
the third module is used for carrying out full connection processing on the histogram vector to obtain a predicted convolution kernel parameter;
a fourth module, configured to perform convolution processing on the original picture based on the predicted convolution kernel parameter, to obtain a curve parameter;
A fifth module, configured to obtain an exposure adjustment curve based on the curve parameter and in combination with a sigmoid function; the exposure adjustment curve is used for adjusting the exposure of the original picture; based on the curve parameters, an exposure adjustment curve is obtained by combining a sigmoid function, and the method comprises the following steps:
An S curve of the mapping between the hidden space and the pixel space is constructed through a sigmoid function, and then an exposure adjustment curve is obtained by combining the curve parameters; wherein, the expression of the exposure adjustment curve is:
Wherein y represents an enhanced result pixel value; a, b represent normalization coefficients; x represents a pixel value; s represents a super parameter; alpha represents a curve parameter; e represents a natural constant.
6. An electronic device comprising a processor and a memory;
the memory is used for storing programs;
The processor executing the program implements the method of any one of claims 1 to 4.
7. A computer-readable storage medium, characterized in that the storage medium stores a program that is executed by a processor to implement the method of any one of claims 1 to 4.
CN202311272977.4A 2023-09-27 2023-09-27 Exposure adjustment curve estimation method and device, electronic equipment and storage medium Active CN117237248B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311272977.4A CN117237248B (en) 2023-09-27 2023-09-27 Exposure adjustment curve estimation method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311272977.4A CN117237248B (en) 2023-09-27 2023-09-27 Exposure adjustment curve estimation method and device, electronic equipment and storage medium

Publications (2)

Publication Number Publication Date
CN117237248A CN117237248A (en) 2023-12-15
CN117237248B true CN117237248B (en) 2024-07-16

Family

ID=89096555

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311272977.4A Active CN117237248B (en) 2023-09-27 2023-09-27 Exposure adjustment curve estimation method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN117237248B (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112446833A (en) * 2019-09-02 2021-03-05 武汉Tcl集团工业研究院有限公司 Image processing method, intelligent terminal and storage medium
CN114693545A (en) * 2022-02-15 2022-07-01 北京大学 Low-illumination enhancement method and system based on curve family function

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113936163B (en) * 2020-07-14 2024-10-15 武汉Tcl集团工业研究院有限公司 Image processing method, terminal and storage medium
CN114022394B (en) * 2022-01-04 2022-04-19 苏州浪潮智能科技有限公司 Image restoration method and device, electronic equipment and storage medium
CN115239575B (en) * 2022-06-06 2023-10-27 荣耀终端有限公司 Beautifying method and device
CN115937030A (en) * 2022-12-12 2023-04-07 杭州电子科技大学 Shadow removal method based on dynamic alignment and illumination perception convolution

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112446833A (en) * 2019-09-02 2021-03-05 武汉Tcl集团工业研究院有限公司 Image processing method, intelligent terminal and storage medium
CN114693545A (en) * 2022-02-15 2022-07-01 北京大学 Low-illumination enhancement method and system based on curve family function

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
"Single low-light image enhancer using Taylor expansion and fullydynamic convolution";Chenggang Dai et al;《Signal Processing》;20210805;第189卷;第1-14页 *

Also Published As

Publication number Publication date
CN117237248A (en) 2023-12-15

Similar Documents

Publication Publication Date Title
Ma et al. Deep guided learning for fast multi-exposure image fusion
Ma et al. Multi-exposure image fusion by optimizing a structural similarity index
Eilertsen et al. A comparative review of tone‐mapping algorithms for high dynamic range video
Kinoshita et al. Scene segmentation-based luminance adjustment for multi-exposure image fusion
CN109712165B (en) Similar foreground image set segmentation method based on convolutional neural network
Huang et al. Framelet regularization for uneven intensity correction of color images with illumination and reflectance estimation
Wang et al. Joint iterative color correction and dehazing for underwater image enhancement
Banerjee et al. Real-time underwater image enhancement: An improved approach for imaging with AUV-150
Srinivas et al. Exposure-based energy curve equalization for enhancement of contrast distorted images
Saleh et al. Adaptive uncertainty distribution in deep learning for unsupervised underwater image enhancement
Wang et al. Fast exposure fusion of detail enhancement for brightest and darkest regions
Song et al. Dual-model: Revised imaging network and visual perception correction for underwater image enhancement
Punnappurath et al. A little bit more: Bitplane-wise bit-depth recovery
Zhu et al. Learning dual transformation networks for image contrast enhancement
CN114240767A (en) Image wide dynamic range processing method and device based on exposure fusion
US11138693B2 (en) Attention-driven image manipulation
Zheng et al. Windowing decomposition convolutional neural network for image enhancement
He et al. Low-light image enhancement with multi-scale attention and frequency-domain optimization
Zhang et al. Learning a single convolutional layer model for low light image enhancement
CN118247181B (en) Image restoration model training method, electronic device and image restoration method
Liang et al. PIE: Physics-Inspired Low-Light Enhancement
CN117237248B (en) Exposure adjustment curve estimation method and device, electronic equipment and storage medium
Zini et al. Back to the future: a night photography rendering ISP without deep learning
Wu et al. Contrast enhancement based on reflectance-oriented probabilistic equalization
Kim Low-light image enhancement by diffusion pyramid with residuals

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