Video data processing method, communication equipment and storage medium
By establishing a frame type index table and processing keyframe messages, the problem of high CPU performance consumption in video service processing of communication devices is solved, and processing efficiency and throughput are improved.
Patent Information
- Application Number
- CN202310684774.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-06-09
- Publication Date
- 2024-12-17
AI Technical Summary
In the prior art, when processing video service data, the CPU performance of the communication device is consumed relatively high, resulting in reduced performance and service processing efficiency, limiting the overall throughput.
By determining the keyframe information of the target video resource, establish a frame type index table, filter out video data streams that meet the preset conditions, identify and perform preset processing on keyframe messages, avoiding full processing of all data streams.
It effectively reduces the performance and memory loss of communication equipment, improves business processing efficiency and overall throughput.
Smart Images

Figure CN119155507A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of communication technology, and in particular to a video data processing method, communication equipment and storage medium. Background Art
[0002] With the development of 5G technology, the speed of web browsing through terminal devices such as mobile phones and laptops is getting faster and faster, and more and more users are accustomed to playing videos through terminal devices.
[0003] Usually, video services are processed by communication equipment and transmitted to terminal equipment to optimize the video played by the terminal equipment. However, compared with conventional services, video services have larger traffic and higher real-time performance, but the computing and scheduling resources of communication equipment are limited. In the process of processing the data traffic of video services in the prior art, there is a problem of high CPU performance consumption of communication equipment, which reduces the performance of communication equipment and service processing efficiency, and ultimately limits the overall throughput of communication equipment. Summary of the invention
[0004] The main purpose of the embodiments of the present invention is to provide a video data processing method, a communication device and a storage medium, aiming to improve the service processing efficiency of the communication device and thus improve the overall throughput of the communication device.
[0005] In a first aspect, an embodiment of the present invention provides a method for processing video data, which is applied to a communication device, and the method includes:
[0006] Determine a target video resource, and establish a frame type index table of the target video resource according to key frame information of the target video resource;
[0007] Detecting a data stream of a to-be-processed video resource that meets a preset data processing condition according to the frame type index table, and identifying a key frame message in the data stream of the to-be-processed video resource according to the detection result;
[0008] Perform preset message processing on the key frame messages in the data stream of the video resource to be processed.
[0009] In a second aspect, an embodiment of the present invention further provides a communication device, comprising: a processor, a memory, a computer program stored in the memory and executable by the processor, and a data bus for realizing connection and communication between the processor and the memory, wherein when the computer program is executed by the processor, the steps of the aforementioned video data processing method are implemented.
[0010] In a third aspect, an embodiment of the present invention further provides a storage medium for computer-readable storage, characterized in that the storage medium stores one or more programs, and the one or more programs can be executed by one or more processors to implement the steps of the aforementioned video data processing method.
[0011] An embodiment of the present invention provides a method for processing video data, a communication device and a storage medium, wherein the method determines a target video resource and establishes a frame type index table of the target video resource according to key frame information of the target video resource; detects a data stream of a to-be-processed video resource that meets preset data processing conditions according to the frame type index table, and identifies key frame messages in the data stream of the to-be-processed video resource according to the detection result; and performs preset message processing on the key frame messages in the data stream of the to-be-processed video resource.
[0012] In the present invention, based on the process of video resource processing by the communication device, a frame type index table is established by establishing a target video resource, and the frame type index table is used to detect the video resources to be processed that meet the preset data processing conditions, and the preset message processing is performed on the key frame messages in the data stream of the video resources to be processed. There is no need to process all the video resources to be processed flowing through the communication device, so the performance and memory loss of the communication device can be effectively reduced, thereby improving the business processing efficiency of the communication device, so as to improve the overall throughput of the communication device. BRIEF DESCRIPTION OF THE DRAWINGS
[0013] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying any creative work.
[0014] Figure 1 It is a schematic diagram of an application scenario of a data transmission system provided by an embodiment of the present invention;
[0015] Figure 2 is a flowchart of a method for processing video data provided by an embodiment of the present invention;
[0016] Figure 3 It is a schematic diagram of a process of screening a video data stream according to a preset data processing condition in a video data processing method provided by an embodiment of the present invention;
[0017] Figure 4 A schematic diagram of a scenario of performing statistical analysis on a screened video data stream in a video data processing method provided by an embodiment of the present invention;
[0018] Figure 5 A schematic diagram of the table structure of a frame type index table established by a method for processing video data provided by an embodiment of the present invention;
[0019] Figure 6 A schematic diagram of a mapping structure between data frames and messages corresponding to target video data;
[0020] Figure 7 A schematic diagram of a scenario in which label information corresponding to a key frame message is encapsulated into a tunnel extension field of a key frame message in a video data processing method provided by an embodiment of the present invention;
[0021] Figure 8 A schematic diagram of the framework structure of a communication device provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0022] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0023] The flowcharts shown in the accompanying drawings are only examples and do not necessarily include all the contents and operations / steps, nor must they be executed in the order described. For example, some operations / steps may also be decomposed, combined or partially merged, so the actual execution order may change according to actual conditions.
[0024] It should be understood that the terms used in this specification of the present invention are only for the purpose of describing specific embodiments and are not intended to limit the present invention. As used in the specification of the present invention and the appended claims, unless the context clearly indicates otherwise, the singular forms "a", "an" and "the" are intended to include plural forms.
[0025] With the development of 5G technology, the speed of web browsing through terminal devices such as mobile phones and laptops is getting faster and faster, and more and more users are accustomed to playing videos through terminal devices.
[0026] Usually, video services are processed by communication equipment and transmitted to terminal equipment to optimize the video played by the terminal equipment. However, compared with conventional services, video services have larger traffic and higher real-time performance, but the computing and scheduling resources of communication equipment are limited. In the process of processing the data traffic of video services in the prior art, there is a problem of high CPU performance consumption of communication equipment, which reduces the performance of communication equipment and service processing efficiency, and ultimately limits the overall throughput of communication equipment.
[0027] In order to solve this technical problem, an embodiment of the present invention provides a method for processing video data, a communication device and a storage medium, wherein the method for processing video data is applied to a communication device, and the communication device includes but is not limited to a network element device.
[0028] Some embodiments of the present invention are described in detail below in conjunction with the accompanying drawings. In the absence of conflict, the following embodiments and features in the embodiments can be combined with each other.
[0029] See also Figure 1 , Figure 1 A schematic diagram of an application scenario of a data transmission system provided by an embodiment of the present invention.
[0030] like Figure 1 As shown, the data transmission system 100 includes a wireless communication system 20 and a resource server 30. The resource server 30 is used to store resource data, which includes but is not limited to video resource data. When the terminal device 10 is watching video resources, the terminal device 10 needs to download the corresponding video resources from the resource server 30, and process the video resources through the wireless communication system 20 and transmit them to the terminal device 10, so that the user can watch the video resources on the terminal device 10. In order to enhance the transmission reliability of the video resources, the wireless communication system 20 needs to process the video resources and transmit the processed video data to the terminal device 10, so that the terminal device 10 can watch the corresponding video, wherein the wireless communication system 20 includes at least one communication device 21, such as the wireless communication system 20 includes a plurality of communication devices 21 connected in communication.
[0031] The video resource is an extended reality video resource for explanation, wherein the extended reality video resource includes but is not limited to virtual reality video resources, augmented reality video resources, and mixed reality video resources.
[0032] The wireless communication system 20 provides better network transmission for the extended reality service so that users can get a better end-to-end service experience. Compared with conventional services, the extended reality service used to transmit extended reality video resources has larger traffic and higher real-time performance, but the computing and scheduling resources of the wireless communication system 20 are limited, and it is impossible to optimize the network transmission of all the traffic of the extended reality service. Therefore, it is necessary to distinguish between target video resources and non-target video resources, and distinguish between the key and non-key parts of the video traffic corresponding to the target video resources, and use the limited computing and scheduling resources of the wireless communication system 20 to provide network transmission optimization for the key part of the traffic of the target video resources, balance input and output, and maximize benefits.
[0033] Typically, the frame types of extended reality video resources transmitted by the extended reality service are divided into three types: I-frames (Intrapictures, node images), P-frames (Predicted pictures, predicted images), and B-frames (Bi-predictivepictures, forward and backward predicted images). For the wireless communication system 20, I-frames are key frames. If key frames have problems such as packet loss during transmission, the video viewing experience of the terminal device 10 may be affected. Therefore, in order to improve the video viewing experience of the terminal device 10, it is necessary to provide key transmission guarantees for them. P-frames or B-frames are not key frames, and they have little impact on the video viewing experience of the terminal device 10, so there is no need to provide key transmission guarantees for them.
[0034] In the present invention, the wireless communication system 20 processes the I frame message of the target video data so that the I frame message of the target video data is given priority during the transmission process, thereby effectively reducing the performance loss of the communication equipment, reliably assisting in improving the performance and business processing efficiency of the communication equipment, and thereby improving the overall throughput of the communication equipment.
[0035] See also Figure 2 , Figure 2 A flowchart of a method for processing video data provided by an embodiment of the present invention.
[0036] like Figure 2 As shown, the method for processing video data is applied to a communication device 21 in a wireless communication system 20, and the method for processing video data includes steps S101 to S103.
[0037] Step S101: determine a target video resource, and establish a frame type index table of the target video resource according to key frame information of the target video resource.
[0038] Exemplarily, in order to improve the performance and business processing efficiency of the communication device 21 in the wireless communication system 20, after receiving the video resources, the communication device 21 in the wireless communication system 20 determines the target video resources from the video resources, and establishes a frame type index table of the target video resources based on the key frame information of the target video resources.
[0039] For example, based on the various types of video resources watched by the terminal device 10, different video resources have different popularity, that is, the video resources include popular video resources (also called high-frequency video resources) whose user click frequency exceeds a first preset value, and non-popular video resources whose user click frequency is lower than a preset value. Based on the high user click rate of popular video resources, taking popular video resources as target video resources for key transmission guarantee can reliably assist in improving the performance and service processing efficiency of the wireless communication system 20, thereby improving the overall throughput of the wireless communication system 20.
[0040] In order to ensure the key transmission of target video resources, after selecting popular video resources as target video resources, the communication device 21 uses the key frame information of the target video resources to establish a frame type index table of the target video resources, so that the subsequently received video resources can be analyzed according to the frame type index table to determine whether the received video resources are popular video resources.
[0041] In some implementations, determining the target video resource includes:
[0042] Filtering the received data stream according to preset data processing conditions to obtain a video data stream;
[0043] A statistical analysis is performed on the video data stream, and a target video resource is determined according to the statistical analysis result, wherein the target video resource is a video resource whose occurrence frequency exceeds a preset number of times within a preset time period.
[0044] Exemplarily, the communication device 21 of the wireless communication system 20 is provided with a data processing condition, and the received data stream is screened using the data processing condition to obtain a video data stream, and the screened video data stream is statistically analyzed to determine a target video resource from the video data according to the statistical analysis result, wherein the target video resource is a video resource whose frequency of occurrence exceeds a preset number of times within a preset time period. Optionally, the data processing condition can be one or more, and the user can set it as needed.
[0045] In some implementations, the step of filtering the received data stream according to a preset data processing condition to obtain a video data stream includes:
[0046] When receiving a data stream to be transmitted, detect whether the transmission protocol of the data stream to be transmitted is a preset transmission protocol; when the transmission protocol of the data stream to be transmitted is the preset transmission protocol, detect whether the data stream to be transmitted is an extended reality business data stream; when the data stream to be transmitted is the extended reality business data stream, detect whether the data format of the data stream to be transmitted is a preset format type; when the data format of the data stream to be transmitted is the preset format type, use the data stream to be transmitted as the video data stream.
[0047] Exemplarily, the communication device 21 of the wireless communication system 20 is provided with a first data processing condition, a second data processing condition and a third data processing condition, and uses the three data processing conditions to detect the received data stream to be transmitted to preliminarily screen the video data stream.
[0048] like Figure 3As shown, specifically, for the first data processing condition, the communication device 21 of the wireless communication system 20 checks the transport layer protocol of the data stream to be transmitted to determine whether the data stream may belong to the extended reality service. For example, the communication device 21 of the wireless communication system 20 can match the first message payload of the TCP stream with the characteristic expression "(GET|POST).*HTTP / 1.
[01] \r\n". If the match is successful, the communication device 21 of the wireless communication system 20 considers that the data stream to be transmitted is HTTP (Hyper Text Transfer Protocol), so that the data stream passes the detection of the first data processing condition, and further performs the detection of the second data processing condition. If the match fails, the stream is not further detected.
[0049] After the data stream to be transmitted meets the first data processing condition, the data stream to be transmitted is tested for the second data processing condition. Specifically, the communication device 21 of the wireless communication system 20 checks the domain name of the data stream to be transmitted (i.e., HTTP stream) to determine whether the HTTP stream may belong to the extended reality service data stream. Typically, the communication device 21 of the wireless communication system 20 presets a number of supported extended reality service domain names, such as "xr.example-1.com", "xr.example-2.net", etc., as a known domain name set. The communication device 21 of the wireless communication system 20 obtains the Host field value in the first uplink request message of each HTTP stream as the current domain name, and the communication device 21 searches for the current domain name in the known domain name set. If it can be found, the data stream to be transmitted passes the check to further test the third data processing condition; if it cannot be found, the data stream to be transmitted is not further tested.
[0050] After the data stream to be transmitted meets the second data processing condition, the data stream to be transmitted is tested for the third data processing condition. Specifically, the communication device 21 checks the stream data format type transmitted by the HTTP stream of the known extended reality service of the data stream to be transmitted to determine whether the data stream meets the supported format type. Typically, the communication device 21 presets several supported extended reality service format types, such as "video / mp4", "video / 3gpp", etc., as a known format type set. The communication device 21 obtains the Content-Type field value in the HTTP response message of the data stream as the current format type, and the communication device 21 searches for the current format type in the known format type set. If it can be found, the data stream to be transmitted is used as the video data stream.
[0051] Alternatively, for the third data processing condition, the communication device 21 of the wireless communication system 20 may check whether the HTTP response message payload data conforms to the extended reality encoding format type. Typically, taking the MPEG-4 encoding format type as an example, the communication device 21 checks whether the first N bytes of the payload data in the HTTP response message of the data stream contain the "ftyp" feature word. If it can be found, the HTTP response message uses the data stream to be transmitted as the video data stream.
[0052] In some implementations, performing statistical analysis on the video data stream and determining the target video resource according to the statistical analysis result includes:
[0053] The video data streams obtained within a preset time period are obtained, and the video resources corresponding to each of the video data streams are recorded; the occurrence frequency of the video resources corresponding to each of the video data streams within the preset time period is counted; and the video resources corresponding to the video data streams whose occurrence frequency exceeds a preset number of times are taken as the target video resources.
[0054] For example, Figure 4 As shown, different video data streams may correspond to different video resources, that is, one video resource may be carried in one video stream or in multiple different video streams.
[0055] The communication device 21 of the wireless communication system 20 extracts the first M bytes of an extended reality resource file in the HTTP payload part from the response message of the HTTP stream corresponding to the video data stream that meets the data processing conditions, and establishes a unique resource name XRUN (K) for different extended reality services. Then, the number of occurrences of the resource name XRUN (K) corresponding to each video resource in the video data stream is counted in units of time slices, and the video resources corresponding to the resource names XRUN (K) ranked first in the number of occurrences are taken as high-frequency video resources, that is, target video resources.
[0056] For example, the communication device 21 of the wireless communication system 20 extracts HTTP header fields such as Host and URL in each video data stream as metadata from the video data stream that meets the data processing conditions, and establishes a unique resource name XRUN(K) for the video resources corresponding to different extended reality services. For example, XRUN(K) can be a string composed of various metadata, "HTTP"+"Request"+"Host:xr.example-1.com"+" / resource / xr / data00001.mp4".
[0057] Then, the number of occurrences of the resource name XRUN(K) is counted with the total statistical duration being T5, where T5 is divided into multiple time slices, from T0 to T1 is one time slice, T1 to T2 is the next time slice, T2 to T3 is the next time slice, T3 to T4 is the next time slice, and T4 to T5 is the last time slice.
[0058] The statistics start from zero at the beginning of each time slice, and the statistical result of each time slice is recorded as Sn at the end of each time slice. For example, the statistical result from time slices T0 to T1 is recorded as S1, the statistical result from time slices T1 to T2 is recorded as S2, the statistical result from time slices T2 to T3 is recorded as S3, the statistical result from time slices T3 to T4 is recorded as S4, and the statistical result from time slices T4 to T5 is recorded as S5.
[0059] The communication device 21 of the wireless communication system 20 uses multiple consecutive time slices as a statistical interval, for example: from T0 to T2 is a statistical interval recorded as B1, from T1 to T3 is the next statistical interval recorded as B2, from T2 to T4 is the next statistical interval recorded as B3, and from T3 to T5 is the next statistical interval recorded as B4. S1 and S2 are combined as the B1 statistical result, S2 and S3 are combined as the B2 statistical result, S3 and S4 are combined as the B3 statistical result, and S4 and S5 are combined as the B4 statistical result. The multiple resource names XRUN(K) in each statistical interval Bx are sorted from most to least according to the number of occurrences, and the video resources corresponding to the top y resource names XRUN(K) in each statistical interval are taken as high-frequency video resources, that is, target video resources. In this sliding time window manner, continuous and stable statistical results are obtained, and y can be set as needed, such as y is a positive integer greater than or equal to 1.
[0060] In some implementations, establishing a frame type index table of the target video resource according to key frame information of the target video resource includes:
[0061] Classifying the target video resources according to the key frame ratio of the target video resources;
[0062] A frame type index table of the target video resource is established according to the resource classification result, and the frame type index table records the identification information of the target video resource, the resource appearance time of the target video resource, and the distribution information of key frames or non-key frames in the target video resource.
[0063] Exemplarily, after obtaining the target video resources, the obtained target video resources are classified according to the key frame ratio of the target video resources. The key frame ratios of target video resources of different categories are different, so as to establish a frame type index table that records the identification information of the corresponding target video resources, the resource appearance time of the target video resources, and the distribution information of the key frames or non-key frames in the target video resources. Based on the frame type index table, the target video resources are classified according to the key frame ratio and the distribution information of the key frames or non-key frames in the target video resources is recorded, so that there is no need to record the distribution of key frames and non-key frames in each video resource, thereby effectively reducing the memory usage of the communication device 21.
[0064] See also Figure 5 Each target video resource has a corresponding index table STBL. After obtaining the target video resource, the communication device 21 of the wireless communication system 20 obtains the proportion of I frames according to the index table STBL of each target video resource, and classifies the target video resources according to the proportion of I frames.
[0065] For example, the communication device 21 obtains the total number of all types of frames Sample_Count from the STSZ (Sample Size Box) table in the index table STBL (Sample to Group Box) of a target video resource with a resource name of XRUN1, and obtains the number of all I frames (also called key frames) I_Count from the STSS (Sync Sample Table) table, and then calculates the result of dividing I_Count by Sample_Count. If the result is less than or equal to 0.5, the communication device 21 records the offset and length sequence of all I frames taken from its STBL table for the target video resource named XRUN1, and ensures that these offsets start from the starting part of the extended reality stream data, not the MDAT (Media Data Box) part, and marks the target video resource named XRUN1 as type 1.
[0066] The communication device 21 obtains the total number of all types of frames Sample_Count from the STSZ table in the index table STBL of a target video resource with a resource name of XRUN2, and obtains the number of all I frames I_Count from the STSS table, and then calculates the result of dividing I_Count by Sample_Count. If the result is greater than 0.5, the communication device 21 records the offset and length sequence of all non-I frames taken from its STBL table for the target video resource with the resource name of XRUN2, and ensures that these offsets start from the starting part of the extended reality stream data, not the MDAT part, and marks the target video resource with the resource name of XRUN2 as type 2.
[0067] When the communication device 21 detects from the index table of a target video resource with a resource name of XRUN3 that the STSS table does not exist (i.e., each frame is an I frame), the target video resource with the resource name of XRUN3 is directly marked as a type 3 full I frame identifier, which only occupies 1 valid bit of memory.
[0068] The communication device 21 detects from the index table of a target video resource with a resource name of XRUN4 that its image data MDAT appears before its index table STBL, and directly marks the target video resource with the resource name of XRUN4 as a type 4 non-I frame identifier, which only occupies 1 valid bit of memory.
[0069] Step S102: detecting the data stream of the to-be-processed video resource that meets the preset data processing condition according to the frame type index table, and identifying the key frame message in the data stream of the to-be-processed video resource according to the detection result.
[0070] Exemplarily, after the frame type index table is established, the communication device 21 of the wireless communication system 20 uses the frame type index table to detect the received data stream of the video resource to be processed that meets the preset data processing conditions, and identifies whether the video resource to be processed is the target video resource that needs to be processed based on the detection result, and identifies the key frame message in the data stream of the target video resource to perform the next processing operation on the key frame message.
[0071] In some implementations, detecting a data stream of a to-be-processed video resource that meets a preset data processing condition according to the frame type index table, and identifying a key frame message in the data stream of the to-be-processed video resource according to the detection result, includes:
[0072] Acquire a data stream of a to-be-processed video resource that meets a preset data processing condition, and identify resource information of the to-be-processed video resource corresponding to the data stream of the to-be-processed video resource;
[0073] It is determined whether the resource information is recorded in the frame type index table, and when the resource information is recorded in the frame type index table, a key frame message in the data stream of the video resource to be processed is identified according to the frame type index table.
[0074] Exemplarily, the communication device 21 of the wireless communication system 20 is provided with the aforementioned first data processing condition, second data processing condition and third data processing condition, and uses the three data processing conditions to detect the received data stream to be transmitted to filter out the data stream of the video resource to be processed.
[0075] Then, the resource information of the data stream of the corresponding video resource to be processed is obtained, and the resource information includes but is not limited to the identification information corresponding to the resource (also called the resource name), and it is determined whether the identification information is recorded in the frame type index table, so as to determine whether the video resource corresponding to the data stream of the current video resource to be processed is the target video resource (i.e., the high-frequency video resource). If it is the target video resource, the frame type index table is used to specifically analyze which category the video resource corresponding to the data stream of the current video resource to be processed belongs to, and the key frame message in the video resource is specifically analyzed and marked.
[0076] Exemplarily, the communication device 21 of the wireless communication system 20 obtains the unique resource name XRUN corresponding to the message from the HTTP request message or HTTP response message that meets the inspection condition, and checks whether the resource name XRUN exists in the frame type index table. If it exists, it indicates that the message corresponding to the video resource currently received by the communication device 21 is the message corresponding to the target video resource, and the message needs to be further detected to determine whether the high message is the message corresponding to the key frame; otherwise, no detection is performed.
[0077] For example, a video resource includes multiple video frames, which include at least one of a key frame (I frame) and a non-key frame (B frame and P frame). During the video resource transmission process, the resource server 30 slices the video resource and processes it into a message form and transmits it to the communication device 21 through a preset data transmission protocol (such as HTTP). Therefore, each video frame may be divided into one or more messages. During the message transmission process, in order to enable the terminal device 10 to have a better viewing experience, it is necessary to ensure the transmission of the message corresponding to the key video frame.
[0078] Typically, the communication device 21 processes the message packet in the form of a data stream. After receiving the data stream of the video resource to be processed that meets the preset data processing conditions, the communication device 21 extracts the unique resource name XRUN(K) of the video resource corresponding to the data stream of the video resource to be processed. The communication device 21 checks whether the HTTP response message containing the resource name XRUN(K) has a Content-Range field. If not, the communication device 21 believes that one HTTP session carries all the stream data corresponding to the video resource with the resource name XRUN(K); if so, the communication device 21 believes that multiple HTTP sessions jointly carry all the stream data of the video resource with the resource name XRUN(K) to be processed.
[0079] For a HTTP session carrying all stream data of a resource named XRUN(K), the communication device 21 determines the correct order of multiple messages carrying the HTTP response message according to the IP length and TCP sequence number of the message. Figure 6 As shown, message 1, message 2, message 3, and message 4 all belong to the same HTTP session.
[0080] In the case where multiple HTTP sessions jointly carry all the stream data of the resource named XRUN(K), the communication device 21 associates the HTTP response messages of the multiple HTTP sessions in order according to the Content-Range field in the HTTP response message, and determines the correct order of the multiple messages carrying the HTTP response message of each HTTP session in combination with the IP length and TCP sequence number of the message, and then obtains the correct order of all the messages of the stream data of the resource named XRUN(K). For example, message 1 and message 2 belong to the first HTTP session, and message 3 and message 4 belong to the second HTTP session.
[0081] After determining all the messages corresponding to the data stream of the video resource to be processed, determine whether the resource name of the video resource to be processed is XRUN(K) and is recorded in the established frame type index table. If the resource name of the video resource to be processed is XRUN(K) and is recorded in the established frame type index table, it indicates that the current video resource to be processed is the target video resource, and it is necessary to identify the resource type of the video resource to be processed and identify the key messages in the video resource to be processed according to the resource type.
[0082] For example, the communication device 21 obtains the I frame of the to-be-processed video resource whose resource name is XRUN(K) to perform resource type determination, so as to determine the resource type corresponding to the to-be-processed video resource according to the proportion of the I frame.
[0083] If it is determined that the resource type of the video resource to be processed is type 1, then based on the I frame offset and length sequence of the resource name XRUN (K) in the frame type index table, determine whether each response message contains a complete or partial I frame. If it does, the message is detected as an I frame; otherwise, the message is detected as a non-I frame.
[0084] If it is determined that the resource type of the video resource to be processed is type 2, the communication device 21 determines whether each response message contains a complete or partial I frame based on the non-I frame offset and length sequence of the resource name XRUN (K) in the frame type index table. If it does, the message is detected as an I frame; otherwise, the message is detected as a non-I frame.
[0085] If it is determined that the resource type of the video resource to be processed is type 3, the communication device 21 detects all of the above HTTP response message packets as I frames.
[0086] If it is determined that the resource type of the video resource to be processed is type 4, the communication device 21 detects all of the above HTTP response message packets as non-I frames.
[0087] Step S103: performing preset message processing on the key frame messages in the data stream of the video resource to be processed.
[0088] Exemplarily, after determining the key frame message in the data stream of the video resource to be processed, a preset message processing operation is performed on the key frame message. The message processing can be set as needed, for example, marking the key frame message so that the next level of communication equipment can further process the key frame message.
[0089] In some implementations, performing preset message processing on key frame messages in the data stream of the video resource to be processed includes:
[0090] A label is assigned to a key frame message in the data stream of the video resource to be processed, where the label is used to indicate that the message is a key frame message.
[0091] Optionally, after assigning a label to the key frame message in the data stream of the video resource to be processed, the method further includes: encapsulating label information corresponding to the label in a tunnel extension field of the key frame message, and outputting the key frame message to a preset message receiving system.
[0092] Exemplarily, in an embodiment of the present invention, the communication device 21 of the wireless communication system 20 is responsible for identifying key frame messages in the data stream of the video resource to be processed, marking the key frame messages by assigning labels, and transmitting them to the next-level communication device in the wireless communication system 20 (in order to distinguish between the communication device 21 and the next-level communication device, the next-level communication device can be recorded as a second communication device) for further processing.
[0093] like Figure 7 As shown, the communication device 21 can be a core network PGW network element or a core network UPF network element. For example, the communication device 21 is a core network PGW network element in a 3GPP 4G network, and the second communication device is an eNodeB network element. The PGW network element is used as the host network element of the communication device 21, and the message is transmitted between the PGW network element and the wireless access network eNodeB network element (the second communication device) through the GTPU tunnel. The communication device 21 encapsulates the high-frequency extended reality flow data resource I frame detection result of the message in the GTPUPrivate Extension extension field, so that the eNodeB network element directly obtains the high-frequency extended reality flow data resource I frame detection result of the message from the extension field, which greatly reduces the processing burden of the eNodeB network element for performing corresponding detection on the message.
[0094] Alternatively, take the communication device 21 as the core network UPF network element in the 3GPP 5G network, and the second communication device as the gNodeB network element as an example. The UPF network element is used as the host network element of the communication device 21, and the message is transmitted between the UPF network element and the wireless access network gNodeB network element (the second communication device) through the GTPU tunnel. The communication device 21 encapsulates the high-frequency extended reality flow data resource I frame detection result of the message in the GTPU Private Extension extension field, so that the gNodeB network element directly obtains the high-frequency extended reality flow data resource I frame detection result of the message from the extension field, which greatly reduces the processing burden of the gNodeB network element for performing corresponding detection on the message.
[0095] In some embodiments, the method further comprises:
[0096] Updating the target video resource, and updating the frame type index table according to the updated target video resource;
[0097] The updated frame type index table is used to detect data packets of the to-be-processed video resources that meet the preset data processing conditions.
[0098] Exemplarily, based on the fact that the popularity of resources has a certain time periodicity, the communication device 21 of the communication system 20 updates the target video resources according to a preset update strategy, and updates the frame type index table according to the updated target video resources, so that the target video resources recorded in the frame type index table are the current popular video resources, and then the updated frame type index table is used to detect the data packets of the video resources to be processed that meet the preset data processing conditions, so that the video service provided by the communication device 21 is more effective.
[0099] See also Figure 8 In some implementations, the communication device 21 includes a processor 211 and a memory 212, and the processor 211 and the memory 212 are connected via a bus 213, such as an I2C (Inter-integrated Circuit) bus.
[0100] Specifically, the processor 211 may be a central processing unit (CPU), and the processor may also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. Among them, the general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc.
[0101] The memory 212 may be a Flash chip, a read-only memory (ROM) disk, an optical disk, a USB flash drive, or a mobile hard disk.
[0102] The processor 211 is used to run the computer program stored in the memory 212, and implement the following steps when executing the computer program:
[0103] Determine a target video resource, and establish a frame type index table of the target video resource according to key frame information of the target video resource;
[0104] Detecting a data stream of a to-be-processed video resource that meets a preset data processing condition according to the frame type index table, and identifying a key frame message in the data stream of the to-be-processed video resource according to the detection result;
[0105] Perform preset message processing on the key frame messages in the data stream of the video resource to be processed.
[0106] In some implementations, determining the target video resource includes:
[0107] Filtering the received data stream according to preset data processing conditions to obtain a video data stream;
[0108] A statistical analysis is performed on the video data stream, and a target video resource is determined according to the statistical analysis result, wherein the target video resource is a video resource whose occurrence frequency exceeds a preset number of times within a preset time period.
[0109] In some implementations, the step of filtering the received data stream according to a preset data processing condition to obtain a video data stream includes:
[0110] When receiving a data stream to be transmitted, detecting whether a transmission protocol of the data stream to be transmitted is a preset transmission protocol;
[0111] When the transmission protocol of the data stream to be transmitted is the preset transmission protocol, detecting whether the data stream to be transmitted is an extended reality service data stream;
[0112] When the data stream to be transmitted is the extended reality service data stream, detecting whether the data format of the data stream to be transmitted is a preset format type;
[0113] When the data format of the data stream to be transmitted is the preset format type, the data stream to be transmitted is used as the video data stream.
[0114] In some implementations, performing statistical analysis on the video data stream and determining the target video resource according to the statistical analysis result includes:
[0115] Acquire the video data streams obtained within a preset time period, and record the video resources corresponding to each of the video data streams;
[0116] Counting the occurrence frequency of the video resource corresponding to each of the video data streams within the preset time period;
[0117] The video resource corresponding to the video data stream that appears more than a preset number of times is used as the target video resource.
[0118] In some implementations, establishing a frame type index table of the target video resource according to key frame information of the target video resource includes:
[0119] Classifying the target video resources according to the key frame ratio of the target video resources;
[0120] A frame type index table of the target video resource is established according to the resource classification result, and the frame type index table records the identification information of the target video resource, the resource appearance time of the target video resource, and the distribution information of key frames or non-key frames in the target video resource.
[0121] In some implementations, detecting a data stream of a to-be-processed video resource that meets a preset data processing condition according to the frame type index table, and identifying a key frame message in the data stream of the to-be-processed video resource according to the detection result, includes:
[0122] Acquire a data stream of a to-be-processed video resource that meets a preset data processing condition, and identify resource information of the to-be-processed video resource corresponding to the data stream of the to-be-processed video resource;
[0123] It is determined whether the resource information is recorded in the frame type index table, and when the resource information is recorded in the frame type index table, a key frame message in the data stream of the video resource to be processed is identified according to the frame type index table.
[0124] In some implementations, performing preset message processing on key frame messages in the data stream of the video resource to be processed includes:
[0125] A label is assigned to a key frame message in the data stream of the video resource to be processed, where the label is used to indicate that the message is a key frame message.
[0126] In some implementations, after assigning a label to the key frame message in the data stream of the video resource to be processed, the processor 211 is further configured to execute:
[0127] The tag information corresponding to the tag is encapsulated in the tunnel extension field of the key frame message, and the key frame message is output to a preset message receiving system.
[0128] In some implementations, the processor 211 is further configured to execute:
[0129] Updating the target video resource, and updating the frame type index table according to the updated target video resource;
[0130] The updated frame type index table is used to detect data packets of the to-be-processed video resources that meet the preset data processing conditions.
[0131] It should be noted that those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working process of the base station described above can refer to the corresponding process in the aforementioned corresponding video data processing method embodiment, and will not be repeated here.
[0132] An embodiment of the present invention further provides a storage medium for computer-readable storage, wherein the storage medium stores one or more programs, and the one or more programs can be executed by one or more processors to implement the steps of the video data processing method of any embodiment provided in the specification of the embodiment of the present invention.
[0133] The storage medium may be an internal storage unit of the aforementioned communication device 21, such as a hard disk or memory of the communication device 21. The storage medium may also be an external storage device of the communication device 21, such as a plug-in hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card, a flash card (Flash Card), etc., equipped on the communication device 21.
[0134] It will be appreciated by those skilled in the art that all or some of the steps, systems, and functional modules / units in the methods disclosed above may be implemented as software, firmware, hardware, and appropriate combinations thereof. In a hardware embodiment, the division between the functional modules / units mentioned in the above description does not necessarily correspond to the division of physical components; for example, a physical component may have multiple functions, or a function or step may be performed by several physical components in cooperation. Some or all physical components may be implemented as software executed by a processor, such as a central processing unit, a digital signal processor, or a microprocessor, or implemented as hardware, or implemented as an integrated circuit, such as an application-specific integrated circuit. Such software may be distributed on a computer-readable medium, which may include a computer storage medium (or non-transitory medium) and a communication medium (or temporary medium). As known to those skilled in the art, the term computer storage medium includes volatile and non-volatile, removable and non-removable media implemented in any method or technology for storing information (such as computer-readable instructions, data structures, program modules, or other data). Computer storage media include, but are not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, digital versatile disks (DVD) or other optical disk storage, magnetic cassettes, magnetic tapes, magnetic disk storage or other magnetic storage devices, or any other medium that can be used to store the desired information and can be accessed by a computer. In addition, it is well known to those of ordinary skill in the art that communication media typically contain computer-readable instructions, data structures, program modules, or other data in a modulated data signal such as a carrier wave or other transport mechanism, and may include any information delivery media.
[0135] It should be understood that the term "and / or" used in the present specification and the appended claims refers to any combination of one or more of the associated listed items and all possible combinations, including these combinations. It should be noted that, in this article, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or system including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, article or system. In the absence of further restrictions, an element defined by the sentence "including a..." does not exclude the presence of other identical elements in the process, method, article or system including the element.
[0136] The serial numbers of the embodiments of the present invention are only for description and do not represent the advantages and disadvantages of the embodiments. The above description is only a specific embodiment of the present invention, but the protection scope of the present invention is not limited thereto. Any technician familiar with the technical field can easily think of various equivalent modifications or replacements within the technical scope disclosed by the present invention, and these modifications or replacements should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention shall be based on the protection scope of the claims.
Claims
1. A method for processing video data, characterized in that: Applied to a communication device, the method comprises: Determine a target video resource, and establish a frame type index table of the target video resource according to key frame information of the target video resource; Detecting a data stream of a to-be-processed video resource that meets a preset data processing condition according to the frame type index table, and identifying a key frame message in the data stream of the to-be-processed video resource according to the detection result; Perform preset message processing on the key frame messages in the data stream of the video resource to be processed.
2. The method according to claim 1, characterized in that: The determining of the target video resource comprises: Filter the received data stream according to preset data processing conditions to obtain a video data stream; A statistical analysis is performed on the video data stream, and a target video resource is determined according to the statistical analysis result, wherein the target video resource is a video resource whose occurrence frequency exceeds a preset number of times within a preset time period.
3. The method according to claim 2, characterized in that The step of filtering the received data stream according to the preset data processing condition to obtain the video data stream includes: When receiving a data stream to be transmitted, detecting whether a transmission protocol of the data stream to be transmitted is a preset transmission protocol; When the transmission protocol of the data stream to be transmitted is the preset transmission protocol, detecting whether the data stream to be transmitted is an extended reality service data stream; When the data stream to be transmitted is the extended reality service data stream, detecting whether the data format of the data stream to be transmitted is a preset format type; When the data format of the data stream to be transmitted is the preset format type, the data stream to be transmitted is used as the video data stream.
4. The method according to claim 2, characterized in that: The performing statistical analysis on the video data stream and determining the target video resource according to the statistical analysis result includes: Acquire the video data streams obtained within a preset time period, and record the video resources corresponding to each of the video data streams; Counting the occurrence frequency of the video resource corresponding to each of the video data streams within the preset time period; The video resource corresponding to the video data stream that appears more than a preset number of times is used as the target video resource.
5. The method according to claim 1, characterized in that The step of establishing a frame type index table of the target video resource according to the key frame information of the target video resource includes: Classifying the target video resources according to the key frame ratio of the target video resources; A frame type index table of the target video resource is established according to the resource classification result, and the frame type index table records the identification information of the target video resource, the resource appearance time of the target video resource, and the distribution information of key frames or non-key frames in the target video resource.
6. The method according to claim 1, characterized in that The detecting, according to the frame type index table, a data stream of a to-be-processed video resource that meets a preset data processing condition, and identifying a key frame message in the data stream of the to-be-processed video resource according to the detection result, includes: Acquire a data stream of a to-be-processed video resource that meets a preset data processing condition, and identify resource information of the to-be-processed video resource corresponding to the data stream of the to-be-processed video resource; It is determined whether the resource information is recorded in the frame type index table, and when the resource information is recorded in the frame type index table, a key frame message in the data stream of the video resource to be processed is identified according to the frame type index table.
7. The method according to claim 1, characterized in that The performing preset message processing on the key frame message in the data stream of the video resource to be processed includes: A label is assigned to a key frame message in the data stream of the video resource to be processed, where the label is used to indicate that the message is a key frame message.
8. The method according to claim 7, characterized in that After assigning labels to the key frame messages in the data stream of the video resource to be processed, the method further includes: The tag information corresponding to the tag is encapsulated in the tunnel extension field of the key frame message, and the key frame message is output to a preset message receiving system.
9. The method according to any one of claims 1 to 8, characterized in that: The method further comprises: Updating the target video resource, and updating the frame type index table according to the updated target video resource; The updated frame type index table is used to detect data packets of the to-be-processed video resources that meet the preset data processing conditions.
10. A communication device, characterized in that: The communication device comprises: a processor, a memory, a computer program stored in the memory and executable by the processor, and a data bus for realizing connection communication between the processor and the memory, wherein when the computer program is executed by the processor, the steps of the method for processing video data as described in any one of claims 1 to 9 are realized.
11. A storage medium for computer-readable storage, characterized in that: The storage medium stores one or more programs, and the one or more programs can be executed by one or more processors to implement the steps of the video data processing method according to any one of claims 1 to 9.
