An integrated learning method in image restoration
By integrating multiple models and optimizing weight allocation using the EM algorithm, combined with real-time brightness detection, the problems of flexibility and high computational resource consumption in image restoration are solved, achieving efficient and stable image restoration results.
Patent Information
- Application Number
- CN202411452503.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-17
- Publication Date
- 2025-12-05
- Estimated Expiration
- 2044-10-17
AI Technical Summary
Existing image restoration methods lack flexibility and plug-and-play convenience, resulting in poor generalization of restoration results and high computational resource consumption. Traditional ensemble methods are not effective in image restoration.
By employing multi-model ensemble and the EM algorithm, weight allocation is optimized through long vector transformation, bucket set partitioning, and Gaussian mixture model. Combined with real-time brightness fluctuation detection and adjustment mechanism, a Gaussian mixture model is formed and stored in a lookup table.
It improves the robustness and accuracy of image restoration, adapts to complex lighting changes, reduces brightness distortion, enhances image quality, and has good scalability and easy optimization potential.
Smart Images

Figure CN119671900B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of image processing model training technology, and in particular to an ensemble learning method for image restoration. Background Technology
[0002] Image restoration has made significant progress over the past few decades, especially with the rise of deep learning. Researchers have developed numerous architectures to address the image restoration problem, including convolutional neural networks (CNNs), visual transformers (ViTs), and more recently, visual state-space models (Mamba). However, a single model with different architectures or randomly initialized states can deviate from the baseline real image during prediction, leading to suboptimal restoration results. To address this issue, ensemble learning, a traditional yet influential machine learning technique, has been applied to image restoration. It aims to improve the generalization and robustness of ensemble results by combining multiple base models. However, most ensemble methods in image restoration focus on ensemble learning during the training phase, which requires determining the ensemble strategy while training multiple models, sacrificing the flexibility and plug-and-play convenience of model replacement. The image restoration industry has an urgent need for advanced post-trained ensemble methods; however, due to the lack of such a method, researchers still tend to use averaging as the primary choice for post-trained ensemble methods.
[0003] Despite this industrial demand, post-trained ensembles in image restoration remain challenging for traditional ensemble algorithms originally designed for classification or regression problems. Unlike classification and regression, image restoration produces predictions that are matrices, where each pixel is correlated with every other pixel, with values ranging from 0 to 255. Therefore, traditional methods like bagging and boosting (such as AdaBoost) either require enormous computational resources for restoration tasks or fail to generalize well due to an imbalance between the number of candidate results and the feature dimension. As an alternative, Jiang et al. proposed a super-resolution post-trained ensemble algorithm, ReFESR, which solves a maximum a posteriori problem with reconstruction constraints through optimization. However, this constraint requires an explicit representation of the degradation process, which is unknown for restoration tasks beyond super-resolution; it also requires prior knowledge of the performance of the base model, further limiting its practicality. Due to these problems with traditional and recent ensemble methods, researchers in image restoration tend to favor weighted averaging as the primary ensemble approach. Summary of the Invention
[0004] To address this, the present invention provides an ensemble learning method for image restoration, which overcomes the problems of poor generalization of restoration results and high computational resource consumption caused by the lack of flexibility and plug-and-play convenience of existing post-training ensemble methods.
[0005] To achieve the above objectives, the present invention provides an ensemble learning method for image restoration, comprising:
[0006] Collect real-time images of the monitoring points of the target task;
[0007] Several restored images are generated by predicting all real-time images within a preset prediction time using several preset restoration models.
[0008] Determine the several long vectors for all restored images corresponding to each preset restoration model;
[0009] The long vector is divided into several buckets of the same width according to the preset bucket width, and several bucket sets with mutually exclusive ranges are formed according to the number of buckets and the preset number.
[0010] The weights of the model to be constructed are determined based on the bucket set and the preset EM algorithm.
[0011] The weights are integrated into an integrated weight and stored in a preset lookup table to form several Gaussian mixture models;
[0012] The brightness fluctuation value is determined based on the real-time brightness of all real-time images within the preset adjustment time after forming several Gaussian mixture models. The preset prediction time is then adjusted based on the brightness fluctuation value until the brightness fluctuation value is less than the preset fluctuation value.
[0013] Further, the step of determining the brightness fluctuation value based on the real-time brightness of all real-time images within the preset adjustment time after forming several Gaussian mixture models includes:
[0014] The real-time brightness of the real-time image is extracted, and the standard deviation of the real-time brightness is calculated to form the brightness fluctuation value.
[0015] Further, the step of adjusting the preset prediction duration based on the brightness fluctuation value until the brightness fluctuation value is less than the preset fluctuation value includes:
[0016] When the brightness fluctuation value is greater than the preset standard brightness fluctuation value, the preset prediction duration is adjusted according to the brightness fluctuation value, the preset standard brightness fluctuation value, and the preset adjustment coefficient until the brightness fluctuation value is less than the preset fluctuation value.
[0017] Furthermore, the determination of several weights for the model to be constructed based on the bucket set and the preset EM algorithm includes:
[0018] Mask mapping is performed on each of the bucket sets to obtain a number of filtered pixels, forming a number of short vectors. The weights of the model to be constructed are estimated based on the short vectors and a preset EM algorithm to form a number of weights.
[0019] Furthermore, estimating the weights of the model to be constructed based on the short vector and the preset EM algorithm includes:
[0020] The reference real image pixels corresponding to the short vectors are used as sample points for the model to be constructed and the preset EM algorithm. The mean and variance of each short vector are calculated to obtain the short vector mean and short vector variance. The weights of the model to be constructed are estimated based on the sample points, the short vector mean, the short vector variance and the preset EM algorithm.
[0021] Further, estimating the weights of the model to be constructed based on sample points, short vector mean, short vector variance, and a preset EM algorithm includes:
[0022] The mean of the short vector is assigned to the mean of a Gaussian distribution, and the variance of the short vector is assigned to the variance of a Gaussian distribution;
[0023] In step E, the posterior probability of each sample point belonging to each Gaussian component is calculated, and the weights of the Gaussian components are updated based on all posterior probabilities to form updated weights.
[0024] In step M, the mean and variance of each Gaussian component are recalculated based on the updated weights to form updated mean and updated variance;
[0025] The weights of each Gaussian component are updated based on the updated mean and the updated variance until convergence or the maximum number of steps is reached.
[0026] Furthermore, determining the plurality of long vectors from all restored images corresponding to each preset restoration model includes:
[0027] All the restored images corresponding to each preset restoration model are flattened and stitched together into a long vector to form the aforementioned long vectors.
[0028] Furthermore, dividing the long vector into several buckets of equal width according to the preset bucket width includes:
[0029] The number of buckets is obtained by calculating the ratio of the pixel value range of the long vector to the preset bucket width.
[0030] Furthermore, the step of forming several mutually exclusive bucket sets based on the number of buckets and the preset number includes:
[0031] Calculate the number of buckets raised to the power of the preset number to obtain the number of bucket sets. Divide the buckets according to the number of bucket sets to form bucket sets with mutually exclusive ranges of bucket set numbers.
[0032] Furthermore, the step of integrating the weights into integrated weights and storing them in a preset lookup table to form several Gaussian mixture models includes:
[0033] All the weights are then combined into an integrated weight vector by weighted summation.
[0034] The integrated weight vector is normalized to form a normalized integrated weight vector;
[0035] The normalized integrated weight vector, the Gaussian distribution mean, and the Gaussian distribution variance are stored in a preset lookup table to form several Gaussian mixture models.
[0036] Compared with existing technologies, the advantages of this invention are that by introducing multi-model ensemble and EM algorithm, the image restoration process becomes more robust and accurate. By performing long vector transformation and bucket partitioning on the restored image, the full utilization of data at different scales is ensured. Furthermore, the weight allocation of each model is effectively optimized by using Gaussian mixture model, improving the detail restoration of the restored image. At the same time, the real-time brightness fluctuation detection and adjustment mechanism enables the system to adaptively adjust the prediction time, effectively cope with complex lighting change scenarios, reduce brightness distortion of the restored image, and improve the overall image quality. By integrating and storing the weights in a lookup table, this method also has good scalability and convenient subsequent optimization potential, effectively solving the problems of poor generalization of restoration results and high computational resource consumption caused by the lack of flexibility and plug-and-play convenience of post-training ensemble methods.
[0037] Furthermore, by masking the bucket set and obtaining effective filtered pixels, it can be ensured that the resulting short vector is representative, thereby improving the accuracy of the model's weight estimation.
[0038] Furthermore, by calculating the mean and variance of short vectors, the statistical characteristics of image data can be better captured, thus improving the accuracy of image restoration.
[0039] Furthermore, through this iterative process, the model to be built can gradually approach the optimal weight distribution, making the model's image restoration more accurate and stable.
[0040] Furthermore, by calculating the brightness fluctuation value of the real-time image, the system can dynamically monitor the impact of illumination changes, reduce fluctuations caused by illumination changes, and make the restored image quality more stable and consistent.
[0041] Furthermore, by dynamically adjusting the prediction duration, this method can adapt to changes in lighting conditions, ensuring that the image restoration model maintains high restoration accuracy even under conditions of large lighting fluctuations.
[0042] Furthermore, by concatenating the images into a long vector, information from multiple restored images can be effectively integrated, thereby improving data availability and processing efficiency in subsequent processing.
[0043] Furthermore, this method can effectively divide long vector data into multiple buckets of the same width, ensuring that each bucket contains pixel values within a similar range.
[0044] Furthermore, the mutually exclusive design improves the accuracy of data classification, enabling subsequent model processing to more effectively identify and utilize the features of different data segments.
[0045] Furthermore, the Gaussian mixture model generated by integrating the weights into an integrated weight vector can effectively represent different features in the image restoration process. Attached Figure Description
[0046] Figure 1 This is a flowchart of the ensemble learning method in image restoration in this embodiment;
[0047] Figure 2 This is a flowchart of the preset EM algorithm in this embodiment;
[0048] Figure 3 This embodiment provides a logic diagram for adjusting the preset prediction duration.
[0049] Figure 4 This is a flowchart illustrating the formation of several Gaussian mixture models for this embodiment. Detailed Implementation
[0050] To make the objectives and advantages of the present invention clearer, the present invention will be further described below with reference to embodiments; it should be understood that the specific embodiments described herein are merely for explaining the present invention and are not intended to limit the present invention.
[0051] Preferred embodiments of the present invention will now be described with reference to the accompanying drawings. Those skilled in the art should understand that these embodiments are merely illustrative of the technical principles of the present invention and are not intended to limit the scope of protection of the present invention.
[0052] It should be noted that in the description of this invention, the terms "upper", "lower", "left", "right", "inner", "outer", etc., which indicate directions or positional relationships, are based on the directions or positional relationships shown in the accompanying drawings. This is only for the convenience of description and is not intended to indicate or imply that the device or element must have a specific orientation, or be constructed and operated in a specific orientation. Therefore, it should not be construed as a limitation of this invention.
[0053] Furthermore, it should be noted that, in the description of this invention, unless otherwise explicitly specified and limited, the terms "installation," "connection," and "linking" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; and they can refer to the internal connection of two components. Those skilled in the art can understand the specific meaning of the above terms in this invention according to the specific circumstances.
[0054] Please see Figure 1 As shown, it is a flowchart of the ensemble learning method in image restoration in this embodiment;
[0055] This embodiment provides an ensemble learning method for image restoration, including:
[0056] Collect real-time images of the monitoring points of the target task;
[0057] Several restored images are generated by predicting all real-time images within a preset prediction time using several preset restoration models.
[0058] Determine the several long vectors for all restored images corresponding to each preset restoration model;
[0059] The long vector is divided into several buckets of the same width according to the preset bucket width, and several bucket sets with mutually exclusive ranges are formed according to the number of buckets and the preset number.
[0060] The weights of the model to be constructed are determined based on the bucket set and the preset EM algorithm.
[0061] The weights are integrated into an integrated weight and stored in a preset lookup table to form several Gaussian mixture models;
[0062] The brightness fluctuation value is determined based on the real-time brightness of all real-time images within the preset adjustment time after forming several Gaussian mixture models. The preset prediction time is then adjusted based on the brightness fluctuation value until the brightness fluctuation value is less than the preset fluctuation value.
[0063] The preset prediction duration refers to the time range for image restoration or prediction. It depends on the image acquisition frequency, processing speed, and the real-time requirements of the target application. It is usually set to 1 to 10 seconds, and in this embodiment, it is set to 5 seconds. A moderate prediction duration helps to acquire sufficient image data while ensuring the real-time performance of the system, which helps to better capture dynamic changes.
[0064] The target task includes, but is not limited to, deblurring and super-resolution image restoration tasks.
[0065] Preset restoration models refer to specific algorithms or techniques used in the image restoration process. These models are designed to process input real-time image data, extract features, remove noise, or reconstruct missing image information. Common image restoration models include convolutional neural networks (CNNs), sparse coding models, non-local means (NLM) methods, and wavelet transforms. The choice of model typically depends on the characteristics of the image (such as resolution and noise type), the restoration objective (such as denoising, super-resolution, or completion), and the available computational resources and real-time requirements. The selected model should be matched to the application scenario to effectively improve image quality. In practice, the number of preset restoration models is usually three to five to ensure diversity and effectiveness. In this embodiment, four preset restoration models are set: convolutional neural networks (CNNs), sparse coding models, non-local means (NLM), and wavelet transform models. The advantage of selecting multiple image restoration models is that the advantages of different models in specific situations can be fully utilized.
[0066] The preset bucket width is the width of each bucket when dividing a long vector into buckets. It depends on the data distribution range and feature scale. It is typically set to 1 / 10 to 1 / 20 of the data range. In this embodiment, it is set to 1 / 15 of the data range. A reasonable bucket width helps ensure a uniform distribution of data, avoiding data sparsity or excessive density, thereby improving the model's training performance.
[0067] A pre-defined lookup table is used to store and quickly retrieve calculated weights or parameters. Its size depends on model complexity and computational efficiency requirements. The size of the lookup table is typically determined by the number of weights and the complexity of the model. In this embodiment, it is set to store the weight information for 10 models, which significantly improves the efficiency of subsequent calculations, avoids redundant calculations, and enhances real-time performance.
[0068] The preset fluctuation value is a threshold used to judge brightness fluctuations. It depends on the characteristics of the image data and the degree of brightness change in the application scenario. It is typically set to a standard deviation of 0.05 to 0.1. In this embodiment, it is set to a standard deviation of 0.08. A reasonable fluctuation value can effectively monitor brightness changes and ensure image restoration quality.
[0069] First, real-time images of the monitoring points are acquired, and multiple preset restoration models are used to predict the images within a specified time period, generating several restored images. These restored images are then converted into long vectors, divided into buckets of preset width, and the model weights are estimated based on these buckets and the EM algorithm. The weights are then weighted and integrated and stored in a lookup table, forming multiple Gaussian mixture models. Finally, the prediction duration is adjusted by detecting brightness fluctuations in the real-time images until the brightness fluctuations are less than a preset value.
[0070] By introducing multi-model ensemble and the EM algorithm, the image restoration process becomes more robust and accurate. By performing long vector transformation and bucket partitioning on the restored image, the system ensures full utilization of data at different scales. Gaussian mixture model is used to effectively optimize the weight allocation of each model, improving the detail restoration of the restored image. At the same time, the real-time brightness fluctuation detection and adjustment mechanism enables the system to adaptively adjust the prediction time, effectively dealing with complex lighting change scenarios, reducing brightness distortion of the restored image, and improving the overall image quality. By integrating and storing the weights in a lookup table, this method also has good scalability and convenient subsequent optimization potential, effectively solving the problems of poor generalization of restoration results and high computational resource consumption caused by the lack of flexibility and plug-and-play convenience of post-trained ensemble methods.
[0071] Specifically, determining several weights for the model to be constructed based on the bucket set and the preset EM algorithm includes:
[0072] Mask mapping is performed on each of the bucket sets to obtain a number of filtered pixels, forming a number of short vectors. The weights of the model to be constructed are estimated based on the short vectors and a preset EM algorithm to form a number of weights.
[0073] Masking is an image processing technique that selectively manipulates certain pixels by applying a mask (usually a binary value or a Boolean matrix) to each pixel, while ignoring other pixels that do not require processing. Masking can divide complex images into multiple regions of interest or select specific pixels for further processing. In this embodiment, masking filters pixels within a bucket set to obtain several pixels of interest, forming a predetermined number of short vectors. The masking process selects pixels based on certain rules or conditions (such as pixel brightness, color, and position), reducing computational burden and allowing subsequent model estimation and weight calculation to be performed only on key pixels.
[0074] In this image restoration method, the bucket sets are first masked to filter out the valid pixels corresponding to each bucket set. These pixels are then analyzed to form short vectors matching a preset number. Subsequently, these short vectors are combined with a preset EM algorithm to estimate the weights of the model to be constructed, ultimately obtaining several weights. These weights will be used for the subsequent construction and optimization of the image restoration model, ensuring that the model can effectively process image data.
[0075] By masking the bucket set and obtaining effective filtered pixels, the resulting short vector can be made representative, thereby improving the accuracy of the model's weight estimation.
[0076] Specifically, estimating the weights of the model to be constructed based on short vectors and a preset EM algorithm includes:
[0077] The reference real image pixels corresponding to the short vectors are used as sample points for the model to be constructed and the preset EM algorithm. The mean and variance of each short vector are calculated to obtain the short vector mean and short vector variance. The weights of the model to be constructed are estimated based on the sample points, the short vector mean, the short vector variance and the preset EM algorithm.
[0078] Reference true image pixels refer to the true color or intensity value of each pixel in a standard image used as a reference or comparison during image restoration or reconstruction. These pixels typically represent image features under ideal conditions and are used to evaluate and guide the performance of restoration algorithms. Generally, in image restoration tasks, reference true image pixels are used to evaluate the quality of the restoration results. In this embodiment, reference true image pixels are determined from manually labeled or automatically generated high-quality image data.
[0079] The weights of the model to be constructed are estimated based on short vectors and a pre-defined EM algorithm. First, the reference real-world image pixels corresponding to the short vectors are used as sample points for the model, and the mean and variance of each short vector are calculated. Then, using these sample points, the mean and variance of the short vectors, the EM algorithm is used to iteratively estimate the weights, ultimately yielding the weights of the model to be constructed. This process ensures that the model weights can be dynamically adjusted to adapt to different image features.
[0080] By calculating the mean and variance of short vectors, the statistical characteristics of image data can be better captured, thus improving the accuracy of image restoration.
[0081] Please continue reading. Figure 2 As shown, it is a flowchart of the preset EM algorithm in this embodiment;
[0082] Specifically, estimating the weights of the model to be constructed based on sample points, short vector mean, short vector variance, and a preset EM algorithm includes:
[0083] The mean of the short vector is assigned to the mean of a Gaussian distribution, and the variance of the short vector is assigned to the variance of a Gaussian distribution;
[0084] In step E, the posterior probability of each sample point belonging to each Gaussian component is calculated, and the weights of the Gaussian components are updated based on all posterior probabilities to form updated weights.
[0085] In step M, the mean and variance of each Gaussian component are recalculated based on the updated weights to form updated mean and updated variance;
[0086] The weights of each Gaussian component are updated based on the updated mean and the updated variance until convergence or the maximum number of steps is reached.
[0087] The EM algorithm is used to estimate the weights of the model to be built. First, the mean and variance of the short vectors are assigned the mean and variance of a Gaussian distribution. In the E step, the posterior probability of each sample point belonging to each Gaussian component is calculated, and the weights of each Gaussian component are updated based on these posterior probabilities, forming the updated weights. In the M step, the mean and variance of each Gaussian component are recalculated based on the updated weights, and this process is iterated until the mean, variance, and weights of the Gaussian components converge or the maximum number of iterations is reached.
[0088] Through this iterative process, the model to be built can gradually approach the optimal weight distribution, making the model's image restoration more accurate and stable.
[0089] Specifically, the step of determining the brightness fluctuation value based on the real-time brightness of all real-time images within a preset adjustment period after forming several Gaussian mixture models includes:
[0090] The real-time brightness of the real-time image is extracted, and the standard deviation of the real-time brightness is calculated to form the brightness fluctuation value.
[0091] Within a preset adjustment period, brightness analysis is performed on all acquired real-time images. First, brightness information for each frame is extracted from these real-time images, and the brightness value for each frame is calculated. Then, based on these brightness values, the standard deviation of the brightness is calculated, which measures the degree of fluctuation in image brightness. Ultimately, the standard deviation serves as the brightness fluctuation value, reflecting the stability or volatility of image brightness.
[0092] By calculating the brightness fluctuation value of real-time images, the system can dynamically monitor the impact of lighting changes, reduce fluctuations caused by lighting changes, and make the restored image quality more stable and consistent.
[0093] Please continue reading. Figure 3 As shown, it is the logic diagram for adjusting the preset prediction duration in this embodiment;
[0094] Specifically, adjusting the preset prediction duration based on the brightness fluctuation value until the brightness fluctuation value is less than the preset fluctuation value includes:
[0095] When the brightness fluctuation value exceeds a preset standard brightness fluctuation value, the preset prediction duration is adjusted based on the brightness fluctuation value, the preset standard brightness fluctuation value, and a preset adjustment coefficient until the brightness fluctuation value falls below the preset fluctuation value. The adjusted preset prediction duration is calculated by multiplying the current prediction duration by an adjustment factor. This adjustment factor is based on the difference between the current brightness fluctuation value and the preset standard brightness fluctuation value, as well as the preset adjustment coefficient. If the current brightness fluctuation value exceeds the standard value, the prediction duration will increase accordingly to allow the system to better adapt to environmental changes and thus improve image restoration performance.
[0096] The preset adjustment coefficient is a parameter used to adjust the relationship between prediction duration and brightness fluctuation value. Its function is to control the adjustment range of prediction duration when the brightness fluctuation value exceeds a preset standard. Typically, the selection of the preset adjustment coefficient depends on the specific application requirements and the system's responsiveness to brightness changes. It is usually set between 0.1 and 1; in this embodiment, it is set to 0.5 to accommodate most common scenarios and provide good responsiveness and stability.
[0097] When the brightness fluctuation value exceeds the preset standard brightness fluctuation value, the system dynamically adjusts the prediction duration based on the current brightness fluctuation value, the preset standard brightness fluctuation value, and a preset adjustment coefficient. This adjustment process continues until the brightness fluctuation value falls below the preset fluctuation value, indicating that the illumination change has stabilized, and the adjustment process ends.
[0098] By dynamically adjusting the prediction duration, this method can adapt to changes in lighting conditions, ensuring that the image restoration model maintains high restoration accuracy even under conditions of large lighting fluctuations.
[0099] Specifically, determining the plurality of long vectors from all restored images corresponding to each preset restoration model includes:
[0100] All the restored images corresponding to each preset restoration model are flattened and stitched together into a long vector to form the aforementioned long vectors.
[0101] First, all restored images corresponding to each preset restoration model are flattened, that is, the two-dimensional image data is converted into one-dimensional vectors to facilitate subsequent operations. Then, these flattened image vectors are concatenated according to a preset number to form several long vectors. These long vectors serve as the basis for subsequent processing, helping the system to better analyze and process the restoration effect.
[0102] By concatenating the images into a long vector, information from multiple restored images can be effectively integrated, thereby improving data availability and processing efficiency in subsequent processing.
[0103] Specifically, dividing the long vector into several buckets of equal width according to the preset bucket width includes:
[0104] The number of buckets is obtained by calculating the ratio of the pixel value range of the long vector to the preset bucket width.
[0105] First, the range of pixel values in the long vector needs to be calculated, that is, the difference between the maximum and minimum values. Next, this range is compared to a preset bucket width to determine the number of buckets that can be created. This calculation process ensures that each bucket can uniformly cover the pixel values in the long vector, thus enabling more accurate data classification and analysis in subsequent processing.
[0106] This method effectively divides long vector data into multiple buckets of equal width, ensuring that each bucket contains pixel values within a similar range.
[0107] Specifically, forming several mutually exclusive bucket sets based on the number of buckets and the preset number includes:
[0108] Calculate the number of buckets raised to the power of the preset number to obtain the number of bucket sets. Divide the buckets according to the number of bucket sets to form bucket sets with mutually exclusive ranges of bucket set numbers.
[0109] First, the number of buckets is raised to a predetermined power to determine the number of bucket sets to be generated. This calculation ensures that each bucket set has sufficient diversity and richness to cover different data features. Next, based on the calculated number of bucket sets, the previously divided buckets are further subdivided to ensure that the ranges of each bucket set are mutually exclusive, i.e., there is no overlap.
[0110] The mutual exclusion design improves the accuracy of data classification, enabling subsequent model processing to more effectively identify and utilize the features of different data segments.
[0111] Please continue reading. Figure 4 As shown, it is a flowchart of the formation of several Gaussian mixture models in this embodiment;
[0112] Specifically, the step of integrating the weights into integrated weights and storing them in a preset lookup table to form several Gaussian mixture models includes:
[0113] All the weights are then combined into an integrated weight vector by weighted summation.
[0114] The integrated weight vector is normalized to form a normalized integrated weight vector;
[0115] The normalized integrated weight vector, the Gaussian distribution mean, and the Gaussian distribution variance are stored in a preset lookup table to form several Gaussian mixture models.
[0116] First, a weighted summation of all weights is performed to create an integrated weight vector. This step ensures that the contributions of each weight are combined into a whole, allowing the model to consider the influence of each component during processing. Next, the integrated weight vector is normalized to ensure that the sum of all weights is 1, resulting in a normalized integrated weight vector. This step is crucial for subsequent probabilistic models because it guarantees that the weight of each Gaussian component is reasonable within the overall model. Finally, the normalized integrated weight vector, the mean and variance of the Gaussian distribution are stored in a pre-defined lookup table, forming several Gaussian mixture models.
[0117] The Gaussian mixture model generated by integrating the weights into an integrated weight vector can effectively represent different features in the image restoration process.
[0118] The technical solution of the present invention has been described above with reference to the preferred embodiments shown in the accompanying drawings. However, it will be readily understood by those skilled in the art that the scope of protection of the present invention is obviously not limited to these specific embodiments. Without departing from the principles of the present invention, those skilled in the art can make equivalent changes or substitutions to the relevant technical features, and the technical solutions after these changes or substitutions will all fall within the scope of protection of the present invention.
[0119] The above description is merely a preferred embodiment of the present invention and is not intended to limit the invention. Various modifications and variations can be made to the present invention by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.
Claims
1. An ensemble learning method in image restoration, characterized in that, The method comprises: collecting real-time images at monitoring points of a target task; predicting all the real-time images within a preset prediction time period through a plurality of preset recovery models to form a plurality of recovery images; determining a plurality of long vectors from all the recovery images corresponding to each preset recovery model; dividing the long vectors into a plurality of buckets with the same width according to the preset bucket width, forming a plurality of bucket sets with mutually exclusive ranges according to the number of buckets and the preset number; determining a plurality of weights of a model to be constructed according to the bucket sets and a preset EM algorithm; integrating the weights into an integrated weight and storing the integrated weight in a preset lookup table to form a plurality of Gaussian mixture models; determining a brightness fluctuation value according to the real-time brightness of all the real-time images within a preset adjustment time period after forming the plurality of Gaussian mixture models, and adjusting the preset prediction time period according to the brightness fluctuation value until the brightness fluctuation value is less than a preset fluctuation value; the determining of the plurality of long vectors from all the recovery images corresponding to each preset recovery model comprises: flattening and splicing all the recovery images corresponding to each preset recovery model into one long vector to form the plurality of long vectors.
2. The ensemble learning method in image restoration according to claim 1, wherein, The determination of the brightness fluctuation value according to the real-time brightness of all the real-time images within the preset adjustment time period after forming the plurality of Gaussian mixture models comprises: extracting the real-time brightness of the real-time images, calculating the standard deviation of the real-time brightness, and forming the brightness fluctuation value.
3. The ensemble learning method in image restoration according to claim 2, wherein, The adjustment of the preset prediction time period according to the brightness fluctuation value until the brightness fluctuation value is less than the preset fluctuation value comprises: when the brightness fluctuation value is greater than a preset standard brightness fluctuation value, adjusting the preset prediction time period according to the brightness fluctuation value, the preset standard brightness fluctuation value, and a preset adjustment coefficient until the brightness fluctuation value is less than the preset fluctuation value.
4. The ensemble learning method in image restoration according to claim 3, wherein, The determination of the plurality of weights of the model to be constructed according to the bucket sets and the preset EM algorithm comprises: mask mapping each of the bucket sets to obtain a plurality of screened pixel points, forming a plurality of short vectors, estimating the weights of the model to be constructed according to the short vectors and the preset EM algorithm, and forming a plurality of weights.
5. The ensemble learning method in image restoration according to claim 4, characterized in that, The estimation of the weights of the model to be constructed according to the short vectors and the preset EM algorithm comprises: taking the reference real image pixel points corresponding to the short vectors as sample points of the model to be constructed and the preset EM algorithm, calculating the mean and variance of each short vector to obtain the short vector mean and the short vector variance, and estimating the weights of the model to be constructed according to the sample points, the short vector mean, the short vector variance, and the preset EM algorithm.
6. The ensemble learning method in image restoration according to claim 5, wherein, The estimation of the weights of the model to be constructed according to the sample points, the short vector mean, the short vector variance, and the preset EM algorithm comprises: assigning the short vector mean to the mean of the Gaussian distribution and assigning the short vector variance to the variance of the Gaussian distribution; calculating the posterior probability of each sample point belonging to each Gaussian component in the E step, updating the weights of the Gaussian components based on all the posterior probabilities to form updated weights; in the M step, recalculating the mean and variance of each Gaussian component based on the updated weights to form updated mean and updated variance; The weight of each Gaussian component is updated according to the updated mean and the updated variance until convergence or a maximum number of steps is reached.
7. The ensemble learning method in image restoration according to claim 6, wherein, The dividing the long vector into several same-width buckets according to the preset bucket width comprises: Calculating the ratio of the pixel value range of the long vector and the preset bucket width to obtain the number of buckets.
8. The ensemble learning method in image restoration according to claim 7, wherein, The forming several range-exclusive bucket sets according to the number of buckets and the preset number comprises: Calculating the preset number power of the number of buckets to obtain the number of bucket sets, and dividing the buckets according to the number of bucket sets to form range-exclusive bucket sets of the number of bucket sets.
9. The ensemble learning method in image restoration according to claim 8, characterized in that, The integrating the weights into integrated weights and storing in a preset lookup table to form several Gaussian mixture models comprises: Integrating all the weights into an integrated weight vector through weighted summation; Normalizing the integrated weight vector to form a normalized integrated weight vector; Storing the normalized integrated weight vector, the Gaussian distribution mean and the Gaussian distribution variance in a preset lookup table to form several Gaussian mixture models.
Citation Information
Patent Citations
Image de-blurring method based on bright stripe information in image
CN105976332A
Method and apparatus for training image restoration model, electronic device, and computer-readable storage medium
US20230177650A1