Camouflage target segmentation measurement method based on context
By employing a context-based camouflage target segmentation metric, the pixel association strength distribution is calculated and forward inference and backward deduction are combined. This solves the problem of the inability to quantify the semantic dependency relationship of camouflage target segmentation in existing technologies, and achieves evaluation results consistent with human visual perception.
Patent Information
- Application Number
- CN202511810184.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-03
- Publication Date
- 2026-03-06
AI Technical Summary
Existing image segmentation evaluation metrics cannot effectively quantify the semantic dependency relationship between the target and the background in camouflaged target scenarios, cannot adapt to the model evaluation needs in complex contexts, and do not conform to human visual perception.
A context-based camouflage target segmentation metric is adopted. The pixel association intensity distribution is calculated through manually labeled images. The evaluation results are calculated by combining forward inference and backward deduction, which reflect the model's understanding and reconstruction of the real target and are adapted to the context-dependent characteristics of target visibility in camouflage scenarios.
It enables a more comprehensive and accurate measurement of the performance of image segmentation models in camouflaged scenarios, with evaluation results that are more consistent with human visual perception and can quantify the differences in the degree of camouflage.
Smart Images

Figure CN121616609A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of image evaluation metrics technology, and specifically to a context-based method for segmenting camouflaged targets. Background Technology
[0002] In camouflaged object segmentation (COS) scenarios where the target object and its background are highly similar in color, texture, and structure, traditional evaluation metrics for visual saliency detection or general image segmentation tasks (such as the beta-weighted F-metric) are typically used. Weighted beta-weighted F-metric Structural similarity measurement Enhance alignment metrics (etc.) to evaluate the accuracy of target object segmentation.
[0003] However, this evaluation method treats each pixel in the image (including the target object and its background) as an independent evaluation unit, and calculates the evaluation score by comparing the predicted value of each pixel with the manually labeled ground truth value (such as counting pixel-level errors such as true positives, false positives, and false negatives). This method has the following technical drawbacks:
[0004] ① The observability of a target in COS is determined by the background environment. When the same target object is in different backgrounds with significantly different camouflage difficulty, traditional indicators only focus on the pixel matching rate, and will give the same score to the target object in different scenes, which is seriously inconsistent with human visual perception (which can intuitively distinguish the difficulty of the background).
[0005] ② Target segmentation relies on the global semantic relationship between the target and the background (such as the continuity between the target edge and the background texture, and the semantic consistency of the target region in the global scene), while traditional metrics only judge the correctness of a single pixel in isolation and cannot capture the global dependency relationship that is crucial to COS.
[0006] In response, those skilled in the art have attempted to optimize the evaluation performance of camouflaged target segmentation by introducing improved metrics that incorporate local dependencies between pixels (such as a weighted F-metric based on local neighborhood pixel associations). However, these improved metrics have limited dependency forms and cannot cover the complex relationships between global context and target visibility in camouflaged scenarios. They still cannot effectively quantify the degree of camouflage of the target object, fail to adapt to the strong contextual characteristics of camouflaged target segmentation tasks, and cannot meet the model evaluation needs in complex contexts.
[0007] In summary, existing segmentation metrics are insufficiently applicable to camouflaged target segmentation tasks and cannot meet the model evaluation needs in complex contexts. There is an urgent need for an evaluation mechanism that can incorporate the semantic dependencies between the target and the background and possesses higher cognitive consistency to comprehensively measure the performance of image segmentation models in camouflaged scenarios. Summary of the Invention
[0008] The purpose of this invention is to address the shortcomings of existing technologies by providing a context-based camouflage target segmentation measurement method. This method defines a Gaussian-based pixel association strength distribution based on manually labeled images. Then, based on this distribution, it performs forward inference (calculating the model's understanding of the real target through convolutional approximation) and backward deduction (verifying the reflection of the real target in the model's prediction results through convolutional approximation and normalization). The results of forward inference and backward deduction are weighted and scored to obtain the final evaluation result for camouflage target segmentation. This evaluation result reflects both the model's understanding of the real target (through forward inference) and the reconstruction of the real target in the prediction results (through backward deduction). It also adapts to the strong context-dependent characteristics of target visibility in camouflage scenes, where background influences visibility, maintaining higher consistency with human visual cognition. This allows for a more comprehensive and accurate measurement of the actual performance of image segmentation models in camouflage scenes.
[0009] The objective of this invention is achieved through the following approach:
[0010] A context-based camouflage target segmentation metric includes the following steps:
[0011] 1) Manually annotate the input image containing the target object to obtain a manually annotated image, and then count all the pixels of the target object in the manually annotated image to form a manually annotated pixel set;
[0012] 2) Perform camouflage target segmentation on the input image to obtain the prediction result, and then count all the pixels of the target object in the prediction result as the prediction pixel set;
[0013] 3) Calculate the pixel dependency intensity distribution of the target object based on the manually labeled pixel set;
[0014] 4) Based on the predicted pixel set and pixel dependency intensity distribution, calculate the average score of forward inference from the perspective of forward inference;
[0015] 5) Based on the manually labeled pixel set and pixel dependency intensity distribution, calculate the weighted score of the reverse deduction from the perspective of reverse deduction;
[0016] 6) The forward inference average score obtained in step 4) and the backward deduction weighted score obtained in step 5) are harmonicly weighted to obtain the evaluation result score of the camouflaged target segmentation.
[0017] Preferably, in step 3), calculating the pixel dependency intensity distribution of the target object based on the manually labeled pixel set specifically includes:
[0018] 3-1) Calculate the covariance of the manually labeled pixel set, and normalize the covariance matrix according to the following formula:
[0019]
[0020] In the formula, The normalized covariance matrix is... For normalized hyperparameters, Let covariance matrix be the variance matrix. For trace operators;
[0021] This invention normalizes the covariance matrix of manually labeled pixel sets using trace operators. Combined with a fixed hyperparameter α, it can eliminate the differences in covariance values between camouflaged target images of different resolutions and sizes, avoid the imbalance in the magnitude of pixel correlation strength calculation results caused by different image scales, and enable the pixel dependency strength distribution in different scenarios to have a unified comparison benchmark, laying a data consistency foundation for subsequent cross-scenario model evaluation.
[0022] 3-2) Determine the correlation strength between any two pixels in the manually labeled pixel set using the following formula:
[0023]
[0024] In the formula, For pixel n and pixel The strength of the association, Let n be the coordinates of pixel n. For pixels coordinates For matrix The inverse matrix, For matrix The determinant of .
[0025] 3-3) Combine all the correlation strengths calculated in step 3-2) to obtain the pixel dependency intensity distribution of the target object.
[0026] Preferably, in step 4), the average score of forward reasoning is calculated in the following manner:
[0027] 4-1) According to In principle, the pixel-dependent intensity distribution obtained in step 3) is discretized to obtain the convolution kernel;
[0028] This invention discretizes the pixel-dependent intensity distribution based on the 3σ principle to generate convolution kernels, which can retain the key features of the correlation strength between pixels to the greatest extent and avoid information loss caused by discretization.
[0029] 4-2) Based on the manually labeled pixel set, the predicted pixel set, and the convolution kernel, calculate the forward inference according to the following formula:
[0030]
[0031] In the formula, Forward reasoning, To predict the pixel set, For manually labeled pixel sets, For convolution kernel, For element-wise multiplication, For convolution;
[0032] 4-3) Based on the forward inference and predicted pixel set, calculate the average score of the forward inference using the following formula:
[0033]
[0034] In the formula, The average score for forward reasoning. Forward reasoning, For predicting the pixel set.
[0035] Preferably, in step 5), the reverse deduction weighted score is calculated in the following manner:
[0036] 5-1) Based on the manually labeled pixel set, the predicted pixel set, and the convolution kernel, calculate the back-derivative using the following formula:
[0037]
[0038] In the formula, This is a reverse deduction. To predict the pixel set, For manually labeled pixel sets, For convolution kernel, It is a matrix of all ones. For element-wise calculation, For element-wise multiplication, For convolution;
[0039] 5-2) Based on the input image, reconstruct the target object to obtain the reconstructed target object;
[0040] 5-3) Calculate the color difference between the target region and the reconstructed target region in the LAB space;
[0041] 5-4) By using a nonlinear mapping, the color difference is fitted according to the following formula to obtain the final level of camouflage:
[0042]
[0043] In the formula, To the degree of disguise, To control the degree of nonlinearity of the mapping, To redraw pixels, The original pixel is represented by Δ, and the redrawn pixel is represented by Δ. With original pixels The color difference between CIEDE2000;
[0044] 5-5) Using the degree of camouflage as a weight matrix, the back-deduction calculated in step 5-1) is superimposed to obtain the context-weighted back-deduction score:
[0045]
[0046] In the formula, For reverse deduction scoring, This is a reverse deduction. For manually labeled pixel sets, The degree of disguise.
[0047] Preferably, in step 5-2), the target object for reconstruction is obtained in the following manner:
[0048] 5-2-1) Through morphological dilation, the region of the target object in the input image is expanded outward by several pixels, and the expanded region is used as the context region;
[0049] 5-2-2) Extract all overlapping N×N image blocks within the target region and the context region, where N is the preset side length of the image block;
[0050] 5-2-3) Embed feature vectors into each image patch extracted in step 5-2-2) to obtain several feature vectors;
[0051] 5-2-4) Match the feature vectors of each image block in the context region with the feature vectors of each image block in the target region. In the context region, use the approximate nearest neighbor algorithm to search for the feature vector with the highest similarity to the feature vectors of each image block in the target region.
[0052] 5-2-5) Add the image patch found in step 5-2-4) to the target region to obtain the reconstructed target region, which has the same visual features as the context region.
[0053] Preferably, in step 5-2-3), the specific process of feature vector embedding is as follows:
[0054] S1) Convert the image patch to the LAB color space and flatten the LAB color values of the image patch into a one-dimensional vector;
[0055] S2) Obtain the center position coordinates of the image patch, standardize the center position coordinates, and then scale them using the parameter λ to balance the weight ratio of spatial information and color information in the feature vector.
[0056] S3) Concatenate the flattened LAB color vector from step S1) with the scaled center position coordinates from step S2) to form an image patch feature vector with dimension (N2+2)×1.
[0057] Preferably, in step 6), the evaluation result score is calculated according to the following formula:
[0058]
[0059] In the formula, To score the evaluation results, The average score for forward reasoning. Weighted score for reverse deduction, To control and Factors of relative importance.
[0060] The beneficial effects of this invention include the following:
[0061] (1) This invention directly abandons the traditional approach of comparing only pixel errors. It models the pixel dependency relationship of the real target through the covariance matrix, combines the correlation strength decay law of Gaussian distribution (the greater the distance, the weaker the correlation), and quantitatively describes the global spatial context. Then, through the bidirectional verification of "forward reasoning-backward deduction", it can avoid the single-dimensional evaluation bias, solve the problem of consistent evaluation of the same shape target under different backgrounds, and make the evaluation results more in line with human visual perception.
[0062] (2) This invention first ensures the contextual consistency between the redrawing target and the background through morphological dilation and ANN search, providing a reliable basis for color difference calculation. Then, based on the mapping of CIEDE2000 color difference (which accurately reflects the human eye's perception of color difference) and γ parameter control, the color difference is transformed into a quantifiable degree of camouflage D, so that the evaluation results can reflect the difference in the difficulty of camouflage of the target under different backgrounds, which can fill the gap in the existing technology that cannot quantify the "degree of camouflage".
[0063] Definitions:
[0064] Visual saliency detection is a technique in the field of computer vision that extracts salient regions from images or videos by simulating human visual attention mechanisms.
[0065] Camouflaged target segmentation is a sub-task in the field of computer vision. It refers to the process of accurately locating and extracting the complete pixel-level region of a target in an image or video data that is highly integrated with the background environment (i.e., "camouflaged") by visual features such as color, texture, and shape, has blurred boundaries, and low recognizability.
[0066] The 3σ principle, also known as the three-standard-deviation principle, is based on the statistical law of normal distribution.
[0067] Morphological dilation is a basic morphological operation based on structuring elements in image processing. Essentially, it expands the target pixels (such as foreground pixels in a binary image) within the area covered by the structuring element into the spatial neighborhood by sliding the structuring element across the target image. Ultimately, it achieves the effects of expanding the boundary of the target region, filling holes, or connecting broken parts.
[0068] CIEDE2000: A color difference evaluation formula developed by the International Commission on Illumination (CIE). It is a color difference calculation standard that accurately reflects the subjective perception of color differences by the human eye, and is used in this invention to calculate redrawn pixels. With original pixels Color differences in the LAB color space provide basic data for subsequent quantification of the degree of disguise. Attached Figure Description
[0069] Figure 1 This is a probabilistic pixel association framework diagram of the Context-measure of this invention;
[0070] Figure 2 This invention provides an algorithm for quantifying the pixel-level camouflage level of a target using Context-measure.
[0071] Figure 3 This is a flowchart of the present invention. Detailed Implementation
[0072] like Figures 1 to 3 As shown, a context-based camouflage target segmentation metric method includes the following steps:
[0073] 1) Manually annotate the input image containing the target object to obtain a manually annotated image, and then count all the pixels of the target object in the manually annotated image to form a manually annotated pixel set;
[0074] 2) Perform camouflage target segmentation on the input image to obtain the prediction result, and then count all the pixels of the target object in the prediction result as the prediction pixel set;
[0075] 3) Calculate the pixel dependency intensity distribution of the target object based on the manually labeled pixel set;
[0076] 4) Based on the predicted pixel set and pixel dependency intensity distribution, calculate the average score of forward inference from the perspective of forward inference;
[0077] 5) Based on the manually labeled pixel set and pixel dependency intensity distribution, calculate the weighted score of the reverse deduction from the perspective of reverse deduction;
[0078] 6) The forward inference average score obtained in step 4) and the backward deduction weighted score obtained in step 5) are harmonicly weighted to obtain the evaluation result score of the camouflaged target segmentation.
[0079] Based on the above method, the following is an example:
[0080] 1) Manually annotate the input image containing the target object to obtain a manually annotated image. Then, count all the pixels of the target object in the manually annotated image to form the manually annotated pixel set. , where Y(p)∈{0,1} represents the value of pixel p;
[0081] 2) Perform camouflage target segmentation on the input image to obtain the prediction result, and then count all pixels of the target object in the prediction result as the prediction pixel set. , where X(p)∈[0,1] represents the value of pixel p;
[0082] 3) Based on the manually labeled pixel set, calculate the pixel dependency intensity distribution of the target object, specifically including:
[0083] In this embodiment, a probabilistic model is used to describe the dependency between any two pixels in order to measure their correlation. Specifically, from the foreground pixel set... Calculate its covariance matrix This is used to characterize the shape of the real target. Then, the covariance matrix is normalized, as follows:
[0084] 3-1) Based on the manually labeled pixel set, calculate the covariance of the manually labeled pixel set, and normalize the covariance matrix according to the following formula to ensure that pixel-level correlation remains comparable between images of different resolutions:
[0085]
[0086] In the formula, The normalized covariance matrix is... This is the normalization hyperparameter, with a value of 6; Let covariance matrix be the variance matrix. Represents the trace operator;
[0087] 3-2) In a given foreground Under the given conditions, the correlation between any two pixels is defined by the following formula, which is the pixel correlation strength distribution, and in other words, the correlation strength between any two pixels in the manually labeled pixel set is determined:
[0088]
[0089] In the formula, For pixel n and pixel The strength of the association, Let n be the coordinates of pixel n. For pixels coordinates For matrix The inverse matrix, For matrix The determinant of , where T is the transpose.
[0090] It is worth noting that in this embodiment, by This can quantitatively describe the correlation strength between two pixels, which decays according to a Gaussian law based on their spatial distance. Intuitively, the farther apart two pixels are, the weaker their correlation.
[0091] 3-3) Combine all the correlation strengths calculated in step 3-2) to obtain the pixel dependency intensity distribution of the target object.
[0092] 4) Based on the predicted pixel set and pixel dependency intensity distribution, calculate the average forward inference score from the perspective of forward inference as follows:
[0093] In this embodiment, the prediction results will be... Compared with human annotation Comparisons are made to understand how well the predictions describe the reality. Forward inference is defined based on the pixel association strength distribution. Expressed as:
[0094]
[0095] Among them, the One predicted foreground pixel Weighted according to their relevance to the actual target,
[0096] To reduce computational costs, this embodiment will, during implementation, Discretize into convolution kernel Its dimensions follow The principle is to cover 99% of the probability distribution and to use a convolutional kernel K for forward inference, as follows:
[0097] 4-1) According to In principle, the pixel-dependent intensity distribution obtained in step 3) is discretized to obtain the convolution kernel;
[0098] 4-2) Based on the manually labeled pixel set, the predicted pixel set, and the convolution kernel, calculate the forward inference according to the following formula:
[0099]
[0100] In the formula, Forward reasoning (output value of forward reasoning). To predict the pixel set, For manually labeled pixel sets, For convolution kernel, For element-wise multiplication, For convolution;
[0101] 4-3) Based on the forward inference and predicted pixel set, calculate the average score of the forward inference using the following formula:
[0102]
[0103] In the formula, The average score for forward reasoning. Forward reasoning, For predicting the pixel set.
[0104] 5) Based on the manually labeled pixel set and pixel dependency intensity distribution, calculate the weighted score for the reverse derivation from the perspective of reverse derivation as follows:
[0105] In this embodiment, starting from manually labeled Y, the following methods are used to verify whether the prediction results can faithfully reconstruct and reflect the potential real situation:
[0106] First, let's reverse the deduction. Defined as:
[0107]
[0108] , indicating the first One manually labeled foreground pixel; , indicating the first One predicted foreground pixel;
[0109] Similar to forward reasoning, Use Convolution kernel centered on By performing an efficient approximation, we obtain:
[0110]
[0111] Furthermore, since the output range of the above formula is Normalization coefficients should be used. Rescale it to .
[0112] Therefore, from arrive The reverse inference process can be written as:
[0113]
[0114] in, It is a matrix of all ones. Calculated by element.
[0115] In this embodiment, the specific method of performing reverse deduction using the above-described reverse inference process is as follows:
[0116] 5-1) Based on the manually labeled pixel set, the predicted pixel set, and the convolution kernel, calculate the back-derivative using the following formula:
[0117]
[0118] In the formula, This is the output value of reverse deduction (reverse inference). To predict the pixel set, For manually labeled pixel sets, For convolution kernel, It is a matrix of all ones. For element-wise calculation, For element-wise multiplication, For convolution;
[0119] 5-2) For example Figure 2 As shown, based on the input image, the target object is reconstructed in the following manner to obtain the reconstructed target object:
[0120] 5-2-1) Through morphological dilation, the region of the target object in the input image is expanded outward by k=20 pixels, and the expanded region is used as the context region;
[0121] 5-2-2) Within the target region and the context region, densely extract all overlapping N×N size image blocks using a sliding window method (N is the preset image block side length, configured according to the actual application scenario);
[0122] 5-2-3) Embed feature vectors into each image patch extracted in step 5-2-2). The feature vector is formed by concatenating the flattened LAB color value of the corresponding image patch with its standardized center position coordinates. The position coordinates are scaled by the parameter λ to balance the contribution of spatial information and color information.
[0123] 5-2-4) Match the feature vectors of each image patch in the context region with the feature vectors of each image patch in the target region. In the context region, use the Approximate Nearest Neighbor (ANN) algorithm to search for the feature vector with the highest similarity (i.e. the best match) with the feature vectors of each image patch in the target region.
[0124] 5-2-5) Project the feature vectors found in step 5-2-4) back into the image space, find the corresponding image blocks, and add the found image blocks into the target object to obtain the reconstructed target object. The reconstructed target object is consistent with the visual features (color, texture) of the context region.
[0125] 5-3) Calculate the color difference between the target object and the reconstructed target region in the LAB space;
[0126] 5-4) By using a nonlinear mapping, the color difference is fitted according to the following formula to obtain the final level of camouflage:
[0127]
[0128] In the formula, To the degree of disguise, To control the degree of nonlinearity of the mapping, It is a matrix of all ones. To redraw pixels, For the original pixel, Δ To redraw pixels With original pixels The CIEDE2000 color difference between them.
[0129] 5-5) Using the degree of camouflage as a weight matrix, the back-deduction calculated in step 5-1) is superimposed to obtain the context-weighted back-deduction score:
[0130]
[0131] In the formula, For reverse deduction scoring, This is a reverse deduction. For manually labeled pixel sets, The degree of disguise.
[0132] 6) The forward inference average score obtained in step 4) and the backward deduction weighted score obtained in step 5) are harmonicly weighted to obtain the evaluation result score for camouflaged target segmentation. :
[0133]
[0134] In the formula, To score the evaluation results, The average score for forward reasoning. Weighted score for reverse deduction, To control and Factors of relative importance.
[0135] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications made to the present invention by those skilled in the art without departing from the spirit of the present invention shall fall within the protection scope of the present invention.
Claims
1. A context-based camouflage target segmentation metric method, characterized in that, The method comprises the following steps: 1) manually annotating an input image comprising a target object to obtain a manually annotated image, and then counting all pixel points of the target object in the manually annotated image as a manually annotated pixel set; 2) performing camouflage target segmentation on the input image to obtain a prediction result, and then counting all pixel points of the target object in the prediction result as a predicted pixel set; 3) calculating a pixel dependence intensity distribution of the target object according to the manually annotated pixel set; 4) calculating a forward reasoning average score from a forward reasoning perspective according to the predicted pixel set and the pixel dependence intensity distribution; 5) calculating a backward deduction weighted score from a backward deduction perspective according to the manually annotated pixel set and the pixel dependence intensity distribution; 6) performing harmonic weighting on the forward reasoning average score obtained in step 4) and the backward deduction weighted score obtained in step 5) to obtain an evaluation result score of the camouflage target segmentation.
2. The method of claim 1, wherein, In step 3), the pixel dependence intensity distribution of the target object is calculated according to the manually annotated pixel set, specifically comprising: 3-1) calculating the covariance of the manually annotated pixel set according to the manually annotated pixel set, and performing normalization processing on the covariance matrix according to the following formula: ; In the formula, is a normalized covariance matrix, is a normalization parameter, is a covariance matrix, is a trace operator; 3-2) determining the correlation intensity of any two pixels in the manually annotated pixel set according to the following formula: ; wherein is the correlation strength of pixel n and pixel is the coordinate of pixel n, is the coordinate of pixel is the inverse matrix of matrix is the determinant of matrix 3-3) combining all the correlation intensities calculated in step 3-2) to obtain the pixel dependence intensity distribution of the target object.
3. The method of claim 1, wherein, In step 4), the forward reasoning average score is calculated in the following manner: 4-1) According to In principle, the pixel-dependent intensity distribution obtained in step 3) is discretized to obtain the convolution kernel; 4-2) calculating forward reasoning according to the manually annotated pixel set, the predicted pixel set, and the convolution kernel according to the following formula: ; wherein, is forward inference, is predicted pixel set, is human annotated pixel set, is convolution kernel, is element-wise multiplication, is convolution; 4-3) calculating the forward reasoning average score according to the forward reasoning and the predicted pixel set according to the following formula: ; wherein is the forward inference average score, is the forward inference, is the predicted pixel set.
4. The method of claim 1, wherein, In step 5), the backward deduction weighted score is calculated in the following manner: 5-1) calculating backward deduction according to the manually annotated pixel set, the predicted pixel set, and the convolution kernel according to the following formula: ; wherein, is backpropagation, is a predicted set of pixels, is a set of human-labeled pixels, is a convolution kernel, is an all-ones matrix, is an element-wise calculation, is an element-wise multiplication, is a convolution; 5-2) reconstructing the target object according to the input image to obtain a reconstructed target object; 5-3) calculating the color difference between the target object and the reconstructed target object in the LAB space; 5-4) fitting the color difference according to the following formula through nonlinear mapping to obtain the final camouflage degree: ; wherein, is the degree of camouflage, is the degree of non-linearity of the control mapping, is the redrawn pixel, is the original pixel, Δ is the redrawn pixel is the CIEDE2000 color difference between the original pixel and the redrawn pixel. 5-5) superimposing the backward deduction calculated in step 5-1) with the camouflage degree as a weight matrix to obtain a context-weighted backward deduction score: ; In the formula, is the reverse deduction score, is the reverse deduction, is the set of manually annotated pixels, is the degree of camouflage.
5. The method of claim 1, wherein, In step 5-2), the reconstructed target object is obtained in the following manner: 5-2-1) expanding the area of the target object in the input image outward by a certain number of pixels through morphological dilation, and taking the expanded area as a context area; 5-2-2) extracting all overlapping N×N size image blocks in the target area and the context area, where N is a preset image block side length; 5-2-3) embedding feature vectors for each image block extracted in step 5-2-2) respectively to obtain a plurality of feature vectors; 5-2-4) matching the feature vectors of the image blocks in the context area and the target area, and searching for a feature vector with the highest similarity to the feature vectors of the image blocks in the target area in the context area using an approximate nearest neighbor algorithm. 5-2-5) Add the image block found in step 5-2-4) to the target region to obtain a reconstructed target region, which is consistent with the visual features of the context region.
6. The method of claim 5, wherein, In step 5-2-3), the specific process of the feature vector embedding is as follows: S1) Convert the image block to the LAB color space, and flatten the LAB color values of the image block into a one-dimensional vector; S2) Obtain the center position coordinates of the image block, normalize the center position coordinates, and then scale them by the parameter λ; S3) Concatenate the flattened LAB color vector of step S1) and the scaled center position coordinates of step S2) to form an image block feature vector with a dimension of (N2+2) x 1.
7. The method of claim 1, wherein, In step 6), the evaluation result score is calculated according to the following formula: ; wherein is the result score, is the forward inference average score, is the backward deduction weighted score, is the control and is the factor of relative importance.
