Automatic exposure method and device and storage medium

By adding a confidence calculation module to the automatic exposure model, the confidence value of the automatic exposure parameters is output, which solves the problem of unsatisfactory automatic exposure parameters and is difficult to judge in the prior art, and improves the automatic exposure effect of the image.

CN120034742APending Publication Date: 2025-05-23BEIJING SPREADTRUM HI TECH COMM TECH CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202510138106.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-02-07
Publication Date
2025-05-23

AI Technical Summary

Technical Problem

The exposure parameters output by the existing automatic exposure algorithms are sometimes unsatisfactory, resulting in poor exposure effects and it is difficult to judge the credibility of the parameters.

Method used

An automatic exposure method is proposed. By adding a confidence calculation module to the automatic exposure model, the confidence value of the automatic exposure parameter is output, the confidence value of the parameter is verified, and the exposure parameters are adjusted according to the confidence value.

Benefits of technology

By outputting the confidence value of the automatic exposure parameters, the credibility of the parameters can be effectively judged, the automatic exposure effect of the image can be improved, and the problem of unsatisfactory parameters and difficult to judge credibility is solved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120034742A_ABST
    Figure CN120034742A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of automatic exposure, in particular to an automatic exposure method and device and a storage medium. The method comprises the steps that a to-be-exposed image is input into an automatic exposure model, the automatic exposure model comprises a feature extraction module, an exposure parameter calculation module and a confidence coefficient calculation module, the feature extraction module is used for extracting image features of the to-be-exposed image, and the confidence coefficient calculation module is used for calculating the confidence coefficient of the to-be-exposed image; the exposure parameter calculation module is used for outputting automatic exposure parameters according to the image features, and the confidence calculation module is used for outputting confidence values of the automatic exposure parameters according to the image features; and after verifying the credibility of the automatic exposure parameter according to the confidence value, exposing the to-be-exposed image. According to the scheme, when the automatic exposure parameter is output, the confidence value of the automatic exposure parameter can be output, so that the problem that whether the automatic exposure parameter output by the automatic exposure algorithm is reasonable or not is difficult to determine is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of automatic exposure technology, and in particular to an automatic exposure method, device and storage medium. Background Art

[0002] Auto Exposure (AE) is a technology widely used in photography and videography. Through the automatic exposure technology, the camera or video camera can automatically adjust the exposure parameters according to the ambient light conditions to obtain an image or video with moderate clarity and brightness. Currently, many electronic devices support automatic exposure algorithms, but the exposure parameters calculated by the automatic exposure algorithm are sometimes not ideal, affecting the exposure effect. Summary of the invention

[0003] In view of this, the present application provides an automatic exposure method, device and storage medium, which can output confidence values ​​of automatic exposure parameters to solve the problem of difficulty in determining whether the automatic exposure parameters output by the automatic exposure algorithm are reasonable.

[0004] In a first aspect, an embodiment of the present invention provides an automatic exposure method, comprising:

[0005] Inputting the image to be exposed into the automatic exposure model, the automatic exposure model comprising: a feature extraction module, an exposure parameter calculation module and a confidence calculation module, wherein the feature extraction module is used to extract the image features of the image to be exposed, the exposure parameter calculation module is used to output the automatic exposure parameters according to the image features, and the confidence calculation module is used to output the confidence value of the automatic exposure parameters according to the image features;

[0006] After verifying the credibility of the automatic exposure parameter according to the confidence value, the image to be exposed is exposed.

[0007] In some embodiments, inputting the image to be exposed into the automatic exposure model includes:

[0008] The image to be exposed, environmental information determined according to the image to be exposed, and a dynamic range of image brightness are input into the automatic exposure model.

[0009] In some embodiments, the feature extraction module includes: a backbone network and a feature fusion network;

[0010] The feature extraction module is used to extract the image features of the image to be exposed, including:

[0011] The backbone network is used to extract image features of the image to be exposed;

[0012] The feature fusion network is used to fuse the image features into features suitable for a dual-branch network, and input them into the exposure parameter calculation module and the confidence calculation module respectively.

[0013] In some embodiments, the method further comprises: performing joint training on the exposure parameter calculation module and the confidence calculation module of the training model for several times; wherein each joint training comprises:

[0014] Inputting a training sample into the model to be trained, wherein the training sample includes an image sample and a true value label of an exposure parameter;

[0015] Using the image samples and the exposure parameter true value labels, the exposure parameter calculation module of the model to be trained is trained to output exposure parameter training values;

[0016] Determining a confidence true value label according to the exposure parameter training value and the exposure parameter true value label;

[0017] Using the image samples and the confidence truth value labels, training the confidence calculation module of the model to be trained, and outputting the confidence training value of the exposure parameter training value;

[0018] Calculating a model loss parameter according to the exposure parameter training value and the confidence training value;

[0019] After adjusting the parameters of the model to be trained according to the model loss parameters, the model to be trained is trained again.

[0020] In some embodiments, determining the confidence truth label according to the exposure parameter training value and the exposure parameter truth label includes:

[0021] Determining error information between the exposure parameter training value and the exposure parameter true value label;

[0022] According to the error information, a corresponding confidence truth label is determined, wherein the value of the confidence truth label decreases as the value of the error information increases, and increases as the value of the error information decreases.

[0023] In some embodiments, determining the error information between the exposure parameter training value and the exposure parameter true value label includes:

[0024] Determining a difference between the exposure parameter training value and the exposure parameter true value label;

[0025] A ratio between the absolute value of the difference and the true value label of the exposure parameter is determined, and the ratio is used as the error information.

[0026] In some embodiments, calculating a model loss parameter according to the training value of the exposure parameter and the training value of the confidence level includes:

[0027] Determining a first loss parameter according to the training value of the exposure parameter and the true value label of the exposure parameter;

[0028] Determining a second loss parameter according to the training value of the confidence level and the true value label of the confidence level;

[0029] Determining the model loss parameter according to the weighting of the first loss parameter and the second loss parameter.

[0030] In some embodiments, before performing several joint trainings on the exposure parameter calculation module and the confidence level calculation module of the model to be trained, the method further includes:

[0031] Individually training the exposure parameter calculation module of the model to be trained by using training samples;

[0032] Wherein, after each training of the exposure parameter calculation module, determining the loss parameter of the exposure parameter calculation module;

[0033] Judging whether the loss parameter of the exposure parameter calculation module meets a set condition;

[0034] If so, starting the joint training of the exposure parameter calculation module and the confidence level calculation module of the model to be trained;

[0035] If not, after adjusting the parameters of the exposure parameter calculation module according to the loss parameter of the exposure parameter calculation module, training the exposure parameter calculation module again.

[0036] In a second aspect, an embodiment of the present invention provides an electronic device, including:

[0037] A network model module for deploying an automatic exposure model, where the automatic exposure model includes: a feature extraction module, an exposure parameter calculation module, and a confidence level calculation module. Wherein, when the automatic exposure model inputs an image to be exposed, the feature extraction module is used to extract the image features of the image to be exposed, the exposure parameter calculation module is used to output an automatic exposure parameter according to the image features, and the confidence level calculation module is used to output a confidence value of the automatic exposure parameter according to the image features;

[0038] An exposure module for exposing the image to be exposed after verifying the credibility of the automatic exposure parameter according to the confidence value.

[0039] In a third aspect, an embodiment of the present invention provides an electronic device, comprising: a memory for storing computer program instructions and a processor for executing the program instructions, wherein when the computer program instructions are executed by the processor, the electronic device executes the method described in the first aspect or any one of the first aspects.

[0040] In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium, wherein the computer-readable storage medium includes a stored program, wherein when the program is running, the device where the computer-readable storage medium is located is controlled to execute a method as described in the first aspect or any one of the first aspects above.

[0041] In the embodiment of the present invention, a branch for calculating confidence is added on the basis of the branch for calculating the automatic exposure parameters. The confidence value of the currently calculated automatic exposure parameters can be output through the branch for calculating the confidence. The credibility of the automatic exposure parameters can be determined according to the confidence value, providing a basis for judging the credibility of the automatic exposure parameters and providing a guarantee for improving the automatic exposure effect of the image. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0043] Figure 1 A schematic diagram of the structure of an automatic exposure model provided by an embodiment of the present invention;

[0044] Figure 2 A curve diagram of a confidence truth value label provided by an embodiment of the present invention;

[0045] Figure 3 A training flow chart of an automatic exposure model provided by an embodiment of the present invention;

[0046] Figure 4 A flowchart of an automatic exposure method provided by an embodiment of the present invention;

[0047] Figure 5 A schematic diagram of the structure of an electronic device provided by an embodiment of the present invention;

[0048] Figure 6 A schematic diagram of the structure of another electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0049] In order to better understand the technical solution of the present application, the embodiments of the present application are described in detail below with reference to the accompanying drawings.

[0050] It should be clear that the described embodiments are only part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in the field without creative work are within the scope of protection of the present application.

[0051] The terms used in the embodiments of the present application are only for the purpose of describing specific embodiments, and are not intended to limit the present application. The singular forms "a", "said" and "the" used in the embodiments of the present application and the appended claims are also intended to include plural forms, unless the context clearly indicates other meanings.

[0052] It should be understood that the term "and / or" used in this article is only a description of the association relationship of associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in this article generally indicates that the associated objects before and after are in an "or" relationship.

[0053] With the improvement of electronic equipment hardware and software technology, electronic equipment can be configured with automatic exposure function. The automatic exposure function in electronic equipment can be implemented through a depth-based automatic exposure network model. When the electronic device takes a photo or video, the automatic exposure network model automatically outputs exposure parameters to expose the image or video. The certainty and credibility of the exposure parameters output by the automatic exposure network model directly affect the automatic exposure effect of the image or video.

[0054] In view of this, an embodiment of the present invention provides an automatic exposure model. The automatic exposure model is provided with a confidence branch, through which not only the automatic exposure parameters of the image to be exposed can be output, but also the confidence value of the automatic exposure parameter can be output through the confidence branch, and the confidence value is used to indicate the certainty and credibility of the currently output automatic exposure parameter, thereby compensating for the problem that the output automatic exposure parameter is unstable and the credibility cannot be judged in the related art.

[0055] See also Figure 1 , is a structural schematic diagram of an automatic exposure model provided by an embodiment of the present invention. Figure 1 The automatic exposure model shown is a dual-branch network model, including a branch for calculating automatic exposure parameters and a branch for calculating the confidence value of the automatic exposure parameters. The confidence value of the currently calculated automatic exposure parameter can be output through the branch for calculating the confidence value. Figure 1As shown, the automatic exposure model specifically includes: a feature extraction module, an exposure parameter calculation module and a confidence calculation module. Among them, the feature extraction module is used to extract the image features of the image to be exposed, and the extracted image features are respectively input into the exposure parameter calculation module and the confidence calculation module. The exposure parameter calculation module is used to output the automatic exposure parameters according to the image features, and the confidence calculation module is used to output the confidence value of the currently calculated automatic exposure parameters according to the image features. The credibility of the automatic exposure parameters can be determined according to the confidence value. If the confidence value of the automatic exposure parameter is lower than the set value, the automatic exposure parameter can be recalculated to expose the image or the default confidence value of the electronic device can be selected to expose the image. If the confidence value of the automatic exposure parameter is higher than the set value, the image to be exposed can be exposed according to the automatic exposure parameter output by the automatic exposure model.

[0056] The automatic exposure model of the embodiment of the present invention adds a branch for calculating the exposure parameter confidence value on the basis of the exposure parameter calculation module. When the automatic exposure model is used for automatic exposure, not only the automatic exposure parameters but also the confidence values ​​of the automatic exposure parameters can be output, providing a basis for judging the credibility of the automatic exposure parameters and providing a guarantee for improving the automatic exposure effect of the image.

[0057] like Figure 1 As shown, the feature extraction module of the automatic exposure model includes a backbone network and a feature fusion network. The backbone network can be any type of deep network, such as a convolutional network, an MLP (Multilayer Perceptron) network, or a Transformer network. The backbone network is used to extract image features of the input image to be exposed. The image features extracted by the backbone network are further input into the feature fusion network, which is used to fuse the input image features into features suitable for the dual-branch network, and then input into the exposure parameter calculation module and the confidence calculation module respectively.

[0058] exist Figure 1 In the automatic exposure model shown, the exposure parameter calculation module can be implemented using a deep regression network model, which is used to calculate the automatic exposure parameters of the image to be exposed according to the image features output by the feature fusion module. The confidence calculation module can be implemented using a classification network model, which is used to calculate the confidence value of the current automatic exposure parameter according to the image features output by the feature fusion module. The confidence value ranges from 0 to 1, and the closer the value is to 1, the higher the confidence of the predicted automatic exposure parameter, and the closer the value is to 0, the lower the confidence of the predicted automatic exposure parameter.

[0059] exist Figure 1In the automatic exposure model shown, the confidence calculation module can calculate the confidence value of the automatic exposure parameter output by the exposure parameter calculation module. In order to enable the confidence calculation module to have this function, the most critical thing when training the confidence calculation module is to determine the true value label of the confidence value. To this end, an embodiment of the present invention provides a method for determining the confidence true value label. In this method, the true value label of the confidence value is determined based on the error information between the automatic exposure parameter output by the exposure parameter calculation module and the true value label of the automatic exposure parameter.

[0060] Assume that the input of the automatic exposure model is X, the automatic exposure parameter output by the exposure parameter calculation module is R, and the true value label of the automatic exposure parameter R is R*. The confidence value of the automatic exposure parameter R output by the confidence calculation module is C, and the confidence true value label is C*. Then a set of training samples can be expressed as {X, R, C, R * , C *}.

[0061] In the embodiment of the present invention, the automatic exposure parameter R and the automatic exposure parameter true value label R * The confidence truth label C* is estimated based on the error information between them. The value of the confidence truth label C* decreases as the value of the error information increases, and increases as the value of the error information decreases, as shown in Formula 1. The maximum value of the confidence truth label C* is 1, and the minimum value is 0.

[0062] Formula 1:

[0063] In some examples, the value of the automatic exposure parameter R is different, but the automatic exposure parameter R is different from the exposure parameter true value label R * The absolute errors between them are the same, and R * The difference between the values ​​of is difficult to accurately represent the error sensitivity of the automatic exposure parameter R. In order to more accurately represent the error sensitivity of the automatic exposure parameter R, the embodiment of the present invention adopts the error percentage method to represent the difference between the automatic exposure parameter R and the exposure parameter true value label R. * Specifically, determine the error information between the automatic exposure parameter R and the exposure parameter true value label R * Determine the absolute value of the difference and the exposure parameter truth label R * The ratio between the automatic exposure parameter R and the exposure parameter true value label R * The error information between them. For details, please refer to Formula 2. P in Formula 2 is used to represent the error information between the automatic exposure parameter R and the exposure parameter true value label R * The error information between them can also be called error percentage and can be represented by P.

[0064] Formula 2: P = |RR * | / R * .

[0065] In some examples, the lower limit and upper limit of the error percentage P are set to P low and P high , confidence truth label C * It can be expressed as formula 3.

[0066] Formula 3:

[0067] In the above formula 3, when the automatic exposure parameter R and the exposure parameter true value label R * The error percentage between P is less than P low When the confidence truth label C * The value of is 1; when the automatic exposure parameter R is equal to the exposure parameter true value label R * The error percentage between P is greater than P high When the confidence truth label C * The value is 0. low ≤P≤P high When the confidence truth label C * The value of is determined according to the function f(.). The following formula 4 is a specific example of a function f(.) provided in an embodiment of the present invention.

[0068] Formula 4:

[0069] f=(P hiig hP) / (P high -P low )

[0070] According to Formula 3 and Formula 4, the confidence truth label C * There is a linear functional relationship between it and the error percentage P, such as Figure 2 As shown in curve 1 in . In some examples, the confidence truth label C * There can also be a nonlinear relationship between the error percentage P, such as Figure 2 Curve 2 and curve 3 in .

[0071] Based on the above-mentioned method for determining the confidence truth value label, an embodiment of the present invention further provides a method for training an automatic exposure model. The training of the automatic exposure model in the embodiment of the present invention includes training of an exposure parameter calculation module and training of a confidence calculation module. Among them, the embodiment of the present invention can be trained by jointly training the exposure parameter calculation module and the confidence calculation module. Figure 3 As shown in Figure 1, each joint training includes:

[0072] 101, input the training samples into the model to be trained, wherein the training samples include image samples and exposure parameter true value labels. The image samples are images for which the automatic exposure parameters are to be calculated. Optionally, in addition to the images for which the automatic exposure parameters are to be calculated, the image samples may also include environmental information determined according to the image samples and the dynamic range of the image brightness. The exposure parameter true value labels are the theoretical values ​​of the exposure parameters of the image samples.

[0073] 102, using the image samples and the exposure parameter true value labels, training the exposure parameter calculation module of the training model, and outputting the exposure parameter training values.

[0074] 103 , determining a confidence truth label according to the exposure parameter training value and the exposure parameter truth label.

[0075] 104 , using the image samples and the confidence truth value labels, train the confidence calculation module of the to-be-trained model, and output the confidence training value of the exposure parameter training value.

[0076] 105, calculating the model loss parameter according to the exposure parameter training value and the confidence training value.

[0077] 106 , after adjusting the parameters of the model to be trained according to the model parameters, the model to be trained is trained again.

[0078] The automatic exposure model in the embodiment of the present invention is a dual-branch network, and the dual-branch network calculates the loss parameter including: determining a first loss parameter according to the exposure parameter training value and the exposure parameter true value label. Determining a second loss parameter according to the confidence training value and the confidence true value label. Determining the model loss parameter according to the weighting of the first loss parameter and the second loss parameter.

[0079] In some examples, the model loss parameter may be calculated using Formula 5.

[0080] Formula 5:

[0081] In the above formula 5, Loss is the model loss parameter, RegLoss is used to represent the loss parameter of the exposure parameter calculation module, and ConfLoss is used to represent the loss parameter of the confidence calculation module. γ is the weight coefficient, usually γ = {0, 0.1}. Among them, in the early stage of model training, the accuracy of the automatic exposure parameters output by the exposure parameter calculation module is poor. The confidence calculation module can be frozen first to train the exposure parameter calculation module separately. After each separate training of the exposure parameter calculation module, the loss parameter of the exposure parameter calculation module is calculated, and it is determined whether the loss parameter of the exposure parameter calculation module meets the set conditions. If the set conditions are met, the joint training of the exposure parameter calculation module and the confidence calculation module is started. If the set conditions are not met, the parameters of the exposure parameter calculation module are adjusted according to the loss parameters of the exposure parameter calculation module, and the exposure parameter calculation module is trained separately again. Among them, the loss parameter of the exposure parameter calculation module meets the set conditions, for example, its loss parameter converges or is less than the set value, that is, when the automatic exposure parameter output by the exposure parameter calculation module has a certain accuracy, the joint training of the exposure parameter calculation module and the confidence calculation module is started.

[0082] In specific implementation, γ can be set to 0 to freeze the confidence calculation module, and the exposure parameter calculation module can be trained separately. When the automatic exposure parameters output by the exposure parameter calculation module have a certain degree of accuracy, the confidence calculation module is unfrozen, that is, γ is set to a non-zero value, and the exposure parameter calculation module and the confidence calculation module are jointly trained.

[0083] After the joint training of the exposure parameter calculation module and the confidence calculation module in the automatic exposure model is completed, the model can output the automatic exposure parameters and their confidence values.

[0084] The above automatic exposure model is applied in an electronic device. The electronic device runs the automatic exposure model and executes the automatic exposure method. Figure 4 As shown, the automatic exposure method performed by the electronic device includes:

[0085] 201, input the image to be exposed into the automatic exposure model, the feature extraction module in the automatic exposure model is used to extract the image features of the image to be exposed, the exposure parameter calculation module is used to output the automatic exposure parameters according to the image features, and the confidence calculation module is used to output the confidence value of the automatic exposure parameters according to the image features. Optionally, in addition to inputting the image to be exposed into the automatic exposure model, environmental information determined according to the image to be exposed and the dynamic range of the image brightness can also be input into the automatic exposure model.

[0086] 202 , verifying the credibility of the automatic exposure parameters according to the confidence value output by the confidence calculation module.

[0087] 203 : If the confidence value of the automatic exposure parameter is greater than or equal to the set value, it is determined that the currently output automatic exposure parameter is credible, and the image to be exposed is exposed based on the automatic exposure parameter.

[0088] 204 , if the confidence value of the automatic exposure parameter is less than the set value, it is determined that the currently output automatic exposure parameter is not credible, and other algorithms are used to recalculate the automatic exposure parameter or preset exposure parameters are used to expose the image to be exposed.

[0089] The automatic exposure method of the embodiment of the present invention can output the confidence value of the automatic exposure parameter while outputting the automatic exposure parameter. The credibility of the automatic exposure parameter can be determined according to the confidence value, thereby compensating for the problem that the automatic exposure parameter output is unstable and the credibility cannot be determined in the related art.

[0090] Corresponding to the above automatic exposure method, an embodiment of the present invention further provides an electronic device, in which an automatic exposure device is deployed to implement the above automatic exposure method. Figure 5 As shown, the automatic exposure device deployed in the electronic device includes:

[0091] A network model module 310, wherein the network model module is used to deploy an automatic exposure model, wherein the automatic exposure model includes: a feature extraction module, an exposure parameter calculation module, and a confidence calculation module, wherein when the automatic exposure model inputs an image to be exposed, the feature extraction module is used to extract image features of the image to be exposed, the exposure parameter calculation module is used to output automatic exposure parameters according to the image features, and the confidence calculation module is used to output a confidence value of the automatic exposure parameters according to the image features;

[0092] The exposure module 320 is used to expose the image to be exposed after verifying the credibility of the automatic exposure parameter according to the confidence value.

[0093] The electronic device of the embodiment of the present invention can execute the automatic exposure method of the embodiment shown above. For the part not described in detail in the embodiment of the present invention, reference can be made to the relevant description of the method embodiment. The execution process and technical effect of the technical solution can be referred to the description in the method embodiment, which will not be repeated here.

[0094] See also Figure 6 , is a schematic diagram of the structure of an electronic device provided by an embodiment of the present invention. Figure 4As shown, the electronic device 400 may include: a processor 401, a memory 402 and a communication unit 403. These components communicate via one or more buses. Those skilled in the art will appreciate that the structure of the electronic device shown in the figure does not limit the embodiments of the present application, and it may be a bus structure or a star structure, and may include more or fewer components than shown in the figure, or combine certain components, or arrange components differently.

[0095] The communication unit 403 is used to establish a communication channel so that the electronic device can communicate with other devices, receive user data sent by other devices or send user data to other devices.

[0096] The processor 401 is the control center of the electronic device, which uses various interfaces and lines to connect various parts of the entire electronic device, and executes various functions of the electronic device and / or processes data by running or executing software programs, instructions, and / or modules stored in the memory 402, and calling data stored in the memory. The processor can be composed of an integrated circuit (IC), for example, it can be composed of a single packaged IC, or it can be composed of multiple packaged ICs with the same or different functions. For example, the processor 401 may include a central processing unit (CPU), a microcontroller Uni (MCU), etc.

[0097] The memory 402 is used to store the execution instructions of the processor 401. The memory 402 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk.

[0098] When the execution instruction in the memory 402 is executed by the processor 401, the electronic device 400 is enabled to execute the automatic exposure method in the embodiment of the present invention.

[0099] In a specific implementation, the present application further provides a computer storage medium, wherein the computer storage medium may store a program, and when the program is executed, the program may include some or all of the steps in each embodiment of the automatic exposure method provided in the present application. The storage medium may be a disk, an optical disk, a read-only memory (ROM) or a random access memory (RAM), etc.

[0100] In a specific implementation, the present application also provides a computer program product, wherein the computer program product includes executable instructions, and when the executable instructions are executed on a computer, the computer executes part or all of the steps in each embodiment of the automatic exposure method provided in the present application.

[0101] The embodiment of the present application also provides a non-temporary computer-readable storage medium, which stores computer instructions, and the computer instructions enable the computer to execute the automatic exposure method provided by the embodiment of the present application.

[0102] The above-mentioned non-temporary computer-readable storage medium can adopt any combination of one or more computer-readable media. The computer-readable medium can be a computer-readable signal medium or a computer-readable storage medium. The computer-readable storage medium can be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples (non-exhaustive list) of computer-readable storage media include: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (Read Only Memory; hereinafter referred to as: ROM), an erasable programmable read-only memory (ErasableProgrammable Read Only Memory; hereinafter referred to as: EPROM) or flash memory, optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In this document, a computer-readable storage medium can be any tangible medium containing or storing a program, which can be used by an instruction execution system, device or device or used in combination with it.

[0103] Computer-readable signal media may include a data signal propagated in baseband or as part of a carrier wave, which carries a computer-readable program code. Such propagated data signals may take a variety of forms, including, but not limited to, electromagnetic signals, optical signals, or any suitable combination of the above. Computer-readable signal media may also be any computer-readable medium other than a computer-readable storage medium, which may send, propagate, or transmit a program for use by or in conjunction with an instruction execution system, apparatus, or device.

[0104] 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.

[0105] Those skilled in the art can clearly understand that the technology in the embodiments of the present application can be implemented by means of software plus a necessary general hardware platform. Based on this understanding, the technical solution in the embodiments of the present application is essentially or the part that contributes to the prior art can be embodied in the form of a software product, which can be stored in a storage medium such as ROM / RAM, a disk, an optical disk, etc., including several instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present application or some parts of the embodiments.

[0106] In this specification, the same or similar parts between the various embodiments can be referred to each other. In particular, for the device embodiment and the terminal embodiment, since they are basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the description in the method embodiment.

Claims

1. An automatic exposure method, characterized in that: include: Inputting the image to be exposed into the automatic exposure model, the automatic exposure model comprising: a feature extraction module, an exposure parameter calculation module and a confidence calculation module, wherein the feature extraction module is used to extract the image features of the image to be exposed, the exposure parameter calculation module is used to output the automatic exposure parameters according to the image features, and the confidence calculation module is used to output the confidence value of the automatic exposure parameters according to the image features; After verifying the credibility of the automatic exposure parameter according to the confidence value, the image to be exposed is exposed.

2. The method according to claim 1, characterized in that The step of inputting the image to be exposed into the automatic exposure model comprises: The image to be exposed, environmental information determined according to the image to be exposed, and a dynamic range of image brightness are input into the automatic exposure model.

3. The method according to claim 1, characterized in that The feature extraction module includes: a backbone network and a feature fusion network; The feature extraction module is used to extract the image features of the image to be exposed, including: The backbone network is used to extract image features of the image to be exposed; The feature fusion network is used to fuse the image features into features suitable for a dual-branch network, and input them into the exposure parameter calculation module and the confidence calculation module respectively.

4. The method according to any one of claims 1 to 3, characterized in that: The method further includes: performing joint training for several times on the exposure parameter calculation module and the confidence calculation module of the training model; wherein each joint training includes: Inputting a training sample into the model to be trained, wherein the training sample includes an image sample and a true value label of an exposure parameter; Using the image samples and the exposure parameter true value labels, the exposure parameter calculation module of the model to be trained is trained to output exposure parameter training values; Determining a confidence true value label according to the exposure parameter training value and the exposure parameter true value label; Using the image samples and the confidence truth value labels, training the confidence calculation module of the model to be trained, and outputting the confidence training value of the exposure parameter training value; Calculating a model loss parameter according to the exposure parameter training value and the confidence training value; After adjusting the parameters of the model to be trained according to the model loss parameters, the model to be trained is trained again.

5. The method according to claim 4, characterized in that The step of determining the confidence true value label according to the exposure parameter training value and the exposure parameter true value label comprises: Determining error information between the exposure parameter training value and the exposure parameter true value label; According to the error information, a corresponding confidence truth label is determined, wherein the value of the confidence truth label decreases as the value of the error information increases, and increases as the value of the error information decreases.

6. The method according to claim 5, characterized in that The determining the error information between the exposure parameter training value and the exposure parameter true value label includes: Determining a difference between the exposure parameter training value and the exposure parameter true value label; A ratio between the absolute value of the difference and the true value label of the exposure parameter is determined, and the ratio is used as the error information.

7. The method according to claim 4, characterized in that: The calculating the model loss parameter according to the exposure parameter training value and the confidence training value includes: Determining a first loss parameter according to the exposure parameter training value and the exposure parameter true value label; Determining a second loss parameter according to the confidence training value and the confidence true value label; A model loss parameter is determined according to a weighting of the first loss parameter and the second loss parameter.

8. The method according to claim 4, characterized in that Before the exposure parameter calculation module and the confidence calculation module of the training model are jointly trained several times, the method further includes: Using the training samples, the exposure parameter calculation module of the model to be trained is trained separately; wherein, after each training of the exposure parameter calculation module, a loss parameter of the exposure parameter calculation module is determined; Determining whether the loss parameter of the exposure parameter calculation module meets the set conditions; If yes, start the joint training of the exposure parameter calculation module and the confidence calculation module of the model to be trained; If not, after adjusting the parameters of the exposure parameter calculation module according to the loss parameters of the exposure parameter calculation module, the exposure parameter calculation module is trained again.

9. An electronic device, characterized in that: include: A network model module, the network model module is used to deploy an automatic exposure model, the automatic exposure model includes: a feature extraction module, an exposure parameter calculation module and a confidence calculation module, wherein, when the automatic exposure model inputs an image to be exposed, the feature extraction module is used to extract image features of the image to be exposed, the exposure parameter calculation module is used to output automatic exposure parameters according to the image features, and the confidence calculation module is used to output the confidence value of the automatic exposure parameters according to the image features; An exposure module is used to expose the image to be exposed after verifying the credibility of the automatic exposure parameter according to the confidence value.

10. An electronic device, characterized in that: include: A memory for storing computer program instructions and a processor for executing the program instructions, wherein when the computer program instructions are executed by the processor, the electronic device executes the method according to any one of claims 1 to 8.

11. A computer-readable storage medium, characterized in that: The computer-readable storage medium includes a stored program, wherein when the program is executed, the device where the computer-readable storage medium is located is controlled to execute the method according to any one of claims 1 to 8.

Citation Information

Cited By

  • Video picture optimization method and device, equipment and medium

    CN121644889A