A video loop stability analysis method, device, equipment and vehicle

CN118397507BActive Publication Date: 2026-09-29CHINA FAW CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202410565697.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-05-09
Publication Date
2026-09-29
Estimated Expiration
2044-05-09

AI Technical Summary

Technical Problem

[0002]在车机台架还是实车的动画验证时,如果存在界面显示效果与预期严重不符或者是其中一秒内的话面与其他时间明显不一致时,则说明可能是在某一时间中的切片错误导致

Benefits of technology

[0044]本发明实施例通过获取待分析视频循环播放的每一帧的视频帧图像;获取视频帧图像中每个像素点及其四邻像素的颜色信息;基于颜色信息进行第一相似度计算,得到视频帧图像中每个像素点的第一相似度;基于每个像素点的第一相似度,整理得到视频帧图像的第二相似度;对循环播放的每一帧的视频帧图像的第二相似度与待分析视频的第一帧图像的第二相似度进行第二相似度计算,获得循环播放的每一帧的视频帧图像对应的第三相似度;将第三相似度按照待分析视频循环播放的时序顺序排列,整理得到相似度序列;对相似度序列进行峰值检测,根据检测到的每个峰值点之间的时间间隔确定待分析视频循环播放的稳定性分析结果。本发明实施例通过分析视频帧的相似度并检测相似度峰值,可以帮助设计师快速定位可能存在问题的视频帧切片,从而及时进行修正和优化,保证视频播放效果的稳定性和一致性。本发明实施例能够高效准确进行视频循环播放稳定性分析。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118397507B_ABST
    Figure CN118397507B_ABST
Patent Text Reader

Abstract

The application discloses a video loop playing stability analysis method, device and equipment and a vehicle, and relates to the technical field of data processing. The method comprises the following steps: acquiring each frame of video frame image of a video to be analyzed which is loop played; acquiring color information of each pixel point and four adjacent pixels in the video frame image; performing first similarity calculation based on the color information to obtain first similarity; obtaining second similarity of the video frame image based on the first similarity; performing second similarity calculation on the second similarity of each frame of video frame image and the first frame image of the video to be analyzed to obtain third similarity of each frame of video frame image; arranging the third similarity according to time sequence to obtain a similarity sequence; performing peak value detection on the similarity sequence, and determining a stability analysis result of the video to be analyzed which is loop played according to a time interval between each peak value point. The application can efficiently and accurately perform video loop playing stability analysis, and can be widely applied to the technical field of data processing.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of data processing technology, and in particular to a method, apparatus, equipment, and vehicle for analyzing the stability of video loop playback. Background Technology

[0002] When verifying animations on a vehicle-mounted test bench or a real vehicle, if the displayed interface significantly deviates from expectations, or if the screen within a single second is noticeably different from other times, it indicates a possible slicing error at a particular point in time. In video animation presentation, a large number of video frames are often played within a short period, with each frame representing a slice. It's impractical for designers to manually identify slice changes within a single second; manual identification is inefficient and prone to overlooking details, leading to inaccurate analysis results. Summary of the Invention

[0003] This invention aims to at least partially address the limitations of related technologies. To this end, this invention proposes a method, apparatus, device, and vehicle for analyzing the stability of video loop playback, capable of efficiently and accurately performing stability analysis of video loop playback.

[0004] On one hand, embodiments of the present invention provide a method for analyzing the stability of video loop playback, including:

[0005] Obtain video frame images of each frame in a loop of the video to be analyzed;

[0006] Obtain the color information of each pixel and its four neighboring pixels in a video frame image;

[0007] The first similarity is calculated based on color information to obtain the first similarity of each pixel in the video frame image;

[0008] Based on the first similarity of each pixel, the second similarity of the video frame images is obtained.

[0009] The second similarity of each video frame image in the loop is calculated with the second similarity of the first frame image of the video to be analyzed, and the third similarity is obtained for each video frame image in the loop.

[0010] The third similarity scores are arranged according to the temporal order of the video being played in a loop, and the similarity scores are then organized to obtain a similarity sequence.

[0011] Peak detection is performed on the similarity sequence, and the stability analysis result of the loop playback of the video to be analyzed is determined based on the time interval between each detected peak point.

[0012] In some embodiments, a first similarity calculation is performed based on color information to obtain the first similarity of each pixel in the video frame image, including:

[0013] Based on a preset order, each pixel in the video frame image is traversed, and the currently traversed pixel is taken as the target pixel.

[0014] Based on the color information of the target pixel and the color information of its four neighboring pixels, the first similarity value between the target pixel and its four neighboring pixels is calculated sequentially using a preset similarity algorithm.

[0015] The average of the first similarity values ​​corresponding to the four pixels is taken as the first similarity of the target pixel.

[0016] The next pixel is taken as the target pixel. Then, based on the color information of the target pixel and the color information of its four neighboring pixels, the first similarity value of the target pixel and its four neighboring pixels is calculated sequentially using a similarity algorithm. This process continues until all pixels in the video frame image have been traversed.

[0017] In some embodiments, a second similarity of the video frame image is obtained based on the first similarity of each pixel, including:

[0018] Based on the coordinate layout of each pixel in the video frame image, the first similarity of each pixel is organized into a two-dimensional array to obtain the second similarity of the video frame image.

[0019] The coordinates of the pixels correspond to the dimensions of the first similarity of the pixels in the two-dimensional array.

[0020] In some embodiments, the second similarity includes the first similarity of each pixel; calculating the second similarity between the second similarity of each looped video frame image and the second similarity of the first frame image of the video to be analyzed, to obtain the third similarity corresponding to each looped video frame image, includes:

[0021] Based on the first similarity of each pixel in each frame of the video frame image in the loop and the first similarity of each corresponding pixel in the first frame image, the second similarity value between each corresponding pixel in the two images is calculated sequentially using a preset similarity algorithm.

[0022] The third similarity is obtained by calculating the proportion of pixels whose second similarity value is greater than the first preset threshold among all corresponding pixels in the video frame image and the first frame image.

[0023] In some embodiments, peak detection is performed on the similarity sequence, and the stability analysis result of the looped playback of the video to be analyzed is determined based on the time interval between each detected peak point, including:

[0024] Peak detection is performed on similarity sequences using a predefined sliding window, and the local maximum value within the sliding window is used as the detected peak point.

[0025] Based on the temporal information of similarity sequences, the time node of each peak point is obtained, and then the time interval of each neighboring peak point is determined.

[0026] The stability analysis results of the video loop playback are determined by comparing each time interval in chronological order. If the time interval changes, the stability analysis result is determined to be unstable; otherwise, the stability analysis result is determined to be stable.

[0027] In some embodiments, the method further includes:

[0028] Using time sequence as the horizontal axis and the third similarity score as the vertical axis, a similarity curve is obtained based on the similarity sequence.

[0029] Based on the preset fluctuation range, a smoothness analysis is performed on the similarity curve, and the stability analysis result of the loop playback of the video to be analyzed is determined according to the smoothness analysis result.

[0030] On the other hand, embodiments of the present invention provide a video loop playback stability analysis device, comprising:

[0031] The first module is used to acquire video frame images of each frame of the video being analyzed in a loop.

[0032] The second module is used to obtain the color information of each pixel and its four neighboring pixels in the video frame image;

[0033] The third module is used to perform the first similarity calculation based on color information to obtain the first similarity of each pixel in the video frame image;

[0034] The fourth module is used to process the first similarity of each pixel to obtain the second similarity of the video frame images;

[0035] The fifth module is used to calculate the second similarity between the second similarity of each video frame image in looped playback and the second similarity of the first frame image of the video to be analyzed, so as to obtain the third similarity corresponding to each video frame image in looped playback.

[0036] The sixth module is used to arrange the third similarity scores according to the temporal order of the looped playback of the video to be analyzed, and to organize them into a similarity sequence.

[0037] The seventh module is used to perform peak detection on the similarity sequence and determine the stability analysis result of the loop playback of the video to be analyzed based on the time interval between each detected peak point.

[0038] In some embodiments, the apparatus further includes:

[0039] The eighth module is used to generate a similarity curve based on the similarity sequence, with time sequence as the horizontal axis and the value of the third similarity as the vertical axis.

[0040] The ninth module is used to perform smoothness analysis on the similarity curve based on a preset fluctuation range, and to determine the stability analysis result of the loop playback of the video to be analyzed based on the smoothness analysis result.

[0041] On the other hand, embodiments of the present invention provide an electronic device, including: a processor and a memory; the memory is used to store a program; the processor executes the program to implement the above-mentioned video loop playback stability analysis method.

[0042] On the other hand, embodiments of the present invention provide a computer storage medium storing a processor-executable program, which, when executed by a processor, is used to implement the above-described video loop playback stability analysis method.

[0043] On the other hand, embodiments of the present invention provide a vehicle, which includes the aforementioned video loop playback stability analysis device or the aforementioned electronic device.

[0044] This invention provides an embodiment of the method for obtaining video frame images of each frame of a looping video to be analyzed; acquiring the color information of each pixel and its four neighboring pixels in the video frame image; calculating a first similarity based on the color information to obtain a first similarity for each pixel in the video frame image; arranging the first similarity of each pixel to obtain a second similarity for the video frame image; calculating a second similarity between the second similarity of the video frame image of each looping frame and the second similarity of the first frame image of the video to be analyzed to obtain a third similarity for each looping frame; arranging the third similarities according to the temporal order of the looping playback of the video to be analyzed to obtain a similarity sequence; and performing peak detection on the similarity sequence to determine the stability analysis result of the looping playback of the video to be analyzed based on the time interval between each detected peak. This invention, by analyzing the similarity of video frames and detecting similarity peaks, can help designers quickly locate potentially problematic video frame segments, thereby enabling timely correction and optimization, ensuring the stability and consistency of video playback effects. This invention can efficiently and accurately perform stability analysis of looping video playback. Attached Figure Description

[0045] The accompanying drawings are provided to further understand the technical solutions of the present invention and constitute a part of the specification. They are used together with the embodiments of the present invention to explain the technical solutions of the present invention, and do not constitute a limitation on the technical solutions of the present invention.

[0046] Figure 1 This is a schematic diagram of an implementation environment for performing stability analysis of video loop playback provided in an embodiment of the present invention;

[0047] Figure 2 This is a flowchart illustrating a video loop playback stability analysis method provided in an embodiment of the present invention;

[0048] Figure 3 This is a schematic diagram of the process for obtaining color information provided in an embodiment of the present invention;

[0049] Figure 4 A schematic diagram illustrating the unfolding process of the first similarity calculation provided in an embodiment of the present invention;

[0050] Figure 5 This is a schematic diagram of the unfolding process of the second similarity calculation provided in an embodiment of the present invention;

[0051] Figure 6 A schematic diagram of the process for obtaining stability analysis results provided in an embodiment of the present invention;

[0052] Figure 7 This is a flowchart illustrating the peak detection algorithm provided in an embodiment of the present invention.

[0053] Figure 8 This is another flowchart illustrating a video loop playback stability analysis method provided in an embodiment of the present invention;

[0054] Figure 9 This is a schematic diagram of the structure of a video loop playback stability analysis device provided in an embodiment of the present invention;

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

[0056] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the invention.

[0057] It should be noted that although functional modules are divided in the system diagram and the logical order is shown in the flowchart, in some cases, the steps shown or described may be performed in a different order than the module division in the system or the order in the flowchart. The terms "first / S100," "second / S200," etc., in the specification, claims, and the aforementioned figures are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence.

[0058] In this document, the term "embodiment" means that a particular feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of the invention. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a separate or alternative embodiment mutually exclusive with other embodiments. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described herein can be combined with other embodiments.

[0059] To facilitate understanding of the technical solution of this invention, the meanings and technical principles of the parameters that may be referenced in the embodiments of this invention will first be explained:

[0060] Similarity calculation: Similarity calculation is a method to measure the degree of similarity between two objects. In feature-review association analysis, similarity calculation is used to measure the similarity between user reviews and feature renderings. Commonly used similarity calculation methods include cosine similarity, Euclidean distance, and Pearson correlation coefficient. These methods represent user reviews and feature renderings as vectors and measure their relevance by calculating the similarity between these vectors.

[0061] It is understood that the video loop playback stability analysis method provided in this embodiment of the invention can be applied to any computer device with data processing and computing capabilities, and this computer device can be various terminals or servers. When the computer device in the embodiment is a server, the server is an independent physical server, or 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. In some embodiments, the terminal is a smartphone, tablet computer, laptop computer, or desktop computer, but it is not limited to these.

[0062] like Figure 1 The diagram shown is a schematic representation of an implementation environment provided by an embodiment of the invention. (Refer to...) Figure 1 The implementation environment includes at least one terminal 102 and a server 101. The terminal 102 and the server 101 can be connected via a network, either wirelessly or via a wired connection, to complete data transmission and exchange.

[0063] Server 101 can be a standalone 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.

[0064] Additionally, server 101 can also be a node server in a blockchain network. Blockchain is a novel application model of computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanisms, and encryption algorithms.

[0065] Terminal 102 can be a smartphone, tablet, laptop, desktop computer, smart speaker, smartwatch, etc. It can also be a vehicle-mounted terminal of the various device types described above, but is not limited to these. Terminal 102 and server 101 can be directly or indirectly connected via wired or wireless communication, and this embodiment of the invention does not impose any limitations.

[0066] Exemplary based on Figure 1 The implementation environment shown in this embodiment of the invention provides a video loop playback stability analysis method. The following description uses the application of this video loop playback stability analysis method in server 101 as an example. It can be understood that this video loop playback stability analysis method can also be applied in terminal 102.

[0067] Reference Figure 2 , Figure 2 This is a flowchart illustrating a video loop playback stability analysis method applied to a server, provided in an embodiment of the present invention. The executing entity of this video loop playback stability analysis method can be any of the aforementioned computer devices (including a server or terminal). (Refer to...) Figure 2 The method includes the following steps:

[0068] S100: Obtain the video frame image of each frame of the video to be analyzed in a loop;

[0069] For example, in some implementations, video or animation displays are composed of a series of consecutive video frames. Video frames are temporally continuous static images; by playing these frames rapidly in succession, smooth dynamic images can be presented. Each frame is a static image containing visual information within a certain time interval. The frame rate of a video represents the number of frames played per second, usually measured in frames per second (fps). Common video frame rates include 24fps, 30fps, and 60fps. When video frames are played continuously, due to the persistence of vision, the human eye perceives these static frames as continuously moving images. The content of each frame changes slightly within a short period, thus producing a smooth animation effect. Therefore, it can be said that video or animation displays are formed by rapidly playing a series of consecutive video frames at a certain frame rate. Each video frame is a static image, but when played continuously, they can present a dynamic visual effect.

[0070] Therefore, the stability analysis of loop playback is based on each video frame in the video.

[0071] S200: Obtain the color information of each pixel and its four neighboring pixels in the video frame image;

[0072] For example, in some specific implementations, four neighboring pixels can be used to determine the information of each pixel. Four neighboring pixels refer to the four adjacent pixels above, below, left, and right of a given pixel in a two-dimensional image. For example... Figure 3 As shown, the specific implementation process is as follows:

[0073] 1. Current pixel position: Assume the coordinates of the current pixel are (x, y).

[0074] 2. Positions of four adjacent pixels:

[0075] Top pixel: coordinates (x, y-1);

[0076] The bottom pixel has coordinates (x, y+1).

[0077] Left pixel: coordinates (x-1, y);

[0078] Right pixel: coordinates (x+1, y);

[0079] 3. Check if the four neighboring pixels are within the image area:

[0080] Ensure that the coordinates of four neighboring pixels are within the valid range of the image, i.e., not exceeding the image's width and height. Pixels at boundaries and vertices that have only three or even two neighboring pixels can be excluded from the calculation.

[0081] 4. Obtain the color information of the four neighboring pixels:

[0082] For the coordinates of each of the four neighboring pixels, check and record the pixel color information at the corresponding position in the image.

[0083] If it is within the image range, obtain the color information of the corresponding pixel.

[0084] S300. Calculate the first similarity based on color information to obtain the first similarity of each pixel in the video frame image;

[0085] It should be noted that in some embodiments, such as Figure 4 As shown, step S300 may include: S301, traversing each pixel in the video frame image according to a preset order, and taking the currently traversed pixel as the target pixel; for example, starting from the pixel at the top left corner, and then traversing horizontally incrementally, continuing the horizontal incremental traversal in the next row of pixels after the horizontal pixel traversal is completed; S302, calculating the first similarity value between the target pixel and its four neighboring pixels sequentially using a preset similarity algorithm based on the color information of the target pixel and the color information of the four neighboring pixels of the target pixel; S303, taking the average of the first similarity values ​​corresponding to the four pixels as the first similarity of the target pixel; S304, taking the next traversed pixel as the target pixel, and then returning the step of calculating the first similarity value between the target pixel and its four neighboring pixels sequentially using a similarity algorithm based on the color information of the target pixel and the color information of the four neighboring pixels of the target pixel; until all pixels in the video frame image have been traversed.

[0086] For example, in some specific implementations, an appropriate similarity calculation method can be selected to implement this step. For each pixel, the similarity between it and its four neighboring pixels is calculated separately, and then the average value is taken as the similarity of that pixel (i.e., the first similarity). For each pixel in the image, the previous calculation steps are repeated to calculate its similarity with its four neighboring pixels, and finally the similarity between all pixels and their four neighboring pixels is obtained.

[0087] S400. Based on the first similarity of each pixel, the second similarity of the video frame image is obtained.

[0088] It should be noted that, in some embodiments, step S400 may include: based on the coordinate layout of each pixel in the video frame image, organizing the first similarity of each pixel into a two-dimensional array to obtain the second similarity of the video frame image; wherein, the coordinates of the pixel correspond to the dimension of the first similarity of the pixel in the two-dimensional array.

[0089] S500: Calculate the second similarity between the second similarity of each video frame image in looped playback and the second similarity of the first frame image of the video to be analyzed, and obtain the third similarity corresponding to each video frame image in looped playback.

[0090] It should be noted that the second similarity includes the first similarity for each pixel; in some embodiments, such as Figure 5 As shown, step S500 may include: S501, calculating the second similarity value between corresponding pixels in the two images sequentially using a preset similarity algorithm, based on the first similarity of each pixel in each frame of the video frame image during loop playback and the first similarity of each corresponding pixel in the first frame image; S502, calculating the proportion of pixels whose second similarity value between all corresponding pixels in the video frame image and the first frame image is greater than a first preset threshold, to obtain a third similarity. It should also be noted that the third similarity can also be calculated by weighted summation or averaging of the second similarity values ​​between corresponding pixels in the two images.

[0091] S600. Arrange the third similarity scores according to the temporal order of the video being analyzed in a loop, and organize them to obtain a similarity sequence;

[0092] S700. Perform peak detection on the similarity sequence, and determine the stability analysis result of the loop playback of the video to be analyzed based on the time interval between each detected peak point.

[0093] It should be noted that in some embodiments, such as Figure 6 As shown, step S700 may include: S701, performing peak detection on the similarity sequence through a predefined sliding window, and finding the local maximum value within the sliding window as the detected peak point; S702, obtaining the time node of each peak point based on the temporal information of the similarity sequence, and then determining the time interval of each adjacent peak point; S703, comparing each time interval in temporal order to determine the stability analysis result of the loop playback of the video to be analyzed; wherein, when the time interval changes, the stability analysis result is determined to be unstable; otherwise, the stability analysis result is determined to be stable.

[0094] For example, in some implementations, the similarity sequence is analyzed to identify peaks. A peak indicates that the similarity has reached a local maximum, typically representing a position where the image is looping. In some implementations, a similarity threshold can also be set to filter out peaks with lower similarity. Specifically, such as... Figure 7 As shown, the flow logic implementation of the peak detection algorithm is as follows:

[0095] Peak detection based on sliding window: By defining a sliding window, the maximum value within the window is found as the peak value.

[0096] Peak stability assessment:

[0097] Analyze the detected peaks and calculate the time intervals or changes in their relative positions.

[0098] If these peaks remain relatively stable and consistent throughout the loop, then the video's loop playback time can be considered stable.

[0099] Threshold setting and verification:

[0100] Set a similarity threshold to filter out peaks with low similarity, thereby determining effective loop playback points.

[0101] The validity of the thresholds should be verified and adjusted according to the actual situation to ensure accuracy and reliability.

[0102] In some embodiments, such as Figure 8 As shown, the method may also include:

[0103] S800. Using time sequence as the horizontal axis and the value of the third similarity as the vertical axis, a similarity curve is obtained based on the similarity sequence.

[0104] S900: Perform smoothness analysis on the similarity curve based on the preset fluctuation range, and determine the stability analysis result of the loop playback of the video to be analyzed based on the result of the smoothness analysis.

[0105] For example, in some specific implementations, if there is an anomaly in the similarity curve that is not smooth during cyclic similarity, it indicates that the video frame is playing incorrectly.

[0106] To explain in detail the principle of the technical solution of the present invention, the overall process of the present invention will be described below with reference to some specific embodiments. It is easy to understand that the following is an explanation of the technical principle of the present invention and should not be regarded as a limitation of the present invention.

[0107] First, it's important to understand that a video frame is a discrete unit of a video signal on the timeline, representing a still image in the video. Video consists of a series of consecutive frames, each containing information about the video scene at a specific moment. When these consecutive frames are played back quickly enough, the human eye perceives continuous motion. A video frame is composed of pixels, each representing a point in the image. The color value of each pixel determines its brightness and color information. Video frames typically have a fixed resolution, such as 720p (1280x720 pixels) or 1080p (1920x1080 pixels). In digital video, each frame is played back at a certain frame rate (e.g., 25 or 30 frames per second). The frame rate determines the smoothness of the video playback; a higher frame rate makes the motion smoother, while a lower frame rate can cause stuttering. By playing back video frames one by one and quickly switching between consecutive frames, we can perceive dynamic video images. Video frames are widely used in various fields, including film, television programs, video games, video calls, and computer vision and machine learning.

[0108] Whether during animation verification on a vehicle-mounted testing bench or in a real vehicle, if the displayed interface significantly deviates from expectations, or if the screen within a single second is noticeably different from other times, it indicates a possible slicing error at a particular point in time. In video animation presentation, a large number of video frames are often played within a short period, with each frame representing a slice. Manually identifying slice changes within a single second is impractical for designers; therefore, an automated method is needed to help designers locate erroneous video frame slices.

[0109] During the loop playback of car-themed videos, the loop duration may be unstable, meaning the video playback cycle is inconsistent. This can lead to choppy scene transitions and even visual fatigue or discomfort. This method accurately analyzes the similarity of video frames and determines the stability of the video's loop playback time, thus solving this problem.

[0110] During video playback, the presence of incorrect video frame segments can lead to discrepancies between the displayed image and expectations, or noticeable inconsistencies. By analyzing the similarity of video frames and detecting peak similarity, designers can quickly locate potentially problematic video frame segments, allowing for timely correction and optimization to ensure the stability and consistency of video playback.

[0111] In view of this, embodiments of the present invention provide a method for analyzing the stability of video loop playback, the specific implementation process of which is as follows:

[0112] S1: Using image processing techniques:

[0113] The four neighboring pixels are used to determine the information of each pixel. In a two-dimensional image, the four neighboring pixels are the top, bottom, left, and right adjacent pixels of a given pixel.

[0114] 1. Current pixel position: Assume the coordinates of the current pixel are (x, y).

[0115] 2. Positions of four adjacent pixels:

[0116] Top pixel: coordinates (x, y-1)

[0117] The bottom pixel has coordinates (x, y+1).

[0118] Left pixel: coordinates (x-1, y)

[0119] Right pixel: coordinates (x+1, y)

[0120] 3. Check if the four neighboring pixels are within the image area:

[0121] Ensure that the coordinates of the four neighboring pixels are within the valid range of the image, i.e., not exceeding the width and height of the image. Pixels at the boundaries, i.e., vertices, have only three or even two neighboring pixels and can be excluded from the calculation.

[0122] 4. Obtain the color information of the four neighboring pixels:

[0123] For the coordinates of each of the four neighboring pixels, check and record the pixel color information at the corresponding position in the image.

[0124] If it is within the image range, obtain the color information of the corresponding pixel.

[0125] S2: Calculate the similarity between each frame and the first frame:

[0126] 1. Similarity Calculation: For each pixel, calculate its similarity to its four neighboring pixels, and then take the average as the similarity of that pixel. An appropriate similarity calculation method can be chosen to implement this step.

[0127] 2. Repeat step 1: For each pixel in the image, repeat step 1 to calculate its similarity to its four neighboring pixels.

[0128] Similarity peak detection:

[0129] Analyzing the similarity sequence, the peak detection algorithm identifies the peak value as the point where the similarity between a video frame and the first frame reaches its highest level, indicating a loop playback point. The specific process is as follows:

[0130] ①. Calculate the similarity sequence: First, according to the preset similarity measurement standard, calculate the similarity between each frame and the first frame, and combine the results into a similarity sequence.

[0131] ②. Finding Peaks: Analyze the similarity sequence to identify peaks. Peaks indicate that the similarity has reached a local maximum, typically representing a position where the image is looping.

[0132] ③. Peak detection algorithm: Use a suitable peak detection algorithm to find the peaks in the similarity sequence.

[0133] Peak detection based on sliding window: By defining a sliding window, the maximum value within the window is found as the peak value.

[0134] Peak stability assessment:

[0135] Analyze the detected peaks and calculate the time intervals or changes in their relative positions.

[0136] If these peaks remain relatively stable and consistent throughout the loop, then the video's loop playback time can be considered stable.

[0137] Threshold setting and verification:

[0138] A similarity threshold is set to filter out peaks with low similarity, thereby determining valid loop playback points. Furthermore, if there are anomalies in the similarity curve during loop playback, it indicates a playback error in the video frame.

[0139] The validity of the thresholds should be verified and adjusted according to the actual situation to ensure accuracy and reliability.

[0140] In some preferred embodiments, an automated detection system can be developed to integrate the above steps into a unified framework.

[0141] In summary, the method of finding peaks in a similarity sequence is a key step in determining the stability of video loop playback time and whether there are errors in video frames.

[0142] On the other hand, such as Figure 9 As shown, this embodiment of the invention provides a video loop playback stability analysis device 900, which may include:

[0143] The first module 910 is used to acquire video frame images of each frame of the video being played in a loop;

[0144] The second module 920 is used to obtain the color information of each pixel and its four neighboring pixels in the video frame image;

[0145] The third module 930 is used to perform the first similarity calculation based on color information to obtain the first similarity of each pixel in the video frame image;

[0146] The fourth module 940 is used to process the first similarity of each pixel to obtain the second similarity of the video frame image;

[0147] The fifth module 950 is used to calculate the second similarity between the second similarity of each video frame image in looped playback and the second similarity of the first frame image of the video to be analyzed, so as to obtain the third similarity corresponding to each video frame image in looped playback.

[0148] The sixth module 960 is used to arrange the third similarity according to the temporal order of the looped playback of the video to be analyzed, and to obtain a similarity sequence;

[0149] Module 7, 970, is used to perform peak detection on similarity sequences and determine the stability analysis results of the loop playback of the video to be analyzed based on the time interval between each detected peak point.

[0150] In some embodiments, the apparatus may further include:

[0151] The eighth module is used to generate a similarity curve based on the similarity sequence, with time sequence as the horizontal axis and the value of the third similarity as the vertical axis.

[0152] The ninth module is used to perform smoothness analysis on the similarity curve based on a preset fluctuation range, and to determine the stability analysis result of the loop playback of the video to be analyzed based on the smoothness analysis result.

[0153] The content of the method embodiments of the present invention is applicable to the device embodiments. The specific functions implemented by the device embodiments are the same as those of the above method embodiments, and the beneficial effects achieved are also the same as those achieved by the above methods.

[0154] On the other hand, embodiments of the present invention also provide an electronic device, which includes a memory and a processor. The memory stores a computer program, and the processor executes the computer program to implement the aforementioned video loop playback stability analysis method. This electronic device can be any smart terminal, including tablet computers, in-vehicle computers, etc.

[0155] It is understood that the content of the above method embodiments is applicable to this device embodiment. The specific functions implemented by this device embodiment are the same as those of the above method embodiments, and the beneficial effects achieved are also the same as those achieved by the above method embodiments.

[0156] like Figure 10 As shown, Figure 10 The hardware structure of an electronic device according to another embodiment is illustrated. The electronic device includes:

[0157] The processor 1001 can be implemented using a general-purpose CPU (Central Processing Unit), microprocessor, application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of the present invention.

[0158] The memory 1002 can be implemented as a read-only memory (ROM), static storage device, dynamic storage device, or random access memory (RAM). The memory 1002 can store the operating system and other application programs. When the technical solutions provided in the embodiments of this specification are implemented through software or firmware, the relevant program code is stored in the memory 1002 and is called and executed by the processor 1001 to execute the network node population optimization method of the embodiments of this invention.

[0159] Input / output interface 1003 is used to implement information input and output;

[0160] The communication interface 1004 is used to enable communication and interaction between this device and other devices. Communication can be achieved through wired means (such as USB, network cable, etc.) or wireless means (such as mobile network, WIFI, Bluetooth, etc.).

[0161] Bus 1005 transmits information between various components of the device (e.g., processor 1001, memory 1002, input / output interface 1003, and communication interface 1004);

[0162] The processor 1001, memory 1002, input / output interface 1003 and communication interface 1004 are connected to each other within the device via bus 1005.

[0163] The electronic device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs.

[0164] The content of the method embodiments of the present invention is applicable to the embodiments of the present electronic device. The specific functions implemented by the embodiments of the present electronic device are the same as those of the above method embodiments, and the beneficial effects achieved are also the same as those achieved by the above methods.

[0165] Another aspect of this invention provides a computer-readable storage medium storing a program that is executed by a processor to implement the aforementioned method.

[0166] It should be noted that the computer-readable medium shown in the embodiments of the present invention can be a computer-readable signal medium or a computer-readable storage medium, or any combination thereof. A computer-readable storage medium can be, for example,—but not limited to—an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of a computer-readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM), flash memory, optical fiber, portable compact disc read-only memory (CD to ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof. In the present invention, a computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, apparatus, or device. In the present invention, a computer-readable signal medium can include a data signal propagated in baseband or as part of a carrier wave, wherein computer-readable program code is carried. Such transmitted data signals can take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. The computer-readable signal medium can also be any computer-readable medium other than a computer-readable storage medium, which can send, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device. The program code contained on the computer-readable medium can be transmitted using any suitable medium, including but not limited to wireless, wired, etc., or any suitable combination thereof.

[0167] The content of the method embodiments of the present invention is applicable to the computer-readable storage medium embodiments. The specific functions implemented by the computer-readable storage medium embodiments are the same as those of the above method embodiments, and the beneficial effects achieved are also the same as those achieved by the above methods.

[0168] This invention also discloses a computer program product or computer program, which includes computer instructions stored in a computer-readable storage medium. A processor of a computer device can read the computer instructions from the computer-readable storage medium and execute the computer instructions, causing the computer device to perform the aforementioned method.

[0169] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of the present invention. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in a block diagram or flowchart, and combinations of blocks in a block diagram or flowchart, may be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.

[0170] It should be noted that although several modules for the device used to perform actions have been mentioned in the detailed description above, this division is not mandatory. In fact, according to embodiments of the present invention, the features and functions of two or more modules or units described above can be embodied in one module or unit. Conversely, the features and functions of one module or unit described above can be further divided and embodied by multiple modules or units.

[0171] Through the above description of the embodiments, those skilled in the art will readily understand that the exemplary embodiments described herein can be implemented by software or by combining software with necessary hardware. Therefore, the technical solutions according to the embodiments of the present invention can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (such as a CD-ROM, USB flash drive, portable hard drive, etc.) or on a network, including several instructions to cause a computing device (such as a personal computer, server, touch terminal, or network device, etc.) to execute the method according to the embodiments of the present invention.

[0172] In some alternative embodiments, the functions / operations mentioned in the block diagrams may not occur in the order shown in the operation diagrams. For example, depending on the functions / operations involved, two consecutively shown blocks may actually be executed substantially simultaneously, or the blocks may sometimes be executed in reverse order. Furthermore, the embodiments presented and described in the flowcharts of this invention are provided by way of example to provide a more comprehensive understanding of the technology. The disclosed methods are not limited to the operations and logic flows presented herein. Alternative embodiments are contemplated in which the order of various operations is changed and sub-operations described as part of a larger operation are executed independently.

[0173] Furthermore, although the invention has been described in the context of functional modules, it should be understood that, unless otherwise stated, one or more of the functions and / or features may be integrated into a single physical device and / or software module, or one or more functions and / or features may be implemented in a separate physical device or software module. It is also understood that a detailed discussion of the actual implementation of each module is unnecessary for understanding the invention. Rather, given the properties, functions, and internal relationships of the various functional modules in the apparatus disclosed herein, the actual implementation of the module will be understood within the scope of conventional skill of an engineer. Therefore, those skilled in the art can implement the invention as set forth in the claims using ordinary techniques without excessive experimentation. It is also understood that the specific concepts disclosed are merely illustrative and not intended to limit the scope of the invention, which is determined by the full scope of the appended claims and their equivalents.

[0174] If a function is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this invention, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of the various embodiments of this invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0175] The logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as a sequenced list of executable instructions for implementing logical functions, and can be embodied in any computer-readable medium for use by, or in conjunction with, an instruction execution means, apparatus, or device (such as a computer-based device, a processor-including device, or other means that can fetch and execute instructions from, or in conjunction with, an instruction execution means, apparatus, or device). For the purposes of this specification, "computer-readable medium" can be any means that can contain, store, communicate, propagate, or transmit programs for use by, or in conjunction with, an instruction execution means, apparatus, or device.

[0176] More specific examples of computer-readable media (a non-exhaustive list) include: electrical connections (electronic devices) having one or more wires, portable computer disk drives (magnetic devices), random access memory (RAM), read-only memory (ROM), erasable and editable read-only memory (EPROM or flash memory), fiber optic devices, and portable optical disc read-only memory (CDROM). Furthermore, computer-readable media can even be paper or other suitable media on which programs can be printed, because programs can be obtained electronically, for example, by optically scanning the paper or other medium, followed by editing, interpreting, or otherwise processing as necessary, and then stored in computer memory.

[0177] It should be understood that various parts of the present invention can be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, multiple steps or methods can be implemented in software or firmware stored in memory and executed by a suitable instruction execution device. For example, if implemented in hardware, as in another embodiment, it can be implemented using any one or a combination of the following techniques known in the art: discrete logic circuits having logic gates for implementing logical functions on data signals, application-specific integrated circuits (ASICs) having suitable combinational logic gates, programmable gate arrays (PGAs), field-programmable gate arrays (FPGAs), etc.

[0178] In the description of this specification, references to terms such as "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment or example is included in at least one embodiment or example of the invention. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples.

[0179] Although embodiments of the invention have been shown and described, those skilled in the art will understand that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the claims and their equivalents.

[0180] The above is a detailed description of the preferred embodiments of the present invention. However, the present invention is not limited to the embodiments. Those skilled in the art can make various equivalent modifications or substitutions without departing from the spirit of the present invention. All such equivalent modifications or substitutions are included within the scope defined by the claims of the present invention.

Claims

1. A method for analyzing the stability of video loop playback, characterized in that, include: Obtain video frame images of each frame in a loop of the video to be analyzed; Obtain the color information of each pixel and its four neighboring pixels in the video frame image; Based on the color information, a first similarity calculation is performed to obtain the first similarity of each pixel in the video frame image; Based on the first similarity of each pixel, the second similarity of the video frame image is obtained; A second similarity calculation is performed between the second similarity of the video frame image of each frame played in a loop and the second similarity of the first frame image of the video to be analyzed, so as to obtain a third similarity corresponding to the video frame image of each frame played in a loop. The third similarity scores are arranged according to the temporal order of the video being played in a loop, and a similarity sequence is obtained. Peak detection is performed on the similarity sequence, and the stability analysis result of the loop playback of the video to be analyzed is determined based on the time interval between each detected peak point.

2. The video loop playback stability analysis method according to claim 1, characterized in that, The step of calculating the first similarity based on the color information to obtain the first similarity of each pixel in the video frame image includes: Based on a preset order, each pixel in the video frame image is traversed, and the currently traversed pixel is taken as the target pixel. Based on the color information of the target pixel and the color information of its four neighboring pixels, a first similarity value between the target pixel and its four neighboring pixels is calculated sequentially using a preset similarity algorithm. The average of the first similarity values ​​corresponding to the four pixels is taken as the first similarity of the target pixel. The next pixel is taken as the target pixel. Then, based on the color information of the target pixel and the color information of its four neighboring pixels, the first similarity value of the target pixel and its four neighboring pixels is calculated sequentially using a similarity algorithm. This process continues until all pixels in the video frame image have been traversed.

3. The video loop playback stability analysis method according to claim 1, characterized in that, The process of obtaining the second similarity of the video frame image based on the first similarity of each pixel includes: Based on the coordinate layout of each pixel in the video frame image, the first similarity of each pixel is organized into a two-dimensional array to obtain the second similarity of the video frame image. The coordinates of the pixel point correspond to the dimension of the first similarity of the pixel point in the two-dimensional array.

4. The video loop playback stability analysis method according to claim 1, characterized in that, The second similarity includes the first similarity for each of the aforementioned pixels; the step of calculating a second similarity between the second similarity of each looped video frame and the second similarity of the first frame of the video to be analyzed, to obtain a third similarity corresponding to each looped video frame, includes: Based on the first similarity of each pixel in the video frame image of each frame of the looped playback and the first similarity of each corresponding pixel in the first frame image, the second similarity value between each corresponding pixel in the two images is calculated sequentially by a preset similarity algorithm. The third similarity is obtained by calculating the proportion of pixels whose second similarity value is greater than a first preset threshold among all corresponding pixels in the video frame image and the first frame image.

5. The video loop playback stability analysis method according to claim 1, characterized in that, The step of performing peak detection on the similarity sequence and determining the stability analysis result of the loop playback of the video to be analyzed based on the time interval between each detected peak point includes: Peak detection is performed on the similarity sequence using a predefined sliding window, and the local maximum value within the sliding window is used as the detected peak point. Based on the temporal information of the similarity sequence, the time node of each peak point is obtained, and then the time interval of each adjacent peak point is determined; The stability analysis result of the looped playback of the video to be analyzed is determined by comparing each time interval in chronological order; wherein, if the time interval changes, the stability analysis result is determined to be unstable, otherwise, the stability analysis result is determined to be stable.

6. The video loop playback stability analysis method according to claim 1, characterized in that, The method further includes: Using time sequence as the horizontal axis and the value of the third similarity as the vertical axis, a similarity curve is obtained based on the similarity sequence. Based on a preset fluctuation range, a smoothness analysis is performed on the similarity curve, and the stability analysis result of the loop playback of the video to be analyzed is determined based on the result of the smoothness analysis.

7. A video loop playback stability analysis device, characterized in that, include: The first module is used to acquire video frame images of each frame of the video being analyzed in a loop. The second module is used to obtain the color information of each pixel and its four neighboring pixels in the video frame image; The third module is used to perform a first similarity calculation based on the color information to obtain the first similarity of each pixel in the video frame image; The fourth module is used to calculate the second similarity of the video frame image based on the first similarity of each pixel. The fifth module is used to calculate a second similarity between the second similarity of the video frame image of each frame in the loop and the second similarity of the first frame image of the video to be analyzed, so as to obtain a third similarity corresponding to the video frame image of each frame in the loop. The sixth module is used to arrange the third similarity according to the temporal order of the looped playback of the video to be analyzed, and organize them to obtain a similarity sequence; The seventh module is used to perform peak detection on the similarity sequence and determine the stability analysis result of the loop playback of the video to be analyzed based on the time interval between each detected peak point.

8. The video loop playback stability analysis device according to claim 7, characterized in that, The device further includes: The eighth module is used to generate a similarity curve based on the similarity sequence, with time sequence as the horizontal axis and the value of the third similarity as the vertical axis. The ninth module is used to perform smoothness analysis on the similarity curve based on a preset fluctuation range, and to determine the stability analysis result of the loop playback of the video to be analyzed based on the result of the smoothness analysis.

9. An electronic device, characterized in that, Including the processor and memory; The memory is used to store programs; The processor executes the program to implement the method as described in any one of claims 1 to 6.

10. A vehicle, characterized in that, The vehicle includes the video loop playback stability analysis device as described in claim 7 or 8, or the electronic device as described in claim 9.

Citation Information

Patent Citations

  • Sticker effect detection method and device, computer equipment and storage medium

    CN115311446A

  • Class agnostic repetition counting in video using temporal self-similarity matrix

    CN115605924A