[go: up one dir, main page]

CN102143377A - Video stream delay factor monitoring method and video stream delay factor monitoring device - Google Patents

Video stream delay factor monitoring method and video stream delay factor monitoring device Download PDF

Info

Publication number
CN102143377A
CN102143377A CN2010105744768A CN201010574476A CN102143377A CN 102143377 A CN102143377 A CN 102143377A CN 2010105744768 A CN2010105744768 A CN 2010105744768A CN 201010574476 A CN201010574476 A CN 201010574476A CN 102143377 A CN102143377 A CN 102143377A
Authority
CN
China
Prior art keywords
video stream
sampling period
clock reference
delay factor
program clock
Prior art date
Legal status (The legal status 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 status listed.)
Pending
Application number
CN2010105744768A
Other languages
Chinese (zh)
Inventor
陈国海
张作富
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies Co Ltd
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 Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN2010105744768A priority Critical patent/CN102143377A/en
Publication of CN102143377A publication Critical patent/CN102143377A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

本发明提供一种视频流延迟因素监测方法及装置。该方法包括:确定上一采样周期视频流的延迟因素是否小于预设阀值;上一采样周期视频流的延迟因素小于预设阀值时,根据当前采样周期视频流中包含节目时钟参考数据包的到达时间和所述数据包中的节目时钟参考,确定当前采样周期视频流的延迟因素。本发明降低了视频监控过程中对存储空间的需求,实现了监控大流量视频流质量的目的。

Figure 201010574476

The invention provides a video stream delay factor monitoring method and device. The method includes: determining whether the delay factor of the video stream in the previous sampling period is less than a preset threshold value; The arrival time of the packet and the program clock reference in the packet determine the delay factor of the video stream for the current sampling period. The invention reduces the requirement for storage space in the process of video monitoring, and realizes the purpose of monitoring the quality of large-flow video streams.

Figure 201010574476

Description

视频流延迟因素监测方法及装置Video stream delay factor monitoring method and device

技术领域technical field

本发明涉及通信技术,尤其涉及一种视频流延迟因素监测方法及装置。The invention relates to communication technology, in particular to a method and device for monitoring video stream delay factors.

背景技术Background technique

交互式网络电视(Internet Protocol Television,简称IPTV)通过网络实时来传输IPTV节目。网络传输很有可能存在网络丢包和网络抖动的现象,严重影响了用户体验。视频传输中,大量延迟的数据包抖动会造成终端缓冲器资源耗尽,产生解码器没有内容可解的时段,从而导致电视上播放的视频质量下降。在许多情况下,电视会显示大量块状视频或显示的仅仅是空白。Internet Protocol Television (IPTV for short) transmits IPTV programs in real time through the network. Network transmission is likely to have network packet loss and network jitter, which seriously affects user experience. In video transmission, a large amount of delayed data packet jitter will cause the terminal buffer resources to be exhausted, resulting in a period of time when the decoder has no content to solve, resulting in a decrease in the quality of the video played on the TV. In many cases, the TV will display a lot of blocky video or just blank.

媒体传输质量指标(Media Delivery Index,MDI)是对视频流在IP网络传输质量进行评估的测量指标。作为IP视频流传输质量测试的行业标准,MDI包含两个指标:延迟因素(delay factor,DF)和媒体丢包率(MLR)。DF值表明被测试视频流的抖动状况。DF将视频流抖动的变化换算为对解码设备缓冲的需求。被测视频流抖动越大,DF值越大。现有视频质量监控方法在监控DF值时,存储当前采样周期内所有数据包的到达时间和字节数。而存储数据包的到达时间和字节数需占用监控装置的存储空间,尤其在对大流量视频质量进行监控时占用的存储空间更大。The Media Delivery Index (MDI) is a measurement index for evaluating the transmission quality of video streams on an IP network. As an industry standard for testing the quality of IP video streaming, MDI includes two indicators: delay factor (DF) and media packet loss rate (MLR). The DF value indicates the jitter condition of the tested video stream. DF converts the change of the jitter of the video stream into the demand for buffering of the decoding device. The greater the jitter of the video stream under test, the greater the DF value. The existing video quality monitoring method stores the arrival time and the number of bytes of all data packets in the current sampling period when monitoring the DF value. However, storing the arrival time and the number of bytes of the data packets needs to occupy the storage space of the monitoring device, especially when the video quality of a large flow is monitored, the storage space occupied is larger.

发明内容Contents of the invention

本发明实施例提供一种视频流延迟因素监测方法及装置,降低了视频监控过程中对存储空间的需求,实现了监控大流量视频流质量的目的。Embodiments of the present invention provide a video stream delay factor monitoring method and device, which reduce the storage space requirement in the video monitoring process and realize the purpose of monitoring the quality of large-flow video streams.

本发明实施例提供一种视频流延迟因素监测方法,包括:An embodiment of the present invention provides a video stream delay factor monitoring method, including:

确定上一采样周期视频流的延迟因素是否小于预设阀值;Determine whether the delay factor of the video stream in the previous sampling period is less than a preset threshold;

上一采样周期视频流的延迟因素小于预设阀值时,根据当前采样周期视频流中包含节目时钟参考数据包的到达时间和所述数据包中的节目时钟参考,确定当前采样周期视频流的延迟因素。When the delay factor of the video stream in the previous sampling period is less than the preset threshold value, according to the arrival time of the program clock reference data packet contained in the video stream of the current sampling period and the program clock reference in the data packet, determine the time delay of the video stream in the current sampling period delay factor.

本发明实施例提供一种视频流延迟因素监控装置,包括:流分配模块和估算模块;An embodiment of the present invention provides a video stream delay factor monitoring device, including: a stream allocation module and an estimation module;

所述流分配模块,用于确定上一采样周期视频流的延迟因素是否小于预设阀值,上一采样周期视频流的延迟因素小于预设阀值时,通知所述估算模块确定当前采样周期视频流的延迟因素;The stream allocation module is used to determine whether the delay factor of the video stream in the previous sampling period is less than a preset threshold, and when the delay factor of the video stream in the previous sampling period is less than the preset threshold, notify the estimation module to determine the current sampling period Latency factors for video streams;

所述估算模块,用于接收到所述流分配模块的通知后,根据当前采样周期视频流中包含节目时钟参考数据包的到达时间和所述数据包中的节目时钟参考,确定当前采样周期视频流的延迟因素。The estimation module is configured to, after receiving the notification from the stream allocation module, determine the current sampling period video stream according to the arrival time of the program clock reference data packet contained in the current sampling period video stream and the program clock reference in the data packet. Stream delay factor.

本发明实施例提供的视频流延迟因素监测方法及装置,在监控当前采样周期的视频流之前,先通过上一采样周期的DF值确定上一采样周期的视频流是否为传输正常的视频流,若DF值小于预设阀值,在当前采样周期只根据包含PCR(program clock reference,节目时钟参考)的数据包的到达时间和其中的PCR确定DF值,不需存储不包含PCR的数据包的到达时间和字节数。只需存储第1个包含RCR数据包到达时间,因此,本实施例在确定上一采样周期的DF值小于预设阀值后,在当前采样周期不需要存储所有数据包的到达时间和字节数,从而降低了视频流监控装置存储空间的需求。In the video stream delay factor monitoring method and device provided by the embodiments of the present invention, before monitoring the video stream of the current sampling period, first determine whether the video stream of the previous sampling period is a normal video stream through the DF value of the previous sampling period, If the DF value is less than the preset threshold value, the DF value is only determined according to the arrival time of the data packet containing the PCR (program clock reference, program clock reference) and the PCR therein in the current sampling period, and there is no need to store the data packet not containing the PCR Arrival time and byte count. It is only necessary to store the arrival time of the first data packet containing RCR. Therefore, this embodiment does not need to store the arrival time and bytes of all data packets in the current sampling period after determining that the DF value of the previous sampling period is less than the preset threshold. number, thereby reducing the storage space requirements of the video stream monitoring device.

附图说明Description of drawings

为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作一简单地介绍,显而易见地,下面描述中的附图是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings that need to be used in the description of the embodiments or the prior art. Obviously, the accompanying drawings in the following description These are some embodiments of the present invention. For those skilled in the art, other drawings can also be obtained according to these drawings without any creative effort.

图1为本发明视频流延迟因素监测方法实施例一流程图;Fig. 1 is a flow chart of Embodiment 1 of a method for monitoring video stream delay factors of the present invention;

图2为本发明视频流延迟因素监测方法实施例二流程图;Fig. 2 is the flow chart of Embodiment 2 of the method for monitoring video stream delay factors of the present invention;

图3为本发明视频流延迟因素监测方法实施例三流程图;FIG. 3 is a flow chart of Embodiment 3 of the method for monitoring video stream delay factors of the present invention;

图4为本发明视频流延迟因素监控装置实施例一结构示意图;FIG. 4 is a structural schematic diagram of Embodiment 1 of a video stream delay factor monitoring device of the present invention;

图5为本发明视频流延迟因素监控装置实施例二的结构示意图;FIG. 5 is a schematic structural diagram of Embodiment 2 of the video stream delay factor monitoring device of the present invention;

图6为本发明视频流延迟因素监控装置实施例三的结构示意图;6 is a schematic structural diagram of Embodiment 3 of the device for monitoring delay factors of video streams according to the present invention;

图7为本发明视频流延迟因素监控装置实施例四的结构示意图。FIG. 7 is a schematic structural diagram of Embodiment 4 of an apparatus for monitoring delay factors of video streams according to the present invention.

具体实施方式Detailed ways

为使本发明实施例的目的、技术方案和优点更加清楚,下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments It is a part of embodiments of the present invention, but not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by persons of ordinary skill in the art without making creative efforts belong to the protection scope of the present invention.

当IP数据包在网络中传输时,会被各种网络设备进行排序、路由和转发,由于各种原因(例如大量P2P流量、文件下载和VoIP通话)都可引起网络瞬时拥塞,从而导致数据通过网络节点的时延变化,这就是所谓的抖动。由于到达网络节点的数据流的瞬时速率与网络节点的处理速率不一致,因此,需将数据包在网络节点的缓存区中进行适当的缓冲,之后再送至视频解码器进行解码。抖动在播放终端的表现现象是:缓存中没有数据包可供视频解码器解码,或者缓存区的空间不足以容纳接收到的数据包导致丢包。MDI的DF是一个时间值,它表示缓存区必须缓冲多少毫秒的数据才能消除抖动,从而不影响播放质量。When IP data packets are transmitted in the network, they will be sorted, routed, and forwarded by various network devices. Due to various reasons (such as a large amount of P2P traffic, file downloads, and VoIP calls), the network can be temporarily congested, resulting in data passing through The delay of network nodes varies, which is called jitter. Since the instantaneous rate of the data flow arriving at the network node is inconsistent with the processing rate of the network node, the data packet needs to be properly buffered in the buffer area of the network node, and then sent to the video decoder for decoding. The manifestation of jitter on the playback terminal is that there is no data packet in the buffer for decoding by the video decoder, or the space in the buffer area is not enough to accommodate the received data packets, resulting in packet loss. The DF of MDI is a time value, which indicates how many milliseconds of data the buffer must buffer to eliminate jitter, so as not to affect the playback quality.

图1为本发明视频流延迟因素监测方法实施例一流程图。如图1所示,本实施例包括:FIG. 1 is a flow chart of Embodiment 1 of the method for monitoring delay factors of video streams according to the present invention. As shown in Figure 1, this embodiment includes:

步骤11:确定上一采样周期视频流的DF值是否小于预设阀值。Step 11: Determine whether the DF value of the video stream in the previous sampling period is smaller than a preset threshold.

设置在网络中任意一节点的视频流监控装置,对采样周期内通过网络节点的视频流进行监控,分析在该采样周期内视频流的DF值。本发明实施例中,每个采样周期确定的DF值,都为下一采样周期确定DF值的策略提供依据。在当前采样周期对通过网络节点的视频流进行DF监控时,先确定在当前采样周期的上一采样周期,其视频流的DF值是否小于预设阀值。如果上一采样周期视频流的DF值小于预设阀值,表明上一采样周期监控的视频流能适应解码器的解码需求,即视频流抖动不影响视频播放质量,称上一采样周期的视频流为传输正常的视频流。在上一采样周期视频流的DF值大于等于预设阀值时,表明上一采样周期监控的视频流不能适应解码器的解码需求,称上一采样周期的视频流为传输异常的视频流。A video stream monitoring device installed at any node in the network monitors the video stream passing through the network node within the sampling period, and analyzes the DF value of the video stream within the sampling period. In the embodiment of the present invention, the DF value determined in each sampling period provides a basis for the strategy for determining the DF value in the next sampling period. When performing DF monitoring on the video stream passing through the network node in the current sampling period, first determine whether the DF value of the video stream in the previous sampling period of the current sampling period is less than a preset threshold. If the DF value of the video stream in the previous sampling period is less than the preset threshold, it indicates that the video stream monitored in the previous sampling period can meet the decoding requirements of the decoder, that is, the jitter of the video stream does not affect the quality of video playback, and it is called the video of the previous sampling period. The stream is a normal video stream for transmission. When the DF value of the video stream in the previous sampling period is greater than or equal to the preset threshold, it indicates that the video stream monitored in the previous sampling period cannot meet the decoding requirements of the decoder, and the video stream in the previous sampling period is called a video stream with abnormal transmission.

网络的性能和网络节点缓存区大小等都会影响DF值预设阀值的设定,可在实验室根据具体的视频流数目和网络节点缓存区大小等测试求取DF值预设阀值。The performance of the network and the size of the network node buffer will affect the setting of the DF value preset threshold. The DF value preset threshold can be obtained in the laboratory according to the specific number of video streams and the size of the network node buffer area.

步骤12:上一采样周期视频流的DF值小于预设阀值时,根据当前采样周期视频流中包含PCR数据包的到达时间和所述数据包中的PCR,确定当前采样周期视频流的DF值。Step 12: When the DF value of the video stream in the previous sampling period is less than the preset threshold, determine the DF of the video stream in the current sampling period according to the arrival time of the PCR data packet contained in the video stream of the current sampling period and the PCR in the data packet value.

在上一采样周期的视频流为传输正常的视频流时,确定当前采样周期视频流的DF值时,只监控视频流中包含PCR数据包,而不监控其它不包含PCR数据包。由于两个PCR的间隔值,可反映消耗包含PCR的两个数据包之间的数据包所需的实际时间,两个包含PCR数据包的到达时间差可反映接收到前一个PCR数据包后接收到后一个PCR数据包所需的时间,其中包括在传输过程中的时延。因此包含PCR数据包的到达时间的变化和数据包中的PCR的变化,可反映出消耗虚拟缓存中数据包的变化情况,从而反映视频流的DF值。When the video stream in the last sampling period is a video stream with normal transmission, when determining the DF value of the video stream in the current sampling period, only the PCR data packets contained in the video stream are monitored, and other packets not containing the PCR data packets are not monitored. Since the interval value of two PCRs reflects the actual time required to consume a packet between two packets containing a PCR, the difference in arrival time of two packets containing a PCR reflects the time a packet received after the previous PCR packet was received. The time required after a PCR packet, which includes the delay in transmission. Therefore, the change of the arrival time of the data packet including the PCR and the change of the PCR in the data packet can reflect the change of the consumed data packet in the virtual buffer, thereby reflecting the DF value of the video stream.

另外,为提高监控可靠性,也可在确定前几个连续的采样周期的DF值小于预设阀值后,在当前采样周期只根据包含PCR数据包的到达时间和其中的PCR,确定当前采样周期的DF值。In addition, in order to improve monitoring reliability, after determining that the DF value of the previous several consecutive sampling periods is less than the preset threshold value, in the current sampling period, only according to the arrival time of the PCR data packet and the PCR in it, determine the current sampling period. Periodic DF value.

在上一采样周期视频流的DF值大于等于预设阀值时,在当前采样周期需监控所有数据包。存储当前采样周期所有数据包的到达时间和字节数,根据当前周期的视频流码率和当前采样周期每个数据包到达前后虚拟缓存的比特数、确定当前采样周期视频流的DF值。When the DF value of the video stream in the previous sampling period is greater than or equal to the preset threshold, all data packets need to be monitored in the current sampling period. Store the arrival time and number of bytes of all data packets in the current sampling period, and determine the DF value of the video stream in the current sampling period according to the bit rate of the video stream in the current sampling period and the number of bits in the virtual cache before and after the arrival of each data packet in the current sampling period.

本实施例在监控当前采样周期的视频流之前,先通过上一采样周期的DF值确定上一采样周期的视频流是否为传输正常的视频流,若DF值小于预设阀值,在当前采样周期只根据包含PCR的数据包的到达时间和其中的PCR确定DF值,而不需存储不包含PCR的数据包的到达时间和字节数。只需存储第1个包含RCR数据包到达时间,因此,本实施例在确定上一采样周期的DF值小于预设阀值后,在当前采样周期不需要存储所有数据包的到达时间和字节数,从而降低了视频流监控装置存储空间的需求。在上一采样周期视频流的DF值大于等于预设阀值时,监控当前周期内的所有数据包。根据当前周期的视频流码率和当前采样周期每个数据包到达前后虚拟缓存的字节数,对当前采样周期视频流的DF值进行精确计算,从而精确判断当前采样周期视频流是否为传输正常的视频流。In this embodiment, before monitoring the video stream of the current sampling period, it is determined whether the video stream of the previous sampling period is a normal video stream through the DF value of the previous sampling period. If the DF value is less than the preset threshold value, the current sampling period The period only determines the DF value according to the arrival time of the data packet containing the PCR and the PCR therein, without storing the arrival time and the number of bytes of the data packet not containing the PCR. It is only necessary to store the arrival time of the first data packet containing RCR. Therefore, this embodiment does not need to store the arrival time and bytes of all data packets in the current sampling period after determining that the DF value of the previous sampling period is less than the preset threshold. number, thereby reducing the storage space requirements of the video streaming monitoring device. When the DF value of the video stream in the previous sampling period is greater than or equal to the preset threshold, all data packets in the current period are monitored. According to the bit rate of the video stream in the current period and the number of bytes in the virtual cache before and after the arrival of each data packet in the current sampling period, the DF value of the video stream in the current sampling period is accurately calculated, so as to accurately determine whether the video stream in the current sampling period is transmitted normally video stream.

图2为本发明视频流延迟因素监测方法实施例二流程图。本发明实施例,通过设置在网络中任意一节点的视频质量监控装置来监控视频流DF值,视频流监控装置接收到视频流后,并不播放视频流,只通过PCR数据包的到达时间和PCR值计算DF值,从而确定实际播放该视频流的播放器中缓存的变化情况。本发明实施例所述的虚拟缓存为IP视频流传输质量测试的行业标准在MDI中定义的一个术语。虚拟缓存不是视频流监控装置的实际缓存,只是用于观察播放器中缓存的大小,虚拟缓存的大小定义为视频流监控装置接收到的字节数与解码需要的字节数的差值。而视频流监控装置的实际缓存用于缓存包含第1个PCR数据包的到达时间。FIG. 2 is a flow chart of Embodiment 2 of the method for monitoring delay factors of video streams according to the present invention. In the embodiment of the present invention, the DF value of the video stream is monitored by a video quality monitoring device installed at any node in the network. The PCR value calculates the DF value, so as to determine the change of the cache in the player that actually plays the video stream. The virtual cache described in the embodiment of the present invention is a term defined in MDI, an industry standard for IP video stream transmission quality testing. The virtual cache is not the actual cache of the video stream monitoring device, but is only used to observe the size of the buffer in the player. The size of the virtual buffer is defined as the difference between the number of bytes received by the video stream monitoring device and the number of bytes required for decoding. The actual cache of the video stream monitoring device is used to cache the arrival time of the first PCR data packet.

如图2所示,图1中步骤12包括:As shown in Figure 2, step 12 in Figure 1 includes:

步骤121:根据当前采样周期每个包含PCR数据包的到达时间和每个数据包中的PCR,确定在每个包含PCR数据包到达前消耗虚拟缓存中的数据包所需的第一时间。Step 121: According to the arrival time of each PCR-containing data packet and the PCR in each data packet in the current sampling period, determine the first time required to consume the data packets in the virtual cache before each PCR-containing data packet arrives.

只对视频流中包含PCR数据包进行监控以确定当前采样周期内视频流的DF值时,按照包含PCR数据包的到达顺序,依次根据每个包含PCR数据包到达时间和数据包中的PCR,计算每个包含PCR数据包到达被监控的网络节点前消耗虚拟缓存中的数据包所需的时间,记为第一时间。When only monitoring the PCR data packets in the video stream to determine the DF value of the video stream in the current sampling period, according to the arrival sequence of the PCR data packets, according to the arrival time of each PCR data packet and the PCR in the data packet, Calculate the time required to consume the data packets in the virtual cache before each data packet containing the PCR arrives at the monitored network node, and record it as the first time.

上述每个第一时间的具体确定方法可为:根据第N个包含PCR数据包的到达时间与第1个包含PCR数据包的到达时间的差值,和第N个包含PCR数据包中的PCR与第1个包含PCR数据包中的PCR的差值,确定在第N个包含PCR数据包到达前消耗虚拟缓存中的数据包所需的第一时间。确定每个PCR数据包对应的第一时间,直至当前采样周期接收到的最后一个包含PCR数据包。The specific determination method of each of the above first times can be: according to the difference between the arrival time of the Nth PCR data packet and the arrival time of the first PCR data packet, and the PCR data packet in the Nth PCR data packet. The difference from the PCR in the first PCR-containing packet determines the first time required to consume the packet in the virtual buffer before the Nth PCR-containing packet arrives. The first time corresponding to each PCR data packet is determined until the last PCR data packet received in the current sampling period.

第一时间的一种计算公式可为:df(n,pre)=(pcrn-pcr1)-(tn-t1)(公式1)A calculation formula for the first time can be: df(n, pre)=(pcr n -pcr 1 )-(t n -t 1 ) (Formula 1)

其中,pcr1表示当前采样周期内第1个包含PCR数据包中的PCR与27MHz的比值;pcrn表示当前采样周期内第N个包含PCR数据包中的PCR与27MHz的比值;tn表示当前采样周期内第N个包含PCR数据包的到达时间,t1表示当前周期内第1包含PCR数据包的到达时间。pcrn-pcr1表示在第N个包含PCR数据包到达前消耗完当前采样周期已接收到数据包所需的时间;tn-t1表示在第N个包含PCR数据包到达前已过去的时间。df(n,pre)表示第N个包含PCR数据包到达前消耗完虚拟缓存中数据所需的时间。Among them, pcr 1 represents the ratio of the PCR in the first PCR data packet and 27MHz in the current sampling period; pcr n represents the ratio of the PCR in the Nth PCR data packet in the current sampling cycle to 27MHz; t n represents the current The arrival time of the Nth PCR data packet in the sampling period, and t1 represents the arrival time of the first PCR data packet in the current period. pcr n -pcr 1 indicates the time required to consume the data packets received in the current sampling period before the arrival of the Nth PCR data packet; t n -t 1 indicates the elapsed time before the arrival of the Nth PCR data packet time. df(n, pre) represents the time required to consume the data in the virtual cache before the Nth PCR packet arrives.

步骤122:根据每个包含PCR数据包的到达时间和每个包含PCR数据包的下一个包含PCR数据包中的PCR,确定在每个包含PCR数据包到达后消耗虚拟缓存中的数据包所需的第二时间。Step 122: Based on the arrival time of each PCR-containing data packet and the PCR in the next PCR-containing data packet of each PCR-containing data packet, determine the time required to consume the data packets in the virtual buffer after each PCR-containing data packet arrives the second time.

对于包含PCR数据包相应的第二时间,按照包含PCR数据包的到达顺序,依次根据每个包含PCR数据包到达时间和下一个包含PCR数据包中的PCR,计算每个包含PCR数据包到达被监控的网络节点后消耗其虚拟缓存中的数据包所需的时间,记为第二时间。For the second time corresponding to the PCR data packet, according to the arrival sequence of the PCR data packet, according to the arrival time of each PCR data packet and the PCR in the next PCR data packet, the arrival time of each PCR data packet is calculated. The time required for the monitored network node to consume the data packets in its virtual cache is recorded as the second time.

上述每个第二时间的具体确定方法可为:根据第N个包含PCR数据包的到达时间与第1个包含PCR数据包的到达时间的差值,和第N+1个包含PCR数据包中的PCR与第1个包含PCR数据包中的PCR的差值,确定在第N个包含PCR数据包到达后播放虚拟缓存中的数据包所需的第二时间。确定每个PCR数据包对应的第一时间,直至当前采样周期接收到的最后一个包含PCR数据包。The specific method for determining each of the above second times can be: according to the difference between the arrival time of the Nth PCR data packet and the arrival time of the first PCR data packet, and the N+1th PCR data packet. The difference between the PCR and the PCR in the first data packet containing the PCR determines the second time required to play the data packet in the virtual cache after the arrival of the Nth data packet containing the PCR. The first time corresponding to each PCR data packet is determined until the last PCR data packet received in the current sampling period.

第二时间的一种计算公式可为:df(n,post)=(pcrn+1-pcr1)-(tn-t1)(公式2)A calculation formula for the second time can be: df(n, post)=(pcr n+1 -pcr 1 )-(t n -t 1 ) (Formula 2)

pcrn+1表示当前采样周期内第N+1个包含PCR数据包中的PCR与27MHz的比值;pcrn+1-pcr1表示在第N个包含PCR数据包到达后消耗完当前采样周期已接收到数据包所需的时间。df(n,post)表示在第N个包含PCR数据包到达后消耗完虚拟缓存中数据包所需的时间。pcr n+1 means the ratio of PCR to 27MHz in the N+1th PCR data packet in the current sampling period; pcr n+1 -pcr 1 means that the current sampling period has been consumed after the arrival of the Nth PCR data packet The time it takes for a packet to be received. df(n, post) represents the time required to consume the data packets in the virtual cache after the arrival of the Nth PCR data packet.

步骤123:根据每个第一时间和每个第二时间,确定当前采样周期视频流的DF值。Step 123: Determine the DF value of the video stream in the current sampling period according to each first time and each second time.

从步骤121中确定的所有第一时间中找出其中的最小值,从步骤122中确定的所有第二时间中找出其中的最大值,根据第一时间中的最小值和第二时间中的最大值,确定当前采样周期的DF值。Find the minimum value among all the first times determined in step 121, and find the maximum value among all the second times determined in step 122, according to the minimum value in the first time and the value in the second time The maximum value determines the DF value for the current sampling period.

本实施例视频流延迟因素监测方法,计算一个采样周期内每个数据包到达网络节点前消耗虚拟缓存中数据包所需的第一时间,确定数据包到达网络节点前消耗虚拟缓存中数据包所需的最小时间;并计算该采样周期内每个数据包到达网络节点后消耗虚拟缓存中数据包所需的第二时间,确定数据包到达网络节点后消耗虚拟缓存中数据包所需的最大时间。通过上述最大时间与最小时间的差值,可反映在该采样周期内数据包到达前后消耗虚拟缓存中数据包所需的时间变化,从而可估算出网络节点在该采样周期内需缓冲多少时间的数据包才能平滑视频流抖动,即该采样周期内视频流的DF值。The video stream delay factor monitoring method of this embodiment calculates the first time required for each data packet to consume the data packet in the virtual buffer before reaching the network node in a sampling period, and determines the time required for the data packet in the virtual buffer to be consumed before the data packet arrives at the network node. and calculate the second time required to consume the data packets in the virtual cache after each data packet arrives at the network node in the sampling period, and determine the maximum time required to consume the data packets in the virtual cache after the data packet arrives at the network node . The difference between the above-mentioned maximum time and minimum time can reflect the change in the time required to consume data packets in the virtual cache before and after the arrival of the data packet in the sampling period, so that it can be estimated how much time the network node needs to buffer data in the sampling period Only packets can smooth the jitter of the video stream, that is, the DF value of the video stream within the sampling period.

图3为本发明视频流延迟因素监测方法实施例三流程图。本实施例将“根据包含PCR的数据包的到达时间和所述数据包中的PCR确定视频流的DF值”称为DF值估算方法,将“根据媒体流码率和每个数据包到达前后虚拟缓存中比特数确定视频流的DF值”称为DF值精算方法。本实施例在确定上一采样周期流入网络节点的视频流是否为传输正常的视频流时,根据上一采样周期计算DF值方法的不同而采用不同的预设阀值进行比较。FIG. 3 is a flow chart of Embodiment 3 of the method for monitoring delay factors of video streams according to the present invention. In this embodiment, "determining the DF value of the video stream according to the arrival time of the data packet containing the PCR and the PCR in the data packet" is called the DF value estimation method, and "according to the bit rate of the media stream and the time before and after the arrival of each data packet The number of bits in the virtual cache determines the DF value of the video stream" is called the DF value actuarial method. In this embodiment, when determining whether the video stream flowing into the network node in the previous sampling period is a video stream with normal transmission, different preset thresholds are used for comparison according to the method of calculating the DF value in the previous sampling period.

如图3所示,本实施例包括:As shown in Figure 3, this embodiment includes:

步骤31:上一采样周期是否根据DF值估算方法确定视频流DF值。如果是执行步骤32,否则执行步骤33。Step 31: Whether to determine the DF value of the video stream according to the DF value estimation method in the previous sampling period. If yes, go to step 32, otherwise go to step 33.

步骤32:确定上一采样周期视频流DF值是否小于估算预设阀值。如果不是执行步骤34,如果是执行步骤35。Step 32: Determine whether the DF value of the video stream in the previous sampling period is smaller than the estimated preset threshold. If not execute step 34, if yes execute step 35.

估算预设阀值为通过DF值估算方法确定视频流DF值后,判断视频流是否为传输正常的视频流的标准。The estimation preset threshold is a standard for judging whether the video stream is a normal video stream after the DF value of the video stream is determined by the DF value estimation method.

步骤33:确定上一采样周期视频流DF值是否小于精算预设阀值。如果不是执行步骤34,如果是执行步骤35。Step 33: Determine whether the DF value of the video stream in the previous sampling period is smaller than the actuarial preset threshold. If not execute step 34, if yes execute step 35.

精算预设阀值为通过DF值精算方法确定视频流DF值后,判断视频流是否为传输正常的视频流的标准。The actuarial preset threshold value is a standard for judging whether the video stream is a normal video stream after the DF value of the video stream is determined by the DF value actuarial method.

步骤34:采用DF值精算方法确定当前采样周期视频流DF值。Step 34: Use the DF value actuarial method to determine the DF value of the video stream in the current sampling period.

步骤35:接收当前采样周期进入网络节点的数据包。Step 35: Receive the data packets entering the network node in the current sampling period.

步骤36:判断该数据包是否包含PCR。如果包含PCR,则执行步骤37,否则返回步骤35执行。Step 36: Determine whether the data packet contains PCR. If PCR is included, execute step 37, otherwise return to step 35 for execution.

若该数据包头部包含PCR字段,则表明该数据包包含有PCR。If the header of the data packet contains a PCR field, it indicates that the data packet contains a PCR.

步骤37:计算该数据包到达网络节点前消耗完虚拟缓存中数据包所需的第一时间。Step 37: Calculate the first time required for the data packet to consume the data packet in the virtual cache before reaching the network node.

第一时间的计算参见公式1。For the calculation of the first time, refer to Formula 1.

步骤38:计算该数据包的上一个包含PCR数据包到达网络节点后消耗完虚拟缓存中数据包所需的第二时间。Step 38: Calculate the second time required for the data packet in the virtual cache to be consumed after the last PCR data packet of the data packet arrives at the network node.

当前接收到的数据包为第N个包含PCR数据包,则计算第N-1个包含PCR数据包到达网络节点后消耗完虚拟缓存中数据包所需的第二时间。计算第N-1个包含PCR数据包的第二时间的具体计算地采用公式2的变形,具体如:df(n-1,post)=(pcrn-pcr1)-(tn-1-t1)。pcrn-1表示当前采样周期内第N-1个包含PCR数据包中的PCR与27MHz的比值;pcrn-1-pcr1表示在第N-1个包含PCR数据包到达后消耗完当前采样周期已接收到数据包所需的时间。df(n-1,post)表示在第N-1个包含PCR数据包到达后消耗完虚拟缓存中数据包所需的时间。The currently received data packet is the Nth data packet containing the PCR, and the second time required for the data packet in the virtual cache to be consumed after the N-1th data packet containing the PCR arrives at the network node is calculated. The specific calculation method of calculating the second time of the N-1th packet containing PCR data adopts the deformation of formula 2, specifically: df(n-1, post)=(pcr n -pcr 1 )-(t n-1- t 1 ). pcr n-1 indicates the ratio of PCR to 27MHz in the N-1th PCR data packet in the current sampling period; pcr n-1 -pcr 1 indicates that the current sampling is consumed after the arrival of the N-1th PCR data packet Period The time it takes for a packet to be received. df(n-1, post) represents the time required to consume the data packets in the virtual cache after the arrival of the N-1 PCR data packet.

步骤39:当前采样周期是否结束。如果没有结束返回步骤35执行,否则执行步骤310。Step 39: Whether the current sampling period ends. If it is not finished, return to step 35 for execution, otherwise, execute step 310.

步骤310:确定所有第一时间中的最小值和所有第二时间中最大值,并计算当前采样周期视频流的DF值。之后进入下一个采样周期。Step 310: Determine the minimum value at all first times and the maximum value at all second times, and calculate the DF value of the video stream in the current sampling period. Then enter the next sampling period.

从所有df(n,post)中找出最大值max(dfpost),从df(n,pre)中找出最小值min(dfpre),确定当前采样周期的DF值。DF值具体确定方法为:Find the maximum value max(df post ) from all df(n, post), find the minimum value min(df pre ) from df(n, pre), and determine the DF value of the current sampling period. The specific method for determining the DF value is:

DF=max(dfpost)-min(dfpre)               (公式3)DF=max(df post )-min(df pre ) (Formula 3)

本实施例视频流延迟因素监测方法,在确定上一采样周期视频流为传输正常的视频流时,采用只监测包括PCR数据包的估算方法计算下一采样周期视频流的DF值;在确定上一采样周期视频流为传输异常的视频流时,采用监测所有数据包的精算方法计算下一采样周期视频流的DF值。在判断上一采样周期视频流是否为传输正常的视频流时,根据上一采样周期计算DF值方法的不同而采用不同的预设阀值,从而提高了判断结果的可靠性。本实施例中,在一个采样周期内只需缓存第1个包含PCR数据包的到达时间,而不需要存储所有数据包的到达时间和字节数。因此降低了监控视频流DF值过程中对存储空间的需求。In the method for monitoring video stream delay factors in this embodiment, when it is determined that the video stream in the previous sampling period is a normal video stream, the DF value of the video stream in the next sampling period is calculated by using an estimation method that only monitors PCR data packets; When the video stream in one sampling period is an abnormal video stream, the DF value of the video stream in the next sampling period is calculated by using the actuarial method of monitoring all data packets. When judging whether the video stream in the previous sampling period is a normal video stream, different preset thresholds are used according to the method of calculating the DF value in the previous sampling period, thereby improving the reliability of the judgment result. In this embodiment, it is only necessary to cache the arrival time of the first data packet containing PCR within a sampling period, instead of storing the arrival time and the number of bytes of all data packets. Therefore, the requirement for storage space in the process of monitoring the DF value of the video stream is reduced.

图4为本发明视频流延迟因素监控装置实施例一的结构示意图。如图4所示,包括:流分配模块41和估算模块42;FIG. 4 is a schematic structural diagram of Embodiment 1 of an apparatus for monitoring delay factors of video streams according to the present invention. As shown in FIG. 4 , it includes: a flow allocation module 41 and an estimation module 42;

流分配模块41,用于确定上一采样周期视频流的延迟因素是否小于预设阀值,上一采样周期视频流的延迟因素小于预设阀值时,通知估算模块42确定当前采样周期视频流的延迟因素;The stream distribution module 41 is used to determine whether the delay factor of the video stream in the previous sampling period is less than the preset threshold value, and when the delay factor of the video stream in the previous sampling period is less than the preset threshold value, notify the estimation module 42 to determine the current sampling period video stream delay factor;

估算模块42,用于接收到流分配模块的通知后,根据当前采样周期视频流中包含PCR数据包的到达时间和数据包中的PCR,确定当前采样周期视频流的延迟因素。进一步,如图5所示,本实施例还包括精算模块43;The estimation module 42 is configured to determine the delay factor of the video stream of the current sampling period according to the arrival time of the PCR data packet contained in the video stream of the current sampling period and the PCR in the data packet after receiving the notification from the stream allocation module. Further, as shown in FIG. 5 , this embodiment also includes an actuarial module 43;

流分配模块41,还用于上一采样周期视频流的延迟因素大于预设阀值时,通知精算模块43确定当前采样周期视频流的延迟因素;The stream allocation module 41 is also used to notify the actuarial module 43 to determine the delay factor of the video stream of the current sampling period when the delay factor of the video stream of the previous sampling period is greater than the preset threshold;

精算模块43,用于接收到流分配模块的通知后,根据当前周期的媒体流码率和当前采样周期每个数据包到达前后虚拟缓存中比特数,确定当前采样周期视频流的延迟因素。The actuarial module 43 is used to determine the delay factor of the video stream in the current sampling period according to the bit rate of the media stream in the current period and the number of bits in the virtual buffer before and after the arrival of each data packet in the current sampling period after receiving the notification from the stream distribution module.

上述各模块的具体操作内容参见图1对应实施例的描述,在此不再赘述。For the specific operation content of the above modules, refer to the description of the corresponding embodiment in FIG. 1 , which will not be repeated here.

本实施例视频流延迟因素监控装置,流分配模块41通过上一采样周期的DF值确定上一采样周期的视频流是否为传输正常的视频流,若DF值小于预设阀值,通知估算模块42确定当前采样周期视频流的延迟因素。估算模块42在当前采样周期只根据包含PCR的数据包的到达时间和其中的PCR确定DF值,而不需要不包含PCR的数据包的到达时间和字节数。因此,本实施例在确定上一采样周期的DF值小于预设阀值后,在当前采样周期不需要存储所有数据包的到达时间和字节数,从而降低了对存储空间的需求。另外,在上一采样周期视频流的DF值大于等于预设阀值时,流分配模块41通知精算模块43监控当前周期内的所有数据包。根据当前周期的视频流码率和当前采样周期每个数据包到达前后虚拟缓存区的字节数,对当前采样周期视频流的DF值进行精确计算,从而精确判断当前采样周期视频流是否为传输正常的视频流。In the video stream delay factor monitoring device of this embodiment, the stream distribution module 41 determines whether the video stream of the previous sampling period is a normal video stream through the DF value of the previous sampling period, and if the DF value is less than the preset threshold value, the estimation module is notified 42 Determine the delay factor of the video stream for the current sampling period. In the current sampling period, the estimation module 42 only determines the DF value according to the arrival time of the data packets containing the PCR and the PCRs therein, and does not need the arrival time and the number of bytes of the data packets not containing the PCR. Therefore, in this embodiment, after it is determined that the DF value in the previous sampling period is less than the preset threshold value, it is not necessary to store the arrival time and the number of bytes of all data packets in the current sampling period, thereby reducing the demand for storage space. In addition, when the DF value of the video stream in the previous sampling period is greater than or equal to the preset threshold, the stream allocation module 41 notifies the actuarial module 43 to monitor all data packets in the current period. According to the bit rate of the video stream in the current period and the number of bytes in the virtual buffer area before and after the arrival of each data packet in the current sampling period, the DF value of the video stream in the current sampling period is accurately calculated, so as to accurately determine whether the video stream in the current sampling period is transmitted normal video stream.

图6为本发明视频流延迟因素监控装置实施例三的结构示意图。如图6估算模块42包括:第一时间确定单元421、第二时间确定单元422和延迟因素确定单元423;FIG. 6 is a schematic structural diagram of Embodiment 3 of an apparatus for monitoring delay factors of video streams according to the present invention. As shown in Figure 6, the estimation module 42 includes: a first time determination unit 421, a second time determination unit 422 and a delay factor determination unit 423;

第一时间确定单元421,用于根据当前采样周期每个包含PCR数据包的到达时间和每个数据包中的PCR,确定在每个包含PCR数据包到达前消耗虚拟缓存中的数据包所需的第一时间。The first time determination unit 421 is configured to determine the time required to consume the data packets in the virtual cache before each PCR data packet arrives according to the arrival time of each PCR data packet and the PCR in each data packet in the current sampling period. the first time.

第一时间确定单元421,具体用于根据每个包含PCR数据包的到达时间与第一个包含PCR数据包的到达时间的差值,和每个包含PCR数据包中的PCR与第一个包含PCR数据包的PCR的差值,确定在每个包含PCR数据包到达前消耗虚拟缓存中的数据包所需的第一时间。The first time determining unit 421 is specifically configured to use the difference between the arrival time of each PCR data packet and the arrival time of the first PCR data packet, and the difference between the PCR in each PCR data packet and the first PCR data packet. The delta of the PCRs of the PCR packets determines the first time required to consume the packets in the virtual buffer before each packet containing the PCR arrives.

第二时间确定单元422,用于根据每个包含PCR的数据包的到达时间和该数据包的下一个包含PCR的数据包中的PCR,确定在每个包含PCR的数据包到达后消耗虚拟缓存中的数据包所需的第二时间。The second time determination unit 422 is configured to determine to consume the virtual buffer after each data packet containing the PCR arrives according to the arrival time of each data packet containing the PCR and the PCR in the next data packet containing the PCR of the data packet The second time required for the packets in .

第二时间确定单元422,具体用于根据每个包含PCR数据包的到达时间与第一个包含PCR数据包的到达时间的差值,和每个包含PCR数据包的下一个包含PCR数据包中的PCR与第一个包含PCR数据包中的PCR的差值,确定在每个包含PCR数据包到达后消耗虚拟缓存中的数据包所需的第二时间。The second time determining unit 422 is specifically configured to, according to the difference between the arrival time of each PCR data packet and the arrival time of the first PCR data packet, and the next PCR data packet of each PCR data packet. The difference between the PCR and the PCR in the first PCR-containing data packet determines the second time required to consume the data packets in the virtual buffer after each PCR-containing data packet arrives.

延迟因素确定单元423,用于根据第一时间中的最小值和第二时间中的最大值的差值,确定当前采样周期视频流的延迟因素。The delay factor determination unit 423 is configured to determine the delay factor of the video stream in the current sampling period according to the difference between the minimum value at the first time and the maximum value at the second time.

上述各模块的具体操作内容参见图2或图3对应实施例的描述,在此不再赘述。For the specific operation content of the above modules, refer to the description of the corresponding embodiment in FIG. 2 or FIG. 3 , and details are not repeated here.

本实施例视频流延迟因素监测装置,第一时间确定单元421计算一个采样周期内每个数据包到达网络节点前消耗虚拟缓存中数据包所需的第一时间,从而可确定该采样周期内消耗流出网络节点的数据包所需的最小时间。第二时间确定单元422计算该采样周期内每个数据包到达网络节点后消耗虚拟缓存中数据包所需的第二时间,从而可确定该采样周期内消耗流入网络节点的数据包所需的最大时间。延迟因素确定单元423根据该采样周期内上述最大时间与最小时间的差值,可估算出网络节点在该采样周期内需虚拟缓存多少时间的数据包才能平滑视频流抖动,从而代表了该采样周期内视频流的DF值。In the device for monitoring video stream delay factors in this embodiment, the first time determination unit 421 calculates the first time required for each data packet to consume data packets in the virtual cache before reaching the network node in a sampling period, so as to determine the time consumed in the sampling period. The minimum time required for a packet to flow out of a network node. The second time determination unit 422 calculates the second time required to consume the data packets in the virtual cache after each data packet arrives at the network node in the sampling period, so as to determine the maximum required time for consuming the data packets flowing into the network node in the sampling period. time. The delay factor determining unit 423 can estimate how much data packets need to be virtual buffered by the network node in the sampling period to smooth the jitter of the video stream according to the difference between the above-mentioned maximum time and the minimum time in the sampling period, thus representing the time in the sampling period The DF value of the video stream.

图7为本发明视频流延迟因素监控装置实施例四的结构示意图。如图7所示,流分配模块41包括:第一流分配单元411和第二流分配单元412。FIG. 7 is a schematic structural diagram of Embodiment 4 of an apparatus for monitoring delay factors of video streams according to the present invention. As shown in FIG. 7 , the flow distribution module 41 includes: a first flow distribution unit 411 and a second flow distribution unit 412 .

第一流分配单元411,用于在上一采样周期估算模块42确定上一采样周期视频流的延迟因素时,确定上一采样周期视频流的延迟因素是否小于估算预设阀值;并在上一采样周期视频流的延迟因素小于估算预设阀值时,通知估算模块确定当前采样周期视频流的延迟因素;在上一采样周期视频流的延迟因素大于等于估算预设阀值时,通知所述精算模块确定当前采样周期视频流的延迟因素。The first stream allocation unit 411 is used to determine whether the delay factor of the video stream of the previous sampling period is less than the estimated preset threshold value when the last sampling period estimating module 42 determines the delay factor of the video stream of the previous sampling period; and When the delay factor of the sampling period video stream is less than the estimated preset threshold, the notification estimation module determines the delay factor of the current sampling period video stream; when the delay factor of the video stream of the previous sampling period is greater than or equal to the estimated preset threshold, the notification said The actuarial module determines the delay factor of the video stream for the current sampling period.

第二流分配单元412,用于在上一采样周期精算模块43确定上一采样周期视频流的延迟因素时,确定上一采样周期视频流的延迟因素是否小于精算预设阀值;并在上一采样周期视频流的延迟因素小于精算预设阀值时,通知估算模块确定当前采样周期视频流的延迟因素;在上一采样周期视频流的延迟因素大于等于精算预设阀值时,通知所述精算模块确定当前采样周期视频流的延迟因素。The second stream allocation unit 412 is used to determine whether the delay factor of the video stream of the previous sampling period is less than the actuarial preset threshold when the last sampling period actuarial module 43 determines the delay factor of the video stream of the previous sampling period; and When the delay factor of the video stream in a sampling period is less than the actuarial preset threshold value, notify the estimation module to determine the delay factor of the video stream in the current sampling period; when the delay factor of the video stream in the previous sampling period is greater than or equal to the actuarial preset threshold value, notify the The actuarial module determines the delay factor of the video stream for the current sampling period.

上述各模块的具体操作内容参见图3对应实施例的描述,在此不再赘述。Refer to the description of the corresponding embodiment in FIG. 3 for the specific operation content of the above modules, and details are not repeated here.

本实施例视频流延迟因素监控装置。在判断上一采样周期视频流是否为传输正常的视频流时,根据上一采样周期计算DF值方法的不同而采用不同的预设阀值,从而提高了判断结果的可靠性。The device for monitoring delay factors of video streams in this embodiment. When judging whether the video stream in the previous sampling period is a normal video stream, different preset thresholds are used according to the method of calculating the DF value in the previous sampling period, thereby improving the reliability of the judgment result.

本领域普通技术人员可以理解:实现上述方法实施例的全部或部分步骤可以通过程序指令相关的硬件来完成,前述的程序可以存储于一计算机可读取存储介质中,该程序在执行时,执行包括上述方法实施例的步骤;而前述的存储介质包括:ROM、RAM、磁碟或者光盘等各种可以存储程序代码的介质。Those of ordinary skill in the art can understand that all or part of the steps for realizing the above-mentioned method embodiments can be completed by hardware related to program instructions, and the aforementioned program can be stored in a computer-readable storage medium. When the program is executed, the It includes the steps of the above method embodiments; and the aforementioned storage medium includes: ROM, RAM, magnetic disk or optical disk and other various media that can store program codes.

最后应说明的是:以上实施例仅用以说明本发明的技术方案,而非对其限制;尽管参照前述实施例对本发明进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本发明各实施例技术方案的精神和范围。Finally, it should be noted that: the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that: it can still be Modifications are made to the technical solutions described in the foregoing embodiments, or equivalent replacements are made to some of the technical features; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the various embodiments of the present invention.

Claims (10)

1.一种视频流延迟因素监测方法,其特征在于,包括:1. A video stream delay factor monitoring method, is characterized in that, comprising: 确定上一采样周期视频流的延迟因素是否小于预设阀值;Determine whether the delay factor of the video stream in the previous sampling period is less than a preset threshold; 上一采样周期视频流的延迟因素小于预设阀值时,根据当前采样周期视频流中包含节目时钟参考数据包的到达时间和所述数据包中的节目时钟参考,确定当前采样周期视频流的延迟因素。When the delay factor of the video stream in the previous sampling period is less than the preset threshold value, according to the arrival time of the program clock reference data packet contained in the video stream of the current sampling period and the program clock reference in the data packet, determine the time delay of the video stream in the current sampling period delay factor. 2.根据权利要求1所述的视频流延迟因素监测方法,其特征在于,还包括:2. The video stream delay factor monitoring method according to claim 1, is characterized in that, also comprises: 上一采样周期视频流的延迟因素大于等于预设阀值时,根据当前周期的媒体流码率和当前采样周期每个数据包到达前后虚拟缓存中比特数,确定当前采样周期视频流的延迟因素。When the delay factor of the video stream in the previous sampling period is greater than or equal to the preset threshold, the delay factor of the video stream in the current sampling period is determined according to the bit rate of the media stream in the current sampling period and the number of bits in the virtual buffer before and after the arrival of each data packet in the current sampling period . 3.根据权利要求2所述的视频流延迟因素监测方法,其特征在于,所述确定上一采样周期视频流的延迟因素是否小于预设阀值包括:3. The video stream delay factor monitoring method according to claim 2, wherein determining whether the delay factor of the video stream in the last sampling period is less than a preset threshold comprises: 在上一采样周期根据包含节目时钟参考的数据包的到达时间和所述数据包中的节目时钟参考确定上一采样周期视频流的延迟因素时,确定上一采样周期视频流的延迟因素是否小于估算预设阀值;When determining the delay factor of the video stream in the previous sampling period based on the arrival time of the data packet containing the program clock reference and the program clock reference in the data packet in the previous sampling period, determine whether the delay factor of the video stream in the previous sampling period is less than Estimate the preset threshold; 在上一采样周期根据媒体流码率和上一采样周期每个数据包到达前后虚拟缓存中比特数确定上一采样周期视频流的延迟因素时,确定上一采样周期视频流的延迟因素是否小于精算预设阀值。When determining the delay factor of the video stream in the previous sampling period according to the bit rate of the media stream and the number of bits in the virtual buffer before and after the arrival of each data packet in the previous sampling period, determine whether the delay factor of the video stream in the previous sampling period is less than Actuarial preset threshold. 4.根据权利要求1、2或3所述的视频流延迟因素监测方法,其特征在于,所述根据当前采样周期视频流中包含节目时钟参考的数据包的到达时间和所述数据包中的节目时钟参考,确定当前采样周期视频流的延迟因素,包括:4. The video stream delay factor monitoring method according to claim 1, 2 or 3, characterized in that, according to the arrival time of the data packet containing the program clock reference in the video stream according to the current sampling period and the time of arrival in the data packet Program clock reference, which determines the delay factors of the video stream in the current sample period, including: 根据当前采样周期每个所述包含节目时钟参考的数据包的到达时间和每个所述数据包中的节目时钟参考,确定在每个所述包含节目时钟参考数据包到达前消耗虚拟缓存中的数据包所需的第一时间;According to the arrival time of each of the data packets containing the program clock reference and the program clock reference in each of the data packets in the current sampling period, it is determined to consume the virtual buffer before each of the data packets containing the program clock reference arrives. The first time the packet is required; 根据每个所述包含节目时钟参考的数据包的到达时间和所述数据包的下一个包含节目时钟参考的数据包中的节目时钟参考,确定在每个所述包含节目时钟参考的数据包到达后消耗虚拟缓存中的数据包所需的第二时间;According to the arrival time of each of the data packets containing the program clock reference and the program clock reference in the next data packet containing the program clock reference of the data packet, it is determined when each of the data packets containing the program clock reference arrives The second time required to consume packets in the virtual cache afterward; 根据每个所述第一时间和每个所述第二时间,确定当前采样周期视频流的延迟因素。According to each of the first times and each of the second times, the delay factor of the video stream in the current sampling period is determined. 5.根据权利要求4所述的视频流延迟因素监测方法,其特征在于:5. video stream delay factor monitoring method according to claim 4, is characterized in that: 所述根据当前采样周期每个所述包含节目时钟参考的数据包的到达时间和每个所述数据包中的节目时钟参考,确定在每个所述包含节目时钟参考的数据包到达前消耗虚拟缓存中的数据包所需的第一时间,具体为:According to the arrival time of each of the data packets containing the program clock reference and the program clock reference in each of the data packets in the current sampling period, it is determined that before the arrival of each of the data packets containing the program clock reference, the virtual The first time a packet in the cache is required, specifically: 根据每个包含节目时钟参考数据包的到达时间与第一个包含节目时钟参考数据包的到达时间的差值,和每个包含节目时钟参考数据包中的节目时钟参考与第一个包含节目时钟参考数据包的节目时钟参考的差值,确定在每个包含节目时钟参考数据包到达前消耗虚拟缓存中的数据包所需的第一时间;Based on the difference between the arrival time of each PCR-containing packet and the arrival time of the first PCR-containing packet, and the difference between the time of arrival of each PCR-containing packet determining the first time required to consume the data packets in the virtual buffer before each data packet containing the program clock reference arrives; 所述根据每个包含节目时钟参考的数据包的到达时间和所述数据包的下一个包含节目时钟参考的数据包中的节目时钟参考,确定在每个所述包含节目时钟参考的数据包到达后消耗虚拟缓存中的数据包所需的第二时间,具体为:According to the arrival time of each data packet containing the program clock reference and the program clock reference in the next data packet containing the program clock reference of the data packet, it is determined when each of the data packets containing the program clock reference arrives The second time required to consume the packets in the virtual cache afterward, specifically: 根据每个包含节目时钟参考数据包的到达时间与第一个包含节目时钟参考数据包的到达时间的差值,和每个包含节目时钟参考数据包的下一个包含节目时钟参考数据包中的节目时钟参考与第一个包含节目时钟参考数据包中的节目时钟参考的差值,确定在每个包含节目时钟参考数据包到达后消耗虚拟缓存中的数据包所需的第二时间;Based on the difference between the arrival time of each PCRD-containing packet and the arrival time of the first PCRD-containing packet, and the program in each next PCRD-containing packet the difference between the clock reference and the program clock reference in the first packet containing the program clock reference, determining a second time required to consume the packets in the virtual buffer after each packet containing the program clock reference arrives; 根据每个所述第一时间和每个所述第二时间,确定当前采样周期视频流的延迟因素,具体为:According to each of the first times and each of the second times, determine the delay factor of the current sampling period video stream, specifically: 根据所述第一时间中的最小值和所述第二时间中的最大值的差值,确定当前采样周期视频流的延迟因素。According to the difference between the minimum value at the first time and the maximum value at the second time, determine the delay factor of the video stream in the current sampling period. 6.一种视频流延迟因素监控装置,其特征在于,包括:流分配模块和估算模块;6. A device for monitoring video stream delay factors, comprising: a stream distribution module and an estimation module; 所述流分配模块,用于确定上一采样周期视频流的延迟因素是否小于预设阀值,上一采样周期视频流的延迟因素小于预设阀值时,通知所述估算模块确定当前采样周期视频流的延迟因素;The stream allocation module is used to determine whether the delay factor of the video stream in the previous sampling period is less than a preset threshold, and when the delay factor of the video stream in the previous sampling period is less than the preset threshold, notify the estimation module to determine the current sampling period Latency factors for video streams; 所述估算模块,用于接收到所述流分配模块的通知后,根据当前采样周期视频流中包含节目时钟参考数据包的到达时间和所述数据包中的节目时钟参考,确定当前采样周期视频流的延迟因素。The estimation module is configured to, after receiving the notification from the stream allocation module, determine the current sampling period video stream according to the arrival time of the program clock reference data packet contained in the current sampling period video stream and the program clock reference in the data packet. Stream delay factor. 7.根据权利要求6所述的视频流延迟因素监控装置,其特征在于,还包括:精算模块;7. The video stream delay factor monitoring device according to claim 6, further comprising: an actuarial module; 所述流分配模块,还用于上一采样周期视频流的延迟因素大于预设阀值时,通知所述精算模块确定当前采样周期视频流的延迟因素;The stream allocation module is also used to notify the actuarial module to determine the delay factor of the current sampling period video stream when the delay factor of the video stream in the previous sampling period is greater than a preset threshold; 所述精算模块,用于接收到所述流分配模块的通知后,根据当前周期的媒体流码率和当前采样周期每个数据包到达前后虚拟缓存中比特数、确定当前周期视频流的延迟因素。The actuarial module is configured to determine the delay factor of the video stream in the current period according to the bit rate of the media stream in the current period and the number of bits in the virtual buffer before and after the arrival of each data packet in the current sampling period after receiving the notification from the stream allocation module . 8.根据权利要求7所述的视频流延迟因素监控装置,其特征在于,所述流分配模块包括:8. The video stream delay factor monitoring device according to claim 7, wherein the stream distribution module comprises: 第一流分配单元,用于在上一采样周期根据所述估算模块确定上一采样周期视频流的延迟因素时,确定上一采样周期视频流的延迟因素是否小于估算预设阀值;并在上一采样周期视频流的延迟因素小于估算预设阀值时,通知所述估算模块确定当前采样周期视频流的延迟因素;在上一采样周期视频流的延迟因素大于等于估算预设阀值时,通知所述精算模块确定当前采样周期视频流的延迟因素;The first stream allocation unit is used to determine whether the delay factor of the video stream in the previous sampling period is less than the estimated preset threshold value when determining the delay factor of the video stream in the previous sampling period according to the estimation module in the previous sampling period; and When the delay factor of the video stream of a sampling period is less than the estimated preset threshold value, the estimation module is notified to determine the delay factor of the video stream of the current sampling period; when the delay factor of the video stream of the previous sampling period is greater than or equal to the estimated preset threshold value, Informing the actuarial module to determine the delay factor of the current sampling period video stream; 第二流分配单元,用于在上一采样周期根据所述精算模块确定上一采样周期视频流的延迟因素时,确定上一采样周期视频流的延迟因素是否小于精算预设阀值;并在上一采样周期视频流的延迟因素小于精算预设阀值时,通知所述估算模块确定当前采样周期视频流的延迟因素;在上一采样周期视频流的延迟因素大于等于精算预设阀值时,通知所述精算模块确定当前采样周期视频流的延迟因素。The second stream allocation unit is used to determine whether the delay factor of the video stream in the previous sampling period is less than the actuarial preset threshold value when determining the delay factor of the video stream in the previous sampling period according to the actuarial module in the previous sampling period; and When the delay factor of the video stream in the previous sampling period is less than the actuarial preset threshold value, notify the estimation module to determine the delay factor of the video stream in the current sampling period; when the delay factor of the video stream in the previous sampling period is greater than or equal to the actuarial preset threshold value , notifying the actuarial module to determine the delay factor of the video stream in the current sampling period. 9.根据权利要求6、7或8所述的视频流延迟因素监控装置,其特征在于,所述估算模块,包括:第一时间确定单元、第二时间确定单元和延迟因素确定单元;9. The video stream delay factor monitoring device according to claim 6, 7 or 8, wherein the estimation module includes: a first time determination unit, a second time determination unit and a delay factor determination unit; 所述第一时间确定单元,用于根据当前采样周期每个所述包含节目时钟参考数据包的到达时间和每个所述数据包中的节目时钟参考,确定在每个所述包含节目时钟参考数据包到达前消耗虚拟缓存中的数据包所需的第一时间;The first time determination unit is configured to determine, according to the arrival time of each of the data packets containing the program clock reference in the current sampling period and the program clock reference in each of the data packets, to determine when each of the data packets containing the program clock reference The first time required to consume a packet in the virtual cache before the packet arrives; 所述第二时间确定单元,用于根据每个包含节目时钟参考的数据包的到达时间和所述数据包的下一个包含节目时钟参考的数据包中的节目时钟参考,确定在每个包含节目时钟参考的数据包到达后消耗虚拟缓存中的数据包所需的第二时间;The second time determination unit is configured to determine, according to the arrival time of each data packet containing the program clock reference and the program clock reference in the next data packet containing the program clock reference of the data packet, to determine the the second time required to consume the packet in the virtual buffer after the arrival of the packet referenced by the clock; 所述延迟因素确定单元,用于根据所述第一时间中的最小值和所述第二时间中的最大值的差值,确定当前采样周期视频流的延迟因素。The delay factor determination unit is configured to determine the delay factor of the video stream in the current sampling period according to the difference between the minimum value at the first time and the maximum value at the second time. 10.根据权利要求9所述的视频流延迟因素监控装置,其特征在于:10. The video stream delay factor monitoring device according to claim 9, characterized in that: 所述第一时间确定单元,具体用于根据每个包含节目时钟参考数据包的到达时间与第一个包含节目时钟参考数据包的到达时间的差值,和每个包含节目时钟参考数据包中的节目时钟参考与第一个包含节目时钟参考数据包的节目时钟参考的差值,确定在每个包含节目时钟参考数据包到达前消耗虚拟缓存中的数据包所需的第一时间;The first time determination unit is specifically configured to use the difference between the arrival time of each packet containing the program clock reference data and the arrival time of the first packet containing the program clock reference data, and the time difference in each packet containing the program clock reference data. The difference between the program clock reference of the program clock reference and the first program clock reference containing the program clock reference data packet determines the first time required to consume the data packets in the virtual buffer before each packet containing the program clock reference data arrives; 所述第二时间确定单元,具体用于根据每个包含节目时钟参考数据包的到达时间与第一个包含节目时钟参考数据包的到达时间的差值,和每个包含节目时钟参考数据包的下一个包含节目时钟参考数据包中的节目时钟参考与第一个包含节目时钟参考数据包中的节目时钟参考的差值,确定在每个包含节目时钟参考数据包到达后消耗虚拟缓存中的数据包所需的第二时间。The second time determination unit is specifically configured to use the difference between the arrival time of each packet containing the program clock reference data and the arrival time of the first packet containing the program clock reference data, and the time difference of each packet containing the program clock reference data. The difference between the program clock reference in the next program clock reference data packet and the program clock reference in the first program clock reference data packet to determine the consumption of data in the virtual buffer after each program clock reference data packet arrives The second time the package takes.
CN2010105744768A 2010-11-30 2010-11-30 Video stream delay factor monitoring method and video stream delay factor monitoring device Pending CN102143377A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN2010105744768A CN102143377A (en) 2010-11-30 2010-11-30 Video stream delay factor monitoring method and video stream delay factor monitoring device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2010105744768A CN102143377A (en) 2010-11-30 2010-11-30 Video stream delay factor monitoring method and video stream delay factor monitoring device

Publications (1)

Publication Number Publication Date
CN102143377A true CN102143377A (en) 2011-08-03

Family

ID=44410558

Family Applications (1)

Application Number Title Priority Date Filing Date
CN2010105744768A Pending CN102143377A (en) 2010-11-30 2010-11-30 Video stream delay factor monitoring method and video stream delay factor monitoring device

Country Status (1)

Country Link
CN (1) CN102143377A (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104486688A (en) * 2014-12-31 2015-04-01 深圳市华宝电子科技有限公司 Vehicle-mounted video transmitting method and device
CN106303503A (en) * 2015-05-25 2017-01-04 德科仕通信(上海)有限公司 A kind of method judging MPEG2-TS VBR code stream quality
CN106331847A (en) * 2015-07-06 2017-01-11 成都鼎桥通信技术有限公司 Audio and video playing method and device
CN109005403A (en) * 2018-07-06 2018-12-14 烽火通信科技股份有限公司 The monitoring method and system of MPEG video transmission quality
CN105491403B (en) * 2014-10-10 2019-02-22 中国电信股份有限公司 For assessing the method and system of realtime video transmission quality
US11483217B2 (en) * 2016-10-31 2022-10-25 Accedian Networks Inc. Precise statistics computation for communication networks

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1155219A (en) * 1995-10-30 1997-07-23 三星电子株式会社 System clock recovery device in MPEG decoding system
US5883924A (en) * 1996-04-12 1999-03-16 Hewlett Packard Company Method and apparatus for PCR jitter measurement in an MPEG-2 transport stream using sliding window
CN1283924A (en) * 1993-05-13 2001-02-14 Rca.汤姆森许可公司 Apparatus and method for synchronizing compressed video signal receiving systems
JP2002135262A (en) * 2000-10-23 2002-05-10 Matsushita Electric Ind Co Ltd Network monitoring system
CN101646099A (en) * 2009-08-28 2010-02-10 重庆重邮东电通信技术有限公司 Network television quality test method
CN101656892A (en) * 2009-09-01 2010-02-24 上海理想信息产业(集团)有限公司 IPTV tester merged to telecom operation and maintenance system and use method thereof
CN101682795A (en) * 2007-05-11 2010-03-24 特克特朗尼克公司 Stream analysis apparatus and stream analysis display method

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1283924A (en) * 1993-05-13 2001-02-14 Rca.汤姆森许可公司 Apparatus and method for synchronizing compressed video signal receiving systems
CN1155219A (en) * 1995-10-30 1997-07-23 三星电子株式会社 System clock recovery device in MPEG decoding system
US5883924A (en) * 1996-04-12 1999-03-16 Hewlett Packard Company Method and apparatus for PCR jitter measurement in an MPEG-2 transport stream using sliding window
JP2002135262A (en) * 2000-10-23 2002-05-10 Matsushita Electric Ind Co Ltd Network monitoring system
CN101682795A (en) * 2007-05-11 2010-03-24 特克特朗尼克公司 Stream analysis apparatus and stream analysis display method
CN101646099A (en) * 2009-08-28 2010-02-10 重庆重邮东电通信技术有限公司 Network television quality test method
CN101656892A (en) * 2009-09-01 2010-02-24 上海理想信息产业(集团)有限公司 IPTV tester merged to telecom operation and maintenance system and use method thereof

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
《视听界(广播电视技术)》 20060810 许卫民,等 浅论节目时钟参考(PCR)在数字电视传输流中的作用 , *

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105491403B (en) * 2014-10-10 2019-02-22 中国电信股份有限公司 For assessing the method and system of realtime video transmission quality
CN104486688A (en) * 2014-12-31 2015-04-01 深圳市华宝电子科技有限公司 Vehicle-mounted video transmitting method and device
CN106303503A (en) * 2015-05-25 2017-01-04 德科仕通信(上海)有限公司 A kind of method judging MPEG2-TS VBR code stream quality
CN106331847A (en) * 2015-07-06 2017-01-11 成都鼎桥通信技术有限公司 Audio and video playing method and device
CN106331847B (en) * 2015-07-06 2019-12-03 成都鼎桥通信技术有限公司 Audio and video playing method and apparatus
US11483217B2 (en) * 2016-10-31 2022-10-25 Accedian Networks Inc. Precise statistics computation for communication networks
CN109005403A (en) * 2018-07-06 2018-12-14 烽火通信科技股份有限公司 The monitoring method and system of MPEG video transmission quality

Similar Documents

Publication Publication Date Title
US20230171301A1 (en) Monitoring Network Conditions
JP5652971B2 (en) Adaptive streaming for digital content distribution
CN102118270B (en) A method and device for measuring user quality of experience (QoE)
CN103188236B (en) The appraisal procedure of media transmission quality and device
US10805196B2 (en) Packet loss and bandwidth coordination
CN102143377A (en) Video stream delay factor monitoring method and video stream delay factor monitoring device
CN102651821B (en) Method and device for evaluating quality of video
CN106487779A (en) bandwidth management
TW201019649A (en) Network system, adjusting method of data transmission rate and computer program procut thereof
CN103888381A (en) Device and method used for controlling jitter buffer
CN107911265B (en) A device for testing the maximum delay of AVB network traffic based on the CBS flow control mechanism
JP2013500634A (en) Adaptive streaming for digital content distribution
US10348627B2 (en) Estimating processor load using frame encoding times
CN101702676A (en) Data buffering process and device
CN1960315B (en) Streaming Media Dejitter Method
US10587518B2 (en) Identifying network conditions
CN103475906B (en) Measuring method and measurement apparatus for media stream
CN101702711B (en) Method and terminal for playing data
JP5643242B2 (en) Media player parameter estimation apparatus, method, and program
CN108390794B (en) Method and system for calculating packet loss rate of streaming media data
CN101369975A (en) A detection method and system for delayed packet loss
Chen et al. Study on relationship between network video packet loss and video quality
KR101636198B1 (en) Method for controlling traffic of video streaming in wireless communication, and receiver implementing the same
KR101293302B1 (en) Set-top box for checking qulity of multimedia broadcasting service and method thereof
CN103873306B (en) A kind of measure user Quality of experience QoE method and device

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C12 Rejection of a patent application after its publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20110803