An abnormality correction method and device for rendering, an electronic device and a storage medium

By obtaining the similarity between the current frame and the rendered frames during the rendering process and performing anomaly analysis, the problem of rendering anomalies being unable to be corrected in real time is solved, enabling real-time detection and correction of rendered images and improving display effects.

CN117036176BActive Publication Date: 2026-02-24TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210456669.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-04-27
Publication Date
2026-02-24
Estimated Expiration
2042-04-27

AI Technical Summary

Technical Problem

Existing technologies cannot detect and quickly and effectively correct rendering anomalies in real time, affecting the presentation of rendered images.

Method used

By obtaining the similarity between the current frame image and the rendered frame image during the rendering process, and performing rendering anomaly analysis and correction when the similarity does not meet the threshold, anomalies can be detected and corrected directly during the image rendering process.

Benefits of technology

It enables real-time detection and correction of rendered images, improving the display effect of rendered images without relying on specific image acquisition tools and complex detection algorithms.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117036176B_ABST
    Figure CN117036176B_ABST
Patent Text Reader

Abstract

Embodiments of the present application disclose a rendering exception correction method and device, electronic equipment and a storage medium; before the current rendering of the Nth frame image is displayed, the Nth frame image and the N-1th frame image which has been rendered are obtained, similarity calculation is performed on the N-1th frame image and the Nth frame image, if the calculated similarity is not greater than a preset similarity threshold, at least one kind of rendering exception analysis is performed on the Nth frame image based on the image information of the Nth frame image, at least one kind of exception probability of the Nth frame image is obtained, if the exception probability satisfies the corresponding exception correction condition, the original image corresponding to the Nth frame image before rendering is corrected and rendered, the frame image after rendering is obtained, and the frame image after rendering is displayed; the specific image acquisition tool and the complex detection algorithm are not depended, the real-time detection of the rendering exception is directly performed in the rendering process of the image, the abnormal rendering image is corrected, and the display effect of the rendering image is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of image processing technology, and more specifically to a method, apparatus, electronic device, and storage medium for correcting rendering anomalies. Background Technology

[0002] With the rapid development of technology, social applications are becoming increasingly prevalent in people's lives. For example, people use various functions of social applications for audio and video calls, video recording, and so on. The realization of these shooting and special effects functions is inseparable from the rendering capabilities of social applications and devices, and presenting stable and smooth rendering effects is also the goal of various rendering functions.

[0003] However, in practice, rendering anomalies can occur due to factors such as the computational load of the rendering process, the performance and status of the device itself, and errors during program execution. Currently, the main method for addressing rendering anomalies is to acquire the rendered image using specialized image acquisition equipment and then employ complex algorithms for anomaly detection. However, this approach cannot detect rendering anomalies in real time, making it difficult to quickly and effectively identify and correct abnormal rendering effects, thus impacting the presentation of the rendered image. Summary of the Invention

[0004] This invention provides a rendering anomaly correction method, apparatus, electronic device, and storage medium that can detect rendering anomalies directly during the image rendering process without relying on specific image acquisition tools and detection algorithms, thus achieving real-time detection and correcting abnormal rendered images, thereby improving the display effect of the rendered images.

[0005] This invention provides a method for correcting rendering anomalies, including:

[0006] Before the currently rendered Nth frame image is displayed, obtain the Nth frame image and the already rendered (N-1)th frame image;

[0007] The similarity between the (N-1)th frame image and the Nth frame image is calculated to obtain the similarity between the (N-1)th frame image and the Nth frame image;

[0008] If the similarity is not greater than a preset similarity threshold, perform at least one rendering anomaly analysis on the Nth frame image based on the image information of the Nth frame image to obtain at least one anomaly probability of the Nth frame image;

[0009] If the anomaly probability satisfies the corresponding anomaly correction condition, the original image before rendering corresponding to the Nth frame image is corrected and rendered to obtain the rendered frame image.

[0010] The rendered frame image is then displayed.

[0011] Accordingly, embodiments of the present invention provide a rendering anomaly correction device, comprising:

[0012] The image acquisition unit is used to acquire the Nth frame image and the already rendered (N-1)th frame image before the currently rendered Nth frame image is displayed;

[0013] A similarity calculation unit is used to calculate the similarity between the (N-1)th frame image and the Nth frame image to obtain the similarity between the (N-1)th frame image and the Nth frame image;

[0014] An anomaly analysis unit is used to perform at least one rendering anomaly analysis on the Nth frame image based on the image information of the Nth frame image if the similarity is not greater than a preset similarity threshold, and to obtain at least one anomaly probability of the Nth frame image.

[0015] A correction rendering unit is used to correct and render the original image before rendering corresponding to the Nth frame image if the anomaly probability satisfies the corresponding anomaly correction condition, so as to obtain the rendered frame image.

[0016] An image display unit is used to display the rendered frame image.

[0017] Optionally, the image acquisition unit is used to acquire an initial Nth frame image corresponding to the Nth frame image based on the current rendering thread before the Nth frame image is displayed, and to preprocess the initial Nth frame image to obtain the Nth frame image.

[0018] Based on the current rendering thread, obtain the initial (N-1)th frame image corresponding to the Nth frame image, and preprocess the initial (N-1)th frame image to obtain the rendered (N-1)th frame image.

[0019] Optionally, the image acquisition unit is used to acquire the initial Nth frame image obtained by the current rendering process;

[0020] The initial Nth frame image is sampled by the current rendering process, and the sampled initial Nth frame image is sent to the detection process to obtain the Nth frame image.

[0021] Obtain the initial (N-1)th frame image corresponding to the Nth frame image from the current rendering thread;

[0022] The initial (N-1)th frame image is sent to the detection process, and the detection process performs image sampling on the initial (N-1)th frame image to obtain the rendered (N-1)th frame image.

[0023] Optionally, the similarity calculation unit is used to calculate a first mean of the pixel values ​​of the Nth frame image based on the pixel values ​​of each pixel in the Nth frame image;

[0024] Calculate the second mean of the pixel values ​​of the (N-1)th frame image based on the pixel values ​​of each pixel in the (N-1)th frame image;

[0025] Based on the first mean and the second mean, the similarity between the (N-1)th frame image and the Nth frame image is calculated.

[0026] Optionally, the anomaly analysis unit is used to determine the first variance and the first mean of the pixel values ​​of the Nth frame image based on the pixel information of the Nth frame image;

[0027] Based on the pixel information of the (N-1)th frame image, determine the second variance and the second mean of the pixel values ​​of the (N-1)th frame image;

[0028] Based on the first variance, the first mean, the second variance, and the second mean, a black screen fault analysis is performed on the Nth frame image to obtain the black screen probability of the Nth frame image having a black screen fault.

[0029] Optionally, the anomaly analysis unit is used to determine at least two target detection regions in the Nth frame image;

[0030] Based on the pixel values ​​of each pixel in each of the target detection regions, the region pixel features corresponding to each of the target detection regions are determined;

[0031] Based on the pixel features of each region, screen distortion fault analysis is performed on the Nth frame image to obtain the probability of screen distortion fault in the Nth frame image.

[0032] Optionally, the anomaly analysis unit is used to determine the pixel variance corresponding to each target detection region as a region pixel feature based on the pixel value of each pixel point in each target detection region;

[0033] Calculate the average variance based on the variance of each pixel;

[0034] The difference between the variance of each pixel and the average variance is calculated to obtain the variance difference of each target detection region;

[0035] Based on the variance differences, the probability of a scattered screen distortion fault in the Nth frame image is determined.

[0036] Optionally, the anomaly analysis unit is used to determine the main direction of the regional gradient corresponding to each target detection region as the regional pixel feature based on the pixel value of each pixel in each target detection region.

[0037] Based on the main gradient direction of each region, direction matching is performed, and the probability of stripe screen distortion in the Nth frame image is determined according to the matching result of the direction matching.

[0038] Optionally, the anomaly analysis unit is used to perform at least one rendering anomaly analysis on the Nth frame image based on the image information of the Nth frame image through a preset anomaly detection network, to obtain at least one anomaly probability of the Nth frame image, wherein the at least one rendering anomaly analysis includes at least one of image mosaic fault analysis, image tomography fault analysis and / or rendering frame drop fault analysis.

[0039] Optionally, the image acquisition unit is used to preprocess the initial Nth frame image using at least one of image processing methods, namely image sampling, smoothing, and color channel processing, to obtain the Nth frame image;

[0040] The initial (N-1)th frame image is preprocessed using at least one of the following image processing methods: image sampling, smoothing, and color channel processing, to obtain the rendered (N-1)th frame image.

[0041] Optionally, the corrected rendering unit is used to obtain the rendering status parameters of the terminal and determine the reason for the rendering anomaly of the Nth frame image based on the rendering status parameters.

[0042] Based on the cause of the rendering error, adjust the rendering state parameters;

[0043] Based on the adjusted rendering state parameters, the original image before rendering is rendered to obtain the rendered frame image.

[0044] Optionally, the rendering anomaly correction device provided in this embodiment of the invention further includes an anomaly reporting unit, used to count the number of anomalies in the rendering frame image corresponding to the anomaly probability that satisfies the anomaly correction condition.

[0045] The ratio between the number of anomalies and the number of detected frame images is calculated to obtain the anomaly rendering ratio;

[0046] When the abnormal rendering ratio meets the preset abnormal reporting conditions, rendering abnormal information is sent to the abnormal information receiving module.

[0047] Accordingly, embodiments of the present invention also provide an electronic device, including a memory and a processor; the memory stores an application program, and the processor is used to run the application program in the memory to perform the steps in any of the rendering anomaly correction methods provided in embodiments of the present invention.

[0048] Accordingly, embodiments of the present invention also provide a computer-readable storage medium storing a plurality of instructions adapted for loading by a processor to execute steps in any of the rendering anomaly correction methods provided in embodiments of the present invention.

[0049] Furthermore, embodiments of the present invention also provide a computer program product, including a computer program or instructions, wherein when the computer program or instructions are executed by a processor, they implement the steps in any of the rendering anomaly correction methods provided in embodiments of the present invention.

[0050] Using the scheme of this embodiment, before displaying the currently rendered Nth frame image, the Nth frame image and the already rendered (N-1)th frame image are acquired. A similarity calculation is performed on the (N-1)th frame image and the Nth frame image to obtain the similarity between them. If the similarity is not greater than a preset similarity threshold, at least one rendering anomaly analysis is performed on the Nth frame image based on its image information to obtain at least one anomaly probability. If the anomaly probability satisfies the corresponding anomaly correction condition, the original image before rendering corresponding to the Nth frame image is corrected and rendered to obtain the rendered frame image. The rendered frame images are displayed. Because this embodiment of the invention calculates similarity between the Nth and (N-1)th frame images based on their rendering effects before displaying the Nth frame image, and performs at least one rendering anomaly analysis when the similarity is not greater than a similarity threshold, the original image of the Nth frame image whose anomaly probability meets the anomaly correction condition is corrected and rendered, and then displayed. Therefore, it is possible to detect rendering anomalies directly during the image rendering process without relying on specific image acquisition tools and complex detection algorithms, thus achieving real-time detection and correcting abnormal rendered images, thereby improving the display effect of the rendered images. Attached Figure Description

[0051] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0052] Figure 1 This is a scene diagram illustrating the rendering anomaly correction method provided in an embodiment of the present invention;

[0053] Figure 2 This is a flowchart of the rendering anomaly correction method provided in an embodiment of the present invention;

[0054] Figure 3This is a schematic diagram of the login page provided in an embodiment of the present invention;

[0055] Figure 4 This is a schematic diagram of the authorization login page provided in an embodiment of the present invention;

[0056] Figure 5 This is another schematic diagram of the authorized login page provided in an embodiment of the present invention;

[0057] Figure 6 This is another schematic diagram of the application login process provided in an embodiment of the present invention;

[0058] Figure 7 This is a schematic diagram of the rendering anomaly correction device provided in an embodiment of the present invention;

[0059] Figure 8 This is another structural schematic diagram of the rendering anomaly correction device provided in an embodiment of the present invention;

[0060] Figure 9 This is a schematic diagram of the structure of the electronic device provided in an embodiment of the present invention. Detailed Implementation

[0061] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0062] This invention provides a rendering anomaly correction method, apparatus, electronic device, and computer-readable storage medium. Specifically, this invention provides a rendering anomaly correction method applicable to a rendering anomaly correction apparatus, which can be integrated into an electronic device.

[0063] The electronic device can be a terminal or other device, including but not limited to mobile terminals and fixed terminals. For example, mobile terminals include but are not limited to smartphones, smartwatches, tablets, laptops, smart vehicles, etc., while fixed terminals include but are not limited to desktop computers, smart TVs, etc.

[0064] The electronic device can also be a server or other similar device. The server can be an independent physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDN (Content Delivery Network), and big data and artificial intelligence platforms, but it is not limited to these.

[0065] The rendering anomaly correction method of this invention can be implemented by the terminal or by both the terminal and the server.

[0066] The following example illustrates the method of correcting rendering errors using both the terminal and the server.

[0067] like Figure 1 As shown, the rendering anomaly correction system provided in this embodiment of the invention includes a terminal 10 and a server 20, etc.; the terminal 10 and the server 20 are connected via a network, such as a wired or wireless network.

[0068] The server 20 can exist as a server that sends images or image frame sequences to be displayed to the terminal 10, and is used to send images or image frame sequences to be displayed to the terminal 10.

[0069] Terminal 10 can be used to acquire the Nth frame image and the already rendered (N-1)th frame image before displaying the currently rendered Nth frame image, calculate the similarity between the (N-1)th frame image and the Nth frame image to obtain the similarity between the Nth frame image and the Nth frame image, if the similarity is not greater than a preset similarity threshold, perform at least one rendering anomaly analysis on the Nth frame image based on the image information of the Nth frame image to obtain at least one anomaly probability of the Nth frame image, if the anomaly probability meets the corresponding anomaly correction condition, correct and render the original image before rendering corresponding to the Nth frame image to obtain the rendered frame image, and display the rendered frame image.

[0070] It is understandable that the steps of rendering exception judgment by terminal 10 can also be performed by server 20.

[0071] The following sections provide detailed descriptions of each example. It should be noted that the order in which the embodiments are described is not intended to limit the preferred order of the embodiments.

[0072] The embodiments of the present invention will be described from the perspective of a rendering anomaly correction device, which can be integrated into a server or terminal.

[0073] like Figure 2As shown, the specific process of the rendering anomaly correction method in this embodiment can be as follows:

[0074] 201. Before the currently rendered Nth frame image is displayed, obtain the Nth frame image and the already rendered (N-1)th frame image.

[0075] The Nth frame image can be the image obtained from the rendering result of the latest rendered image frame in the currently being rendered image frame sequence.

[0076] The (N-1)th frame can be the image obtained from the rendering result of the image frame preceding the most recently rendered image frame in the currently rendering image frame sequence. It should be noted that the image frame corresponding to the Nth frame and the image frame corresponding to the (N-1)th frame can be adjacent image frames, or they can be non-adjacent image frames.

[0077] Generally speaking, the rendering effect of the (N-1)th frame is normal.

[0078] For example, in an image frame sequence including three image frames A, B, and C, the most recently rendered image frame is C. The rendering result of C can be directly used as the Nth frame. The (N-1)th frame can be the rendering result corresponding to either image frame B or image frame A.

[0079] In some examples, N can be any positive integer. If N = 1, there is no N-1 frame image. In this case, the step of calculating the similarity between the N-1 frame image and the Nth frame image can be skipped, and the step of performing at least one rendering anomaly analysis on the Nth frame image based on the image information of the Nth frame image can be directly performed.

[0080] Alternatively, N can be a positive integer greater than or equal to 2. If the currently rendered image is the first frame, it can be assumed that the rendering effect of the first frame is normal, and so on.

[0081] Specifically, an image frame sequence can be a video, an image sequence consisting of a set of continuous or non-continuous images such as a moving image, etc.

[0082] In some optional embodiments, to improve the efficiency of the rendering anomaly detection process, the image of the rendering result obtained directly from the rendering thread can be preprocessed to reduce the amount of computation in the rendering anomaly detection process. Specifically, the step "before displaying the currently rendered Nth frame image, obtain the Nth frame image and the already rendered (N-1)th frame image" may include:

[0083] Before the currently rendered Nth frame image is displayed, based on the current rendering thread, the initial Nth frame image corresponding to the Nth frame image is obtained, and the initial Nth frame image is preprocessed to obtain the Nth frame image;

[0084] Based on the current rendering thread, obtain the initial (N-1)th frame image corresponding to the Nth frame image, and preprocess the initial (N-1)th frame image to obtain the rendered (N-1)th frame image.

[0085] In an electronic device system, a rendering thread is the operational unit that specifically performs rendering tasks. Rendering threads calculate the effects of image frame sequences to generate the final output. It can be understood that rendering threads can run in a central processing unit (CPU) or a dedicated graphics processing unit (GPU).

[0086] The initial Nth frame image can be the rendering result of the most recently rendered image frame in the currently rendering image frame sequence. In other words, the initial Nth frame image can be the image of the Nth frame image before preprocessing.

[0087] The initial (N-1)th frame image can be the rendering result of the image frame that precedes the most recently rendered image frame in the currently rendering image frame sequence. In other words, the initial (N-1)th frame image can be the image of the (N-1)th frame image before preprocessing.

[0088] In some examples, to further reduce the overall time consumption of the rendering anomaly correction process, the currently rendered image can be preprocessed in the rendering thread before being read into the detection thread. That is, the step "Based on the current rendering thread, obtain the initial Nth frame image corresponding to the Nth frame image, and preprocess the initial Nth frame image to obtain the Nth frame image" can include:

[0089] From the current rendering process, obtain the initial Nth frame image obtained from the current rendering;

[0090] The initial Nth frame image is sampled by the current rendering process, and the sampled initial Nth frame image is sent to the detection process to obtain the Nth frame image.

[0091] The methods for sampling the initial Nth frame image can include, but are not limited to, nearest neighbor interpolation, bilinear interpolation, bilinear sampling, etc. Through image sampling, pixels in the initial Nth frame image can be selected or rejected, resulting in an Nth frame image containing information different from the unsampled initial Nth frame image.

[0092] For example, the initial Nth frame image can be downsampled. By downsampling, some pixels in the initial Nth frame image can be rejected, resulting in an Nth frame image with reduced information content.

[0093] On the other hand, to conserve the processing resources of the rendering thread, already rendered images can be processed in the detection thread. For example... Figure 3 As shown, the step "Based on the current rendering thread, obtain the initial (N-1)th frame image corresponding to the Nth frame image, preprocess the initial (N-1)th frame image to obtain the rendered (N-1)th frame image" can include:

[0094] Obtain the initial (N-1)th frame image corresponding to the Nth frame image from the current rendering thread;

[0095] The initial (N-1)th frame image is sent to the detection process, which then samples the initial (N-1)th frame image to obtain the rendered (N-1)th frame image.

[0096] The method for sampling the initial (N-1)th frame image can be the same as or different from the method for sampling the initial Nth frame image. For example, the method for sampling the initial (N-1)th frame image can be bilinear interpolation downsampling, and the method for sampling the initial Nth frame image can be bilinear sampling.

[0097] The detection process is the operational unit within the electronic device's system that specifically performs the task of detecting rendering anomalies. The detection thread can determine whether the Nth frame of the image exhibits any rendering anomalies.

[0098] This example demonstrates how to significantly reduce the time spent reading image data from the GPU to the CPU. For instance, for the initial Nth frame image, sampling is performed directly within the GPU's rendering process, reducing the data volume of the Nth frame and thus reducing the time spent reading it into the CPU's detection process. Similarly, for the initial N-1th frame image, to avoid consuming GPU computing resources, it can also be directly read into the CPU for sampling and processing.

[0099] In other examples, since the already rendered image, i.e. the initial N-1 frame image, is itself rendered by the rendering thread from an image frame, and generally has also undergone the process of rendering anomaly detection and correction, the rendering thread can store the image obtained after sampling the initial N-1 frame image, and can use this image as the N-1 frame image to perform similarity calculation with the N frame image.

[0100] In other words, before the step "obtaining the Nth frame image and the already rendered (N-1)th frame image before displaying the currently rendered Nth frame image", the rendering anomaly correction method provided in this embodiment of the invention may further include:

[0101] Obtain the initial (N-1)th frame image from the current rendering process;

[0102] The initial N-1 frame image is sampled using the current rendering process to obtain the sampled initial N-1 frame image.

[0103] If the initial N-1 frame image is rendered normally, the sampled initial N-1 frame image will be used as the N-1 frame image.

[0104] Correspondingly, the step "Before displaying the currently rendered Nth frame image, obtain the Nth frame image and the already rendered (N-1)th frame image" can include:

[0105] Before the currently rendered Nth frame image is displayed, based on the current rendering thread, the initial Nth frame image corresponding to the Nth frame image is obtained, and the initial Nth frame image is preprocessed to obtain the Nth frame image;

[0106] Based on the current rendering thread, obtain the rendered frame N-1.

[0107] In other words, in some examples, the sampled image obtained during the rendering anomaly correction process of an image that has already been rendered normally can be reused. It is understandable that if the already rendered image is an anomaly, the sampled image obtained during the rendering anomaly correction process will also be anomaly and generally will not be used in the rendering anomaly correction process for the Nth frame.

[0108] Specifically, image preprocessing can include, but is not limited to, image sampling, smoothing, histogram equalization, and / or edge detection. Technicians can choose the appropriate preprocessing method based on the needs of the specific application. For example, the step "preprocess the initial Nth frame image to obtain the Nth frame image" can include:

[0109] The initial Nth frame image is preprocessed using at least one of the following image processing methods: image sampling, smoothing, and color channel processing, to obtain the Nth frame image.

[0110] For example, the step "preprocessing the initial (N-1)th frame image to obtain the (N-1)th frame image" may include:

[0111] The initial (N-1)th frame image is preprocessed using at least one of the following image processing methods: image sampling, smoothing, and color channel processing, to obtain the rendered (N-1)th frame image.

[0112] Preprocessing images using image processing techniques such as smoothing and color channel processing can eliminate noise interference and further optimize the processing time for rendering anomaly correction.

[0113] Image smoothing can be an image processing method used to highlight large areas, low-frequency components, or the main body of an image, or to suppress image noise and high-frequency interference components. Its purpose is to make image brightness change gradually, reduce abrupt gradients, and improve image quality. Image smoothing methods can include interpolation methods, linear smoothing methods, convolution methods, and so on.

[0114] Color channel processing refers to the process of manipulating the color channels of an image. This can include channel splitting, channel merging, and so on.

[0115] In practical applications, image preprocessing can improve the stability of detection algorithms during the rendering anomaly detection stage to some extent.

[0116] 202. Calculate the similarity between the (N-1)th frame image and the Nth frame image to obtain the similarity between the (N-1)th frame image and the Nth frame image.

[0117] In this embodiment of the invention, similarity is a parameter used to measure the degree of similarity between the (N-1)th frame image and the Nth frame image.

[0118] In some examples, similarity calculation can be achieved through histogram matching, matrix factorization, and other methods.

[0119] In other examples, similarity can be obtained by measuring the correlation between the pixel values ​​of the Nth frame image and the (N-1)th frame image. That is, the step "calculate the similarity between the (N-1)th frame image and the Nth frame image to obtain the similarity between the (N-1)th frame image and the Nth frame image" can specifically include:

[0120] Calculate the first mean of the pixel values ​​of the Nth frame image based on the pixel values ​​of each pixel in the Nth frame image;

[0121] Calculate the second mean of the pixel values ​​in the (N-1)th frame image based on the pixel values ​​of each pixel.

[0122] Based on the first mean and the second mean, calculate the similarity between the (N-1)th frame image and the Nth frame image.

[0123] The first mean can be the mean calculated based on the pixel values ​​of each pixel in the Nth frame image. The second mean can be the mean calculated based on the pixel values ​​of each pixel in the (N-1)th frame image.

[0124] Generally, the similarity between the (N-1)th frame and the Nth frame can be calculated using the following formula:

[0125]

[0126]

[0127] Subtracting the mean is equivalent to subtracting the difference in brightness parameters in the image, preventing the two images from having low similarity due to different brightness parameters.

[0128] In some optional embodiments, if the (N-1)th frame image and the Nth frame image have the same size, the step "calculating the similarity between the (N-1)th frame image and the Nth frame image to obtain the similarity between the (N-1)th frame image and the Nth frame image" may specifically include:

[0129] Based on the pixel values ​​of each pixel in the Nth frame image, calculate the first mean and the first standard deviation of the pixel values ​​in the Nth frame image;

[0130] Based on the pixel values ​​of each pixel in the (N-1)th frame image, calculate the second mean and second standard deviation of the pixel values ​​in the (N-1)th frame image;

[0131] The similarity between the (N-1)th frame image and the Nth frame image is calculated based on the first mean, the first standard deviation, the second mean, and the second standard deviation.

[0132] The first standard deviation is the standard deviation calculated based on the pixel values ​​of each pixel in the Nth frame image. The second standard deviation is the standard deviation calculated based on the pixel values ​​of each pixel in the (N-1)th frame image.

[0133] Specifically, the similarity between the (N-1)th frame and the Nth frame can be calculated using the following formula:

[0134]

[0135] Where, σ x σ can be the first standard deviation of the Nth frame image. y It can be the second standard deviation of the N-1th frame image.

[0136] By calculating the similarity between the (N-1)th frame image and the Nth frame image, a preliminary and quick assessment of the rendering effect of the Nth frame image can be made.

[0137] 203. If the similarity is not greater than the preset similarity threshold, perform at least one rendering anomaly analysis on the Nth frame image based on the image information of the Nth frame image to obtain at least one anomaly probability of the Nth frame image.

[0138] The similarity threshold can be a value in the range of -1 to 1, or it can be any value. Those skilled in the art can set it according to the application of the present invention.

[0139] In practical applications, considering that various added effects and filters can significantly impact image content and thus reduce similarity, a relatively high similarity threshold is typically set. If the similarity is greater than this threshold, the (N-1)th frame and the Nth frame are considered almost identical, with no anomalies, and the Nth frame or its corresponding initial Nth frame is directly displayed. If the similarity is not greater than the threshold, further rendering anomaly detection is performed.

[0140] Image information can be information representing the statistical or content features of an image. For example, image information may include, but is not limited to, the mean, variance, gradient, and content vector of image pixel values.

[0141] It is understandable that there can be many types of rendering anomalies in the actual rendering process. For example, rendering anomalies can include black screen failures, screen tearing failures, and pixelation of the image, etc. The at least one rendering anomaly analysis performed in this embodiment of the invention is to analyze at least one of several different rendering failure scenarios.

[0142] For example, in this embodiment of the invention, the Nth frame image can be analyzed for rendering anomalies such as black screen failure analysis, screen distortion failure analysis, and mosaic failure analysis simultaneously or not simultaneously; or the Nth frame image can be analyzed for rendering anomalies such as black screen failure analysis, screen distortion failure analysis, and mosaic failure analysis sequentially. When it is determined that there is a black screen failure in the Nth frame image, the screen distortion failure analysis and mosaic failure analysis are no longer performed.

[0143] Among them, at least one anomaly probability can correspond to different types of rendering anomaly analysis. For example, if three types of rendering anomaly analysis are performed on the Nth frame image, namely black screen fault analysis, screen tearing fault analysis, and mosaic fault analysis, then three anomaly probabilities corresponding to the three types can be obtained respectively.

[0144] Alternatively, at least one anomaly probability may not correspond to a rendering anomaly type. For example, if three types of rendering anomaly analyses are performed on the Nth frame image—black screen fault analysis, distorted screen fault analysis, and mosaic fault analysis—and three probabilities corresponding to each type are obtained, the probability with the highest value among the three probabilities can be taken as the anomaly probability, and so on.

[0145] In related technologies, large neural network models are typically used to directly predict the probability of rendering anomalies in the rendered image. However, with these solutions, it is difficult to deploy the neural network model directly on mobile devices, as it requires significant computing resources and cannot achieve real-time prediction of rendering anomalies.

[0146] In this embodiment of the invention, targeted algorithm designs were implemented for each type of rendering anomaly, enabling the analysis of at least one rendering anomaly using simple and feasible algorithms even with limited computing resources.

[0147] Taking rendering anomalies, including black screen failures, as an example, the step "based on the image information of the Nth frame image, perform at least one rendering anomaly analysis on the Nth frame image to obtain at least one anomaly probability of the Nth frame image" specifically includes:

[0148] Based on the pixel information of the Nth frame image, determine the first variance and the first mean of the pixel values ​​of the Nth frame image;

[0149] Based on the pixel information of the (N-1)th frame image, determine the second variance and the second mean of the pixel values ​​of the (N-1)th frame image;

[0150] Based on the first variance, the first mean, the second variance, and the second mean, a black screen fault analysis is performed on the Nth frame image to obtain the black screen probability of the Nth frame image having a black screen fault.

[0151] The pixel information can be the pixel value of each pixel in the Nth frame image. The first variance can be the variance calculated based on the pixel values ​​of each pixel in the Nth frame image. The second variance can be the variance calculated based on the pixel values ​​of each pixel in the (N-1)th frame image.

[0152] The black screen fault manifests as the (N-1)th frame being normal, while the Nth frame completely loses its content and turns entirely black. By statistically analyzing the mean and variance of the frames, if the variance and mean of the Nth frame are significantly smaller than those of the (N-1)th frame, a black screen fault can be identified in the Nth frame through a reasonable threshold setting; conversely, if the variance and mean of the Nth frame are similar to those of the (N-1)th frame, then the Nth frame can be considered to have no black screen fault.

[0153] In some optional examples, the probability of a black screen can be represented by a value between 0 and 1. Specifically, the probability of a black screen can be calculated using the following formula:

[0154]

[0155] Where, p last p can be an approximate probability of the (N-1)th frame image. current This can be an approximate probability of the Nth frame image. currentIt can be calculated using the following formula:

[0156]

[0157] Where dev is the first variance of the Nth frame image, ave is the first mean of the Nth frame image, and threshold is the preset calculation threshold. last The calculation method and p current Similarly, this embodiment will not be described in detail here.

[0158] Taking rendering anomalies, including screen tearing, as an example, the step "based on the image information of the Nth frame image, perform at least one rendering anomaly analysis on the Nth frame image to obtain at least one anomaly probability of the Nth frame image" can specifically include:

[0159] In the Nth frame of the image, at least two target detection regions are identified;

[0160] Based on the pixel values ​​of each pixel in each target detection region, determine the region pixel features corresponding to each target detection region;

[0161] Based on the pixel features of each region, screen distortion fault analysis is performed on the Nth frame image to obtain the probability of screen distortion fault in the Nth frame image.

[0162] The target detection region can be a region randomly selected in the Nth frame image, or it can be a pre-specified region.

[0163] Among them, region pixel features can be used to represent the statistical or content features of the corresponding target detection region. For example, region pixel features may include, but are not limited to, the mean, variance, and gradient of pixel values ​​in the target detection region.

[0164] In practical applications, screen flickering is a very common rendering anomaly, typically manifesting as random noise in pixel blocks or stripes appearing in a certain direction on the screen. It's usually difficult to design a robust algorithm to detect all screen flickering anomalies; however, by designing targeted algorithm solutions, most screen flickering anomalies can be effectively detected.

[0165] For example, to address the scattered, pixelated screen artifacts caused by random noise distribution, different regions can be randomly selected from the Nth frame image. The mean pixel value within each region is subtracted, and the variance of the pixels within that region is calculated. If the variance values ​​of the randomly selected regions are similar, it can be determined that a scattered, pixelated screen artifact fault exists in the image. Specifically, the step "determine the region pixel features corresponding to the target detection region based on the pixel values ​​of each pixel in the target detection region" can include:

[0166] Based on the pixel values ​​of each pixel in each target detection region, the pixel variance corresponding to each target detection region is determined as the region pixel feature.

[0167] Among them, pixel variance can be the variance calculated based on the pixel values ​​of each pixel in the corresponding target detection region.

[0168] Specifically, to determine whether the variances of each target detection region are similar, it can be calculated that the variance of each region is close to the average variance of all regions, and the difference does not exceed a certain threshold. In other words, the step "Based on the pixel features of each region, perform screen distortion anomaly analysis on the Nth frame image to obtain the probability of screen distortion in the Nth frame image" can specifically include:

[0169] Calculate the average variance based on the variance of each pixel.

[0170] Calculate the difference between the variance of each pixel and the mean variance to obtain the variance difference of each target detection region;

[0171] Based on the differences in each variance, determine the probability of scattered screen distortion in the Nth frame image.

[0172] The variance mean is the average of the variances for each target detection region. The probability of scattered screen artifacts can be calculated based on the number of variance differences that are not greater than a preset judgment threshold.

[0173] In some optional examples, for the case of striped screen distortion, several regions can be randomly selected, and the principal gradient direction of the image within each region can be calculated. If the principal gradient directions of the randomly selected regions are consistent, then the current image is determined to be a striped screen distortion anomaly. That is, the step "determine the region pixel features corresponding to each target detection region based on the pixel values ​​of each pixel point in each target detection region" can specifically include:

[0174] Based on the pixel values ​​of each pixel in each target detection region, the principal direction of the regional gradient corresponding to each target detection region is determined as the regional pixel feature.

[0175] Among them, the principal direction of the regional gradient is the direction of change of the pixel value of each pixel in the corresponding target detection region.

[0176] At this point, the step "based on the pixel features of each region, perform screen distortion analysis on the Nth frame image to obtain the screen distortion probability of the Nth frame image" can specifically include:

[0177] Based on the main gradient direction of each region, direction matching is performed, and the probability of stripe screen fault in the Nth frame image is determined according to the direction matching result.

[0178] Direction matching can involve comparing whether the principal gradient directions of different regions are the same, or calculating the directional differences between the principal gradient directions of different regions. The matching result can be that the principal gradient directions of different regions are the same or different, or it can be the proportion of the principal gradient directions of the same regions among all the principal gradient directions of all regions, and so on.

[0179] Correspondingly, if the matching result is that the main gradient directions of each region are the same, the probability of striped screen can be 1; if the matching result is that the main gradient directions of each region are different, the probability of striped screen can be 0; or, the proportion of the same main gradient direction in all regions can be used as the probability of striped screen, etc.

[0180] In some examples, a classification network can be designed to determine whether an anomaly exists in the Nth frame image. The step "based on the image information of the Nth frame image, perform at least one rendering anomaly analysis on the Nth frame image to obtain at least one anomaly probability of the Nth frame image" can specifically include:

[0181] Based on the image information of the Nth frame, at least one rendering anomaly analysis is performed on the Nth frame through a preset anomaly detection network to obtain at least one anomaly probability of the Nth frame. The at least one rendering anomaly analysis includes at least one of image mosaic fault analysis, image tomography fault analysis, and rendering frame drop fault analysis.

[0182] Mosaic refers to the degradation of tonal details in certain areas of an image, resulting in a disordered color block effect. Because this blurring appears to be composed of small squares, this image effect is figuratively called a mosaic. Image mosaic-like defects refer to the appearance of a mosaic-like effect in an image that did not originally have one; this situation is known as image mosaic-like defects.

[0183] Image tomography is characterized by a failure to exhibit subtle gradations in color depth, resulting in a patchy, broken appearance instead of smooth gradients. For example, a row of pixels in an image might normally have values ​​of (0, 0.25, 0.5, 0.75, 1, 1.25, 1.5, 1.75, 2, 2.25, 2.5…), but in the Nth frame, that row has values ​​of (0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2…). In this case, image tomography exists in the Nth frame.

[0184] Frame dropping during rendering refers to a problem where a sequence of image frames is not rendered, meaning the rendered frame sequence is discontinuous. For example, frames a and b displayed on the terminal should be two adjacent rendered frames in the frame sequence, but in reality, frame a1 between a and b is not displayed. This is a case of frame dropping during rendering.

[0185] Understandably, to ensure the effectiveness of rendering anomaly analysis, the anomaly detection network can be pre-trained and used in practical applications. Specifically, during training, normally rendered images and images with at least one rendering anomaly, such as mosaic-like faults, image tortuosity faults, and rendering frame dropping faults, can be used for training.

[0186] To differentiate between different anomalies, there is no need to manually design features or standards; high-dimensional feature extraction and distance division can be achieved by relying on neural networks.

[0187] It should be noted that, in this embodiment of the invention, multi-threading and other techniques can be used to perform black screen fault analysis, screen distortion fault analysis, and image mosaic fault analysis on the Nth frame image in different detection threads. These different detection threads can be synchronous or asynchronous.

[0188] In other examples, such as Figure 4 As shown, within the same detection thread, black screen fault analysis, distorted screen fault analysis, and mosaic fault analysis can be performed sequentially on the Nth frame image. It is understandable that only one or some types of anomaly analysis can be performed on the Nth frame image, or all types of anomaly analysis can be performed.

[0189] For example, we can first perform black screen fault analysis on the Nth frame. If the probability of a black screen anomaly meets the anomaly correction condition, we can stop performing screen flickering fault analysis and mosaic fault analysis, etc. Alternatively, we can continue performing screen flickering fault analysis and mosaic fault analysis, etc., regardless of whether the probability of a black screen anomaly meets the anomaly correction condition.

[0190] It is understood that the order of anomaly analysis for each type can be arbitrarily adjusted, and this embodiment of the invention does not limit this.

[0191] 204. If the anomaly probability satisfies the corresponding anomaly correction condition, the original image before rendering corresponding to the Nth frame image is corrected and rendered to obtain the rendered frame image.

[0192] The anomaly correction conditions can be set by technical personnel according to actual application needs. For example, if a higher anomaly probability indicates a higher probability of rendering anomalies in the Nth frame, the anomaly correction condition can be that the anomaly probability is greater than a preset anomaly threshold. Alternatively, if a higher anomaly probability indicates a lower probability of rendering anomalies in the Nth frame, the anomaly correction condition can be that the anomaly probability is less than a preset anomaly threshold, and so on.

[0193] For example, we can determine the rendering exception type corresponding to the exception probability, and set different exception correction conditions for different rendering exception types.

[0194] Specifically, the original image is the image frame corresponding to the Nth frame in the image frame sequence. The rendered frame image is the image obtained by rendering the original image.

[0195] In practical applications, such as Figure 5 As shown, when an anomaly is determined in the current frame, the electronic device can troubleshoot common causes and perform rapid corrections. The original image before rendering, corresponding to the Nth frame, is corrected and rendered to obtain the target rendered frame image, including:

[0196] Obtain the rendering status parameters of the terminal, and determine the reason for the rendering anomaly of the Nth frame image based on the rendering status parameters;

[0197] Adjust the rendering state parameters according to the cause of the rendering error;

[0198] Based on the adjusted rendering state parameters, the original image before rendering is rendered to obtain the rendered frame image.

[0199] Specifically, rendering status parameters may include, but are not limited to, the availability of video memory, memory, CPU usage, and number of threads of the electronic device.

[0200] For example, if the visual anomaly is caused by insufficient video memory, quickly releasing unnecessary video memory usage after the system performs video memory statistics can quickly restore normal visual quality. Other issues can also be fixed by reloading textures, skipping the current abnormal or stuttering scene, or restarting the rendering thread.

[0201] 205. Display the rendered frame image.

[0202] In some examples, the rendered image is the image obtained by rendering the original image normally. That is, it is necessary to perform rendering anomaly detection on the rendered image of the original image. If the anomaly probability of the rendered image of the original image does not meet the corresponding anomaly correction condition, then the rendered image of the original image can be used as the rendered frame image.

[0203] In other examples, to ensure smooth display, the rendered frame image may be the image obtained by re-rendering the original image one or n times, and may not necessarily be the image with normal rendering effect.

[0204] In practical applications, to facilitate technicians in locating and resolving rendering problems, the rendering anomaly correction method provided in this embodiment of the invention may further include:

[0205] The number of anomalies in the frame images corresponding to the anomaly probabilities that satisfy the anomaly correction conditions is counted.

[0206] The ratio between the number of anomalies and the number of detected frame images is used to obtain the anomaly rendering ratio;

[0207] When the abnormal rendering ratio meets the preset abnormal reporting conditions, rendering abnormal information is sent to the abnormal information receiving module.

[0208] Specifically, the conditions for anomaly reporting can be that the proportion of abnormal rendering exceeds a preset reporting proportion threshold. Generally, for each returned anomaly probability, the system will accumulate multiple results and only report anomalies when the proportion of anomalies that meet the anomaly correction conditions exceeds the preset reporting proportion threshold.

[0209] The exception information receiving module can be used to store rendering exception information. Specifically, the rendering exception information may include, but is not limited to, the rendering time corresponding to the rendering exception, the cause of the exception, the device identifier where the exception occurred, etc.

[0210] In some optional examples, embodiments of the present invention can also set a detection frequency, which determines how many frames a detection is initiated. A lower detection frequency can effectively save the impact of detection time on the overall frame rate.

[0211] It is understandable that if the anomaly probability of the Nth frame image does not meet the anomaly correction condition, the Nth frame image can be displayed directly, or the initial Nth frame image corresponding to the Nth frame image can be displayed.

[0212] As can be seen from the above, in this embodiment of the invention, before the currently rendered Nth frame image is displayed, the Nth frame image and the already rendered (N-1)th frame image are acquired. A similarity calculation is performed between the (N-1)th and Nth frame images to obtain the similarity between them. If the similarity is not greater than a preset similarity threshold, at least one rendering anomaly analysis is performed on the Nth frame image based on its image information to obtain at least one anomaly probability. If the anomaly probability satisfies the corresponding anomaly correction condition, the original image before rendering corresponding to the Nth frame image is corrected and rendered to obtain the rendered frame image. The rendered frame image is then further processed... The present invention performs a similarity calculation based on the similarity of the rendering effect between the Nth frame image and the (N-1)th frame image before displaying the rendered Nth frame image. When the similarity is not greater than the similarity threshold, at least one rendering anomaly analysis is further performed. The original image corresponding to the Nth frame image whose anomaly probability meets the anomaly correction condition is corrected and rendered and displayed. Therefore, it can directly detect rendering anomalies during the image rendering process without relying on specific image acquisition tools and complex detection algorithms, thus achieving real-time detection and correcting abnormal rendered images, thereby improving the display effect of the rendered image.

[0213] Based on the methods described in the preceding embodiments, the following examples will provide further detailed explanations.

[0214] In this embodiment, the combination Figure 1 The system will be explained.

[0215] like Figure 6 As shown, the specific process of the rendering anomaly correction method in this embodiment is as follows:

[0216] 601. Before the Nth frame of the currently rendered image is displayed, the terminal acquires the Nth frame image and the (N-1)th frame image that has already been rendered.

[0217] Specifically, step 601 may include:

[0218] From the current rendering process, obtain the initial Nth frame image obtained from the current rendering;

[0219] The initial Nth frame image is sampled by the current rendering process, and the sampled initial Nth frame image is sent to the detection process to obtain the Nth frame image.

[0220] Obtain the initial (N-1)th frame image corresponding to the Nth frame image from the current rendering thread;

[0221] The initial (N-1)th frame image is sent to the detection process, which then samples the initial (N-1)th frame image to obtain the N-1th frame image.

[0222] 602. The terminal calculates the similarity between the (N-1)th frame image and the Nth frame image to obtain the similarity between the (N-1)th frame image and the Nth frame image.

[0223] Generally, the similarity between the (N-1)th frame and the Nth frame can be calculated using the following formula:

[0224]

[0225]

[0226] The calculated similarity.

[0227] Subtracting the mean is equivalent to subtracting the difference in brightness parameters in the image, preventing the two images from having low similarity due to different brightness parameters.

[0228] 603. If the similarity is not greater than the preset similarity threshold, the terminal performs black screen fault analysis on the Nth frame image based on the image information of the Nth frame image to obtain the probability of black screen fault in the Nth frame image.

[0229] A black screen fault manifests as the (N-1)th frame appearing normal, while the Nth frame completely loses its content and turns entirely black. By statistically analyzing the mean and variance of the frames, if the variance and mean of the Nth frame are significantly lower than those of the (N-1)th frame, a black screen fault can be identified in the Nth frame using a reasonable threshold setting. Conversely, if the variance and mean of the Nth frame are similar to those of the (N-1)th frame, then the Nth frame can be considered to be free of a black screen fault.

[0230] 604. If the probability of a black screen failure does not meet the abnormal correction conditions, the terminal performs a screen distortion failure analysis on the Nth frame image based on the image information of the Nth frame image to obtain the probability of a screen distortion failure in the Nth frame image.

[0231] In practical applications, screen flickering is a very common rendering anomaly, typically manifesting as random noise in pixel blocks or stripes appearing in a certain direction on the screen. It's usually difficult to design a robust algorithm to detect all cases of screen flickering, but by designing targeted algorithm solutions, most screen flickering issues can be effectively detected.

[0232] For example, to address a scattered, speckled screen display issue with randomly distributed noise, different regions can be randomly selected from the Nth frame image. The mean pixel value within each region is subtracted, and the variance of the pixels within that region is calculated. If the variance values ​​of the randomly selected regions are similar, it can be identified as a scattered, speckled screen display issue.

[0233] To address the striped screen distortion issue, several regions can be randomly selected, and the principal gradient directions of the image within each region can be calculated. If the principal gradient directions of the randomly selected regions are consistent, then a striped screen distortion issue is determined to exist in the current image.

[0234] 605. If the probability of screen distortion does not meet the abnormal correction conditions, the terminal performs special fault analysis on the Nth frame image based on the image information of the Nth frame image to obtain the special fault probability of the Nth frame image.

[0235] In some examples, classification networks can be designed to determine whether the Nth frame of the image has special faults such as image mosaic fault analysis, image tomography fault analysis, and rendering frame loss fault analysis.

[0236] 606. If the probability of a special fault meets the anomaly correction conditions, proceed to step 607. If the probability of a special fault does not meet the anomaly correction conditions, proceed to step 608.

[0237] 607. The terminal performs corrective rendering on the original image before rendering corresponding to the Nth frame image to obtain the rendered frame image.

[0238] If an anomaly is detected in the current frame, the electronic device can troubleshoot common causes and perform rapid corrections. The original image before rendering, corresponding to the Nth frame, is corrected and rendered to obtain the target rendered frame image, including:

[0239] Obtain the rendering status parameters of the terminal, and determine the reason for the rendering anomaly of the Nth frame image based on the rendering status parameters;

[0240] Adjust the rendering state parameters according to the cause of the rendering error;

[0241] Based on the adjusted rendering state parameters, the original image before rendering is rendered to obtain the rendered frame image.

[0242] Specifically, rendering status parameters may include, but are not limited to, the availability of video memory, memory, CPU usage, and number of threads of the electronic device.

[0243] For example, if the visual anomaly is caused by insufficient video memory, quickly releasing unnecessary video memory usage after the system performs video memory statistics can quickly restore normal visual quality. Other issues can also be fixed by reloading textures, skipping the current abnormal or stuttering scene, or restarting the rendering thread.

[0244] 608. The terminal displays the rendered frame image.

[0245] If the anomaly probabilities of each type do not meet the anomaly correction conditions, the Nth frame image or the initial Nth frame image corresponding to the Nth frame image can be displayed as the rendered frame image.

[0246] Understandably, after anomaly detection is completed, the anomaly probability P of the current frame is returned, ranging from 0 to 1. After receiving the result, the CPU processing thread performs further analysis and system processing, mainly including two parts: 1. Detection frequency setting and probability result statistics; 2. Screen correction and anomaly reporting. The first part, the detection frequency, determines how many frames the system initiates a detection. A lower detection frequency can effectively save detection time and reduce its impact on the overall frame rate. Simultaneously, for each returned anomaly probability, the system accumulates multiple results and only reports an anomaly when the proportion exceeding the threshold setting is predominant. In the second part, if an anomaly is confirmed in the current screen, the system will investigate common causes and perform rapid corrections. For example, if the screen anomaly is caused by insufficient video memory, quickly releasing unnecessary video memory usage after system video memory statistics can quickly restore normal screen display. Other issues can also be fixed by reloading textures, skipping the current abnormal or stuttering frame, restarting the rendering thread, etc., ensuring rapid repair when encountering anomalies during use. At the same time, the screen anomaly situation and specific parameter information are reported in the background, facilitating subsequent program optimization and creating positive feedback.

[0247] As can be seen from the above, in this embodiment of the invention, before the currently rendered Nth frame image is displayed, the Nth frame image and the already rendered (N-1)th frame image are acquired. A similarity calculation is performed between the (N-1)th and Nth frame images to obtain the similarity between them. If the similarity is not greater than a preset similarity threshold, at least one rendering anomaly analysis is performed on the Nth frame image based on its image information to obtain at least one anomaly probability. If the anomaly probability satisfies the corresponding anomaly correction condition, the original image before rendering corresponding to the Nth frame image is corrected and rendered to obtain the rendered frame image. The rendered frame image is then further processed... The present invention performs a similarity calculation based on the similarity of the rendering effect between the Nth frame image and the (N-1)th frame image before displaying the rendered Nth frame image. When the similarity is not greater than the similarity threshold, at least one rendering anomaly analysis is further performed. The original image corresponding to the Nth frame image whose anomaly probability meets the anomaly correction condition is corrected and rendered and displayed. Therefore, it can directly detect rendering anomalies during the image rendering process without relying on specific image acquisition tools and complex detection algorithms, thus achieving real-time detection and correcting abnormal rendered images, thereby improving the display effect of the rendered image.

[0248] To better implement the above methods, this embodiment of the invention also provides a rendering anomaly correction device.

[0249] refer to Figure 7 The device includes:

[0250] The image acquisition unit 701 can be used to acquire the Nth frame image and the already rendered (N-1)th frame image before the currently rendered Nth frame image is displayed;

[0251] The similarity calculation unit 702 can be used to calculate the similarity between the (N-1)th frame image and the Nth frame image to obtain the similarity between the (N-1)th frame image and the Nth frame image;

[0252] The anomaly analysis unit 703 can be used to perform at least one rendering anomaly analysis on the Nth frame image based on the image information of the Nth frame image if the similarity is not greater than a preset similarity threshold, so as to obtain at least one anomaly probability of the Nth frame image.

[0253] The modified rendering unit 704 can be used to modify and render the original image before rendering the Nth frame image if the abnormal probability meets the corresponding abnormal correction condition, so as to obtain the rendered frame image.

[0254] The image display unit 705 can be used to display the rendered frame image.

[0255] In some optional embodiments, the image acquisition unit 701 can be used to acquire the initial Nth frame image corresponding to the Nth frame image based on the current rendering thread before the Nth frame image is displayed, and to preprocess the initial Nth frame image to obtain the Nth frame image.

[0256] Based on the current rendering thread, obtain the initial (N-1)th frame image corresponding to the Nth frame image, and preprocess the initial (N-1)th frame image to obtain the N-1th frame image.

[0257] In some optional embodiments, the image acquisition unit 701 can be used to acquire the initial Nth frame image obtained by the current rendering process.

[0258] The initial Nth frame image is sampled by the current rendering process, and the sampled initial Nth frame image is sent to the detection process to obtain the Nth frame image.

[0259] Obtain the initial (N-1)th frame image corresponding to the Nth frame image from the current rendering thread;

[0260] The initial (N-1)th frame image is sent to the detection process, which then samples the initial (N-1)th frame image to obtain the N-1th frame image.

[0261] In some optional embodiments, the similarity calculation unit 702 can be used to calculate a first mean of the pixel values ​​of the Nth frame image based on the pixel values ​​of each pixel in the Nth frame image;

[0262] Calculate the second mean of the pixel values ​​in the (N-1)th frame image based on the pixel values ​​of each pixel.

[0263] Based on the first mean and the second mean, calculate the similarity between the (N-1)th frame image and the Nth frame image.

[0264] In some optional embodiments, the anomaly analysis unit 703 can be used to determine a first variance and a first mean of the pixel values ​​of the Nth frame image based on the pixel information of the Nth frame image.

[0265] Based on the pixel information of the (N-1)th frame image, determine the second variance and the second mean of the pixel values ​​of the (N-1)th frame image;

[0266] Based on the first variance, the first mean, the second variance, and the second mean, a black screen fault analysis is performed on the Nth frame image to obtain the black screen probability of the Nth frame image having a black screen fault.

[0267] In some optional embodiments, the anomaly analysis unit 703 can be used to determine at least two target detection regions in the Nth frame image;

[0268] Based on the pixel values ​​of each pixel in each target detection region, determine the region pixel features corresponding to each target detection region;

[0269] Based on the pixel features of each region, screen distortion fault analysis is performed on the Nth frame image to obtain the probability of screen distortion fault in the Nth frame image.

[0270] In some optional embodiments, the anomaly analysis unit 703 can be used to determine the pixel variance corresponding to each target detection region as a region pixel feature based on the pixel value of each pixel point in each target detection region.

[0271] Calculate the average variance based on the variance of each pixel.

[0272] Calculate the difference between the variance of each pixel and the mean variance to obtain the variance difference of each target detection region;

[0273] Based on the differences in each variance, determine the probability of scattered screen distortion in the Nth frame image.

[0274] In some optional embodiments, the anomaly analysis unit 703 can be used to determine the main direction of the regional gradient corresponding to each target detection region as the regional pixel feature based on the pixel value of each pixel in each target detection region.

[0275] Based on the main gradient direction of each region, direction matching is performed, and the probability of stripe screen fault in the Nth frame image is determined according to the direction matching result.

[0276] In some optional embodiments, the anomaly analysis unit 703 can be used to perform at least one rendering anomaly analysis on the Nth frame image based on the image information of the Nth frame image through a preset anomaly detection network, and obtain at least one anomaly probability of the Nth frame image. The at least one rendering anomaly analysis may include at least one of image mosaic fault analysis, image tomography fault analysis and rendering frame drop fault analysis.

[0277] In some optional embodiments, the image acquisition unit 701 can be used to preprocess the initial Nth frame image through at least one of image processing methods, namely image sampling, smoothing and color channel processing, to obtain the Nth frame image;

[0278] The initial (N-1)th frame image is preprocessed using at least one of the following image processing methods: image sampling, smoothing, and color channel processing, to obtain the (N-1)th frame image.

[0279] In some optional embodiments, the modified rendering unit 704 can be used to obtain the rendering status parameters of the terminal and determine the reason for the rendering abnormality of the Nth frame image based on the rendering status parameters.

[0280] Adjust the rendering state parameters according to the cause of the rendering error;

[0281] Based on the adjusted rendering state parameters, the original image before rendering is rendered to obtain the rendered frame image.

[0282] In some alternative embodiments, such as Figure 8 As shown, the rendering anomaly correction device provided in this embodiment of the invention may further include an anomaly reporting unit 706, which can be used to count the number of anomalies in the frame image corresponding to the anomaly probability that meets the anomaly correction conditions.

[0283] The ratio between the number of anomalies and the number of detected frame images is used to obtain the anomaly rendering ratio;

[0284] When the abnormal rendering ratio meets the preset abnormal reporting conditions, rendering abnormal information is sent to the abnormal information receiving module.

[0285] As can be seen from the above, the rendering anomaly correction device can acquire the Nth frame image and the already rendered (N-1)th frame image before displaying the currently rendered Nth frame image. It then calculates the similarity between the (N-1)th and Nth frame images to obtain their similarity. If the similarity is not greater than a preset similarity threshold, it performs at least one rendering anomaly analysis on the Nth frame image based on its image information to obtain at least one anomaly probability. If the anomaly probability satisfies the corresponding anomaly correction condition, it corrects and renders the original image of the Nth frame image before rendering, resulting in the rendered frame image. The rendered frame image... The present invention performs a similarity calculation based on the similarity of the rendering effect of the Nth frame image and the (N-1)th frame image before displaying the rendered Nth frame image. When the similarity is not greater than the similarity threshold, at least one rendering anomaly analysis is further performed. The original image corresponding to the Nth frame image whose anomaly probability meets the anomaly correction condition is corrected and rendered and displayed. Therefore, it can directly detect rendering anomalies during the image rendering process without relying on specific image acquisition tools and complex detection algorithms, thus achieving real-time detection and correcting abnormal rendered images, thereby improving the display effect of the rendered image.

[0286] Furthermore, embodiments of the present invention also provide an electronic device, which may be a terminal or a server, etc. Figure 9 As shown, it illustrates a structural schematic diagram of the electronic device involved in an embodiment of the present invention, specifically:

[0287] The electronic device may include a radio frequency (RF) circuit 901, a memory 902 including one or more computer-readable storage media, an input unit 903, a display unit 904, a sensor 905, an audio circuit 906, a wireless fidelity (WiFi) module 907, a processor 908 including one or more processing cores, and a power supply 909, etc. Those skilled in the art will understand that... Figure 9 The electronic device structure shown does not constitute a limitation on the electronic device and may include more or fewer components than shown, or combine certain components, or have different component arrangements. Wherein:

[0288] RF circuit 901 can be used for receiving and transmitting signals during information transmission or calls. Specifically, it receives downlink information from the base station and hands it over to one or more processors 908 for processing; additionally, it transmits uplink data to the base station. Typically, RF circuit 901 includes, but is not limited to, an antenna, at least one amplifier, a tuner, one or more oscillators, a Subscriber Identity Module (SIM) card, a transceiver, a coupler, a low-noise amplifier (LNA), a duplexer, etc. Furthermore, RF circuit 901 can also communicate wirelessly with networks and other devices. Wireless communication can use any communication standard or protocol, including but not limited to GSM, GPRS, CDMA, WCDMA, LTE, email, and SMS.

[0289] The memory 902 can be used to store software programs and modules. The processor 908 executes various functional applications and data processing by running the software programs and modules stored in the memory 902. The memory 902 may mainly include a program storage area and a data storage area. The program storage area may store the operating system, application programs required for at least one function (such as sound playback function, image playback function, etc.), etc.; the data storage area may store data created according to the use of the electronic device (such as audio data, telephone directory, etc.). In addition, the memory 902 may include high-speed random access memory, and may also include non-volatile memory, such as at least one disk storage device, flash memory device, or other volatile solid-state storage device. Accordingly, the memory 902 may also include a memory controller to provide access to the memory 902 for the processor 908 and the input unit 903.

[0290] Input unit 903 can be used to receive input digital or character information, and to generate keyboard, mouse, joystick, optical, or trackball signal inputs related to user settings and function control. Specifically, in one embodiment, input unit 903 may include a touch-sensitive surface and other input devices. A touch-sensitive surface, also known as a touch display or touchpad, can collect user touch operations on or near it (e.g., user operations using fingers, styluses, or any suitable object or accessory on or near the touch-sensitive surface) and drive corresponding connection devices according to a pre-set program. Optionally, the touch-sensitive surface may include a touch detection device and a touch controller. The touch detection device detects the user's touch position and the signal generated by the touch operation, transmitting the signal to the touch controller; the touch controller receives touch information from the touch detection device, converts it into touch point coordinates, sends it to the processor 908, and can receive and execute commands from the processor 908. Furthermore, various types of touch-sensitive surfaces, such as resistive, capacitive, infrared, and surface acoustic wave, can be used. In addition to the touch-sensitive surface, input unit 903 may also include other input devices. Specifically, other input devices may include, but are not limited to, one or more of the following: physical keyboard, function keys (such as volume control buttons, power buttons, etc.), trackball, mouse, joystick, etc.

[0291] Display unit 904 can be used to display information input by the user or information provided to the user, as well as various graphical user interfaces of electronic devices. These graphical user interfaces can be composed of graphics, text, icons, video, and any combination thereof. Display unit 904 may include a display panel, optionally configured as a liquid crystal display (LCD), organic light-emitting diode (OLED), or similar form. Furthermore, a touch-sensitive surface may cover the display panel. When the touch-sensitive surface detects a touch operation on or near it, it transmits the information to processor 908 to determine the type of touch event. Subsequently, processor 908 provides corresponding visual output on the display panel according to the type of touch event. Although in Figure 9 In this context, the touch-sensitive surface and the display panel are two separate components for implementing input and output functions. However, in some embodiments, the touch-sensitive surface and the display panel can be integrated to achieve both input and output functions.

[0292] Electronic devices may also include at least one sensor 905, such as a light sensor, a motion sensor, and other sensors. Specifically, the light sensor may include an ambient light sensor and a proximity sensor, wherein the ambient light sensor can adjust the brightness of the display panel according to the ambient light level, and the proximity sensor can turn off the display panel and / or backlight when the electronic device is moved to the ear. As a type of motion sensor, a gravity acceleration sensor can detect the magnitude of acceleration in various directions (generally three axes), and can detect the magnitude and direction of gravity when stationary. It can be used for applications that recognize the phone's posture (such as landscape / portrait switching, related games, magnetometer posture calibration), vibration recognition related functions (such as pedometers, taps), etc. Other sensors that may be configured in electronic devices, such as gyroscopes, barometers, hygrometers, thermometers, and infrared sensors, will not be described in detail here.

[0293] Audio circuitry 906, a speaker, and a microphone provide an audio interface between the user and the electronic device. Audio circuitry 906 converts received audio data into electrical signals, transmits them to the speaker, and the speaker converts them into sound signals for output. Conversely, the microphone converts collected sound signals into electrical signals, which are then received by audio circuitry 906, converted back into audio data, and processed by processor 908. The processed data is then transmitted via RF circuitry 901 to, for example, another electronic device, or output to memory 902 for further processing. Audio circuitry 906 may also include an earphone jack to facilitate communication between external headphones and the electronic device.

[0294] WiFi is a short-range wireless transmission technology. Electronic devices using the WiFi module 907 can help users send and receive emails, browse web pages, and access streaming media, providing users with wireless broadband internet access. Although Figure 9 WiFi module 907 is shown, but it is understood that it is not a necessary component of the electronic device and can be omitted as needed without changing the nature of the invention.

[0295] The processor 908 is the control center of the electronic device, connecting various parts of the phone via various interfaces and lines. It executes software programs and / or modules stored in the memory 902, and calls data stored in the memory 902 to perform various functions and process data. Optionally, the processor 908 may include one or more processing cores; preferably, the processor 908 may integrate an application processor and a modem processor, wherein the application processor mainly handles the operating system, user interface, and applications, and the modem processor mainly handles wireless communication. It is understood that the modem processor may not be integrated into the processor 908.

[0296] The electronic device also includes a power supply 909 (such as a battery) that supplies power to various components. Preferably, the power supply can be logically connected to the processor 908 through a power management system, thereby enabling functions such as charging, discharging, and power consumption management through the power management system. The power supply 909 may also include one or more DC or AC power supplies, recharging systems, power fault detection circuits, power converters or inverters, power status indicators, and other arbitrary components.

[0297] Although not shown, the electronic device may also include a camera, Bluetooth module, etc., which will not be described in detail here. Specifically, in this embodiment, the processor 908 in the electronic device loads the executable files corresponding to the processes of one or more applications into the memory 902 according to the following instructions, and the processor 908 runs the applications stored in the memory 902 to realize various functions, as follows:

[0298] Before the currently rendered Nth frame image is displayed, obtain the Nth frame image and the already rendered (N-1)th frame image;

[0299] Calculate the similarity between the (N-1)th frame image and the Nth frame image to obtain the similarity between the (N-1)th frame image and the Nth frame image;

[0300] If the similarity is not greater than the preset similarity threshold, perform at least one rendering anomaly analysis on the Nth frame image based on the image information of the Nth frame image to obtain at least one anomaly probability of the Nth frame image;

[0301] If the anomaly probability meets the corresponding anomaly correction condition, the original image before rendering corresponding to the Nth frame image is corrected and rendered to obtain the rendered frame image.

[0302] Display the rendered frame image.

[0303] Those skilled in the art will understand that all or part of the steps in the various methods of the above embodiments can be performed by instructions, or by instructions controlling related hardware. These instructions can be stored in a computer-readable storage medium and loaded and executed by a processor.

[0304] To this end, embodiments of the present invention provide a computer-readable storage medium storing a plurality of instructions that can be loaded by a processor to execute steps in any of the rendering anomaly correction methods provided in the embodiments of the present invention. For example, the instructions can execute the following steps:

[0305] Before the currently rendered Nth frame image is displayed, obtain the Nth frame image and the already rendered (N-1)th frame image;

[0306] Calculate the similarity between the (N-1)th frame image and the Nth frame image to obtain the similarity between the (N-1)th frame image and the Nth frame image;

[0307] If the similarity is not greater than the preset similarity threshold, perform at least one rendering anomaly analysis on the Nth frame image based on the image information of the Nth frame image to obtain at least one anomaly probability of the Nth frame image;

[0308] If the anomaly probability meets the corresponding anomaly correction condition, the original image before rendering corresponding to the Nth frame image is corrected and rendered to obtain the rendered frame image.

[0309] Display the rendered frame image.

[0310] For details on the implementation of each of the above operations, please refer to the previous examples, which will not be repeated here.

[0311] The computer-readable storage medium may include: read-only memory (ROM), random access memory (RAM), disk or optical disk, etc.

[0312] Since the instructions stored in the computer-readable storage medium can execute the steps in any of the rendering anomaly correction methods provided in the embodiments of the present invention, the beneficial effects that any of the rendering anomaly correction methods provided in the embodiments of the present invention can achieve can be realized, as detailed in the preceding embodiments, and will not be repeated here.

[0313] According to one aspect of this application, a computer program product or computer program is also provided, comprising computer instructions stored in a computer-readable storage medium. A processor of an electronic device reads the computer instructions from the computer-readable storage medium and executes the computer instructions, causing the electronic device to perform the methods provided in the various optional implementations of the above embodiments.

[0314] The above provides a detailed description of a rendering anomaly correction method, apparatus, electronic device, and storage medium provided by embodiments of the present invention. Specific examples have been used to illustrate the principles and implementation methods of the present invention. The descriptions of the above embodiments are only for the purpose of helping to understand the method and core ideas of the present invention. At the same time, those skilled in the art will recognize that there will be changes in the specific implementation methods and application scope based on the ideas of the present invention. Therefore, the content of this specification should not be construed as a limitation of the present invention.

Claims

1. A method of rendering anomaly correction, characterized by, The method comprises the following steps: Before the current Nth frame image is displayed, the Nth frame image and the N-1th frame image which has been rendered are obtained; Similarity calculation is performed on the N-1th frame image and the Nth frame image to obtain the similarity between the N-1th frame image and the Nth frame image; If the similarity is not greater than a preset similarity threshold, at least one kind of rendering abnormality analysis is performed on the Nth frame image based on image information of the Nth frame image to obtain at least one kind of abnormality probability of the Nth frame image; the rendering abnormality analysis comprises at least one or more of black screen fault analysis, screen flower fault analysis, image mosaic fault analysis, image fault analysis or rendering frame loss fault analysis; when the rendering abnormality analysis is the black screen fault analysis, the step of performing at least one kind of rendering abnormality analysis on the Nth frame image based on the image information of the Nth frame image to obtain at least one kind of abnormality probability of the Nth frame image comprises the following steps: based on pixel information of the Nth frame image, a first variance and a first average of pixel values of the Nth frame image are determined; based on pixel information of the N-1th frame image, a second variance and a second average of pixel values of the N-1th frame image are determined; the black screen probability is calculated by the following formula: Wherein, plast is the approximate probability of the N-1th frame image, pcurrent is the approximate probability of the Nth frame image; pcurrent is calculated by the following formula: Wherein, dev is the first variance of the Nth frame image, ave is the first average of the Nth frame image, and threshold is a preset calculation threshold; the calculation of plast is the same as that of pcurrent; If the abnormality probability satisfies a corresponding abnormality correction condition, the original image corresponding to the Nth frame image before rendering is corrected and rendered to obtain a rendered frame image; The rendered frame image is displayed.

2. The rendering anomaly correction method of claim 1, wherein, The step of obtaining the Nth frame image and the N-1th frame image which has been rendered before the current Nth frame image is displayed comprises the following steps: Before the current Nth frame image is displayed, based on a current rendering thread, an initial Nth frame image corresponding to the Nth frame image is obtained, and the initial Nth frame image is preprocessed to obtain the Nth frame image; Based on the current rendering thread, an initial N-1th frame image corresponding to the N-1th frame image is obtained, and the initial N-1th frame image is preprocessed to obtain the N-1th frame image which has been rendered.

3. The rendering anomaly correction method of claim 2, wherein, The step of obtaining the Nth frame image and the N-1th frame image which has been rendered before the current Nth frame image is displayed comprises the following steps: The initial Nth frame image obtained by the current rendering process is obtained from the current rendering process; The initial Nth frame image is image-sampled by the current rendering process, and the initial Nth frame image after image sampling is sent to a detection process to obtain the Nth frame image; The method comprises the following steps: According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated.

4. The rendering anomaly correction method of claim 1, wherein, According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated.

5. The rendering anomaly correction method of claim 1, wherein, According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated.

6. The rendering anomaly correction method of claim 5, wherein, According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated.

7. The rendering anomaly correction method of claim 5, wherein, According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth frame image is calculated. According to the pixel value of each pixel point in the Nth frame image, a first mean value of the pixel value of the Nth 8. The rendering anomaly correction method of claim 1, wherein, The step of performing at least one rendering anomaly analysis on the Nth frame image based on the image information of the Nth frame image to obtain at least one anomaly probability of the Nth frame image includes: Based on the image information of the Nth frame image, at least one rendering anomaly analysis is performed on the Nth frame image through a preset anomaly detection network to obtain at least one anomaly probability of the Nth frame image. The at least one rendering anomaly analysis includes at least one of image mosaic fault analysis, image tomography fault analysis, and rendering frame drop fault analysis.

9. The rendering anomaly correction method of claim 2, wherein, The preprocessing of the initial Nth frame image to obtain the Nth frame image includes: The initial Nth frame image is preprocessed using at least one of image processing methods, namely image sampling, smoothing, and color channel processing, to obtain the Nth frame image. The preprocessing of the initial (N-1)th frame image to obtain the rendered (N-1)th frame image includes: The initial (N-1)th frame image is preprocessed using at least one of the following image processing methods: image sampling, smoothing, and color channel processing, to obtain the rendered (N-1)th frame image.

10. The rendering anomaly correction method of claim 1, wherein, The step of correcting and rendering the original image before rendering corresponding to the Nth frame image to obtain the rendered frame image includes: Obtain the rendering status parameters of the terminal, and determine the reason for the rendering anomaly of the Nth frame image based on the rendering status parameters; Based on the cause of the rendering error, adjust the rendering state parameters; Based on the adjusted rendering state parameters, the original image before rendering is rendered to obtain the rendered frame image.

11. The rendering anomaly correction method of any one of claims 1-10, wherein, The method further includes: The number of anomalies in the frame images corresponding to the anomaly probabilities that satisfy the anomaly correction conditions is counted. The ratio between the number of anomalies and the number of detected frame images is calculated to obtain the anomaly rendering ratio; When the abnormal rendering ratio meets the preset abnormal reporting conditions, rendering abnormal information is sent to the abnormal information receiving module.

12. An abnormality correction apparatus for rendering, characterized by include: The image acquisition unit is used to acquire the Nth frame image and the already rendered (N-1)th frame image before the currently rendered Nth frame image is displayed; A similarity calculation unit is used to calculate the similarity between the (N-1)th frame image and the Nth frame image to obtain the similarity between the (N-1)th frame image and the Nth frame image; An anomaly analysis unit is used to perform at least one rendering anomaly analysis on the Nth frame image based on the image information of the Nth frame image if the similarity is not greater than a preset similarity threshold, to obtain at least one anomaly probability of the Nth frame image; wherein, the rendering anomaly analysis includes at least one or more of black screen fault analysis, screen tearing fault analysis, image mosaic fault analysis, image tomography fault analysis, or rendering frame dropping fault analysis; when the rendering anomaly analysis is black screen fault analysis, the step of performing at least one rendering anomaly analysis on the Nth frame image based on the image information of the Nth frame image to obtain at least one anomaly probability of the Nth frame image includes: determining a first variance and a first mean of the pixel values ​​of the Nth frame image based on the pixel information of the Nth frame image; determining a second variance and a second mean of the pixel values ​​of the (N-1)th frame image based on the pixel information of the (N-1)th frame image; the black screen probability is calculated by the following formula: Where plast is the approximate probability of the (N-1)th frame image, and pcurrent is the approximate probability of the Nth frame image; pcurrent is calculated using the following formula: Where dev is the first variance of the Nth frame image, ave is the first mean of the Nth frame image, and threshold is the preset calculation threshold; the calculation of plast is the same as that of pcurrent. A correction rendering unit is used to correct and render the original image before rendering corresponding to the Nth frame image if the anomaly probability satisfies the corresponding anomaly correction condition, so as to obtain the rendered frame image. An image display unit is used to display the rendered frame image.

13. The rendering anomaly correction device according to claim 12, characterized in that, The image acquisition unit is used to acquire the initial Nth frame image corresponding to the Nth frame image based on the current rendering thread before the Nth frame image is displayed, and to preprocess the initial Nth frame image to obtain the Nth frame image. Based on the current rendering thread, obtain the initial (N-1)th frame image corresponding to the Nth frame image, and preprocess the initial (N-1)th frame image to obtain the rendered (N-1)th frame image.

14. The rendering anomaly correction device according to claim 13, characterized in that, The image acquisition unit is used to acquire the initial Nth frame image obtained by the current rendering process; to perform image sampling on the initial Nth frame image through the current rendering process; and to send the sampled initial Nth frame image to the detection process to obtain the Nth frame image. Obtain the initial (N-1)th frame image corresponding to the Nth frame image from the current rendering thread; The initial (N-1)th frame image is sent to the detection process, and the detection process performs image sampling on the initial (N-1)th frame image to obtain the rendered (N-1)th frame image.

15. The rendering anomaly correction device according to claim 12, characterized in that, The similarity calculation unit is configured to calculate a first mean of pixel values ​​in the Nth frame image based on the pixel values ​​of each pixel in the Nth frame image; calculate a second mean of pixel values ​​in the (N-1)th frame image based on the pixel values ​​of each pixel in the (N-1)th frame image; and calculate the similarity between the (N-1)th frame image and the Nth frame image based on the first mean and the second mean.

16. The rendering anomaly correction device according to claim 12, characterized in that, The anomaly analysis unit is used to determine at least two target detection regions in the Nth frame image; determine the region pixel features corresponding to each target detection region based on the pixel values ​​of each pixel point in each target detection region; and perform screen distortion fault analysis on the Nth frame image based on the region pixel features to obtain the probability of screen distortion fault in the Nth frame image.

17. The rendering anomaly correction apparatus according to claim 16, characterized in that, The anomaly analysis unit is used to determine the pixel variance corresponding to each target detection region as a region pixel feature based on the pixel value of each pixel point in each target detection region; calculate the average variance based on each pixel variance; and calculate the difference between each pixel variance and the average variance to obtain the variance difference value of each target detection region. Based on the variance differences, the probability of a scattered screen distortion fault in the Nth frame image is determined.

18. The rendering anomaly correction apparatus according to claim 16, characterized in that, The anomaly analysis unit is used to determine the main direction of the regional gradient corresponding to each target detection region as the regional pixel feature based on the pixel value of each pixel in each target detection region; perform direction matching based on the main direction of the regional gradient, and determine the probability of stripe screen fault in the Nth frame image based on the matching result of the direction matching.

19. The rendering anomaly correction apparatus according to claim 12, characterized in that, The anomaly analysis unit is used to perform at least one rendering anomaly analysis on the Nth frame image based on the image information of the Nth frame image through a preset anomaly detection network, and obtain at least one anomaly probability of the Nth frame image. The at least one rendering anomaly analysis includes at least one of image mosaic fault analysis, image tomography fault analysis and / or rendering frame drop fault analysis.

20. The rendering anomaly correction device according to claim 13, characterized in that, The image acquisition unit is used to preprocess the initial Nth frame image using at least one of image processing methods, namely image sampling, smoothing, and color channel processing, to obtain the Nth frame image. The initial (N-1)th frame image is preprocessed using at least one of the following image processing methods: image sampling, smoothing, and color channel processing, to obtain the rendered (N-1)th frame image.

21. The rendering anomaly correction device according to claim 12, characterized in that, The corrective rendering unit is used to obtain the rendering status parameters of the terminal, determine the reason for the rendering anomaly of the Nth frame image based on the rendering status parameters, and adjust the rendering status parameters based on the reason for the rendering anomaly. Based on the adjusted rendering state parameters, the original image before rendering is rendered to obtain the rendered frame image.

22. The rendering anomaly correction apparatus of any one of claims 12 to 21, wherein, The rendering anomaly correction device further includes: An anomaly reporting unit is used to count the number of anomalies in the rendered frame images corresponding to the anomaly probability that meets the anomaly correction conditions; calculate the ratio between the number of anomalies and the number of detected frame images to obtain the anomaly rendering ratio; and send rendering anomaly information to the anomaly information receiving module when the anomaly rendering ratio meets the preset anomaly reporting conditions.

23. An electronic device, comprising: It includes a memory and a processor; the memory stores an application program, and the processor runs the application program within the memory to perform the steps in the rendering anomaly correction method according to any one of claims 1 to 11.

24. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a plurality of instructions adapted for loading by a processor to perform the steps of the rendering anomaly correction method according to any one of claims 1 to 11.

25. A computer program product comprising computer programs or instructions, characterized in that, When the computer program or instructions are executed by the processor, they implement the steps of the rendering anomaly correction method as described in any one of claims 1 to 11.

Citation Information

Patent Citations

  • Black screen detection method, device, compute device and storage medium

    CN109005457A

  • Image display method and device, electronic equipment and computer readable storage medium

    CN111752520A