Deep learning image conversion model training method, device, equipment and medium

By training and adjusting the deep learning image conversion model, it solves the problems of traditional camera image processing error accumulation and large number of model parameters, realizes efficient conversion and offline deployment of RAW images to SRGB images, and improves the accuracy of image conversion and device adaptability. sex.

CN116095256BActive Publication Date: 2024-09-24SHENZHEN SKYWORTH DIGITAL TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202211723050.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-12-30
Publication Date
2024-09-24
Estimated Expiration
2042-12-30

AI Technical Summary

Technical Problem

Traditional cameras have serious error accumulation during image processing, resulting in blurry output images and lack of texture details. The image processing model based on deep learning has a large number of parameters and cannot be embedded in camera equipment, making it difficult to directly convert RAW images to SRGB images.

Method used

By obtaining the image data set and white balance value, train the deep learning image conversion model, use the preset image conversion model for evaluation and hyperparameter adjustment, build a lightweight image conversion model, and achieve efficient conversion of RAW images to SRGB images.

Benefits of technology

The color accuracy of the image conversion model is improved and the number of parameters is reduced, allowing the deep learning image conversion model to be deployed offline on camera equipment, solving the deployment problem caused by the large number of parameters.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116095256B
    Figure CN116095256B
Patent Text Reader

Abstract

The present application discloses a deep learning image conversion model training method, apparatus, equipment and medium, the deep learning image conversion model training method comprising: obtaining an image data set and a white balance value of a shooting device corresponding to the image data set; inputting the original RAW image in the image data set and the white balance value into a preset image conversion model to obtain a predicted output SRGB image; based on the label image in the test set data in the image data set and the predicted output SRGB image, determining whether the predicted output SRGB image meets a preset condition; if not, adjusting the hyperparameters of the preset image conversion model and training the preset image conversion model again; if so, terminating the training and obtaining a target image conversion model. The present application solves the technical problem that it is difficult to implement the conversion model of the original RAW image of the camera into the SRGB image conversion model through deep learning technology.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of image processing technology, and in particular to a deep learning image conversion model training method, device, equipment and medium. Background Art

[0002] Traditional cameras use photosensitive components to capture RAW (unprocessed) images and display SRGB (standard Red Green Blue) images on the screen. They need to go through a series of traditional image processing, namely ISP (Image Signal Processing) steps, such as de-mosaicing, white balance, color correction, tone mapping, denoising, sharpening, gamma correction, etc. Too many traditional image processing steps lead to serious error accumulation. The subsequent output images are always blurred and lack texture details. The current image processing models built based on deep learning are mainly based on deep learning end-to-end or two-stage joint adjustment algorithms, but the parameters of these algorithms are relatively large, reaching more than 100M. Due to the large number of parameters, they cannot meet the needs of being embedded in camera equipment and offline deployment, which makes it difficult to implement the conversion model of the camera's original RAW image directly into an SRGB image. Summary of the invention

[0003] The main purpose of this application is to provide a deep learning image conversion model training method, device, equipment and medium, aiming to solve the technical problem that it is difficult to implement the SRGB image conversion model directly converting the original RAW image of the camera.

[0004] To achieve the above objectives, the present application provides a deep learning image conversion model training method, the deep learning image conversion model training method comprising:

[0005] Acquire an image data set and a white balance value of a shooting device corresponding to the image data set;

[0006] Inputting the original RAW image in the training set data in the image data set and the white balance value into a preset image conversion model to obtain a predicted output SRGB image;

[0007] Based on the label image in the image data set and the predicted output SRGB image, by evaluating the preset image conversion model, determining whether the predicted output SRGB image of the preset image conversion model meets a preset condition;

[0008] If not, adjusting the hyperparameters of the preset image conversion model, and retraining the preset image conversion model based on the new image data set and the new white balance value;

[0009] If so, the training is terminated to obtain a target image conversion model trained by the preset image conversion model.

[0010] Optionally, before the step of acquiring the image data set and the white balance value of the shooting device corresponding to the image data set, the method further includes:

[0011] The image dataset is obtained by collecting four original RAW images with different exposure times corresponding to each target scene and corresponding SRGB images through a shooting device, wherein the shooting device includes three cameras with different shooting qualities, and the SRGB images are used as label images in the image dataset;

[0012] Image enhancement is performed on the collected multiple original images to obtain the image data set, wherein the image enhancement method includes at least one of rotation, shearing and color transformation.

[0013] Optionally, the preset image conversion model is composed of a preset number of mapping training modules, and the preset image conversion model is composed of an affine coupling layer and an attention mechanism module, wherein, in the mapping training module, the affine coupling layer is before the attention mechanism module, and the attention mechanism module is composed of a spatial attention module and a channel attention module.

[0014] Optionally, the step of evaluating the preset image conversion model based on the label image in the image data set and the predicted output SRGB image, and determining whether the predicted output SRGB image of the preset image conversion model meets a preset condition includes:

[0015] By using a preset loss function, a feature loss value between the predicted output SRGB image and the label image corresponding to the original RAW image is calculated;

[0016] If the feature loss value is greater than a preset threshold, the predicted output SRGB image does not meet the preset condition;

[0017] If the feature loss value is not greater than the preset threshold, the predicted output SRGB image meets the preset condition.

[0018] Optionally, the preset loss function consists of a mean square error loss function and a color loss function;

[0019] The step of calculating the feature loss value between the predicted output SRGB image and the label image corresponding to the original RAW image by using the preset loss function comprises:

[0020] Processing the label image in the image data set and the predicted output SRGB image by a mean square error loss function to obtain a mean square error loss value between the predicted output SRGB image and the label image corresponding to the original RAW image;

[0021] Gaussian blur is performed on the label image and the predicted output SRGB image, and the label image and the predicted output SRGB image after Gaussian blur are processed by a color loss function to obtain a color loss value between the predicted output SRGB image and the label image corresponding to the original RAW image;

[0022] A feature loss value between the predicted output SRGB image and the label image corresponding to the original RAW image is determined according to the mean square error loss weight, the color loss weight, the mean square error loss value, and the color loss value.

[0023] Optionally, the step of performing Gaussian blur on the label image and the predicted output SRGB image includes:

[0024] Extracting pixel values ​​of each pixel in the label image and the predicted output SRGB image, and performing Gaussian blurring on the label image and the predicted output SRGB image based on each pixel value and a two-dimensional Gaussian blur operator;

[0025] The two-dimensional Gaussian blur operator includes a first hyperparameter, a second hyperparameter and a third hyperparameter, and each of the hyperparameters is set by a model trainer according to requirements when training the model to perform model training.

[0026] Optionally, the hyperparameters include at least one of the number of hidden layers of the deep neural network of the target image conversion model, a learning rate, a regularization parameter, the number of neurons in each neural network, and the number of original RAW images input each time during the training process;

[0027] The step of adjusting the hyperparameters of the preset image conversion model and retraining the preset image conversion model based on the new image data set and the new white balance value includes:

[0028] Obtaining an evaluation result of the preset image conversion model, and adjusting each hyperparameter of the target image conversion model based on the evaluation result;

[0029] Based on the adjusted hyperparameters, the new image dataset, and the new white balance value, the adjusted preset image conversion model is retrained.

[0030] The present application also provides a deep learning image conversion model training device, which is applied to a deep learning image conversion model training device, and the deep learning image conversion model training device includes:

[0031] A data acquisition module, used to acquire an image data set and a white balance value of a shooting device corresponding to the image data set;

[0032] A model output module, used for inputting the original RAW image in the training set data in the image data set and the white balance value into a preset image conversion model to obtain a predicted output SRGB image;

[0033] A model testing module, configured to determine whether the predicted output SRGB image of the preset image conversion model meets a preset condition by evaluating the preset image conversion model based on the label image in the image data set and the predicted output SRGB image;

[0034] A model optimization module, used to adjust the hyperparameters of the preset image conversion model and retrain the preset image conversion model based on a new image data set and a new white balance value;

[0035] The model determination module is used to end the training and obtain a target image conversion model trained by the preset image conversion model.

[0036] Optionally, the model acquisition module is further used to:

[0037] The image dataset is obtained by collecting four original RAW images with different exposure times corresponding to each target scene and corresponding SRGB images through a shooting device, wherein the shooting device includes three cameras with different shooting qualities, and the SRGB images are used as label images in the image dataset;

[0038] The image data set is concentrated into different scene images captured by three different cameras, each scene image captured by the three cameras includes an original RAW image and a corresponding SRGB target image;

[0039] Image enhancement is performed on the collected multiple original images to obtain the image data set, wherein the image enhancement method includes at least one of rotation, shearing and color transformation.

[0040] Optionally, the model output module is further used for:

[0041] By using a preset loss function, a feature loss value between the predicted output SRGB image and the label image corresponding to the original RAW image is calculated;

[0042] If the feature loss value is greater than a preset threshold, the predicted output SRGB image does not meet the preset condition;

[0043] If the feature loss value is not greater than the preset threshold, the predicted output SRGB image meets the preset condition.

[0044] Optionally, the model output module is further used for:

[0045] Processing the label image in the image data set and the predicted output SRGB image by a mean square error loss function to obtain a mean square error loss value between the predicted output SRGB image and the label image corresponding to the original RAW image;

[0046] Gaussian blur is performed on the label image and the predicted output SRGB image, and the label image and the predicted output SRGB image after Gaussian blur are processed by a color loss function to obtain a color loss value between the predicted output SRGB image and the label image corresponding to the original RAW image;

[0047] A feature loss value between the predicted output SRGB image and the label image corresponding to the original RAW image is determined according to the mean square error loss weight, the color loss weight, the mean square error loss value, and the color loss value.

[0048] Optionally, the model output module is further used for:

[0049] Extracting pixel values ​​of each pixel in the label image and the predicted output SRGB image, and performing Gaussian blurring on the label image and the predicted output SRGB image based on each pixel value and a two-dimensional Gaussian blur operator;

[0050] The two-dimensional Gaussian blur operator includes a first hyperparameter, a second hyperparameter and a third hyperparameter, and each of the hyperparameters is set by a model trainer according to requirements when training the model to perform model training.

[0051] Optionally, the module optimization module is also used for:

[0052] Obtaining an evaluation result of the preset image conversion model, and adjusting each hyperparameter of the target image conversion model based on the evaluation result;

[0053] Based on the adjusted hyperparameters, the new image dataset, and the new white balance value, the adjusted preset image conversion model is retrained.

[0054] The present application also provides an electronic device, which is a physical device, and includes: a memory, a processor, and a program of the deep learning image conversion model training method stored in the memory and executable on the processor. When the program of the deep learning image conversion model training method is executed by the processor, the steps of the deep learning image conversion model training method as described above can be implemented.

[0055] The present application also provides a computer-readable storage medium, on which is stored a program for implementing a deep learning image conversion model training method. When the program of the deep learning image conversion model training method is executed by a processor, the steps of the deep learning image conversion model training method as described above are implemented.

[0056] The present application also provides a computer program product, including a computer program, which, when executed by a processor, implements the steps of the deep learning image conversion model training method as described above.

[0057] The present application provides a deep learning image conversion model training method, apparatus, device and medium, firstly obtaining an image data set and a white balance value of a shooting device corresponding to the image data set, then inputting the original RAW image in the training set data in the image data set and the white balance value into a preset image conversion model, obtaining a predicted output SRGB image, then based on the label image in the image data set and the predicted output SRGB image, by evaluating the preset image conversion model, it is determined whether the predicted output SRGB image of the preset image conversion model meets the preset conditions, if not, the hyperparameters of the preset image conversion model are adjusted, and based on the new image data, the predicted output SRGB image of the preset image conversion model is obtained. The preset image conversion model is trained again based on the set and the new white balance value. If yes, the training is terminated to obtain the target image conversion model trained by the preset image conversion model. The technical solution of the present application trains the image conversion model by collecting a large number of supervised image data sets and the white balance value of the shooting device, thereby enhancing the color accuracy of the image output by the image conversion model, thereby forming a lightweight deep learning image conversion model, thereby overcoming the technical defect that the image processing model constructed by deep learning has a large number of parameters and cannot be embedded in the camera device, and meets the demand for offline deployment of the target image conversion model on the camera device, so that the deep learning image conversion model can be successfully implemented. BRIEF DESCRIPTION OF THE DRAWINGS

[0058] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.

[0059] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

[0060] Figure 1 This is a flowchart of the first embodiment of the deep learning image conversion model training method of the present application;

[0061] Figure 2 This is the overall framework flow chart of RAW image conversion to SRGB image in the deep learning image conversion model training method of this application;

[0062] Figure 3 This is a flowchart of image acquisition and preprocessing in the deep learning image conversion model training method of this application;

[0063] Figure 4 This is a schematic diagram of the composition structure of the mapping training module in the deep learning image conversion model training method of this application;

[0064] Figure 5 This is a schematic diagram of the composition structure of the deep learning image conversion model training device of this application;

[0065] Figure 6 This is a schematic diagram of the device structure of the hardware operating environment involved in the deep learning image conversion model training method in the embodiment of the present application.

[0066] The purpose, features and advantages of this application will be further described in conjunction with the embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION

[0067] In order to make the above-mentioned purposes, features and advantages of the present application more obvious and understandable, the technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work belong to the scope of protection of this application.

[0068] Embodiment 1

[0069] Nowadays, traditional cameras use light-sensing components to capture raw images and display sRGB images on the screen normally. They need to go through a series of traditional ISP pip line steps, such as demosaicing, white balance, color correction, tone mapping, denoising, sharpening, gamma correction, etc., and the excessive number of traditional ISP pip line processing steps leads to serious error accumulation, and the subsequent output images are always blurred and lack texture details. In particular, the output images in scenes with insufficient lighting lose a lot of information. On the other hand, compared with SLR cameras, security-based surveillance cameras have a compact structure and a smaller integrated lens and sensor system, resulting in a poor signal-to-noise ratio (SNR) and other adverse physical effects on (unprocessed) images.

[0070] Therefore, deep learning technology has been continuously developed in this field and has become an important means to solve the above problems. Deep learning is mainly divided into supervised learning and unsupervised learning. It can solve the problem from end to end and avoid error accumulation caused by too many steps. So far, there has been some progress. It is usually collected by collecting unsupervised data from ground cameras and SLR cameras respectively, and cleverly designing unsupervised network models to learn the mapping relationship between low-end images and high-quality images, so as to solve the problem of poor shooting quality of low-end devices. In addition, by collecting the same data pairs, a supervised data set is formed to build a supervised training model structure to facilitate better training of network models. At present, it has applications in the conversion of raw images to SRGB images, dark light enhancement in the YUV domain, image quality enhancement, and color correction of high dynamic range imaging. Both supervised learning and unsupervised learning have their own advantages and disadvantages. For example, it is difficult to construct paired data for supervised learning, and the quality of unsupervised learning label data is very good, but it is difficult to train and optimize to an ideal state. It is also difficult to achieve an ideal state for end-to-end network model training. Therefore, in some technologies, two-stage and joint debugging are used to solve the problem of converting raw images to SRGB images. These methods also have the problem of too many parameters (greater than 400M), which results in a very slow image output speed and cannot be deployed on surveillance cameras. Moreover, due to the large memory, they cannot be embedded in the camera equipment, and offline deployment cannot be achieved, and ultimately they cannot be implemented. Therefore, this application designs a lightweight deep learning model (Flowsenet), which trains the network model by collecting a large amount of data sets, and then optimizes the model, which can eventually be deployed on offline camera equipment to achieve product implementation.

[0071] The present application embodiment provides a deep learning image conversion model training method. In the first embodiment of the deep learning image conversion model training method of the present application, refer to Figure 1, the deep learning image conversion model training method includes:

[0072] Step S10, obtaining an image data set and a white balance value of a shooting device corresponding to the image data set;

[0073] Step S20, inputting the original RAW image in the training set data in the image data set and the white balance value into a preset image conversion model to obtain a predicted output SRGB image;

[0074] Step S30, based on the label image in the image data set and the predicted output SRGB image, by evaluating the preset image conversion model, determining whether the predicted output SRGB image of the preset image conversion model meets a preset condition;

[0075] Step S40: if not, adjusting the hyperparameters of the preset image conversion model, and retraining the preset image conversion model based on the new image data set and the new white balance value;

[0076] Step S50: If yes, the training is terminated to obtain a target image conversion model trained by the preset image conversion model.

[0077] In the embodiment of the present application, it should be noted that the collected image data includes multiple groups of images of the target scene, including original RAW images and SRGB images, wherein the RAW images are unprocessed images collected by the camera device, and the SRGB images are processed, that is, images that can be displayed on the screen, and the trained target image conversion model is used to convert the input RAW images into corresponding SRGB images; the collected image data is a supervised data set, that is, including each RAW image as the original RAW image and the corresponding SRGB image as a label image; the white balance value of the shooting device is the wb value of the shooting device corresponding to each RAW image, which is used to make the trained target image conversion model more accurate and reduce the color deviation of the output image; in addition, compared with the prior art, the preset image conversion model of the embodiment of the present application also introduces a SE (Squeeze-and-Excitation, spatial attention and channel attention) module to improve the traditional image conversion model from RAW to SRGB, improve the accuracy of image conversion, reduce the number of parameters, so that the deep learning image conversion model can be deployed offline on the camera device.

[0078] As a preferred embodiment, in an embodiment of the present application, 36,000 images (3*4*3000) of 3,000 scenes are collected as a supervised data set to train and optimize the target image conversion model, wherein each original RAW image has a corresponding label image (SRGB image), and the collected image data are randomly divided into a training set, a test set, and a validation set in a ratio of 6:3:1, wherein the validation set is used to test the preset image conversion model during the training process to obtain the current state of the preset image conversion model.

[0079] As an example, step S10 to step S50 include: inputting the original RAW image in the training set data in each group of image data sets collected into a preset image conversion model to obtain a corresponding predicted output SRGB image, wherein the preset image conversion model (Flowsenet model) is composed of a preset number of mapping training modules, and the mapping training module is composed of an affine coupling layer and an attention mechanism module; inputting the original RAW image in the test set data in the image data set and the white balance value of the shooting device corresponding to the test set data into the preset image conversion model, and processing the original RAW image in the test set data in the image data and the white balance value of the shooting device corresponding to the test set data through the preset image conversion model to obtain a corresponding predicted output SRGB image; comparing each of the predicted output SRGB images with the corresponding label image in the test set data to obtain an evaluation result of the preset image conversion model; and judging the predicted output SRGB image of the preset image conversion model based on the evaluation result. whether the predicted output SRGB image of the preset image conversion model meets the preset conditions; if the predicted output SRGB image of the preset image conversion model meets the preset conditions, stop training the preset image conversion model; if the predicted output SRGB image of the preset image conversion model does not meet the preset conditions, adjust the hyperparameters of the preset image conversion model; rebuild the preset image conversion model based on the adjusted hyperparameters; return to execute step S20: input the original RAW image in the training set data in the image data set and the white balance value into the preset image conversion model to obtain a predicted output SRGB image, until the predicted output SRGB image of the preset image conversion model meets the preset conditions, stop training the preset image conversion model and set the preset image conversion model as the target image conversion model.

[0080] As a preference, in an embodiment of the present application, the preset number is 8, that is, the entire framework of the Flowsenet model consists of 8 mapping training modules.

[0081] In addition, before the step of acquiring the image data set and the white balance value of the shooting device corresponding to the image data set, the method further includes:

[0082] Step A10, collecting four original RAW images with different exposure times corresponding to each target scene and corresponding SRGB images by a shooting device to obtain the image data set, wherein the shooting device includes three cameras with different shooting qualities, and the SRGB images are used as label images in the image data set;

[0083] Step A20, performing image enhancement on the collected multiple original images to obtain the image data set, wherein the image enhancement method includes at least one of rotation, shearing and color transformation.

[0084] In the embodiment of the present application, it should be noted that the embodiment of the present application provides a method for collecting RAW (original RAW images) of different exposure times of each target scene through different camera devices and image preprocessing, so as to overcome the technical defects in the prior art that the photosensitive components of different models of cameras have different characteristics, and the network models trained with different data sets produce very poor raw image results for other models of cameras. Figure 2 In order to make the trained image conversion model more generalizable, the collected Bayer RAW image is first enhanced to obtain a Demosai ced RAW image, and then the Demosaiced RAW image is input into K mapping training modules for processing, and an SRGB image is input, and then the LOSS value of the SRGB image and the label image is obtained.

[0085] In addition, as an example, refer to Figure 3 In the image acquisition process, the embodiment of the present application uses three cameras with different shooting quality models (low, medium, and high) to collect images. Each camera sets four different exposure times to shoot the same scene. A total of 3,000 scenes and 36,000 images (3*4*3000) are collected to form a supervised data set, which is then input into the preset image conversion model for converting RAW images to SRGB.

[0086] As an example, steps A10 to A20 include: collecting RAW images and corresponding SRGB images of four different exposure times in each target scene through three cameras of different shooting quality models to obtain the image data set; grouping the images according to each of the RAW images and the corresponding SRGB images in the image data set, each group of images including the RAW images and the corresponding SRGB images; performing image enhancement on the RAW images in each of the groups of images, wherein the image enhancement includes at least rotation, shearing and color transformation to obtain the enhanced RAW images; dividing each group of images into a training set, a verification set and a test set, wherein the training set is used to train the preset image conversion model, the verification set is used to verify the training status of the preset image conversion model during the training process, and the test set is used to test the training results of the target conversion model to determine whether the predicted output SRGB image of the target conversion model meets the preset conditions.

[0087] In the embodiment of the present application, it should be noted that the embodiment of the present application provides a design method for a mapping training module, referring to Figure 4 , which specifically includes an affine coupling layer and a SE module, wherein the SE module is composed of a spatial attention module and a channel attention module. The SE module uses a fully connected layer and multiplicative feature fusion to assign a weight to each noise point in the denoising task, automatically remove low-weight noise points, retain high-weight noise points, improve network operation efficiency, reduce parameter calculation, and thus reduce the number of parameters of the deep learning image conversion model; in the process of constructing the preset image conversion model, machine learning library frameworks including Tensorflow (Google tensor flow graph) and Pytorch (an open source Python machine learning library) are used to build the model.

[0088] The step of evaluating the preset image conversion model based on the label image in the image data set and the predicted output SRGB image to determine whether the predicted output SRGB image of the preset image conversion model meets the preset conditions includes:

[0089] Step S31, calculating a feature loss value between the predicted output SRGB image and the label image corresponding to the original RAW image by using a preset loss function;

[0090] Step S32, if the feature loss value is greater than a preset threshold, the predicted output SRGB image does not meet the preset condition;

[0091] Step S33: If the feature loss value is not greater than the preset threshold, the predicted output SRGB image meets the preset condition.

[0092] In the embodiment of the present application, it should be noted that a model training method is provided in the embodiment of the present application, in which the wb (white balance) value of the shooting device corresponding to the original RAW image in the training set data is applied. Through this method, the trained target image conversion model is more accurate and the color deviation of the predicted output SRGB image is reduced; before training the preset image conversion model, the preset image conversion model is initialized first, and the values ​​of each hyperparameter in the preset image conversion model are obtained. The values ​​can be set according to the specific needs of the user, wherein the hyperparameters include at least the number of hidden layers of the deep neural network, the learning rate, the regularization parameter, the number of neurons in each neural network, and the number of original RAW images input each time during the training process.

[0093] As an example, step S31 to step S33 include: inputting the image-enhanced original RAW images in the training set data, the image-enhanced original RAW images in the validation set, and the wb value of the shooting device corresponding to each original RAW image into the preset image conversion model in batches to obtain an initial predicted output SRGB image, wherein the validation set is used to detect the training progress of the preset image conversion model during the training process; calculating the feature loss value between the predicted output SRGB image and the label image through a preset loss function, wherein the preset loss function is composed of an MSE loss function and a color loss function, and is used to analyze the mean square error loss and color loss of the predicted output SRGB image; by judging whether the feature loss value is greater than a preset threshold, judging whether the predicted output SRGB image meets the preset condition, so as to continuously iteratively train the preset image conversion model.

[0094] The step of calculating the feature loss value between the predicted output SRGB image and the label image corresponding to the original RAW image by using the preset loss function includes:

[0095] Step S121, processing the label image in the image data set and the predicted output SRGB image by a mean square error loss function to obtain a mean square error loss value between the predicted output SRGB image and the label image corresponding to the original RAW image;

[0096] Step S122, performing Gaussian blur on the label image and the predicted output SRGB image, and processing the label image after Gaussian blur and the predicted output SRGB image after Gaussian blur by a color loss function to obtain a color loss value between the predicted output SRGB image and the label image corresponding to the original RAW image;

[0097] Step S123, determining a feature loss value between the predicted output SRGB image and the label image corresponding to the original RAW image according to the mean square error loss weight, the color loss weight, the mean square error loss value, and the color loss value.

[0098] In the embodiment of the present application, it should be noted that the embodiment of the present application provides a method for designing a loss function (Loss). Specifically, the preset loss function is composed of a mean square error loss function (MSE) and a color loss function. The mean square error loss function is used to measure the difference between the output image of the image conversion model and the label image, and the color loss function is used to make the model output result and the real image closer and more realistic in color in addition to clear details.

[0099] As an example, steps S121 to S123 include: substituting the predicted output SRGB image and the label image into the formula of the mean square error loss function to obtain the mean square error loss value between the predicted output SRGB image and the label image corresponding to the original RAW image; obtaining each hyperparameter in the two-dimensional Gaussian blur operator and constructing a two-dimensional Gaussian blur operator; performing Gaussian blur on the label image and the predicted output SRGB image according to the two-dimensional Gaussian blur operator to obtain a Gaussian blurred label image and a Gaussian blurred predicted output SRGB image; substituting the Gaussian blurred label image and the Gaussian blurred predicted output SRGB image into the color loss function In the formula, the color loss value between the predicted output SRGB image and the label image corresponding to the original RAW image is obtained; the mean square error loss weight and the color loss weight are obtained to respectively characterize the proportion of the mean square error loss function and the color loss function in the preset loss function, and the sum of the mean square error loss weight and the color loss weight is 1; the product of the mean square error loss value and the mean square error loss weight is obtained to obtain the mean square error loss weight; the product of the color loss value and the color loss weight is obtained to obtain the color loss weight; the sum of the mean square error loss weight and the color loss weight is obtained to obtain the feature loss value between the predicted output SRGB image and the label image corresponding to the original RAW image.

[0100] As an example, the preset loss function can be expressed as: Loss=λLoss1+(1-λ)Loss2, wherein as a preferred embodiment, the value of λ can be 0.8, wherein Loss1 is the MSE loss function, and Loss2 is the color loss function.

[0101] Among them, the MSE loss function formula can be expressed as:

[0102]

[0103] Among them, I out Output SRGB image for initial prediction, I gt is the label image.

[0104] The color loss function formula can be expressed as:

[0105]

[0106] Among them, I b With Y b They represent the initial predicted output SRGB image and label image after Gaussian blur, respectively.

[0107] The step of performing Gaussian blurring on the label image and the predicted output SRGB image comprises:

[0108] Step C10, extracting the pixel value of each pixel in the label image and the predicted output SRGB image, and performing Gaussian blurring on the label image and the predicted output SRGB image based on each pixel value and a two-dimensional Gaussian blur operator;

[0109] Step C20, wherein the two-dimensional Gaussian blur operator includes a first hyperparameter, a second hyperparameter and a third hyperparameter, and each of the hyperparameters is set by the model trainer according to needs when training the model to perform model training.

[0110] As an example, steps C10 to C20 include: extracting the coordinate values ​​of each pixel point in the label image and the predicted output SRGB image; calculating the coordinate values ​​of 8 points around each pixel point according to the coordinate values ​​of each pixel point; determining the pixel value of each pixel point and the corresponding pixel value of the 8 points around each pixel point according to the coordinate values ​​of the 8 points around each pixel point; obtaining the first hyperparameter, the second hyperparameter and the third hyperparameter in the two-dimensional Gaussian blur operator, each of which is obtained through user input; constructing a two-dimensional Gaussian blur operator based on each hyperparameter; based on the pixel value of each pixel point and the corresponding pixel value of the 8 points around each pixel point, Gaussian blurring the label image and the predicted output SRGB image through a two-dimensional Gaussian blur operator to obtain the label image and the predicted output SRGB image after Gaussian blurring.

[0111] As an example, the formula for Gaussian blur can be expressed as:

[0112]

[0113] Among them, I b(x, y) is the pixel value of the initial predicted output SRGB image after Gaussian blur, i, j are the coordinates of each pixel, k and l are -1 or 1, then (i+k, j+l) represents the coordinates of the 8 pixels around the pixel (i, j), G(k, l) is a two-dimensional Gaussian blur operator, that is:

[0114]

[0115] Among them, A, u and δ are the first hyperparameter, the second hyperparameter and the third hyperparameter respectively, which can be set by the user according to actual needs. As a preferred embodiment, A=0.053, u=0, δ=3.

[0116] As another example, the step of evaluating the preset image conversion model based on the label image in the image data set and the predicted output SRGB image, and determining whether the predicted output SRGB image of the preset image conversion model meets the preset condition further includes:

[0117] Step D10, based on the label image in the test set data in the image data set, detecting a similarity value between the predicted output SRGB image and the label image, wherein the similarity value includes at least one of a peak signal-to-noise ratio, a structural similarity, and a learning-perceived image block similarity;

[0118] Step D20, determining whether the similarity value is not less than a preset threshold value, and if so, determining that the predicted output SRGB image of the preset image conversion model meets a preset condition;

[0119] Step D30: If not, it is determined that the predicted output SRGB image of the preset image conversion model does not meet the preset condition.

[0120] In the embodiments of the present application, it should be noted that the similarity value is used to measure the training results of the preset image conversion model to determine whether the preset image conversion model meets the preset conditions. The similarity value may include multiple measurement indicators, including Peak Signal to Noise Ratio (PSNR), Structural Similarity (SSIM), and Learned Perceptual Image Patch Similarity (LPIPS). The above indicators are all commonly used indicators for evaluating deep learning network models.

[0121] As an example, step D10 to step D30 include: based on the label image in the test set data in the image data, respectively calculating the peak signal-to-noise ratio, structural similarity and learning-perceptual image block similarity between the predicted output SRGB image and the corresponding label image, and obtaining the peak signal-to-noise ratio, structural similarity and learning-perceptual image block similarity between the predicted output SRGB image and the label image; obtaining user preset conditions, wherein the preset conditions only include the peak signal-to-noise ratio threshold, the structural similarity threshold and the learning-perceptual image block similarity threshold; judging whether the peak signal-to-noise ratio, structural similarity and learning-perceptual image block similarity between the predicted output SRGB image and the label image are not less than the peak signal-to-noise ratio threshold, the structural similarity threshold and the learning-perceptual image block similarity threshold in the preset conditions; if they are not less than, judging that the preset image conversion model meets the preset conditions; otherwise, judging that the preset image conversion model does not meet the preset conditions.

[0122] The step of adjusting the hyperparameters of the preset image conversion model and retraining the preset image conversion model based on a new image data set and a new white balance value includes:

[0123] Step S41, obtaining an evaluation result of the preset image conversion model, and adjusting each hyperparameter of the preset image conversion model based on the evaluation result;

[0124] Step S42: retraining the adjusted preset image conversion model based on the adjusted hyperparameters, the new image data set, and the new white balance value.

[0125] In the embodiment of the present application, it should be noted that the hyperparameters include at least one of the number of hidden layers of the deep neural network of the preset image conversion model, the learning rate, the regularization parameter, the number of neurons in each neural network, and the number of original RAW images input each time during the training process. The hyperparameters are necessary parameters for constructing the image conversion model. When the preset image conversion model is first constructed, the initial hyperparameters set by the user are obtained, and then after model training, the preset image conversion model is analyzed and evaluated to determine whether it is necessary to adjust the hyperparameters in the preset image conversion model. If so, reset the hyperparameters, reconstruct the preset image conversion model, and then perform model training again.

[0126] As an example, step S41 to step S42 include: obtaining an evaluation result of the preset image conversion model, wherein the evaluation result includes a similarity value between the predicted output SRGB image and the label image; based on various indicators in the evaluation result, determining to adjust various hyperparameters of the preset image conversion model to obtain the adjusted hyperparameters; based on the adjusted hyperparameters, a new image data set, and a new white balance value, constructing a preset image conversion model, and returning to execute step S20.

[0127] The present application embodiment provides a deep learning image conversion model training method, firstly obtains an image dataset and a white balance value of a shooting device corresponding to the image dataset, then inputs the original RAW image in the training set data in the image dataset and the white balance value into a preset image conversion model, obtains a predicted output SRGB image, then based on the label image in the image dataset and the predicted output SRGB image, by evaluating the preset image conversion model, it is determined whether the predicted output SRGB image of the preset image conversion model meets a preset condition, if not, the hyperparameters of the preset image conversion model are adjusted, and based on a new image dataset and a new The white balance value of the preset image conversion model is trained again. If yes, the training is terminated to obtain the target image conversion model trained by the preset image conversion model. The technical solution of the embodiment of the present application trains the image conversion model by collecting a large number of supervised image data sets and the white balance value of the shooting device, thereby enhancing the color accuracy of the image output by the image conversion model, thereby forming a lightweight deep learning image conversion model, thereby overcoming the technical defect that the image processing model constructed by deep learning has a large number of parameters and cannot be embedded in the camera device, and meets the demand for offline deployment of the target image conversion model on the camera device, so that the deep learning image conversion model can be successfully implemented.

[0128] Embodiment 2

[0129] The present application also provides a deep learning image conversion model training device, which is applied to a deep learning image conversion model training device, referring to Figure 5 , the deep learning image conversion model training device comprises:

[0130] A data acquisition module, used to acquire an image data set and a white balance value of a shooting device corresponding to the image data set;

[0131] A model output module, used for inputting the original RAW image in the training set data in the image data set and the white balance value into a preset image conversion model to obtain a predicted output SRGB image;

[0132] A model testing module, configured to determine whether the predicted output SRGB image of the preset image conversion model meets a preset condition by evaluating the preset image conversion model based on the label image in the image data set and the predicted output SRGB image;

[0133] A model optimization module, used to adjust the hyperparameters of a preset image conversion model and retrain the preset image conversion model based on a new image data set and a new white balance value;

[0134] The model determination module is used to end the training and obtain a target image conversion model trained by the preset image conversion model.

[0135] Optionally, the model acquisition module is further used for:

[0136] The image dataset is obtained by collecting four original RAW images with different exposure times corresponding to each target scene and corresponding SRGB images through a shooting device, wherein the shooting device includes three cameras with different shooting qualities, and the SRGB images are used as label images in the image dataset;

[0137] The image data set is concentrated into different scene images captured by three different cameras, each scene image captured by the three cameras includes an original RAW image and a corresponding SRGB target image;

[0138] Image enhancement is performed on the collected multiple original images to obtain the image data set, wherein the image enhancement method includes at least one of rotation, shearing and color transformation.

[0139] Optionally, the model output module is further used for:

[0140] The affine coupling layer and the attention mechanism module are combined to obtain a mapping training module, wherein in the mapping training module, the affine coupling layer is before the attention mechanism module, and the attention mechanism module is composed of a spatial attention module and a channel attention module;

[0141] A preset number of mapping training modules are combined to obtain the preset image conversion model.

[0142] Optionally, the model output module is further used for:

[0143] By using a preset loss function, a feature loss value between the predicted output SRGB image and the label image corresponding to the original RAW image is calculated;

[0144] If the feature loss value is greater than a preset threshold, the predicted output SRGB image does not meet the preset condition.

[0145] Optionally, the model output module is further used for:

[0146] Processing the label image in the image data set and the predicted output SRGB image by a mean square error loss function to obtain a mean square error loss value between the predicted output SRGB image and the label image corresponding to the original RAW image;

[0147] Gaussian blur is performed on the label image and the predicted output SRGB image, and the label image and the predicted output SRGB image after Gaussian blur are processed by a color loss function to obtain a color loss value between the predicted output SRGB image and the label image corresponding to the original RAW image;

[0148] A feature loss value between the predicted output SRGB image and the label image corresponding to the original RAW image is determined according to the mean square error loss weight, the color loss weight, the mean square error loss value, and the color loss value.

[0149] Optionally, the model output module is further used for:

[0150] Extracting pixel values ​​of each pixel in the label image and the predicted output SRGB image, and performing Gaussian blurring on the label image and the predicted output SRGB image based on each pixel value and a two-dimensional Gaussian blur operator;

[0151] The two-dimensional Gaussian blur operator includes a first hyperparameter, a second hyperparameter and a third hyperparameter, and each of the hyperparameters is set by a model trainer according to requirements when training the model to perform model training.

[0152] Optionally, the model testing module is further used to:

[0153] Based on the label image in the test set data in the image data set, detecting a similarity value between the predicted output SRGB image and the label image, wherein the similarity value includes at least one of a peak signal-to-noise ratio, a structural similarity, and a learning-perceived image block similarity;

[0154] Determine whether the similarity value is not less than a preset threshold value, and if so, determine that the predicted output SRGB image of the target image conversion model meets a preset condition;

[0155] If not, it is determined that the predicted output SRGB image of the target image conversion model does not meet the preset condition.

[0156] Optionally, the module optimization module is also used for:

[0157] Obtaining an evaluation result of the preset image conversion model, and adjusting each hyperparameter of the target image conversion model based on the evaluation result;

[0158] Based on the adjusted hyperparameters, the new image dataset, and the new white balance value, the adjusted preset image conversion model is retrained.

[0159] The deep learning image conversion model training device provided in the present application adopts the deep learning image conversion model training method in the above-mentioned embodiment, which solves the technical problem that it is difficult to implement the SRGB image conversion model directly converting the original RAW image of the camera. Compared with the prior art, the beneficial effects of the deep learning image conversion model training device provided in the embodiment of the present application are the same as the beneficial effects of the deep learning image conversion model training method provided in the above-mentioned embodiment, and the other technical features in the deep learning image conversion model training device are the same as the features disclosed in the method of the previous embodiment, which will not be repeated here.

[0160] Embodiment 3

[0161] An embodiment of the present application provides an electronic device, which includes: at least one processor; and a memory communicatively linked to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the deep learning image conversion model training method in the above-mentioned embodiment one.

[0162] Reference below Figure 6 , which shows a schematic diagram of the structure of an electronic device suitable for implementing the embodiments of the present disclosure. The electronic device in the embodiments of the present disclosure may include, but is not limited to, mobile terminals such as mobile phones, notebook computers, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablet computers), PMPs (portable multimedia players), vehicle-mounted terminals (such as vehicle-mounted navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Figure 6 The electronic device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.

[0163] like Figure 6 As shown, the electronic device may include a processing device (e.g., a central processing unit, a graphics processing unit, etc.), which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) or a program loaded from a storage device into a random access memory (RAM). In the RAM, various programs and data required for the operation of the electronic device are also stored. The processing device, ROM, and RAM are connected to each other via a bus. An input / output (I / O) interface is also linked to the bus.

[0164] Typically, the following systems can be linked to the I / O interface: input devices including, for example, a touch screen, a touchpad, a keyboard, a mouse, an image sensor, a microphone, an accelerometer, a gyroscope, etc.; output devices including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; storage devices including, for example, a magnetic tape, a hard disk, etc.; and communication devices. The communication device can allow the electronic device to communicate with other devices wirelessly or by wire to exchange data. Although the figure shows an electronic device with various systems, it should be understood that it is not required to implement or have all the systems shown. More or fewer systems may be implemented or have alternatively.

[0165] In particular, according to an embodiment of the present disclosure, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present disclosure includes a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program contains a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through a communication device, or installed from a storage device, or installed from a ROM. When the computer program is executed by a processing device, the above-mentioned functions defined in the method of the embodiment of the present disclosure are executed.

[0166] The electronic device provided by the present application adopts the deep learning image conversion model training method in the above embodiment to solve the technical problem that it is difficult to implement the SRGB image conversion model directly converting the original RAW image of the camera. Compared with the prior art, the beneficial effects of the electronic device provided by the embodiment of the present application are the same as the beneficial effects of the deep learning image conversion model training method provided by the above embodiment 1, and the other technical features in the electronic device are the same as the features disclosed in the method of the previous embodiment, which will not be repeated here.

[0167] It should be understood that the various parts of the present disclosure can be implemented with hardware, software, firmware or a combination thereof. In the description of the above embodiments, specific features, structures, materials or characteristics can be combined in any one or more embodiments or examples in a suitable manner.

[0168] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.

[0169] Embodiment 4

[0170] This embodiment provides a computer-readable storage medium having computer-readable program instructions stored thereon, and the computer-readable program instructions are used to execute the method for deep learning image conversion model training in the above-mentioned embodiment one.

[0171] The computer-readable storage medium provided in the embodiment of the present application can be, for example, a USB flash drive, but is not limited to electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, systems or devices, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical link with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present embodiment, the computer-readable storage medium can be any tangible medium containing or storing a program, which can be used by an instruction execution system, a system or a device or used in combination with it. The program code contained on the computer-readable storage medium can be transmitted with any appropriate medium, including but not limited to: wires, optical cables, RF (radio frequency), etc., or any suitable combination of the above.

[0172] The computer-readable storage medium may be included in the electronic device, or may exist independently without being installed in the electronic device.

[0173] The computer-readable storage medium carries one or more programs. When the one or more programs are executed by an electronic device, the electronic device: obtains an image data set and a white balance value of a shooting device corresponding to the image data set; inputs the original RAW image in the test set data in the image data set and the white balance value of the shooting device corresponding to the test set data into the target image conversion model to obtain a predicted output SRGB image; based on the label image in the image data set and the predicted output SRGB image, by evaluating the preset image conversion model, it is determined whether the predicted output SRGB image of the preset image conversion model meets the preset conditions; if not, the hyperparameters of the target image conversion model are adjusted, and the target image conversion model is trained again based on the training set data in the collected image data set, the white balance value of the shooting device corresponding to the training set data, and a preset loss function, until the predicted output SRGB image output by the target image conversion model meets the preset conditions. Computer program code for performing the operations of the present disclosure may be written in one or more programming languages ​​or a combination thereof, including object-oriented programming languages, such as Java, Smalltalk, C++, and conventional procedural programming languages, such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving a remote computer, the remote computer may be linked to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be linked to an external computer (e.g., via the Internet using an Internet service provider).

[0174] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present application. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0175] The modules involved in the embodiments described in the present disclosure may be implemented by software or hardware, wherein the name of the module does not limit the unit itself in some cases.

[0176] The computer-readable storage medium provided by the present application stores computer-readable program instructions for executing the above-mentioned deep learning image conversion model training method, which solves the technical problem that it is difficult to implement the SRGB image conversion model directly converting the original RAW image of the camera. Compared with the prior art, the beneficial effects of the computer-readable storage medium provided by the embodiment of the present application are the same as the beneficial effects of the deep learning image conversion model training method provided by the above-mentioned embodiment, and will not be repeated here.

[0177] Embodiment 5

[0178] The present application also provides a computer program product, including a computer program, which, when executed by a processor, implements the steps of the deep learning image conversion model training method as described above.

[0179] The computer program product provided by this application solves the technical problem that it is difficult to implement the SRGB image conversion model that directly converts the original RAW image of the camera. Compared with the prior art, the beneficial effects of the computer program product provided by the embodiment of this application are the same as the beneficial effects of the deep learning image conversion model training method provided by the above embodiment, which will not be repeated here.

[0180] The above are only preferred embodiments of the present application, and are not intended to limit the patent scope of the present application. Any equivalent structure or equivalent process transformation made using the contents of the present application specification and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent processing scope of the present application.

Claims

1. A deep learning image conversion model training method, characterized in that: The deep learning image conversion model training method comprises: Acquire an image data set and a white balance value of a shooting device corresponding to the image data set; Inputting the original RAW image in the training set data in the image data set and the white balance value into a preset image conversion model to obtain a predicted output SRGB image, wherein the preset image conversion model is composed of a preset number of mapping training modules, and the mapping training module is composed of an affine coupling layer and an attention mechanism module, wherein in the mapping training module, the affine coupling layer is before the attention mechanism module, and the attention mechanism module is composed of a spatial attention module and a channel attention module; Based on the label image in the image data set and the predicted output SRGB image, the preset image conversion model is evaluated to determine whether the predicted output SRGB image of the preset image conversion model meets a preset condition; If not, adjusting the hyperparameters of the preset image conversion model, and retraining the preset image conversion model based on the new image data set and the new white balance value; If so, the training is terminated to obtain a target image conversion model trained by the preset image conversion model.

2. The deep learning image conversion model training method according to claim 1, characterized in that: Before the step of acquiring the image data set and the white balance value of the shooting device corresponding to the image data set, the method further includes: Collecting four original RAW images with different exposure times corresponding to each target scene and corresponding SRGB images by a shooting device to obtain multiple original images, wherein the shooting device includes three cameras with different shooting qualities, and the SRGB images are used as label images in the image data set; Image enhancement is performed on the collected multiple original images to obtain the image data set, wherein the image enhancement method includes at least one of rotation, shearing and color transformation.

3. The deep learning image conversion model training method according to claim 1, characterized in that: The step of evaluating the preset image conversion model based on the label image in the image data set and the predicted output SRGB image, and determining whether the predicted output SRGB image of the preset image conversion model meets the preset condition comprises: By using a preset loss function, a feature loss value between the predicted output SRGB image and the label image corresponding to the original RAW image is calculated; If the feature loss value is greater than a preset threshold, the predicted output SRGB image does not meet the preset condition; If the feature loss value is not greater than the preset threshold, the predicted output SRGB image meets the preset condition.

4. The deep learning image conversion model training method as claimed in claim 3, characterized in that: The preset loss function consists of a mean square error loss function and a color loss function; The step of calculating the feature loss value between the predicted output SRGB image and the label image corresponding to the original RAW image by using a preset loss function comprises: Processing the label image in the image data set and the predicted output SRGB image by a mean square error loss function to obtain a mean square error loss value between the predicted output SRGB image and the label image corresponding to the original RAW image; Gaussian blur is performed on the label image and the predicted output SRGB image, and the label image and the predicted output SRGB image after Gaussian blur are processed by a color loss function to obtain a color loss value between the predicted output SRGB image and the label image corresponding to the original RAW image; A feature loss value between the predicted output SRGB image and the label image corresponding to the original RAW image is determined according to the mean square error loss weight, the color loss weight, the mean square error loss value, and the color loss value.

5. The deep learning image conversion model training method according to claim 4, characterized in that: The step of performing Gaussian blurring on the label image and the predicted output SRGB image comprises: Extracting pixel values ​​of each pixel in the label image and the predicted output SRGB image, and performing Gaussian blurring on the label image and the predicted output SRGB image based on each pixel value and a two-dimensional Gaussian blur operator; The two-dimensional Gaussian blur operator includes a first hyperparameter, a second hyperparameter and a third hyperparameter, and each of the hyperparameters is set by a model trainer according to requirements when training the model to perform model training.

6. The deep learning image conversion model training method according to claim 1, characterized in that: The hyperparameters include at least one of the number of hidden layers of the deep neural network of the target image conversion model, a learning rate, a regularization parameter, the number of neurons in each neural network, and the number of original RAW images input each time during the training process; The step of adjusting the hyperparameters of the preset image conversion model and retraining the preset image conversion model based on the new image data set and the new white balance value includes: Obtaining an evaluation result of the preset image conversion model, and adjusting each hyperparameter of the target image conversion model based on the evaluation result; Based on the adjusted hyperparameters, the new image dataset, and the new white balance value, the adjusted preset image conversion model is retrained.

7. A deep learning image conversion model training device, characterized in that: The deep learning image conversion model training device comprises: A data acquisition module, used to acquire an image data set and a white balance value of a shooting device corresponding to the image data set; A model output module, used for inputting the original RAW image in the training set data in the image data set and the white balance value into a preset image conversion model to obtain a predicted output SRGB image, wherein the preset image conversion model is composed of a preset number of mapping training modules, and the mapping training module is composed of an affine coupling layer and an attention mechanism module, wherein in the mapping training module, the affine coupling layer is before the attention mechanism module, and the attention mechanism module is composed of a spatial attention module and a channel attention module; A model testing module, configured to determine whether the predicted output SRGB image of the preset image conversion model meets a preset condition by evaluating the preset image conversion model based on the label image in the image data set and the predicted output SRGB image; A model optimization module, used to adjust the hyperparameters of the preset image conversion model and retrain the preset image conversion model based on a new image data set and a new white balance value; The model determination module is used to end the training and obtain the target image conversion model trained by the preset image conversion model.

8. An electronic device, characterized in that: The electronic device comprises: At least one processor; and a memory communicatively linked to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor so that the at least one processor can perform the steps of the deep learning image conversion model training method described in any one of claims 1 to 6.

9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a program for implementing a deep learning image conversion model training method, and the program for implementing a deep learning image conversion model training method is executed by a processor to implement the steps of the deep learning image conversion model training method as described in any one of claims 1 to 6.