WO2023241057A1 - 数据处理方法、装置、设备及存储介质 - Google Patents

数据处理方法、装置、设备及存储介质 Download PDF

Info

Publication number
WO2023241057A1
WO2023241057A1 PCT/CN2023/073991 CN2023073991W WO2023241057A1 WO 2023241057 A1 WO2023241057 A1 WO 2023241057A1 CN 2023073991 W CN2023073991 W CN 2023073991W WO 2023241057 A1 WO2023241057 A1 WO 2023241057A1
Authority
WO
WIPO (PCT)
Prior art keywords
data
frame
processed
description information
frame data
Prior art date
Application number
PCT/CN2023/073991
Other languages
English (en)
French (fr)
Inventor
张俊勤
Original Assignee
京东科技信息技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 京东科技信息技术有限公司 filed Critical 京东科技信息技术有限公司
Publication of WO2023241057A1 publication Critical patent/WO2023241057A1/zh

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/23Processing of content or additional data; Elementary server operations; Server middleware
    • H04N21/234Processing of video elementary streams, e.g. splicing of video streams or manipulating encoded video stream scene graphs
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/02Protocols based on web technology, e.g. hypertext transfer protocol [HTTP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/23Processing of content or additional data; Elementary server operations; Server middleware
    • H04N21/231Content storage operation, e.g. caching movies for short term storage, replicating data over plural servers, prioritizing data for deletion
    • H04N21/23106Content storage operation, e.g. caching movies for short term storage, replicating data over plural servers, prioritizing data for deletion involving caching operations
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/23Processing of content or additional data; Elementary server operations; Server middleware
    • H04N21/233Processing of audio elementary streams
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/23Processing of content or additional data; Elementary server operations; Server middleware
    • H04N21/234Processing of video elementary streams, e.g. splicing of video streams or manipulating encoded video stream scene graphs
    • H04N21/23418Processing of video elementary streams, e.g. splicing of video streams or manipulating encoded video stream scene graphs involving operations for analysing video streams, e.g. detecting features or characteristics
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/60Network structure or processes for video distribution between server and client or between remote clients; Control signalling between clients, server and network components; Transmission of management data between server and client, e.g. sending from server to client commands for recording incoming content stream; Communication details between server and client 
    • H04N21/63Control signaling related to video distribution between client, server and network components; Network processes for video distribution between server and clients or between remote clients, e.g. transmitting basic layer and enhancement layers over different transmission paths, setting up a peer-to-peer communication via Internet between remote STB's; Communication protocols; Addressing
    • H04N21/643Communication protocols
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/60Network structure or processes for video distribution between server and client or between remote clients; Control signalling between clients, server and network components; Transmission of management data between server and client, e.g. sending from server to client commands for recording incoming content stream; Communication details between server and client 
    • H04N21/63Control signaling related to video distribution between client, server and network components; Network processes for video distribution between server and clients or between remote clients, e.g. transmitting basic layer and enhancement layers over different transmission paths, setting up a peer-to-peer communication via Internet between remote STB's; Communication protocols; Addressing
    • H04N21/643Communication protocols
    • H04N21/6437Real-time Transport Protocol [RTP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/80Generation or processing of content or additional data by content creator independently of the distribution process; Content per se
    • H04N21/83Generation or processing of protective or descriptive data associated with content; Content structuring
    • H04N21/845Structuring of content, e.g. decomposing content into time segments
    • H04N21/8456Structuring of content, e.g. decomposing content into time segments by decomposing the content in the time domain, e.g. in time segments

Definitions

  • the present disclosure relates to the field of data processing technology, and in particular, to a data processing method, device, equipment and storage medium.
  • the playback of streaming media data needs to complete slicing processing according to the adaptive code rate streaming media transmission protocol based on Hypertext Transfer Protocol.
  • the edge node performs slicing.
  • different edge nodes may have different parameters such as the duration of each generated shard due to different configuration parameters. Due to the existence of differences, when streaming media is switched, playback accidents such as discontinuous playback, re-frames, and freezes of streaming media data obtained from different edge nodes may occur, and the slicing processing effect is poor.
  • the other is source station node slicing, and edge nodes return to the source, thereby providing users with segmented live streams.
  • this method requires the source node to have strong computing capabilities, and cannot fully utilize the distributed computing capabilities of edge nodes, resulting in low slicing processing efficiency.
  • the present disclosure provides a data processing method, device, equipment and storage medium to solve the problem in the prior art that independent streaming media data slicing is performed at edge nodes or source station nodes, resulting in poor slicing processing effects and low efficiency.
  • a data processing method which is applied to a source station node and includes: obtaining the current frame data to be processed; parsing the frame data to be processed, and generating consistency description information corresponding to the frame data to be processed, Among them, the consistency description information is the description information used when slicing the frame data to be processed; the consistency description information and the corresponding frame data to be processed are distributed to at least one edge node in sequence.
  • obtaining current frame data to be processed includes: obtaining current frame data transmitted based on a message queue, where the message queue includes video frames and audio frames; determining that the current frame data is a video frame or audio frame, based on the current frame data, obtain the frame data to be processed; generate the consistency description information corresponding to the frame data to be processed, including: when the current frame data is a video frame, generate the frame data to be processed with a video identifier Corresponding consistency description information; when the current frame data is an audio frame, generate consistency description information with audio identifiers corresponding to the frame data to be processed.
  • obtaining the frame data to be processed based on the current frame data includes: when the current frame data is a video frame, using the current frame data as Frame data to be processed; when the current frame data is an audio frame, obtain N consecutive audio frames including the current frame data; use N audio frames as frame data to be processed, where N is an integer greater than 0.
  • obtaining N consecutive audio frames including the current frame data includes: when the current frame data is an audio frame, caching the current frame data; Acquire the current frame data transmitted based on the message queue again, and determine whether the current frame data obtained again is an audio frame; if not, use the cached audio frame as the frame data to be processed; if so, determine the current frame data obtained again and Is the total data length of the cached audio frames less than or equal to the preset maximum length of the packaged elementary stream? If so, cache the current frame data; if not, use the cached audio frames as frame data to be processed and clear the audio cache. Cache the current frame data after space.
  • the consistency description information and Distributing the corresponding frame data to be processed to at least one edge node includes: distributing the consistency description information as a video frame in the message queue to at least one edge node; distributing the video frame to at least one edge node based on the message queue; Alternatively, based on the message queue, N audio frames are distributed to at least one edge node in sequence.
  • the consistency description information is customized supplementary enhanced information
  • parsing the frame data to be processed and generating the consistency description information corresponding to the frame data to be processed includes: determining whether the frame data to be processed contains Supplementary enhancement information; if not, generate custom supplementary enhancement information for the frame data to be processed; if yes, after determining that the supplementary enhancement information is not custom supplementary enhancement information, generate custom supplementary enhancement information for the frame data to be processed.
  • the custom supplementary enhancement information includes a custom identifier, and the custom identifier is used to indicate that the consistency description information is generated according to the custom consistency protocol; before obtaining the frame data to be processed, It also includes: applying for identification cache space for custom identifiers, where the custom identifier cached in the identification cache space is extracted from the custom supplementary enhancement information corresponding to the frame data to be processed in the previous frame; determining the supplementary enhancement information It is not custom supplementary enhancement information, including: obtaining the custom identifier in the identity cache space; comparing the protocol identifier in the supplementary enhancement information with the custom identifier in the identity cache space, and when the comparison result indicates inconsistency , it is determined that the supplemental enhancement information is not custom supplemental enhancement information.
  • a data processing method which is applied to an edge node and includes: obtaining consistency description information transmitted by a source station node, and obtaining frame data to be processed corresponding to the consistency description information, wherein: consistency
  • the sexual description information is the description information used when slicing the frame data to be processed; according to the consistency description information, the frame data to be processed is sliced to generate at least one consistent transport stream fragment.
  • the consistency description information includes a video identifier or an audio identifier
  • the frame data to be processed is a video frame or an audio frame
  • slicing the frame data to be processed includes: when determining that the consistency description information includes a video identifier, updating the current video slice description information according to the consistency description information, so as to obtain the video frame of the next frame based on the current video slice description information. Perform slicing processing; when it is determined that the consistency description information includes the audio identifier, use the current audio slice description information to perform slicing processing on the audio frame in the preset data cache space, clear the data cache space, and perform slicing processing according to the consistency description information. Update the current audio slice description information.
  • obtaining the consistency description information transmitted by the source station node and obtaining the frame data to be processed corresponding to the consistency description information includes: obtaining the data frame transmitted by the source station node based on the message queue; When the data frame is an audio frame, the audio frame is stored in the data cache space, where the audio frame in the data cache space is the frame data to be processed corresponding to the current audio slice description information; when the data frame is a video frame, determine The video frame is the frame data to be processed corresponding to the current video slice description information, or the video frame is determined to be the consistency description information.
  • the consistency description information is custom supplementary enhancement information
  • determining the video frame as consistency description information includes: determining the video frame as supplementary enhancement information; determining the supplementary enhancement information as custom supplementary enhancement information.
  • a source station node device for data processing including: a source station acquisition module for acquiring the current frame data to be processed; an information generation module for parsing the frame to be processed data to generate consistency description information corresponding to the frame data to be processed, where the consistency description information is the description information used when slicing the frame data to be processed; the distribution module is used to sequentially transfer the consistency description information and the frame data to be processed, Distributed to at least one edge node.
  • an edge node device for data processing including: an edge acquisition module, used to acquire the consistency description information transmitted by the source station node, and to acquire the pending data corresponding to the consistency description information.
  • Processing frame data wherein the consistency description information is the description information used when slicing the frame data to be processed; the slicing processing module Block is used to slice the frame data to be processed according to the consistency description information and generate at least one consistent transport stream fragment.
  • an electronic device including a memory, a processor, and a computer program stored in the memory and executable on the processor.
  • the processor executes the program, any one of the above is implemented.
  • the data processing method in which the source node is the execution subject; or, when the processor executes the program, the data processing method in which the edge node is the execution subject is implemented as described in any of the above.
  • a non-transitory computer-readable storage medium is also provided, on which a computer program is stored.
  • the origin station node as described in any of the above is implemented.
  • the source station node and the edge node cooperate to complete the slicing process.
  • the source node obtains the frame data to be processed, it generates the consistency description information corresponding to the frame data to be processed.
  • the consistency description information is the description information used when slicing the frame data to be processed.
  • the edge node distributes the consistency description information and the corresponding frame data to be processed to at least one edge node in sequence.
  • the edge node obtains the one-time description information transmitted by the source node and the corresponding frame data to be processed, it slices the frame data to be processed according to the one-time description information to generate at least one consistent transmission stream fragment.
  • the source station node generates the consistency description information used when slicing the frame data to be processed, and then the edge node completes the slicing process based on the consistency description information. That is, the source station node generates consistency description information for each frame data that needs to be sliced. Processing frame data, preprocessing for slice consistency is performed to avoid differences in slice parameters caused by independent slicing of edge nodes, ensuring the playback effect of each consistent transport stream slice; at the same time, the actual slicing process of the frame data to be processed is It is completed at the edge node, making full use of the computing power of the edge node to improve slicing processing efficiency.
  • Figure 1 is a schematic diagram of a network architecture according to an embodiment of the present disclosure
  • Figure 2 is a schematic flowchart of a data processing method implemented through a source station node according to an embodiment of the present disclosure
  • Figure 3 is a schematic diagram of customized supplementary enhanced information data configuration according to an embodiment of the present disclosure
  • Figure 4 is a schematic diagram of the data configuration of the basic protocol data area according to an embodiment of the present disclosure
  • Figure 5 is a schematic diagram of the data configuration of the slice update extended data area according to an embodiment of the present disclosure
  • Figure 6 is an example diagram of video frame arrangement in the message queue according to an embodiment of the present disclosure.
  • Figure 7 is a schematic flowchart of a data processing method implemented through an edge node according to an embodiment of the present disclosure
  • Figure 8 is a schematic diagram of the processing flow when an edge node receives a data frame based on a message queue according to an embodiment of the present disclosure
  • Figure 9 is a schematic diagram of a data processing method implemented in a CDN network according to an embodiment of the present disclosure.
  • Figure 10 is a schematic structural diagram of a source station node device for data processing according to an embodiment of the present disclosure
  • FIG. 11 is a schematic structural diagram of an edge node device for data processing according to an embodiment of the present disclosure
  • Figure 12 is a schematic structural diagram of an electronic device according to an embodiment of the present disclosure.
  • CDN Content Delivery Network
  • RTMP Real Time Messaging Protocol
  • Hypertext Transfer Protocol-based adaptive bit rate streaming protocol (HTTP Live Streaming, HLS): a dynamic bit rate adaptive technology mainly used for audio and video services on servers and terminals.
  • Message queue A linked list of messages with a specific format and specific priority.
  • PES Packet Elementary Stream
  • ADTS Audio Data Transport Stream
  • ES Elementary Stream
  • Supplemental Enhancement Information It is a concept in the code stream category. It provides a way to add information to the audio and video code stream. It is one of the features of the H.264 video compression standard.
  • Transport Stream The audio and video encapsulation format specified by the HLS protocol.
  • the data processing method provided by this disclosure is mainly used in a network architecture similar to a content delivery network (Content Delivery Network, CDN).
  • the origin node and the edge node cooperate to implement slicing of the frame data to be processed.
  • the source node communicates with M edge nodes, where M is an integer greater than 0.
  • the source node receives the externally transmitted multimedia data stream, and then forwards the multimedia data stream to each edge node.
  • the origin node is any device with data processing capabilities, such as servers, computers, etc.
  • each edge node is any device with data processing capabilities, such as servers, laptops, or smartphones.
  • the device types implemented by each edge node can be the same or different.
  • the connection method between the source station node and each edge node can be either a wired connection or a wireless connection.
  • the following uses the origin station node as the execution subject to introduce the data processing method provided by this disclosure.
  • Step 201 Obtain the current frame data to be processed.
  • the source station node receives the externally transmitted multimedia data stream.
  • the origin node receives the pushed or pulled RTMP data stream.
  • RTMP data streams include different types of data such as video data, audio data and/or protocol control data.
  • the data that needs to be sliced during streaming media playback is video data and audio data.
  • HTTP Live Streaming, HLS adaptive bit rate streaming media transmission protocol
  • HTTP Hyper Text Transfer Protocol
  • the objects of slicing processing are video data and audio data.
  • the consistency protocol is preset according to the actual situation and needs.
  • the consistency protocol is used to instruct the source station node and the edge node to cooperate with each other to realize the communication based on the nodes at both ends. Consistent slicing processing. More specifically, the HLS protocol can be modified on demand based on the HLS protocol to obtain a consistency protocol that is ultimately applicable to both the source node and the edge node.
  • the consistency information encapsulation logic is preset at the source node. According to the consistency information encapsulation logic, the RTMP data stream is processed using the frame as the processing unit.
  • the consistency information encapsulation logic enables the source station node to consistently encapsulate video frames or audio frames based on the content of the consistency protocol, that is, generate corresponding consistency description information.
  • the RTMP data stream is transmitted based on message queue (MSG).
  • MSG message queue
  • the specific implementation process is as follows: obtain the current frame data transmitted based on the message queue, where the message queue includes video frames and audio frames; after determining that the current frame data is a video frame or an audio frame, Based on the current frame data, obtain the frame data to be processed; generate consistency description information corresponding to the frame data to be processed, including: when the current frame data is a video frame, generate a consistency description corresponding to the frame data to be processed with a video identifier Information; when the current frame data is an audio frame, generate consistency description information corresponding to the frame data to be processed with an audio identifier.
  • the source station node only generates consistency description information for video (Video) data or audio (Audio) data.
  • the source station node uses the frame data as the current frame data, and updates the current frame data.
  • the source node identifies the type of the received current frame data and only processes the video frames and audio frames that need to be fragmented to avoid wasting processing resources caused by invalid processing of other types of data.
  • the length of the video frame is greater than the length of the audio frame.
  • the frame data to be processed is obtained based on the current frame data.
  • the specific implementation process is as follows: when the current frame data is a video frame, the current frame data is used as the frame data to be processed; when the current frame data is a video frame, the frame data to be processed is obtained.
  • the frame data is an audio frame, obtain N consecutive audio frames including the current frame data; use N audio frames as frame data to be processed, where N is an integer greater than 0.
  • the current frame data is a video frame
  • the video frame is directly used as the frame data to be processed
  • N consecutive audio frames need to be used as data to be processed.
  • the value of N is determined according to the actual processing process. Specifically, when the current frame data is an audio frame, obtain N consecutive audio frames including the current frame data.
  • the specific implementation process is as follows: when the current frame data is an audio frame, cache the current frame data; obtain the message-based The current frame data transmitted in the queue is used to determine whether the current frame data obtained again is an audio frame; if not, the cached audio frame is used as the frame data to be processed; if so, the current frame data obtained again and the cached audio frame are judged. Is the total data length less than or equal to the preset maximum length of the packaged basic stream? If so, cache the current frame data; if not, use the cached audio frame as the frame data to be processed, clear the audio cache space and cache the current frame data. .
  • N audio frames are processed as large frame data.
  • PES Packet Elementary Stream
  • N consecutive audio frames are used as PES packets.
  • the frame data obtained in the previous frame is a non-audio frame such as video data or other types of data
  • the current frame data obtained is an audio frame
  • the audio frame is parsed, combined with the preset PES maximum length, to pre-generate PES
  • the ADTS Audio Data Transport Stream
  • ADTS refers to a data format of the Elementary Stream (ES).
  • the cached audio frame and the preset generated ADTS header data form a PES packet, and the PES packet is used as the data frame to be processed to generate corresponding consistency description information.
  • whether to generate new ADTS header data can be determined based on whether the amount of buffered audio frame data is zero. When the amount of cached audio frame data is not zero, only the currently received audio frame continues to be cached; when the amount of cached audio frame data is zero, that is, there is no cached audio frame, and when an audio frame is currently received, a new ADTS header data.
  • the audio frame data length is small, if continuous audio frames are obtained, the continuous audio frames are repackaged into at least one PES packet, and consistency description information corresponding to the PES packet is generated. This can avoid generating corresponding consistency description information for each audio frame, causing a waste of processing resources. At the same time, it can reduce the amount of data transmission between the source node and the edge node.
  • Step 202 Parse the frame data to be processed and generate consistency description information corresponding to the frame data to be processed, where the consistency description information is the description information used when slicing the frame data to be processed.
  • the frame data to be processed is parsed and corresponding consistency description information is generated.
  • the generated consistency description information includes the video identifier
  • the frame data to be processed is an audio frame
  • the generated consistency description information includes the audio identifier
  • the consistency description information is used when slicing the frame data to be processed.
  • the consistency description information includes the duration of each slice, the number of video frames, the number of audio frames, and the start of the video.
  • cc(continuity_counte) refers to the incrementing counter.
  • the consistency description information is customized supplementary enhancement information.
  • Custom supplemental enhancement information refers to supplemental enhancement information (Supplemental Enhancement Information, SEI) that sets specific configuration values as needed.
  • SEI Supplemental Enhancement Information
  • the description information used when slicing the frame data to be processed is added through SEI, so that the original streaming media data will not be affected by the new information.
  • the frame data to be processed is parsed and the consistency description information corresponding to the frame data to be processed is generated.
  • the specific implementation process is as follows: determine whether the frame data to be processed contains supplementary enhancement information; if not, generate a custom supplement of the frame data to be processed. Enhancement information; if so, after determining that the supplementary enhancement information is not custom supplementary enhancement information, generate custom supplementary enhancement information for the frame data to be processed.
  • the customized supplementary enhancement information is expressed as JDSEI.
  • the source node After receiving a burst of externally transmitted data (i.e., frame data to be processed), the source node will determine whether the frame data to be processed contains the SEI. If not, it will directly construct and generate the JDSEI corresponding to the frame data to be processed. If it is included, determine whether the SEI is a JDSEI. If so, it means that the frame data to be processed has been configured with description information for consistent slicing. There is no need to generate the JDSEI again and the frame data to be processed is forwarded directly; if not, This indicates that the SEI contained in the frame data to be processed is not JDSEI. The frame data to be processed does not have description information configured for consistency slicing, and the JDSEI corresponding to the frame data to be processed needs to be regenerated.
  • the custom supplementary enhancement information includes a custom identifier
  • the custom identifier is used to indicate that the consistency description information is generated according to the custom consistency protocol.
  • the custom identifier that identifies the cache in the cache space is extracted from the custom supplementary enhancement information corresponding to the frame data of the previous frame to be processed.
  • the implementation process is as follows: obtain the custom identifier in the identity cache space; compare the protocol identifier in the supplementary enhancement information with the custom identifier in the identity cache space. When the comparison results indicate inconsistencies, it is determined that the supplemental enhancement information is not custom supplementary enhancement information.
  • a dedicated cache space is applied for in advance to save the latest customized supplementary enhancement information.
  • the custom supplementary enhancement information is cached in the pre-applied identification cache space.
  • the frame data to be processed this time contains custom supplementary enhancement information, clear the logo cache space, and update the custom supplementary enhancement information contained in the frame data to be processed this time to the logo cache space; if this time If the frame data to be processed this time does not contain custom supplementary enhancement information, the logo cache space will be cleared, and the corresponding custom supplementary enhancement information in the frame data to be processed generated this time will be updated to the logo cache space. It is convenient to process the frame data to be processed obtained in the next frame.
  • the custom supplementary enhancement information (represented as JDSEI) sets specific configuration formats and parameters according to actual conditions and needs. For example, according to data size restrictions and configuration parameter requirements, the custom supplementary enhancement information is set as shown in Figure 3 to configure.
  • the description information in the custom supplementary enhanced information includes four parts, namely: FLV-HEAD, SEI-HEAD, Base-Data and Extended-Data.
  • the first part is FLV-HEAD: This part is the streaming media protocol (Flash Video, FLV) data header, which represents analog video packaging information.
  • This data header is 5-byte data information. Specifically, it is Video Data information based on the FLV protocol.
  • the second part is SEI-HEAD:
  • This part is SEI identifier information, this part contains 4+2 bytes.
  • the 1st to 4th bytes are filled with the length of the SEI information area;
  • the 5th byte stores 0x06, which means that this data frame is the SEI frame information of H.264, where H.264 represents a streaming media encoding and decoding rule;
  • the 6th byte Store 0x05, 0x05 means that this SEI information is customized information data.
  • 0x06 and 0x05 are hexadecimal-based numbers respectively.
  • Base-Data This part is the basic protocol data area, which is the data that needs to be transmitted in each SEI frame. The specific content is shown in Figure 4.
  • each grid represents a bit (1bit)
  • the first line is a bit identifier
  • 0 to 7 in the first line represent 8 bits
  • each 8 bits is a byte
  • one line is 4 byte.
  • 0x4A, 0x53, 0x45 and 0x49 are hexadecimal based numbers respectively.
  • 8bitTS represents the protocol version (version).
  • the storage format is, for example, when the version is version:1.0.0.1, the data stored in 8bitTS is: 10 00 00 01, that is: 0x81, among which 10 00 00 01 is binary. Number, 0x81 is a hexadecimal number.
  • the audio data is all 0.
  • m3u8 is the index file used when playing Transport Stream (TS) slices, and #EXT-X-DISCONTINUITY is used to describe that this slice is not continuous with the previous slice.
  • Occupies 1 bit representing the flexible use (active) item of the slice file. It has no practical use for the time being and can be used as reserved (reserved) in the future.
  • Occupies 4 bits represents the starting cc (continuity counter) of audio and video data encapsulated by TS slices, 0x00 ⁇ 0x0F loop.
  • the fourth part is Extended-Data: This part of the data is slice update extended data, which is only sent when the current slice needs to be closed and a new slice opened. It is enabled when the update slice item represented by 7 in Base-Data is 1, and records the relevant information of the slice. As shown in Figure 5, each grid represents a byte (1byte), the first line is a byte identifier, and 0 to 7 in the first line represent 8 bytes (byte). There are 32 bytes in the slice update extended data area, representing 4 types of information, respectively represented as 1 to 4 in the second line, as follows:
  • ID the ID number of the slice (Identity document, ID). This ID can be a sequentially increasing number, system time or slice timestamp, etc. with identification information.
  • EXT-X-MEDIA-SEQUENCE Occupying 4 bytes, the value of the slice and the event sequence identification value (sequence id) are used to update EXT-X-MEDIA-SEQUENCE to make m3u8 consistent. Among them, EXT-X-MEDIA-SEQUENCE is used to specify the starting sequence number of the slice.
  • the specific configuration content of the above-mentioned custom supplementary enhancement information is only an exemplary description.
  • the number of specifically configured bytes and the specific content stored in each byte can be set according to actual conditions and needs.
  • Step 203 Distribute the consistency description information and corresponding frame data to be processed to at least one edge node in sequence.
  • the consistency description information and the corresponding frame data to be processed are distributed to at least one edge node in sequence.
  • the consistency description information and the corresponding frame data to be processed are distributed to at least one edge node in sequence.
  • the specific implementation process is as follows: the consistency description information is used as a video frame in the message queue and distributed to at least one edge node. ;
  • the frame data to be processed is a video frame, the frame data to be processed is used as a video frame in the message queue and distributed to at least one edge node;
  • the frame data to be processed is an audio frame, the frame data to be processed is used as a video frame in the message queue of audio frames, distributed to at least one edge node.
  • the consistency description information is inserted into the message queue as a video frame for distribution.
  • the corresponding video frames are still distributed as video frames, and the corresponding audio frames are still distributed as audio frames.
  • the consistency description information is custom supplementary enhancement information (denoted as JDSEI)
  • the JDSEI is inserted into the message queue of the original streaming media data as a new video frame.
  • V1, V2, V3, V4...Vk respectively represent different video frames; A1, A2...Aj respectively represent different audio frames; JDSEI 1, JDSEI 2, JDSEI 3, JDSEI 4, JDSEI 5 , JDSEI 6...JDSEI n respectively represent different customized supplementary enhancement information.
  • V1 corresponds to JDSEI 1
  • V2 corresponds to JDSEI 2
  • V3 corresponds to JDSEI 3
  • A1 corresponds to JDSEI 4
  • V4 corresponds to JDSEI 5
  • A2 corresponds to JDSEI 6
  • Vk corresponds to JDSEI n
  • Aj corresponds to JDSEI (n+1).
  • each JDSEI, video frame and audio frame are sent based on the message queue.
  • n is an integer greater than
  • k is an integer greater than
  • j is an integer greater than 0.
  • edge node as the execution subject to introduce the data processing method provided by this disclosure.
  • Step 701 Obtain the consistency description information transmitted by the source node, and obtain the frame data to be processed corresponding to the consistency description information, where the consistency description information is the description information used when slicing the frame data to be processed.
  • each edge node receives the distributed consistency description information and the corresponding frame data to be processed respectively.
  • the edge node needs to set the consistency information parsing logic in advance. According to the consistency information parsing logic, the frame data to be processed is sliced based on the consistency description information.
  • the edge node when the source station node uses the consistency description information as a video frame, together with the video frame and audio frame of the streaming media data, and transmits them to each edge node based on the message queue, the edge node obtains the consistency description transmitted by the source station node. information, and obtain the frame data to be processed corresponding to the consistency description information.
  • the specific implementation process is as follows: obtain the data frame transmitted by the source station node based on the message queue; when the data frame is an audio frame, store the audio frame in the data cache space, where , the audio frame in the data cache space is the frame data to be processed corresponding to the current audio slice description information; when the data frame is a video frame, determine that the video frame is the frame data to be processed corresponding to the current video slice description information, or determine the video Frame is consistency description information.
  • the edge node after receiving the consistency description information, the edge node will parse the consistency description information. If it is determined after the analysis that the consistency description information is for audio data, the current audio slice description information will be updated to maintain the current audio slice.
  • the description information is the latest description information for audio data; if it is determined after parsing that the consistent description information is for video data, the current video slice description information is updated to keep the current video slice description information as The latest description information for video data.
  • the edge node receives data frames one by one based on the message queue. After receiving the data frame, the edge node first determines whether the data frame is an audio frame or a video frame. When the received data frame is an audio frame, the audio frame is the original streaming media data to be played, and the audio frame is first stored in Data cache space, and the audio frames in the data cache space are the frame data to be processed corresponding to the current audio slice description information.
  • the video frame is the consistency description information or the original streaming media data to be played. If it is determined that the video frame is the original streaming media data to be played, then the video frame is the video frame to be processed corresponding to the current video slice description information.
  • the edge node when the source node transmits consecutive N audio frames as PES packets, the edge node receives the consistency description information of the audio frame or first receives the audio frame with ADTS header data. At this time , store the ADTS header data and the audio frame into the data cache space, and then store the subsequent continuously received audio frames into the data cache space one by one until all N audio frames are stored. It is convenient for subsequent edge nodes to slice the corresponding PES packet according to the consistency description information.
  • Step 702 Slice the frame data to be processed according to the consistency description information to generate at least one consistent transport stream fragment.
  • the edge node slices the corresponding frame data to be processed according to the consistency description information, and generates at least one consistent transport stream (Transport Stream, TS) slice. These TS fragments can be played based on the HLS protocol. It should be noted that if the TS fragments are generated by the edge node and there are local playback conditions, the edge node can play the generated TS fragments locally; and/or the edge node can store the generated TS fragments in the local memory. , when other edge nodes or other types of clients request these TS fragments from the edge node that stores TS fragments, the edge node can transmit the local TS fragments to other edge nodes or clients.
  • TS Transport Stream
  • the consistency description information is for video data or audio data.
  • the consistency description information includes a video identifier or an audio identifier
  • the frame data to be processed is a video frame or an audio frame.
  • the frame data to be processed is sliced.
  • the specific implementation process is as follows: when it is determined that the consistency description information includes the video identifier, the current video slice description information is updated according to the consistency description information. , perform slicing processing on the video frame acquired in the next frame; when determining that the consistency description information includes the audio identifier, use the current audio slice description information to perform slicing processing on the audio frames in the preset data cache space, and then clear the data cache space. , and update the current audio slice description information according to the consistency description information.
  • the edge node when the source node configures corresponding consistency description information for each received video frame and configures corresponding consistency description information for consecutive N audio frames, the edge node needs to configure the corresponding consistency description information according to the video frame and audio frame. Different characteristics of transmission, slicing video frames or audio frames.
  • the consistency description information obtained by the edge node contains a video identifier
  • the consistency description information is parsed and the current video slice description information is updated.
  • the source node after the source node sends the consistency description information containing the video identifier, it will send the video frame corresponding to the consistency description information in the next frame. Therefore, the next frame received by the edge node will be the video frame corresponding to the current video slice description information. At this time, the corresponding video frame can be sliced through the current video slice description information.
  • the current audio slice description information is not updated temporarily. Because after the source node sends the consistency description information containing the audio identifier, it will send N consecutive audio frames corresponding to the consistency description information. Therefore, after the edge node receives the consistency description information containing the audio identifier, it means that the consecutive N audio frames have been transmitted and have been stored in the data cache space. Therefore, using the last updated current audio slice description information, the All audio frame slices in the data buffer space. After slicing is completed, use the consistency description information obtained this time to update the current Audio slice description information, and then the edge node continues to receive N consecutive audio frames corresponding to the updated current audio slice description information.
  • the video frame is determined to be the consistency description information.
  • the specific implementation process is as follows: the video frame is determined to be the supplementary enhancement information; the supplementary enhancement information is determined to be the custom supplementary enhancement information. .
  • a certain frame of data received by the source station node from the outside has its own SEI.
  • This SEI is not consistency description information, but contains other information describing the frame data. That is, the SEI is not customized in this disclosure.
  • Supplemental Enhancement Information (denoted as JDSEI).
  • JDSEI Supplemental Enhancement Information
  • the source node transmits data, in addition to transmitting the JDSEI corresponding to the frame data, it also transmits the original configured SEI, and then transmits the corresponding frame data.
  • the edge node will continuously receive JDSEI, original SEI and real frame data. In order to avoid parsing errors, after the edge node determines that it has received the SEI, it will determine whether the SEI is a JDSEI. If not, it will parse the original SEI to implement other corresponding functions; if it is, it will parse the JDSEI for subsequent slicing processing.
  • the conformance description information is custom supplementary enhancement information (denoted as JDSEI).
  • JDSEI custom supplementary enhancement information
  • Step 801 receive a new data frame
  • Step 802 Determine whether the data frame is an audio frame. If so, execute step 803. If not, execute step 804;
  • Step 803 store the audio frame into the data cache space, and execute step 801;
  • Step 804 Determine whether the video frame is JDSEI. If not, execute step 805. If yes, execute step 806;
  • Step 805 Slice the video frame according to the current video slice description information, where the current video slice description information is obtained from the previous frame and contains the video identifier. If the JDSEI is updated, perform step 801;
  • Step 806 Determine whether the JDSEI contains a video identifier. If so, execute step 807. If not, execute step 808;
  • Step 807 Parse the JDSEI containing the video identifier, update the current video slice description information, and execute step 801;
  • Step 808 determine that the JDSEI contains the audio identifier, and slice all audio frames in the data cache space according to the current audio slice description information, where the current audio slice description information is updated from the last obtained JDSEI containing the audio identifier. ;
  • Step 809 Clear the data cache space, parse the JDSEI containing the audio identifier obtained this time, update the current audio slice description information, and execute step 801.
  • the CDN network includes an origin node and three edge nodes (edge), and the three edge nodes are edge1, edge2, and edge3 respectively.
  • the origin node communicates with three edge nodes respectively.
  • the source node is configured with a consistency information encapsulation module, which is used to implement preset consistency information encapsulation logic.
  • Each edge node is equipped with a consistency information parsing module, which is used to implement the preset consistency information parsing logic.
  • the source node enables the consistency information encapsulation module to receive pushed or pulled RTMP data streams.
  • the consistency information encapsulation module Through the consistency information encapsulation module, each to-be-processed frame data included in the RTMP data stream is processed, and the corresponding custom supplementary enhancement information (identified as JDSEI) is generated.
  • the JDSEI is sent according to the frame division frequency and distributed to the recipient through the RTMP protocol. Every edge in the CDN network.
  • the edge node enables the consistency information encapsulation module to parse the RTMP data stream transmitted by the source node. Through the consistency information encapsulation module, the received JDSEI is parsed to complete the slicing of video data or audio data based on the HLS protocol and generate TS fragments.
  • the consistency information encapsulation module configured in each edge node is generated according to the consistency protocol, the parameters of the TS fragments generated by each edge node are consistent. Use Users can switch between edge1, edge2, and edge3 to obtain TS slices and play them normally.
  • the consistent slicing function is proposed.
  • the original RTMP data stream is consistently encapsulated, so that the TS fragments generated at the edge node all comply with the unified settings of the source node. is determined to ensure that the parameters of TS fragments are consistent.
  • the newly added JDSEI does not affect the normal playback of the original RTMP data stream, and the impact on the current stream bandwidth is minimized.
  • the generation of consistent TS sharding not only solves the problem of irregular slicing of edge nodes, but also can extend new terminal mechanisms such as multi-point buffering and P2P transparent transmission buffering. And the original mode of transparently transmitting source node slices to the edge can be abandoned to reduce intranet bandwidth.
  • the source station node and the edge node cooperate to complete the slicing process.
  • the source node obtains the frame data to be processed, it generates the consistency description information corresponding to the frame data to be processed.
  • the consistency description information is the description information used when slicing the frame data to be processed.
  • the edge node distributes the consistency description information and the corresponding frame data to be processed to at least one edge node in sequence.
  • the edge node obtains the one-time description information transmitted by the source node and the corresponding frame data to be processed, it slices the frame data to be processed according to the one-time description information to generate at least one consistent transmission stream fragment.
  • the source station node generates the consistency description information used when slicing the frame data to be processed, and then the edge node completes the slicing process based on the consistency description information. That is, the source station node generates consistency description information for each frame data that needs to be sliced. Processing frame data, preprocessing for slice consistency is performed to avoid differences in slice parameters caused by independent slicing of edge nodes, ensuring the playback effect of each consistent transport stream slice; at the same time, the actual slicing process of the frame data to be processed is It is completed at the edge node, making full use of the computing power of the edge node to improve slicing processing efficiency.
  • the source node device for data processing provided by the embodiment of the present disclosure is described below.
  • the source node device for data processing described below can interact with the data processing method described above with the source node as the execution subject.
  • Origin node devices used for data processing include:
  • the source station acquisition module 1001 is used to acquire the current frame data to be processed
  • the information generation module 1002 is used to parse the frame data to be processed and generate the consistency description information corresponding to the frame data to be processed, where the consistency description information is the description information used when slicing the frame data to be processed;
  • the distribution module 1003 is used to distribute the consistency description information and the frame data to be processed to at least one edge node in sequence.
  • the source station acquisition module 1001 is specifically used to acquire the current frame data transmitted based on the message queue, where the message queue includes video frames and audio frames; after determining that the current frame data is a video frame or an audio frame, based on the current Frame data, obtain the frame data to be processed;
  • the information generation module 1002 is specifically configured to generate consistency description information with a video identifier corresponding to the frame data to be processed when the current frame data is a video frame; when the current frame data is an audio frame, generate a message with an audio identifier. , the consistency description information corresponding to the frame data to be processed.
  • the source station acquisition module 1001 is specifically configured to use the current frame data as the frame data to be processed when the current frame data is a video frame; when the current frame data is an audio frame, obtain continuous frames including the current frame data. N audio frames; use N audio frames as frame data to be processed, where N is an integer greater than 0.
  • the distribution module 1003 is specifically configured to use the consistency description information as The video frames in the message queue are distributed to at least one edge node; based on the message queue, the video frames are distributed to at least one edge node; or, based on the message queue, N audio frames are distributed to at least one edge node in sequence.
  • the information generation module 1002 is specifically used to determine whether the frame data to be processed contains supplementary enhancement information; if not, generate customized supplementary enhancement information of the frame data to be processed; if so, determine that the supplementary enhancement information is not custom supplementary After the information is enhanced, customized supplementary enhancement information of the frame data to be processed is generated, where the consistency description information is the custom supplementary enhancement information.
  • the origin node device used for data processing also includes a space application module 1004, which is used to apply for the identification cache space of the custom identifier before obtaining the frame data to be processed, wherein the custom identifier cached in the identification cache space The identifier is extracted from the custom supplementary enhancement information corresponding to the frame data of the previous frame to be processed.
  • edge node device used for data processing provided by the embodiment of the present disclosure is described below.
  • the edge node device used for data processing described below can correspond to the data processing method described above with the edge node as the execution subject.
  • edge node devices used for data processing include:
  • the edge acquisition module 1101 is used to obtain the consistency description information transmitted by the source station node, and obtain the frame data to be processed corresponding to the consistency description information, where the consistency description information is the description information used when slicing the frame data to be processed;
  • the slicing processing module 1102 is configured to slice the frame data to be processed according to the consistency description information and generate at least one consistent transport stream fragment.
  • the slice processing module 1102 is specifically used to determine the consistency description information.
  • the current video slice description information is updated according to the consistency description information, so that the video frame obtained in the next frame is sliced according to the current video slice description information; when it is determined that the consistency description information includes an audio identifier, the current video slice description information is used.
  • Audio slice description information after slicing the audio frames in the preset data cache space, clear the data cache space, and update the current audio slice description information according to the consistency description information, where the consistency description information includes video identification or audio Identifies that the frame data to be processed is a video frame or audio frame.
  • the edge acquisition module 1101 is specifically used to acquire the data frame transmitted by the source node based on the message queue; when the data frame is an audio frame, the audio frame is stored in the data cache space, where the audio frame in the data cache space The frame is the frame data to be processed corresponding to the current audio slice description information; when the data frame is a video frame, it is determined that the video frame is the frame data to be processed corresponding to the current video slice description information, or the video frame is determined to be the consistency description information.
  • the edge acquisition module 1101 is specifically used to determine that the video frame is supplementary enhancement information; determine that the supplementary enhancement information is custom supplementary enhancement information, where the consistency description information is custom supplementary enhancement information.
  • a data processing method with the execution edge node as the execution subject includes: obtaining the consistency description information transmitted by the source station node, and obtaining the to-be-processed frame data corresponding to the consistency description information, where the consistency description information is to-be-processed Description information used when processing frame data for slicing; based on the consistency description information, the frame data to be processed is sliced to generate at least one consistent transport stream fragment.
  • the above-mentioned logical instructions in the memory 1203 can be implemented in the form of software functional units and can be stored in a computer-readable storage medium when sold or used as an independent product.
  • the technical solution of the embodiments of the present disclosure is essentially or contributes to the existing technology or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, It includes several instructions to cause a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in various embodiments of the present disclosure.
  • the aforementioned storage media include: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), magnetic disk or optical disk and other media that can store program code. .
  • the present disclosure also provides a computer program product.
  • the computer program product includes a computer program stored on a non-transitory computer-readable storage medium.
  • the computer program includes program instructions.
  • the program instructions When the program instructions are read by a computer, During execution, the computer can execute the data processing method provided by each of the above methods in which the source node is the execution subject.
  • the method includes: obtaining the current frame data to be processed; parsing the frame data to be processed, and generating the consistency corresponding to the frame data to be processed. Description information, where the consistency description information is the description information used when slicing the frame data to be processed; distribute the consistency description information and the corresponding frame data to be processed to at least one edge node in turn;
  • the present disclosure also provides a non-transitory computer-readable storage medium, on which a computer program is stored.
  • the data processing is performed by executing the above-mentioned source station nodes as the execution subject.
  • the method includes: obtaining the current frame data to be processed; parsing the frame data to be processed, and generating consistency description information corresponding to the frame data to be processed, where the consistency description information is the description information used when slicing the frame data to be processed. ; Distribute the consistency description information and corresponding frame data to be processed to at least one edge node in turn;
  • the computer program when executed by the processor, it implements a data processing method with the edge nodes provided above as the execution subject.
  • the method includes: obtaining the consistency description information transmitted by the source station node, and obtaining the consistency description information corresponding to The frame data to be processed, where the consistency description information is the description information used when slicing the frame data to be processed; according to the consistency description information, the frame data to be processed is sliced to generate at least one consistent transport stream fragment.
  • the device embodiments described above are only illustrative.
  • the units described as separate components may or may not be physically separated.
  • the components shown as units may or may not be physical units, that is, they may be located in One location, or it can be distributed across multiple network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment. Persons of ordinary skill in the art can understand and implement the method without any creative effort.

Landscapes

  • Engineering & Computer Science (AREA)
  • Signal Processing (AREA)
  • Multimedia (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)
  • Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)

Abstract

本公开涉及数据处理技术领域,尤其涉及一种数据处理方法、装置、设备及存储介质。以源站节点为执行主体时,方法包括:获取当前的待处理帧数据;解析所述待处理帧数据,生成所述待处理帧数据对应的一致性描述信息,其中,所述一致性描述信息为所述待处理帧数据进行切片时使用的描述信息;依次将所述一致性描述信息和对应的所述待处理帧数据,分发给至少一个边缘节点。本公开用以解决现有技术中在边缘节点或源站节点独立进行流媒体数据切片,导致切片处理效果差、效率低的问题。

Description

数据处理方法、装置、设备及存储介质
相关申请的交叉引用
本公开要求于2022年6月13日在中国知识产权局提交的申请号为No.202210667519.X,标题为“数据处理方法、装置、设备及存储介质”的中国专利申请的优先权,通过引用将该中国专利申请公开的全部内容并入本文。
技术领域
本公开涉及数据处理技术领域,尤其涉及一种数据处理方法、装置、设备及存储介质。
背景技术
在当前主流内容分发网络中,流媒体数据的播放,需要根据基于超文本传输协议的自适应码率流媒体传输协议完成切片处理。现有技术中,常用的切片方式有两种,一种是源站节点将数据发送给边缘节点后,由边缘节点进行切片。但是该方式下,不同的边缘节点因为配置参数不同等原因,导致生成的每个分片的时长等参数可能出现差别。因为差别的存在,可能导致在流媒体切换时,从不同边缘节点获取的流媒体数据播放不连续、重帧以及卡顿等播放事故出现,切片处理效果差。另一种是源站节点切片,边缘节点回源,从而为用户提供分片直播流。但是该方式下,需要源站节点具有强大的计算能力,且无法充分利用边缘节点的分布式计算能力,切片处理效率低。
发明内容
本公开提供一种数据处理方法、装置、设备及存储介质,用以解决现有技术中在边缘节点或源站节点独立进行流媒体数据切片,导致切片处理效果差、效率低的问题。
根据本公开的第一方面,提供了一种数据处理方法,应用于源站节点,包括:获取当前的待处理帧数据;解析待处理帧数据,生成待处理帧数据对应的一致性描述信息,其中,一致性描述信息为待处理帧数据进行切片时使用的描述信息;依次将一致性描述信息和对应的待处理帧数据,分发给至少一个边缘节点。
根据本公开提供的一种数据处理方法,获取当前的待处理帧数据,包括:获取基于消息队列传输的当前帧数据,其中,消息队列中包括视频帧和音频帧;确定当前帧数据为视频帧或音频帧后,基于当前帧数据,获取待处理帧数据;生成待处理帧数据对应的一致性描述信息,包括:当当前帧数据为视频帧时,生成带有视频标识的、待处理帧数据对应的一致性描述信息;当当前帧数据为音频帧时,生成带有音频标识的、待处理帧数据对应的一致性描述信息。
根据本公开提供的一种数据处理方法,确定当前帧数据为视频帧或音频帧后,基于当前帧数据,获取待处理帧数据,包括:当当前帧数据为视频帧时,将当前帧数据作为待处理帧数据;当当前帧数据为音频帧时,获取包括当前帧数据的、连续的N个音频帧;将N个音频帧作为待处理帧数据,其中,N为大于0的整数。
根据本公开提供的一种数据处理方法,当当前帧数据为音频帧时,获取包括当前帧数据的、连续的N个音频帧,包括:当当前帧数据为音频帧时,缓存当前帧数据;再次获取基于消息队列传输的当前帧数据,判断再次获取的当前帧数据是否为音频帧;若否,将已缓存的所述音频帧作为待处理帧数据;若是,判断再次获取的当前帧数据和已缓存的音频帧的总数据长度,是否小于或等于预设的打包基本码流最大长度,若是,缓存当前帧数据;若否,将已缓存的音频帧作为待处理帧数据,并清空音频缓存空间后缓存当前帧数据。
根据本公开提供的一种数据处理方法,依次将一致性描述信息和 对应的待处理帧数据,分发给至少一个边缘节点,包括:将一致性描述信息作为消息队列中的视频帧,分发给至少一个边缘节点;基于消息队列,将视频帧分发给至少一个边缘节点;或者,基于消息队列,将N个音频帧依次分发给至少一个所述边缘节点。
根据本公开提供的一种数据处理方法,一致性描述信息为自定义补充增强信息;解析待处理帧数据,生成待处理帧数据对应的一致性描述信息,包括:判断待处理帧数据中是否包含补充增强信息;若否,生成待处理帧数据的自定义补充增强信息;若是,确定补充增强信息不是自定义补充增强信息后,生成待处理帧数据的自定义补充增强信息。
根据本公开提供的一种数据处理方法,自定义补充增强信息包括自定义标识符,自定义标识符用于指示一致性描述信息是根据自定义一致性协议生成的;获取待处理帧数据之前,还包括:申请自定义标识符的标识缓存空间,其中,标识缓存空间中缓存的自定义标识符,是由上一帧待处理帧数据对应的自定义补充增强信息中提取的;确定补充增强信息不是自定义补充增强信息,包括:获取标识缓存空间中的自定义标识符;将补充增强信息中的协议标识符,与标识缓存空间中的所述自定义标识符进行比较,当比较结果指示不一致时,确定补充增强信息不是自定义补充增强信息。
根据本公开的第二方面,提供了一种数据处理方法,应用于边缘节点,包括:获取源站节点传输的一致性描述信息,以及获取一致性描述信息对应的待处理帧数据,其中,一致性描述信息为待处理帧数据进行切片时使用的描述信息;根据一致性描述信息,对待处理帧数据进行切片,生成至少一个一致性传输流分片。
根据本公开提供的一种数据处理方法,一致性描述信息包括视频标识或音频标识,待处理帧数据为视频帧或音频帧;根据所述一致性 描述信息,对待处理帧数据进行切片,包括:确定一致性描述信息包括视频标识时,根据一致性描述信息更新当前视频切片描述信息,以根据当前视频切片描述信息,对下一帧获取的视频帧进行切片处理;确定一致性描述信息包括音频标识时,采用当前音频切片描述信息,对预先设置的数据缓存空间内的所述音频帧进行切片处理后,清空数据缓存空间,并根据一致性描述信息更新当前音频切片描述信息。
根据本公开提供的一种数据处理方法,获取源站节点传输的一致性描述信息,以及获取一致性描述信息对应的待处理帧数据,包括:获取源站节点基于消息队列传输的数据帧;当数据帧为音频帧时,将音频帧存储至数据缓存空间,其中,数据缓存空间内的所述音频帧,为当前音频切片描述信息对应的待处理帧数据;当数据帧为视频帧时,确定视频帧为当前视频切片描述信息对应的待处理帧数据,或者,确定视频帧为一致性描述信息。
根据本公开提供的一种数据处理方法,一致性描述信息为自定义补充增强信息;确定视频帧为一致性描述信息,包括:确定视频帧为补充增强信息;确定补充增强信息为自定义补充增强信息。
根据本公开的第三方面,还提供了一种用于数据处理的源站节点装置,包括:源站获取模块,用于获取当前的待处理帧数据;信息生成模块,用于解析待处理帧数据,生成待处理帧数据对应的一致性描述信息,其中,一致性描述信息为待处理帧数据进行切片时使用的描述信息;分发模块,用于依次将一致性描述信息和待处理帧数据,分发给至少一个边缘节点。
根据本公开的第四方面,还提供了一种用于数据处理的边缘节点装置,包括:边缘获取模块,用于获取源站节点传输的一致性描述信息,以及获取一致性描述信息对应的待处理帧数据,其中,所述一致性描述信息为待处理帧数据进行切片时使用的描述信息;切片处理模 块,用于根据一致性描述信息,对待处理帧数据进行切片,生成至少一个一致性传输流分片。
根据本公开的第五方面,还提供了一种电子设备,包括存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,处理器执行程序时实现如上述任一种所述的源站节点为执行主体的数据处理方法;或者,处理器执行程序时实现如上述任一种所述的边缘节点为执行主体的数据处理方法。
根据本公开的第六方面,还提供了一种非暂态计算机可读存储介质,其上存储有计算机程序,该计算机程序被处理器执行时实现如上述任一种所述的源站节点为执行主体的数据处理方法;或者,该计算机程序被处理器执行时实现如上述任一种所述的边缘节点为执行主体的数据处理方法。
本公开提供的数据处理方法、装置、设备及存储介质,由源站节点和边缘节点配合完成切片的过程。源站节点获取待处理帧数据后,生成该待处理帧数据对应的一致性描述信息,该一致性描述信息则是用于待处理帧数据进行切片时使用的描述信息。然后边缘节点将一直性描述信息和对应的待处理帧数据,依次分发给至少一个边缘节点。而边缘节点获取到源站节点传输的一次性描述信息和对应的待处理帧数据后,根据一次性描述信息对待处理帧数据进行切片,生成至少一个一致性传输流分片。在上述过程中,由源站节点生成待处理帧数据进行切片时使用的一致性描述信息,然后由边缘节点基于该一致性描述信息完成切片过程,也就是由源站节点对各个需要切片的待处理帧数据,进行了切片一致性的预处理,避免了边缘节点独立切片造成的切片参数存在差别,保证了各个一致性传输流分片的播放效果;同时,待处理帧数据的实际切片过程则是在边缘节点完成的,充分利用了边缘节点的计算能力,提升切片处理效率。
附图说明
为了更清楚地说明本公开或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作一简单地介绍,显而易见地,下面描述中的附图是本公开的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1是根据本公开实施例的网络架构示意图;
图2是根据本公开实施例的通过源站节点实现数据处理方法的流程示意图;
图3是根据本公开实施例的自定义补充增强信息数据配置示意图;
图4是根据本公开实施例的基础协议数据区数据配置示意图;
图5是根据本公开实施例的切片更新扩展数据区数据配置示意图;
图6是根据本公开实施例的消息队列中视频帧排列示例图;
图7是根据本公开实施例的通过边缘节点实现数据处理方法的流程示意图;
图8是根据本公开实施例的边缘节点基于消息队列接收数据帧时的处理流程示意图;
图9是根据本公开实施例的CDN网络中实现数据处理方法的示意图;
图10是根据本公开实施例的用于数据处理的源站节点装置的结构示意图;
图11是根据本公开实施例的用于数据处理的边缘节点装置的结构示意图;
图12是根据本公开实施例的电子设备的结构示意图。
具体实施方式
为使本公开实施例的目的、技术方案和优点更加清楚,下面将结合本公开实施例中的附图,对本公开实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本公开实施例一部分实施例,而不是全部的实施例。基于本公开实施例中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本公开实施例保护的范围。
首先,对本公开提到的技术术语进行解释,具体如下:
内容分发网络(Content Delivery Network,CDN):建立并覆盖在承载网之上,由分布在不同区域的边缘节点服务器群组成的分布式网络。
基于实时消息传输协议(Real Time Messaging Protocol,RTMP):一种用来进行实时数据通信的网络协议,主要用来在支持RTMP协议的流媒体/交互服务器之间进行音视频和数据通信。
基于超文本传输协议的自适应码率流媒体传输协议(HTTP Live Streaming,HLS):一种动态码率自适应技术,主要用于服务器和终端的音视频服务。
消息队列(MSG):消息的链表,具有特定的格式以及特定的优先级。
打包基本码流(Packet Elementary Stream,PES):PES流是音视频数据流经过PES打包器处理后形成的数据流。
ADTS(Audio Data Transport Stream):ADTS指的是基本码流(Elementary Stream,ES)的一种数据格式。
补充增强信息(Supplemental Enhancement Information,SEI):是码流范畴里面的概念,提供了向音视频码流中加入信息的办法,是H.264视频压缩标准的特性之一。
传输流(Transport Stream,TS):HLS协议规定的音视频封装格式。
本公开提供的数据处理方法,主要应用于类似于内容分发网络(Content Delivery Network,CDN)的网络架构中,由源站节点和边缘节点配合实现待处理帧数据的切片。具体的,如图1所示,源站节点与M个边缘节点通信连接,M为大于0的整数。源站节点接收外部传输的多媒体数据流,然后将多媒体数据流转发给各个边缘节点。需要说明的是,源站节点为具有数据处理能力的任意一种设备,例如,服务器、计算机等;每个边缘节点为具有数据处理能力的任意一种设备,例如,服务器、笔记本电脑或智能手机等,各个边缘节点实现的设备类型可以是一样的,也可以是不一样的。源站节点与各个边缘节点的连接方式既可以是有线连接,也可以是无线连接。
下面以源站节点为执行主体,介绍本公开提供的数据处理方法。
在实施例中,如图2所示,通过源站节点实现数据处理方法的流程步骤如下:
步骤201,获取当前的待处理帧数据。
本实施例中,源站节点接收外部传输的多媒体数据流。具体的,当多媒体数据流的传输基于实时消息传输协议(Real Time Messaging Protocol,RTMP)时,源站节点接收推送或拉取的RTMP数据流。RTMP数据流包括视频数据、音频数据和/或协议控制数据等不同类型的数据。而流媒体播放时需要进行切片处理的数据是视频数据和音频数据,例如,在基于超文本传输协议(Hyper Text Transfer Protocol,HTTP)的自适应码率流媒体传输协议(HTTP Live Streaming,HLS)下完成切片时,则切片处理的对象为视频数据和音频数据。
本实施例中,根据实际情况和需要预先设定一致性协议,该一致性协议用于指示源站节点和边缘节点相互配合,实现基于两端节点的 一致性切片处理。更具体的,可以在HLS协议的基础上,对HLS协议进行需求化修改,以得到最终适用于源站节点和边缘节点两端的一致性协议。基于一致性协议,在源站节点预先设置一致性信息封装逻辑,按照该一致性信息封装逻辑,以帧为处理单元,对RTMP数据流进行处理。该一致性信息封装逻辑使源站节点能够基于一致性协议的内容,对视频帧或音频帧进行一致性封装,即生成对应的一致性描述信息。
在实施例中,RTMP数据流是基于消息队列(MSG)进行传输的。具体的,获取当前的待处理帧数据,具体实现过程如下:获取基于消息队列传输的当前帧数据,其中,消息队列中包括视频帧和音频帧;确定当前帧数据为视频帧或音频帧后,基于当前帧数据,获取待处理帧数据;生成待处理帧数据对应的一致性描述信息,包括:当当前帧数据为视频帧时,生成带有视频标识的、待处理帧数据对应的一致性描述信息;当当前帧数据为音频帧时,生成带有音频标识的、待处理帧数据对应的一致性描述信息。
本实施例中,源站节点只针对视频(Video)数据或音频(Audio)数据生成一致性描述信息,当源站节点实时接收到一帧数据后,将该帧数据作为当前帧数据,对当前帧数据进行解析,即可确定当前帧帧数据是否为视频帧或音频帧。若当前帧数据不是视频帧或音频帧,则舍弃该当前数据帧,不进行一致性处理,继续接收下一帧数据,作为当前帧数据进行处理。若当前帧数据为视频帧时,对应生成的一致性描述信息中则包含视频标识;若当前帧数据为音频帧时,对应生成的一致性描述信息中则包含音频标识。
本实施例中,源站节点通过对接收的当前帧数据进行类型识别,只针对需要分片的视频帧和音频帧进行处理,避免对其他类型数据进行无效处理导致的处理资源浪费。
在实施例中,由于视频帧和音频帧的数据长度是不一样的,视频帧的长度大于音频帧的长度。则确定当前帧数据为视频帧或音频帧后,基于当前帧数据,获取待处理帧数据,具体实现过程如下:当当前帧数据为视频帧时,将当前帧数据作为待处理帧数据;当当前帧数据为音频帧时,获取包括当前帧数据的、连续的N个音频帧;将N个音频帧作为待处理帧数据,其中,N为大于0的整数。
本实施例中,若当前帧数据为视频帧,则直接将该视频帧作为待处理帧数据;若当前帧数据为音频帧,则需要将连续的N个音频帧作为待处理数据。
在实施例中,N的取值根据实际处理过程而定。具体的,当当前帧数据为音频帧时,获取包括当前帧数据的、连续的N帧音频帧,实现的具体过程如下:当当前帧数据为音频帧时,缓存当前帧数据;再次获取基于消息队列传输的当前帧数据,判断再次获取的当前帧数据是否为音频帧;若否,将已缓存的音频帧作为待处理帧数据;若是,判断再次获取的当前帧数据和已缓存的音频帧的总数据长度,是否小于或等于预设的打包基本码流最大长度,若是,缓存当前帧数据;若否,将已缓存的音频帧作为待处理帧数据,并清空音频缓存空间后缓存当前帧数据。
本实施例中,由于音频帧的数据长度小于视频帧的数据长度,若连续获取多个音频帧,则将N个音频帧作为大的帧数据来处理。具体的,根据预设的打包基本码流(Packet Elementary Stream,PES)最大长度,将连续的N个音频帧作为PES包。当上一帧获取到的帧数据为视频数据或其他类型数据等非音频帧时,且当下获得的当前帧数据为音频帧,则解析该音频帧,结合预设的PES最大长度,预生成PES包对应的ADTS(Audio Data Transport Stream)头数据,其中,ADTS指的是基本码流(Elementary Stream,ES)的一种数据格式。 将当前的音频帧缓存,继续接收后续的音频帧,直至再次获取的当前帧数据不再是音频帧,或者,直至再次获取的音频帧和已缓存的音频帧的总数据长度,超过预设的PES最大长度。已缓存的音频帧与预设生成的ADTS头数据形成PES包,将该PES包作为待处理数据帧,生成对应的一致性描述信息。
生成PES包后,清除已缓存的音频帧。当再次获取的当前帧数据仍然是音频帧时,重复预生成ADTS头数据,生成PES包的过程,直至新接收的当前帧数据不再是音频帧。
本实施例中,是否生成新的ADTS头数据,可以根据已缓存的音频帧数据量是否为零来确定。当已缓存的音频帧数据量不为零时,只继续缓存当前接收的音频帧;当已缓存的音频帧数据量为零,即没有缓存的音频帧,且当前接收了音频帧时,生成新的ADTS头数据。
本实施例中,由于音频帧数据长度较小,则若获取连续的音频帧,则将连续的音频帧重新打包成至少一个PES包,生成该PES包对应的一致性描述信息。由此可以避免每一个音频帧均生成对应的一致性描述信息,造成处理资源浪费的问题,同时,减少源站节点和边缘节点之间的数据传输量。
步骤202,解析待处理帧数据,生成待处理帧数据对应的一致性描述信息,其中,一致性描述信息为待处理帧数据进行切片时使用的描述信息。
本实施例中,获取待处理帧数据后,解析待处理帧数据,生成对应的一致性描述信息。具体的,当待处理帧数据为视频帧时,生成的一致性描述信息中包含视频标识;当待处理帧数据为音频帧时,生成的一致性描述信息中包含音频标识。
一致性描述信息在待处理帧数据进行切片时使用,具体的,一致性描述信息包括每个切片的时长、视频帧数、音频帧数、视频起始 cc、音频起始cc、更精确到某帧的90K时间戳以及其他描述信息中的一种或几种。其中,cc(continuity_counte)指的是递增计数器。
在实施例中,一致性描述信息为自定义补充增强信息。自定义补充增强信息指的是根据需要设置具体配置值的补充增强信息(Supplemental Enhancement Information,SEI)。通过SEI添加待处理帧数据进行切片时使用的描述信息,使原有流媒体数据不会收到新增信息的影响。具体的,解析待处理帧数据,生成待处理帧数据对应的一致性描述信息,具体实现过程如下:判断待处理帧数据中是否包含补充增强信息;若否,生成待处理帧数据的自定义补充增强信息;若是,确定补充增强信息不是自定义补充增强信息后,生成待处理帧数据的自定义补充增强信息。
本实施例中,将自定义补充增强信息表示为JDSEI。源站节点接收外部传输的一阵数据(即待处理帧数据)后,会判断该待处理帧数据是否包含SEI,若不包含,则直接构造生成该待处理帧数据对应的JDSEI。若包含,则判断该SEI是否为JDSEI,若是,则表明该待处理帧数据已经配置了进行一致性切片使用的描述信息,不需要再次生成该JDSEI,直接转发该待处理帧数据;若否,则表明该待处理帧数据中包含的SEI不是JDSEI,该待处理帧数据中没有配置进行一致性切片使用的描述信息,需要重新生成该待处理帧数据对应的JDSEI。
本实施例中,通过确定待处理帧数据中是否已经配置了自定义补充增强信息,当待处理帧数据中已经包含自定义补充增强信息时,则不需要再重复生成自定义补充增强信息,避免数据重复和处理资源浪费。
在实施例中,自定义补充增强信息包括自定义标识符,自定义标识符用于指示一致性描述信息是根据自定义一致性协议生成的。具体的,在获取待处理帧数据之前,申请自定义标识符的标识缓存空间, 其中,标识缓存空间中缓存的自定义标识符,是由上一帧待处理帧数据对应的自定义补充增强信息中提取的。确定补充增强信息不是自定义补充增强信息,实现过程如下:获取标识缓存空间中的自定义标识符;将补充增强信息中的协议标识符,与标识缓存空间中的自定义标识符进行比较,当比较结果指示不一致时,确定补充增强信息不是自定义补充增强信息。
本实施例中,预先申请专用的缓存空间,用于保存最新的自定义补充增强信息。当对上一帧的待处理帧数据进行处理时,确定或生成上一帧待处理帧数据的自定义补充增强信息后,将自定义补充增强信息缓存至预先申请的标识缓存空间中。在对本次获取的待处理帧数据进行处理时,通过标识缓存空间中存储的自定义补充增强信息,来确定待处理帧数据中包含的补充增强信息是否为自定义补充增强信息。若本次获取的待处理帧数据中包含的是自定义补充增强信息,则清空标识缓存空间,将本次获取的待处理帧数据中包含的自定义补充增强信息更新至标识缓存空间;若本次获取的待处理帧数据中不包含自定义补充增强信息,则清空标识缓存空间,将本次生成的待处理帧数据中对应的自定义补充增强信息更新至标识缓存空间。便于对下一帧获取的待处理帧数据进行处理。
在实施例中,自定义补充增强信息(表示为JDSEI)根据实际情况和需要设定具体配置格式和参数,例如,根据数据大小的限制和配置参数需求,将自定义补充增强信息按照图3所示进行配置。
具体的,自定义补充增强信息中的描述信息包含四部分,分别为:FLV-HEAD、SEI-HEAD、Base-Data和Extended-Data。
第一部分为FLV-HEAD:此部分为流媒体协议(Flash Video,FLV)数据头,表示模拟视频封装信息。此数据头为5字节数据信息,具体的,为基于FLV协议下的Video Data信息。
第二部分为SEI-HEAD:此部分为SEI标识符信息,此部分包含4+2字节。第1~4字节填充SEI信息区长度;第5字节存储0x06,代表此数据帧为H.264的SEI帧信息,其中,H.264表示一种流媒体编解码规则;第6字节存储0x05,0x05代表此SEI信息为自定义信息数据。其中,0x06和0x05分别是基于十六进制的数字。
第三部分为Base-Data:此部分为基础协议数据区,作为每个SEI帧需要传输的数据,具体内容如图4所示。
图4中,每格代表一个比特(1bit),第一行为位标识符,第一行中的0~7代表8比特(bit),每8个bit为一个字节(byte),一行为4个byte。在该基础协议数据区共有18个字节,代表了15类信息,分别表示为第二行至第五行中的1~15,具体如下:
1:占8bit,代表协议长度,即自定义SEI数据中载荷大小(payload size)信息。若自定义的一致性协议长度低于255bit,则占用1字节或2字节即可满足协议需求。
2:占4字节,32biTS,代表协议标识符(即上述实施例中的自定义标识符),用于标识为自定义协议信息,即通用唯一识别码(Universally Unique Identifier,UUID)。可选的,4字节存储的数据为:0x4A,0x53,0x45和0x49(代表该数据帧为JDSEI)。SEI自定义数据要求UUID需要16byte,为了降低数据量,此处仅使用4byte作为区分,其余15byte替换为有效的数据区(可能不足15bytes)。0x4A,0x53,0x45和0x49分别是基于十六进制的数字。
3:占8biTS,代表协议版本(version),存储格式例如,当版本为version:1.0.0.1时,则8biTS存储的数据为:10 00 00 01,即:0x81,其中,10 00 00 01为二进制数字,0x81为十六进制数字。
4:占2bit,代表协议标识的数据类型,音频类型和视频类型,0代表视频,1代表音频。由于切片是针对视频数据和音频数据的,在 自定义的一致性协议下暂时不存在第三种类型。
5:占1bit,代表是否为关键帧(I帧),0代表非关键帧,1代表关键帧。其中音频数据全为0。
6:占1bit,代表本帧显示时间戳(Presentation Time Stamp,PTS)和解码时间戳(Decoding Time StampdTS,DTS)是否相同,0代表相同,1代表不同。其中音频数据全为0。
7:占1bit,代表是否更新切片,0代表不更新切片,1代表更新切片。当为1时,会启用后续的扩展数据区,即Extended-Data区。
8:占1bit,代表此切片是否与上一个切片连续,若不连续,则需要在生成的m3u8中添加#EXT-X-DISCONTINUITY,代表不连续。其中,m3u8为播放传输流(Transport Stream,TS)分片时使用的索引文件,#EXT-X-DISCONTINUITY用于描述此切片与上一个切片不连续。
9:占1bit,代表切片文件的灵活使用(active)项,暂时无实际用途,可后续作为预留(reserved)使用。
10:占1bit,代表切片文件是否开启以高级加密标准(Advanced Encryption Standard,AES)进行加密,开启后,关键密钥(key_frags)和开放式安全套接层协议(Open Secure SockeTS Layer,openssl)基于随机密钥(key)才生效。
11:占4bit,代表TS切片封装的音视频数据的起始cc(continuity counter),0x00~0x0F循环。
12:占4bit,代表TS切片封装节目关联表(Program Association Table,PAT)和节目映射表(Program Map Table,PMT)的起始cc,此cc在切片头添加,在视频I帧前添加,纯音频数据则仅有切片头添加。具体数值在0x00~0x0F循环,0x00~0x0F为十六进制数字。
13:占8bit,1个字节,预留(reserved)字段,协议更新时使用。
14:占5byte,代表此帧数据的90K时间戳,若数据类型=0,即视频,则代表紧随此JDSEI帧之后的第一视频帧所处的90K时间戳。若数据类型=1,即音频,依旧代表紧随此JDSEI帧之后的第一音频帧所处的90K时间戳。
15:占4byte,代表90K的PTS与DTS差值,此值在6不为0,即PTS与DTS不相同的情况下存在。
第四部分为Extended-Data:此部分数据为切片更新扩展数据,仅当需要关闭当前切片,开启新切片时发送。在Base-Data中7所代表的更新切片项为1时启用,记录了切片的相关信息。如图5所示,每格代表一个字节(1byte),第一行为字节标识符,第一行中的0~7代表8字节(byte)。在该切片更新扩展数据区共有32个字节,代表了4类信息,分别表示为第二行中的1~4,具体如下:
1:占8bytes,切片的所属身份证标识号(Identity document,ID),此ID可以为顺序递增数字、***时间或切片时间戳等具有标识信息的内容。
2:占4bytes,切片所属的计值和事件序列标识值(sequence id),用于更新EXT-X-MEDIA-SEQUENCE使用,使m3u8能一致。其中,EXT-X-MEDIA-SEQUENCE用于指定切片开始的序号。
3:占4bytes,切片所属key_frags,此项在BaseData的10位置为1,即开启AES加密时使用,代表有多少个切片使用同一个加密key,当此项为0时,表示采用当前的最新key。
4:占16bytes,AES所使用的openssl生成的16字节伪随机key,用于对文件加密使用,在BaseData的10位置为1时存在。
本实施例中,上述自定义补充增强信息的具体配置内容,仅是一个示例性说明,具体配置的字节数量和每个字节存储的具体内容,可以根据实际情况和需要设定。
步骤203,依次将一致性描述信息和对应的待处理帧数据,分发给至少一个边缘节点。
本实施例中,生成一致性描述信息后,将一致性描述信息和对应的待处理帧数据,依次分发给至少一个边缘节点。
在实施例中,依次将一致性描述信息和对应的待处理帧数据,分发给至少一个边缘节点,具体实现过程如下:将一致性描述信息作为消息队列中的视频帧,分发给至少一个边缘节点;当待处理帧数据为视频帧时,将待处理帧数据作为消息队列中的视频帧,分发给至少一个边缘节点;当待处理帧数据为音频帧时,将待处理帧数据作为消息队列中的音频帧,分发给至少一个边缘节点。
本实施例中,不论一致性描述信息是针对视频帧还是音频帧的,均将一致性描述信息作为视频帧***消息队列中进行分发。而对应的视频帧仍旧以视频帧分发,对应的音频帧仍旧以音频帧分发。由此,可以保证一致性描述信息的顺利分发,尤其是在HLS协议等约束下,保证一致性描述信息能够成功传输给边缘节点。
在实施例中,当一致性描述信息为自定义补充增强信息(表示为JDSEI)时,将JDSEI作为新的视频帧***原始流媒体数据的消息队列中。
如图6所示,V1、V2、V3、V4……Vk分别表示不同的视频帧;A1、A2……Aj分别表示不同的音频帧;JDSEI 1、JDSEI 2、JDSEI 3、JDSEI 4、JDSEI 5、JDSEI 6……JDSEI n分别表示不同的自定义补充增强信息。V1对应JDSEI 1,V2对应JDSEI 2,V3对应JDSEI 3,A1对应JDSEI 4,V4对应JDSEI 5,A2对应JDSEI 6,Vk对应JDSEI n,Aj对应JDSEI(n+1)。按照图6中的顺序,基于消息队列发送各个JDSEI、视频帧和音频帧。其中,n为大于0的整数,k为大于0的整数,j为大于0的整数。
下面以边缘节点为执行主体,介绍本公开提供的数据处理方法。
在实施例中,如图7所示,通过边缘节点实现数据处理方法的流程步骤如下:
步骤701,获取源站节点传输的一致性描述信息,以及获取一致性描述信息对应的待处理帧数据,其中,一致性描述信息为待处理帧数据进行切片时使用的描述信息。
本实施例中,源站节点将一致性描述信息和对应的待处理帧数据分发给至少一个边缘节点之后,各个边缘节点分别接收分发的一致性描述信息和对应的待处理帧数据。若要根据一致性描述信息对待处理帧数据进行切片,边缘节点需要预先设置一致性信息解析逻辑,按照该一致性信息解析逻辑,基于一致性描述信息对待处理帧数据进行切片。
在实施例中,源站节点将一致性描述信息作为视频帧,与流媒体数据的视频帧和音频帧,共同基于消息队列传输给各个边缘节点时,边缘节点获取源站节点传输的一致性描述信息,以及获取一致性描述信息对应的待处理帧数据,具体实现过程如下:获取源站节点基于消息队列传输的数据帧;当数据帧为音频帧时,将音频帧存储至数据缓存空间,其中,数据缓存空间内的音频帧,为当前音频切片描述信息对应的待处理帧数据;当数据帧为视频帧时,确定视频帧为当前视频切片描述信息对应的待处理帧数据,或者,确定视频帧为一致性描述信息。
本实施例中,边缘节点接收到一致性描述信息后,会解析该一致性描述信息,若解析后确定一致性描述信息是针对音频数据的,则更新当前音频切片描述信息,以保持当前音频切片描述信息为针对音频数据最新的描述信息;若解析后确定一致性描述信息是针对视频数据的,则更新当前视频切片描述信息,以保持当前视频切片描述信息为 针对视频数据最新的描述信息。
本实施例中,边缘节点基于消息队列逐个接收数据帧。接收到数据帧后,边缘节点首先判断该数据帧是音频帧还是视频帧,当接收的数据帧是音频帧时,则该音频帧为待播放的原始流媒体数据,先将该音频帧存储至数据缓存空间,而数据缓存空间内的音频帧,为当前音频切片描述信息对应的待处理帧数据。
当接收的数据帧是视频帧时,由于源站节点将一致性描述信息作为视频帧传输,则该视频帧是一致性描述信息或待播放的原始流媒体数据。若确定该视频帧为待播放的原始流媒体数据,则该视频帧为当前视频切片描述信息对应的待处理帧视频。
在实施例中,当源站节点将连续的N个音频帧作为PES包进行传输时,边缘节点在接收音频帧的一致性描述信息后,或首先接收带有ADTS头数据的音频帧,此时,将ADTS头数据与该音频帧存储至数据缓存空间中,然后再将后续连续接收的音频帧逐个存储至数据缓存空间,直至N个音频帧全部存储完毕。便于后续边缘节点根据一致性描述信息,将对应的PES包切片。
步骤702,根据一致性描述信息,对待处理帧数据进行切片,生成至少一个一致性传输流分片。
本实施中,边缘节点根据一致性描述信息,将对应的待处理帧数据切片,生成至少一个一致性传输流(Transport Stream,TS)分片。这些TS分片可以基于HLS协议进行播放。需要说明的是,TS分片生成的,边缘节点本地若存在播放条件,则边缘节点可以在本地播放生成的TS分片;和/或,边缘节点可以将生成的TS分片存储在本地存储器中,当其他边缘节点或者其他类型的客户端,向存储有TS分片的边缘节点请求这些TS分片时,该边缘节点可以将本地的TS分片传输给其他边缘节点或客户端。
在实施例中,一致性描述信息是针对视频数据或音频数据的。具体的,一致性描述信息包括视频标识或音频标识,待处理帧数据为视频帧或音频帧。基于上述,根据一致性描述信息,对待处理帧数据进行切片,具体实现过程如下:确定一致性描述信息包括视频标识时,根据一致性描述信息更新当前视频切片描述信息,以根据当前视频切片描述信息,对下一帧获取的视频帧进行切片处理;确定一致性描述信息包括音频标识时,采用当前音频切片描述信息,对预先设置的数据缓存空间内的音频帧进行切片处理后,清空数据缓存空间,并根据一致性描述信息更新当前音频切片描述信息。
本实施例中,当源站节点为接收的每一个视频帧配置对应的一致性描述信息,而为连续的N个音频帧配置对应的一致性描述信息时,边缘节点要根据视频帧和音频帧传输的不同特点,对视频帧或音频帧进行切片。
具体的,当边缘节点获得的一致性描述信息包含视频标识时,解析该一致性描述信息,更新当前视频切片描述信息。根据源站节点数据传输方式,源站节点发送包含视频标识的一致性描述信息后,会在下一帧发送该一致性描述信息对应的视频帧。所以边缘节点下一帧接收的会是当前视频切片描述信息对应的视频帧。此时,即可通过当前视频切片描述信息将对应的视频帧切片。
当边缘节点获得的一致性描述信息包含音频标识时,暂时不更新当前音频切片描述信息。因为源站节点在发送包含音频标识的一致性描述信息后,会发送该一致性描述信息对应的连续的N个音频帧。所以边缘节点接收包含音频标识的一致性描述信息后,表示连续的N个音频帧已经传输完毕,并均已存储于数据缓存空间中了,所以,使用上一次更新的当前音频切片描述信息,将数据缓存空间中的所有音频帧切片。切片完成后,再使用本次获得的一致性描述信息更新当前 音频切片描述信息,然后边缘节点继续接收更新后的当前音频切片描述信息对应的连续N个音频帧。
在实施例中,当一致性描述信息为自定义补充增强信息时,确定视频帧为一致性描述信息,具体实现过程如下:确定视频帧为补充增强信息;确定补充增强信息为自定义补充增强信息。
本实施例中,源站节点从外部接收的某一帧数据,自带有SEI,该SEI不是一致性描述信息,而是包含描述该帧数据其他信息的,即该SEI不是本公开中自定义补充增强信息(表示为JDSEI)。当源站节点在传输数据时,除了传输该帧数据对应的JDSEI,还会将原始配置的SEI传输,然后再传输对应的帧数据。相对应的,边缘节点会连续接收JDSEI、原始SEI和真实的帧数据。为了避免解析错误,边缘节点确定接收到SEI后,会判断该SEI是否为JDSEI,若否,则解析该原始SEI,实现相应的其他功能;若是,则解析该JDSEI,用于后续的切片处理。
在实施例中,一致性描述信息为自定义补充增强信息(表示为JDSEI)。当源站节点将一致性描述信息作为视频帧,与流媒体数据的视频帧和音频帧,共同基于消息队列传输给各个边缘节点时,如图8所示,边缘节点基于消息队列接收数据帧时的处理过程如下:
步骤801,接收新的数据帧;
步骤802,判断数据帧是否为音频帧,若是,执行步骤803,若否,执行步骤804;
步骤803,将音频帧存储至数据缓存空间,执行步骤801;
步骤804,判断视频帧是否为JDSEI,若否,执行步骤805,若是,执行步骤806;
步骤805,根据当前视频切片描述信息,对该视频帧进行切片,其中,当前视频切片描述信息是由上一帧得到的包含视频标识的 JDSEI更新得到的,执行步骤801;
步骤806,判断JDSEI中是否包含视频标识,若是,执行步骤807,若否,执行步骤808;
步骤807,解析包含视频标识的JDSEI,更新当前视频切片描述信息,执行步骤801;
步骤808,确定JDSEI中包含音频标识,根据当前音频切片描述信息,对数据缓存空间中的所有音频帧进行切片,其中,当前音频切片描述信息是由上一次得到的包含音频标识的JDSEI更新得到的;
步骤809,清空数据缓存空间,并解析本次获得的包含音频标识的JDSEI,更新当前音频切片描述信息,执行步骤801。
在实施例中,如图9所示,在CDN网络中,包括源站节点和三个边缘节点(edge),三个边缘节点分别为edge1、edge2和edge3。源站节点分别与三个边缘节点通信连接。源站节点配置有一致性信息封装模块,用于实现预先设置的一致性信息封装逻辑。每个边缘节点分别设置有一致性信息解析模块,用于实现预先设置的一致性信息解析逻辑。
具体的,源站节点启用一致性信息封装模块,接收推送或拉取的RTMP数据流。通过一致性信息封装模块,将RTMP数据流包括的每一个待处理帧数据进行处理,生成对应的自定义补充增强信息(标识为JDSEI),按照帧分割频率进行JDSEI的发送,通过RTMP协议分发给CDN网络中的每一个edge。
边缘节点启用一致性信息封装模块,解析源站节点传输的RTMP数据流。通过一致性信息封装模块,解析收到的JDSEI,以基于HLS协议完成对视频数据或音频数据的切片,生成TS分片。
由于各个边缘节点中配置的一致性信息封装模块,均是根据一致性协议生成的,所以各个边缘节点生成的TS分片的参数均一致,用 户可在edge1、edge2、edge3随意切换获取TS分片,并正常播放。
本实施例中,一致性切片功能被提出,在源站节点唯一的情况下,原始的RTMP数据流被进行一致性封装处理,从而在边缘节点生成的TS分片均遵从源站节点的统一设定,保证TS分片的参数一致。而新增的JDSEI,不影响原始RTMP数据流的正常播放,并对当前流带宽的影响尽可能的降低。一致性TS分片的生成,不仅解决了边缘节点切片不规律的问题,并可以延伸出多点缓冲,P2P透传缓冲等终端新的机制。且可以抛弃原有的源站节点切片透传到边缘的模式,降低内网带宽。
本公开提供的数据处理方法,由源站节点和边缘节点配合完成切片的过程。源站节点获取待处理帧数据后,生成该待处理帧数据对应的一致性描述信息,该一致性描述信息则是用于待处理帧数据进行切片时使用的描述信息。然后边缘节点将一直性描述信息和对应的待处理帧数据,依次分发给至少一个边缘节点。而边缘节点获取到源站节点传输的一次性描述信息和对应的待处理帧数据后,根据一次性描述信息对待处理帧数据进行切片,生成至少一个一致性传输流分片。在上述过程中,由源站节点生成待处理帧数据进行切片时使用的一致性描述信息,然后由边缘节点基于该一致性描述信息完成切片过程,也就是由源站节点对各个需要切片的待处理帧数据,进行了切片一致性的预处理,避免了边缘节点独立切片造成的切片参数存在差别,保证了各个一致性传输流分片的播放效果;同时,待处理帧数据的实际切片过程则是在边缘节点完成的,充分利用了边缘节点的计算能力,提升切片处理效率。
下面对本公开实施例提供的用于数据处理的源站节点装置进行描述,下文描述的用于数据处理的源站节点装置,与上文描述的以源站节点为执行主体的数据处理方法可相互对应参照。如图10所示, 用于数据处理的源站节点装置包括:
源站获取模块1001,用于获取当前的待处理帧数据;
信息生成模块1002,用于解析待处理帧数据,生成待处理帧数据对应的一致性描述信息,其中,一致性描述信息为待处理帧数据进行切片时使用的描述信息;
分发模块1003,用于依次将一致性描述信息和待处理帧数据,分发给至少一个边缘节点。
在实施例中,源站获取模块1001,具体用于获取基于消息队列传输的当前帧数据,其中,消息队列中包括视频帧和音频帧;确定当前帧数据为视频帧或音频帧后,基于当前帧数据,获取待处理帧数据;
信息生成模块1002,具体用于当当前帧数据为视频帧时,生成带有视频标识的、待处理帧数据对应的一致性描述信息;当当前帧数据为音频帧时,生成带有音频标识的、待处理帧数据对应的一致性描述信息。
在实施例中,源站获取模块1001,具体用于当当前帧数据为视频帧时,将当前帧数据作为待处理帧数据;当当前帧数据为音频帧时,获取包括当前帧数据的、连续的N个音频帧;将N个音频帧作为待处理帧数据,其中,N为大于0的整数。
在实施例中,源站获取模块1001,具体用于当当前帧数据为音频帧时,缓存当前帧数据;再次获取基于消息队列传输的当前帧数据,判断再次获取的当前帧数据是否为音频帧;若否,将已缓存的音频帧作为待处理帧数据;若是,判断再次获取的当前帧数据和已缓存的音频帧的总数据长度,是否小于或等于预设的打包基本码流最大长度,若是,缓存当前帧数据;若否,将已缓存的音频帧作为待处理帧数据,并清空音频缓存空间后缓存当前帧数据。
在实施例中,分发模块1003,具体用于将一致性描述信息作为 消息队列中的视频帧,分发给至少一个边缘节点;基于消息队列,将视频帧分发给至少一个边缘节点;或者,基于消息队列,将N个音频帧依次分发给至少一个边缘节点。
在实施例中,信息生成模块1002,具体用于判断待处理帧数据中是否包含补充增强信息;若否,生成待处理帧数据的自定义补充增强信息;若是,确定补充增强信息不是自定义补充增强信息后,生成待处理帧数据的自定义补充增强信息,其中,一致性描述信息为自定义补充增强信息。
在实施例中,用于数据处理的源站节点装置还包括空间申请模块1004,用于获取待处理帧数据之前,申请自定义标识符的标识缓存空间,其中,标识缓存空间中缓存的自定义标识符,是由上一帧待处理帧数据对应的自定义补充增强信息中提取的。
信息生成模块1002,具体用于获取标识缓存空间中的自定义标识符;将补充增强信息中的协议标识符,与标识缓存空间中的自定义标识符进行比较,当比较结果指示不一致时,确定补充增强信息不是自定义补充增强信息。
下面对本公开实施例提供的用于数据处理的边缘节点装置进行描述,下文描述的用于数据处理的边缘节点装置,与上文描述的以边缘节点为执行主体的数据处理方法可相互对应参照。如图11所示,用于数据处理的边缘节点装置包括:
边缘获取模块1101,用于获取源站节点传输的一致性描述信息,以及获取一致性描述信息对应的待处理帧数据,其中,一致性描述信息为待处理帧数据进行切片时使用的描述信息;
切片处理模块1102,用于根据一致性描述信息,对待处理帧数据进行切片,生成至少一个一致性传输流分片。
在实施例中,切片处理模块1102,具体用于确定一致性描述信 息包括视频标识时,根据一致性描述信息更新当前视频切片描述信息,以根据当前视频切片描述信息,对下一帧获取的视频帧进行切片处理;确定一致性描述信息包括音频标识时,采用当前音频切片描述信息,对预先设置的数据缓存空间内的音频帧进行切片处理后,清空数据缓存空间,并根据一致性描述信息更新当前音频切片描述信息,其中,一致性描述信息包括视频标识或音频标识,待处理帧数据为视频帧或音频帧。
在实施例中,边缘获取模块1101,具体用于获取源站节点基于消息队列传输的数据帧;当数据帧为音频帧时,将音频帧存储至数据缓存空间,其中,数据缓存空间内的音频帧,为当前音频切片描述信息对应的待处理帧数据;当数据帧为视频帧时,确定视频帧为当前视频切片描述信息对应的待处理帧数据,或者,确定视频帧为一致性描述信息。
在实施例中,边缘获取模块1101,具体用于确定视频帧为补充增强信息;确定补充增强信息为自定义补充增强信息,其中,一致性描述信息为自定义补充增强信息。
图12示例了一种电子设备的实体结构示意图,如图8所示,该电子设备可以包括:处理器(processor)1201、通信接口(Communications Interface)1202、存储器(memory)1203和通信总线1204,其中,处理器1201,通信接口1202,存储器1203通过通信总线1204完成相互间的通信。处理器1201可以调用存储器1203中的逻辑指令,以执行源站节点为执行主体的数据处理方法,该方法包括:获取当前的待处理帧数据;解析待处理帧数据,生成待处理帧数据对应的一致性描述信息,其中,一致性描述信息为待处理帧数据进行切片时使用的描述信息;依次将一致性描述信息和对应的待处理帧数据,分发给至少一个边缘节点;
或者,以执行边缘节点为执行主体的数据处理方法,该方法包括:获取源站节点传输的一致性描述信息,以及获取一致性描述信息对应的待处理帧数据,其中,一致性描述信息为待处理帧数据进行切片时使用的描述信息;根据一致性描述信息,对待处理帧数据进行切片,生成至少一个一致性传输流分片。
此外,上述的存储器1203中的逻辑指令可以通过软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在计算机可读取存储介质中。基于这样的理解,本公开实施例的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的部分可以以软件产品的形式体现出来,该计算机软件产品存储在存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本公开各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、磁碟或者光盘等各种可以存储程序代码的介质。
另一方面,本公开还提供一种计算机程序产品,所述计算机程序产品包括存储在非暂态计算机可读存储介质上的计算机程序,所述计算机程序包括程序指令,当所述程序指令被计算机执行时,计算机能够执行上述各方法所提供的源站节点为执行主体的数据处理方法,该方法包括:获取当前的待处理帧数据;解析待处理帧数据,生成待处理帧数据对应的一致性描述信息,其中,一致性描述信息为待处理帧数据进行切片时使用的描述信息;依次将一致性描述信息和对应的待处理帧数据,分发给至少一个边缘节点;
或者,计算机能够执行上述各方法所提供的边缘节点为执行主体的数据处理方法,该方法包括:获取源站节点传输的一致性描述信息,以及获取一致性描述信息对应的待处理帧数据,其中,一致性描述信 息为待处理帧数据进行切片时使用的描述信息;根据一致性描述信息,对待处理帧数据进行切片,生成至少一个一致性传输流分片。
又一方面,本公开还提供一种非暂态计算机可读存储介质,其上存储有计算机程序,该计算机程序被处理器执行时实现以执行上述各提供的源站节点为执行主体的数据处理方法,该方法包括:获取当前的待处理帧数据;解析待处理帧数据,生成待处理帧数据对应的一致性描述信息,其中,一致性描述信息为待处理帧数据进行切片时使用的描述信息;依次将一致性描述信息和对应的待处理帧数据,分发给至少一个边缘节点;
或者,该计算机程序被处理器执行时实现以执行上述各提供的边缘节点为执行主体的数据处理方法,该方法包括:获取源站节点传输的一致性描述信息,以及获取一致性描述信息对应的待处理帧数据,其中,一致性描述信息为待处理帧数据进行切片时使用的描述信息;根据一致性描述信息,对待处理帧数据进行切片,生成至少一个一致性传输流分片。
以上所描述的装置实施例仅仅是示意性的,其中所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部模块来实现本实施例方案的目的。本领域普通技术人员在不付出创造性的劳动的情况下,即可以理解并实施。
通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到各实施方式可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件。基于这样的理解,上述技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品可以存储在计算机可读存储介质中,如ROM/RAM、磁碟、光 盘等,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行各个实施例或者实施例的某些部分所述的方法。
最后应说明的是:以上实施例仅用以说明本公开的技术方案,而非对其限制;尽管参照前述实施例对本公开进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本公开各实施例技术方案的精神和范围。

Claims (15)

  1. 一种由源站节点执行的数据处理方法,包括:
    获取当前的待处理帧数据;
    解析所述待处理帧数据,生成与所述待处理帧数据对应的一致性描述信息,其中,所述一致性描述信息为所述待处理帧数据进行切片时使用的描述信息;
    依次将所述一致性描述信息和对应的所述待处理帧数据,分发给至少一个边缘节点。
  2. 根据权利要求1所述的数据处理方法,其中,所述获取当前的待处理帧数据,包括:
    获取基于消息队列传输的当前帧数据,其中,所述消息队列中包括视频帧和音频帧;
    确定所述当前帧数据为视频帧或音频帧后,基于所述当前帧数据,获取所述待处理帧数据;
    所述解析所述待处理帧数据,生成所述待处理帧数据对应的一致性描述信息,包括:
    当所述当前帧数据为所述视频帧时,解析所述视频帧,生成带有视频标识的、所述待处理帧数据对应的一致性描述信息;
    当所述当前帧数据为所述音频帧时,解析所述音频帧,生成带有音频标识的、所述待处理帧数据对应的一致性描述信息。
  3. 根据权利要求2所述的数据处理方法,其中,所述确定所述当前帧数据为视频帧或音频帧后,基于所述当前帧数据,获取所述待处理帧数据,包括:
    当所述当前帧数据为所述视频帧时,将所述当前帧数据作为所述待处理帧数据;
    当所述当前帧数据为所述音频帧时,获取包括所述当前帧数据的、 连续的N个音频帧;将所述N个音频帧作为所述待处理帧数据,其中,N为大于0的整数。
  4. 根据权利要求3所述的数据处理方法,其中,所述当所述当前帧数据为所述音频帧时,获取包括所述当前帧数据的、连续的N个音频帧,包括:
    当所述当前帧数据为所述音频帧时,缓存所述当前帧数据;
    再次获取基于消息队列传输的当前帧数据,判断再次获取的所述当前帧数据是否为所述音频帧;
    若否,将已缓存的所述音频帧作为所述待处理帧数据;
    若是,判断再次获取的所述当前帧数据和已缓存的所述音频帧的总数据长度,是否小于或等于预设的打包基本码流最大长度,若是,缓存所述当前帧数据;若否,将已缓存的所述音频帧作为所述待处理帧数据,并清空音频缓存空间后缓存所述当前帧数据。
  5. 根据权利要求3所述的数据处理方法,其中,所述依次将所述一致性描述信息和对应的所述待处理帧数据,分发给至少一个边缘节点,包括:
    将所述一致性描述信息作为所述消息队列中的视频帧,分发给至少一个所述边缘节点;
    基于所述消息队列,将所述视频帧分发给至少一个所述边缘节点;或者,基于所述消息队列,将所述N个音频帧依次分发给至少一个所述边缘节点。
  6. 根据权利要求1所述的数据处理方法,其中,所述一致性描述信息为自定义补充增强信息;
    所述解析所述待处理帧数据,生成所述待处理帧数据对应的一致性描述信息,包括:
    判断所述待处理帧数据中是否包含补充增强信息;若否,生成所 述待处理帧数据的自定义补充增强信息;若是,确定所述补充增强信息不是所述自定义补充增强信息后,生成所述待处理帧数据的自定义补充增强信息。
  7. 根据权利要求6所述的数据处理方法,其中,所述自定义补充增强信息包括所述自定义标识符,所述自定义标识符用于指示所述一致性描述信息是根据自定义一致性协议生成的;
    所述获取待处理帧数据之前,还包括:
    申请所述自定义标识符的标识缓存空间,其中,所述标识缓存空间中缓存的所述自定义标识符,是由上一帧所述待处理帧数据对应的所述自定义补充增强信息中提取的;
    所述确定所述补充增强信息不是所述自定义补充增强信息,包括:
    获取所述标识缓存空间中的所述自定义标识符;将所述补充增强信息中的协议标识符,与所述标识缓存空间中的所述自定义标识符进行比较,当比较结果指示不一致时,确定所述补充增强信息不是所述自定义补充增强信息。
  8. 一种由边缘节点执行的数据处理方法,包括:
    获取源站节点传输的一致性描述信息,以及获取所述一致性描述信息对应的待处理帧数据,其中,所述一致性描述信息为所述待处理帧数据进行切片时使用的描述信息;
    根据所述一致性描述信息,对所述待处理帧数据进行切片,生成至少一个一致性传输流分片。
  9. 根据权利要求8所述的数据处理方法,其中,所述一致性描述信息包括视频标识或音频标识,所述待处理帧数据为视频帧或音频帧;
    所述根据所述一致性描述信息,对所述待处理帧数据进行切片,包括:
    确定所述一致性描述信息包括所述视频标识时,根据所述一致性描述信息更新当前视频切片描述信息,以根据所述当前视频切片描述信息,对下一帧获取的所述视频帧进行切片处理;
    确定所述一致性描述信息包括所述音频标识时,采用当前音频切片描述信息,对预先设置的数据缓存空间内的所述音频帧进行切片处理后,清空所述数据缓存空间,并根据所述一致性描述信息更新当前音频切片描述信息。
  10. 根据权利要求9所述的数据处理方法,其中,所述获取源站节点传输的一致性描述信息,以及获取所述一致性描述信息对应的待处理帧数据,包括:
    获取所述源站节点基于消息队列传输的数据帧;
    当所述数据帧为音频帧时,将所述音频帧存储至所述数据缓存空间,其中,所述数据缓存空间内的所述音频帧,为当前音频切片描述信息对应的待处理帧数据;
    当所述数据帧为视频帧时,确定所述视频帧为所述当前视频切片描述信息对应的所述待处理帧数据,或者,确定所述视频帧为所述一致性描述信息。
  11. 根据权利要求10所述的数据处理方法,其中,所述一致性描述信息为自定义补充增强信息;
    所述确定所述视频帧为所述一致性描述信息,包括:
    确定所述视频帧为补充增强信息;
    确定所述补充增强信息为自定义补充增强信息。
  12. 一种用于数据处理的源站节点装置,包括:
    源站获取模块,用于获取当前的待处理帧数据;
    信息生成模块,用于解析所述待处理帧数据,生成所述待处理帧数据对应的一致性描述信息,其中,所述一致性描述信息为所述待处 理帧数据进行切片时使用的描述信息;
    分发模块,用于依次将所述一致性描述信息和所述待处理帧数据,分发给至少一个边缘节点。
  13. 一种用于数据处理的边缘节点装置,包括:
    边缘获取模块,用于获取源站节点传输的一致性描述信息,以及获取所述一致性描述信息对应的待处理帧数据,其中,所述一致性描述信息为所述待处理帧数据进行切片时使用的描述信息;
    切片处理模块,用于根据所述一致性描述信息,对所述待处理帧数据进行切片,生成至少一个一致性传输流分片。
  14. 一种电子设备,包括:
    处理器;以及
    存储器,存储了可在所述处理器上运行的计算机程序,其中,所述程序在由所述处理器执行时使得所述电子设备执行如权利要求1至7任一项所述的数据处理方法;
    或者,所述程序在由所述处理器执行所述程序时使得所述电子设备执行如权利要求8至11任一项所述的数据处理方法。
  15. 一种非暂态计算机可读存储介质,其上存储有计算机程序,其中,所述计算机程序被处理器执行时执行如权利要求1至7任一项所述的数据处理方法;
    或者,所述计算机程序被处理器执行时执行如权利要求8至11任一项所述的数据处理方法。
PCT/CN2023/073991 2022-06-13 2023-01-31 数据处理方法、装置、设备及存储介质 WO2023241057A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202210667519.X 2022-06-13
CN202210667519.XA CN115086714A (zh) 2022-06-13 2022-06-13 数据处理方法、装置、设备及存储介质

Publications (1)

Publication Number Publication Date
WO2023241057A1 true WO2023241057A1 (zh) 2023-12-21

Family

ID=83251856

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2023/073991 WO2023241057A1 (zh) 2022-06-13 2023-01-31 数据处理方法、装置、设备及存储介质

Country Status (2)

Country Link
CN (1) CN115086714A (zh)
WO (1) WO2023241057A1 (zh)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115086714A (zh) * 2022-06-13 2022-09-20 京东科技信息技术有限公司 数据处理方法、装置、设备及存储介质

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108600859A (zh) * 2018-03-30 2018-09-28 深圳市网心科技有限公司 一种数据切片方法及***
CN109495505A (zh) * 2018-12-21 2019-03-19 北京金山云网络技术有限公司 流媒体协议转换方法、装置、***及计算机可读介质
CN109618208A (zh) * 2018-12-25 2019-04-12 湖南快乐阳光互动娱乐传媒有限公司 一种直播流分布式切片同步方法及装置
CN111770390A (zh) * 2020-07-09 2020-10-13 腾讯科技(深圳)有限公司 数据处理方法、装置、服务器及存储介质
US20210195259A1 (en) * 2019-12-23 2021-06-24 Comcast Cable Communications, Llc Method and apparatus for managing redundant segmented streams
CN115086714A (zh) * 2022-06-13 2022-09-20 京东科技信息技术有限公司 数据处理方法、装置、设备及存储介质

Family Cites Families (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103634610B (zh) * 2012-08-24 2018-02-16 中兴通讯股份有限公司 直播内容分发***及方法
CN103973662B (zh) * 2013-02-06 2017-06-20 华为技术有限公司 流媒体请求方法及控制器
CN106470352B (zh) * 2015-08-18 2020-04-07 中兴通讯股份有限公司 直播频道播放方法、装置及***
WO2017035804A1 (zh) * 2015-09-02 2017-03-09 深圳好视网络科技有限公司 一种传送流切片方法及装置
CN108055594B (zh) * 2017-11-14 2020-09-29 北京百度网讯科技有限公司 边缘切片的实现方法、装置、计算机设备及存储介质
CN113141524B (zh) * 2020-01-17 2023-09-29 北京达佳互联信息技术有限公司 资源传输方法、装置、终端及存储介质
CN111510752B (zh) * 2020-06-18 2021-04-23 平安国际智慧城市科技股份有限公司 数据传输方法、装置、服务器及存储介质
CN111737012B (zh) * 2020-07-31 2020-12-04 腾讯科技(深圳)有限公司 数据包的同步方法、装置、设备及存储介质
CN112367527A (zh) * 2020-10-28 2021-02-12 广州市网星信息技术有限公司 一种传送流文件生成方法、装置、设备及存储介质

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108600859A (zh) * 2018-03-30 2018-09-28 深圳市网心科技有限公司 一种数据切片方法及***
CN109495505A (zh) * 2018-12-21 2019-03-19 北京金山云网络技术有限公司 流媒体协议转换方法、装置、***及计算机可读介质
CN109618208A (zh) * 2018-12-25 2019-04-12 湖南快乐阳光互动娱乐传媒有限公司 一种直播流分布式切片同步方法及装置
US20210195259A1 (en) * 2019-12-23 2021-06-24 Comcast Cable Communications, Llc Method and apparatus for managing redundant segmented streams
CN111770390A (zh) * 2020-07-09 2020-10-13 腾讯科技(深圳)有限公司 数据处理方法、装置、服务器及存储介质
CN115086714A (zh) * 2022-06-13 2022-09-20 京东科技信息技术有限公司 数据处理方法、装置、设备及存储介质

Also Published As

Publication number Publication date
CN115086714A (zh) 2022-09-20

Similar Documents

Publication Publication Date Title
WO2023024834A9 (zh) 一种游戏数据处理方法、装置及存储介质
US9414123B2 (en) Method for hybrid delivery of MMT package and content and method for receiving content
JP4690400B2 (ja) Saf同期化階層パケット構造とこれを用いるサーバシステム
JP2018148577A (ja) ダウンローディング及びストリーミングをサポートするパケットの送信装置
JP5961760B2 (ja) Mpeg−2トランスポートストリームにおけるiso−bmffイベントボックスの搬送
US20150181003A1 (en) Method and apparatus for transmitting and receiving packets in hybrid transmission service of mmt
KR102026266B1 (ko) 부호화된 미디어 데이터를 전송하는 장치에서의 네트워크 지터 추정 방법
KR102306352B1 (ko) Mmtp 디캡슐화 버퍼의 시그날링 및 동작
KR20160106718A (ko) 브로드캐스트 채널을 통한 dash 콘텐츠 스트리밍 방법 및 장치
KR102098723B1 (ko) Mmt 전송 패킷의 설정 방법 및 전송 방법
WO2023241057A1 (zh) 数据处理方法、装置、设备及存储介质
CN109977137B (zh) 一种数据查询方法和装置
KR102480751B1 (ko) Mmt에서 미디어 데이터의 저 지연 소비 시그날링 및 동작 방법 및 장치
CN113115120A (zh) 视频切片方法、装置、电子设备及存储介质
CN110086797B (zh) 媒体流的实时接收方法、客户端、计算机设备和存储介质
CN113285947B (zh) 一种hls直播和组播直播接续的方法和装置
WO2021017958A1 (zh) 视频转码方法及装置
CN112203105A (zh) 一种新媒体移动直播方法及***
CN110557370B (zh) 一种pamir同步终端信息的方法、***、电子设备及存储介质
CN115604481B (zh) 提升编解码与传输并行的方法、装置及***
WO2020098455A1 (zh) 媒体流的实时递送方法及服务器
CN110012064B (zh) 一种数据同步的方法和***
WO2024066652A1 (zh) 数据传输方法、装置、计算机可读介质及电子设备
CN113453006B (zh) 一种图片封装方法、设备以及存储介质
WO2020216035A1 (zh) 媒体流的实时推送方法、实时接收方法、服务器及客户端

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 23822629

Country of ref document: EP

Kind code of ref document: A1