Packet loss protection method and related equipment
By dynamically setting the cascade length and assisting redundant coding at the sending end, the problem of increased delay caused by inaccurate packet loss rate prediction is solved, and packet loss protection with low delay and high decoding success rate in real-time communication applications is achieved. , improving user experience.
Patent Information
- Application Number
- CN202310355801.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-03-22
- Publication Date
- 2024-09-24
AI Technical Summary
Existing packet loss protection technology has the problem of increasing latency when improving user experience. How to effectively prevent packet loss without increasing processing latency, especially in real-time video and audio communication applications, the packet loss rate Inaccurate prediction causes decoding failure.
By dynamically setting the cascade length of each packet at the sending end, and assisting redundant coding based on feedback information from the receiving end, a corresponding amount of joint data is obtained for joint encoding, ensuring that the processing delay is within the preset delay upper limit and improving decoding. success rate.
When the link packet loss rate cannot be accurately predicted, lower processing delay and higher decoding success rate are achieved, meeting the needs of delay-sensitive applications and improving user experience.
Smart Images

Figure CN118694476A
Abstract
Description
Technical Field
[0001] The embodiments of the present application relate to the field of communication technology, and in particular to a packet loss protection method and related equipment. Background Art
[0002] With the development of technology, many applications (such as real-time video communication applications and real-time audio communication applications) require lower and lower end-to-end latency. In the process of transmitting data packets from the sender to the receiver, there is a common problem of data packet loss. If no corresponding measures are taken, the receiver will not be able to correctly restore the original data (such as video and audio) after receiving the data packet with packet loss. Therefore, packet loss protection is very important. The existing packet loss protection technology has the problem of increasing latency. How to perform packet loss protection to improve user experience is an urgent problem to be solved. Summary of the invention
[0003] The embodiments of the present application provide a packet loss protection method and related equipment, which can avoid increasing the signal while overcoming the packet loss problem and improve the user experience.
[0004] A first aspect provides a packet loss protection method, which is applied to a sending end, and the method includes: obtaining first original data of a first group and obtaining a first cascade length corresponding to the first group, wherein the first cascade length is used to indicate the number of first joint data, the first joint data is data in other groups used for cascade encoding with the data of the first group, the first cascade length is greater than or equal to 0 and less than or equal to an upper limit value of the cascade length, the upper limit value of the cascade length is determined according to a preset upper limit value of a delay, and the preset upper limit value of the delay is related to the first original data; encoding according to the first cascade length and the first original data to obtain first coded data; and sending the first coded data and the first cascade length to a receiving end.
[0005] In an embodiment of the present application, when the transmitting end obtains the cascade length corresponding to each packet, the transmitting end determines the preset delay upper limit value according to the original data to be transmitted currently, and then determines the cascade length upper limit value according to the preset delay upper limit value, and then can be adjusted within the range of the cascade length upper limit value to obtain the cascade length of the packet pair. The cascade length corresponding to each packet is greater than or equal to 0 and less than or equal to the cascade length upper limit value, thereby ensuring that the processing delay of the packet data can be controlled within the preset delay upper limit value, and the processing delay of the packet data includes the delay required for joint encoding according to the cascade length corresponding to the packet and the delay required for decoding the encoded data after the joint encoding of the packet (the delay required for decoding includes the delay of waiting for the cascade data corresponding to the packet and the delay of performing the decoding operation), thereby meeting the processing delay requirements corresponding to the service type (or application or application type) to be transmitted, avoiding the increase of processing delay due to overcoming packet loss, and improving user experience.
[0006] In one possible implementation, obtaining the first cascade length corresponding to the first packet includes: obtaining feedback information sent by the receiving end, wherein the feedback information is used to indicate packet loss on a first link, and the first link is a link between the sending end and the receiving end; and obtaining the first cascade length corresponding to the first packet according to the feedback information.
[0007] In a possible implementation, the method further includes: the more serious the packet loss situation of the first link is, the closer the first cascade length is to the upper limit of the cascade length. In a possible implementation, obtaining the first cascade length corresponding to the first packet according to the feedback information includes: when it is determined according to the feedback information that the packet loss prediction is not underestimated, obtaining the first cascade length as 0; when it is determined according to the feedback information that the packet loss prediction is underestimated, obtaining the first cascade length according to the feedback information and the upper limit of the cascade length, and the first cascade length is greater than 0.
[0008] In one possible implementation, obtaining feedback information sent by the receiving end includes: determining k adjacent groups, where the adjacent group is a group adjacent to the first group among the groups sent by the sending end, and k is an integer greater than or equal to 2; for each adjacent group, obtaining feedback information of the adjacent group sent by the receiving end, where the feedback information includes a total packet loss length and a burst packet loss length.
[0009] In one possible implementation, the method further includes: obtaining a predicted packet loss length; for each adjacent group, obtaining a packet loss prediction of the adjacent group based on a total packet loss length corresponding to the adjacent group and the predicted packet loss length; and determining whether packet loss prediction underestimation occurs based on the packet loss prediction of each adjacent group.
[0010] In one possible implementation, obtaining the first cascade length according to the feedback information and the upper limit of the cascade length includes: determining a first coefficient according to the burst packet loss length of each adjacent group, wherein the first coefficient is greater than 0 and less than or equal to 1; and obtaining the first cascade length according to the first coefficient and the upper limit of the cascade length.
[0011] In a possible implementation, determining the first coefficient according to the burst packet loss length of each adjacent packet includes: obtaining a first coefficient function F, where the first coefficient function F is:
[0012]
[0013] Among them, k is the number of adjacent groups, α i is the smoothing coefficient of the i-th group combination, and The combination is a combination of two adjacent groups in k adjacent groups, b i is the burst packet loss length of adjacent packet i, r iis the number of coded packets of the adjacent group i; obtaining a smoothing coefficient and the number of coded packets; determining a first coefficient according to the smoothing coefficient, the number of coded packets, the burst packet loss length, and the first coefficient function F; then obtaining a first cascade length according to the first coefficient and the upper limit of the cascade length includes:
[0014]
[0015] Among them, C1 is the first cascade length, C max The upper limit of the cascade length.
[0016] In one possible implementation, the method further includes: obtaining a cascade length upper limit value based on that a decoding delay at the receiving end is less than or equal to a preset delay upper limit value, wherein the decoding delay at the receiving end includes a first delay and a waiting delay for waiting to receive joint data, wherein the first delay is a delay corresponding to a decoding operation on the joint data and original data of a preset group size, and the preset group size is consistent with the group size of the first group.
[0017] In a possible implementation, according to the decoding delay of the receiving end being less than or equal to the preset delay upper limit value, obtaining the cascade length upper limit value includes: obtaining a first formula according to the decoding delay of the receiving end being less than or equal to the preset delay upper limit value:
[0018] W(n+c)+(c*s) / b≤τ
[0019] Among them, W(n+c) is the first delay, n is the preset packet size, c is the size of the joint data, W is the empirical function, s is the size of a single data, b is the sending rate, and τ is the preset delay upper limit value; c that satisfies the maximum value in the first formula is used as the cascade length upper limit value.
[0020] In one possible implementation, encoding is performed according to the first cascade length and the first original data to obtain the first encoded data, including: encoding the first original data of the first group to obtain initial encoded data; when the first cascade length is 0, using the initial encoded data as the first encoded data; when the first cascade length is not 0, obtaining data in other groups according to the first cascade length, and using the obtained data in the other groups as the first joint data, and concatenating the initial encoded data and the first joint data to obtain the first encoded data, wherein the other groups are groups after the first group.
[0021] In a second aspect, a packet loss protection method is provided, which is applied to a receiving end, and the method includes: obtaining first coded data and a first concatenation length of a first group, wherein the first coded data is data obtained by the sending end after encoding according to the first concatenation length and the first original data of the first group, the first concatenation length is used to indicate the number of first joint data, the first joint data is data in other groups used for concatenation encoding with the data of the first group, the first concatenation length is greater than or equal to 0 and less than or equal to an upper limit value of the concatenation length, the upper limit value of the concatenation length is determined according to a preset delay upper limit value, and the preset delay upper limit value is related to the first original data; decoding the first coded data according to the first concatenation length to obtain first decoded data.
[0022] In one possible implementation, decoding the first encoded data according to the first cascade length includes: when the first cascade length is 0, decoding the first encoded data; when the first cascade length is not 0, obtaining corresponding first joint data from other groups according to the first cascade length, where the other groups are groups after the first group; decoding according to the first encoded data and the first joint data.
[0023] The third aspect provides a transmitting end, including: a first acquisition module, used to acquire the first original data of the first group; a control module, used to acquire the first cascade length corresponding to the first group, wherein the first cascade length is used to indicate the number of first joint data, the first joint data is data in other groups used for cascade encoding with the data of the first group, the first cascade length is greater than or equal to 0 and less than or equal to the upper limit of the cascade length, the upper limit of the cascade length is determined according to a preset delay upper limit, and the preset delay upper limit is related to the first original data; an encoding module, used to encode according to the first cascade length and the first original data to obtain first encoded data; a first transmission module, used to send the first encoded data and the first cascade length to the receiving end.
[0024] In one possible implementation, the control module is used to execute any of the above packet loss protection methods.
[0025] In one possible implementation, the encoding module is used to execute the above packet loss protection method.
[0026] In one possible implementation, the first transmission module is also used to obtain network status and feedback information, and transmit the feedback information to the control module; the sending end also includes: a packet loss prediction module, which is used to predict the packet loss rate according to the network status, and transmit the packet loss rate to the control module; the control module is also used to obtain a preset delay upper limit value, and update the cascade length corresponding to each group according to the packet loss rate, feedback information and the preset delay upper limit value.
[0027] The fourth aspect provides a receiving end, which includes: a second transmission module, used to obtain first encoded data and a first cascade length of a first group, wherein the first encoded data is data obtained by the transmitting end after encoding according to the first cascade length and the first original data of the first group, the first cascade length is used to indicate the number of first joint data, the first joint data is data in other groups used for cascade encoding with the data of the first group, the first cascade length is greater than or equal to 0 and less than or equal to the upper limit of the cascade length, the upper limit of the cascade length is determined according to a preset delay upper limit, and the preset delay upper limit is related to the first original data; a decoding module, used to decode the first encoded data according to the first cascade length to obtain first decoded data.
[0028] In one possible implementation, decoding the first encoded data according to the first cascade length includes: when the first cascade length is 0, decoding the first encoded data; when the first cascade length is not 0, obtaining corresponding first joint data from other groups according to the first cascade length, where the other groups are groups after the first group; decoding according to the first encoded data and the first joint data.
[0029] The fifth aspect provides a packet loss protection system, comprising a network, a sending end as any one of the above items, and a receiving end as above, wherein the sending end and the receiving end communicate through the network.
[0030] The sixth aspect provides an electronic device, including: a processor and a memory; the memory is used to store a computer program, the computer program includes program instructions; the processor is used to call the computer program to execute the above packet loss protection method.
[0031] The seventh aspect provides a chip system, which is applied to an electronic device, and the chip system includes an interface circuit and a processor; the interface circuit and the processor are interconnected through lines; the interface circuit is used to receive signals from the memory of the electronic device and send signals to the processor, and the signals include computer instructions stored in the memory; when the processor executes the computer instructions, the chip system executes the above packet loss protection method.
[0032] An eighth aspect provides a computer storage medium, including computer instructions. When the computer instructions are executed on an electronic device, the electronic device executes the above-mentioned packet loss protection method.
[0033] The ninth aspect provides a computer program product, which, when executed on a computer, enables the computer to execute the above-mentioned packet loss protection method.
[0034] The technical effects obtained by the above-mentioned second, third, fourth and fifth aspects are similar to the technical effects obtained by the corresponding technical means in the first aspect, and will not be repeated here.
[0035] The beneficial effects of the technical solution provided by this application include at least:
[0036] In the embodiment of the present application, by dynamically setting the cascade length corresponding to each group, a corresponding amount of data (joint data) is obtained from other groups according to the cascade length corresponding to the group, so as to perform joint coding based on the obtained joint data. When the cascade length corresponding to each group is dynamically set, the transmitting end obtains the feedback information sent by the receiving end, so as to assist the redundant coding based on the feedback information, so as to achieve packet loss protection on the next hop link (link) of the node with lower processing delay and higher decoding success rate in an environment where the link packet loss rate cannot be accurately predicted. BRIEF DESCRIPTION OF THE DRAWINGS
[0037] Figure 1 A schematic diagram of forward error correction coding provided in an embodiment of the present application.
[0038] Figure 2 (a) is a schematic diagram of group-independent encoding provided in an embodiment of the present application.
[0039] Figure 2 (b) is a schematic diagram of cascade coding provided in an embodiment of the present application.
[0040] Figure 3 A schematic diagram of the packet loss protection system structure provided in an embodiment of the present application.
[0041] Figure 4 A flowchart of a packet loss protection method provided in an embodiment of the present application.
[0042] Figure 5 A schematic flow chart of a method for obtaining an upper limit value of a cascade length provided in an embodiment of the present application.
[0043] Figure 6 A schematic flow chart of a method for obtaining a first cascade length corresponding to a first group provided in an embodiment of the present application.
[0044] Figure 7 A flowchart of a method for obtaining feedback information sent by a receiving end provided in an embodiment of the present application.
[0045] Figure 8 A schematic flow chart of a method for obtaining a first cascade length corresponding to a first group according to feedback information provided in an embodiment of the present application.
[0046] Fig. 9 A flowchart of a method for underestimating whether packet loss occurs at a transmitting end provided in an embodiment of the present application.
[0047] Fig.10A schematic flow chart of a method for obtaining a first cascade length according to feedback information and an upper limit of a cascade length provided in an embodiment of the present application.
[0048] Fig.11 A schematic flow chart of a method for determining a first coefficient according to burst packet loss lengths of respective adjacent packets provided in an embodiment of the present application.
[0049] Fig.12 A schematic flow chart of a method for encoding according to a first cascade length and first original data provided in an embodiment of the present application.
[0050] Fig.13 A flowchart of another packet loss protection method provided in an embodiment of the present application.
[0051] Fig.14 A schematic flow chart of a method for decoding first encoded data according to a first cascade length provided in an embodiment of the present application.
[0052] Fig.15 A flowchart of another packet loss protection method provided in an embodiment of the present application.
[0053] Fig.16 A flowchart of a decoding method provided in an embodiment of the present application.
[0054] Fig.17A A schematic diagram of the processing flow for a situation where packet loss prediction underestimation does not occur provided in an embodiment of the present application.
[0055] Fig. 17B A schematic diagram of the processing flow for the case where packet loss prediction is underestimated provided in an embodiment of the present application.
[0056] Fig.18 A schematic diagram of the decoding success rate effect provided for the implementation of this application.
[0057] Fig.19 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0058] In this article, the terms "comprises", "comprising" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device that includes a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of more restrictions, an element defined by the sentence "comprising a" does not exclude the presence of other identical elements in the process, method, article or device that includes the element.
[0059] In this application, "at least one" means one or more, and "more than one" means two or more than two. "And / or" describes the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone, where A and B can be singular or plural. The terms "first", "second", "third", "fourth", etc. (if any) in the specification, claims and drawings of this application are used to distinguish similar objects, rather than to describe a specific order or sequence.
[0060] In the embodiments of the present application, words such as "exemplary" or "for example" are used to indicate examples, illustrations or descriptions. Any embodiment or design described as "exemplary" or "for example" in the embodiments of the present application should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplary" or "for example" is intended to present related concepts in a specific way.
[0061] With the development of technology, many applications require lower and lower end-to-end latency. Represented by interactive applications and real-time live broadcast applications, such applications that want to achieve real-time communication (RTC) require end-to-end transmission latency of hundreds of milliseconds (usually 300ms), or even lower. In some embodiments, in actual transmission, network service providers build / rent cloud hosts to build an overlay network on top of the Internet to meet the low-latency transmission requirements of real-time communication applications. Through low-latency routing algorithms, an overlay path that meets the latency requirements can be selected for end-to-end real-time communication data transmission.
[0062] In the process of data transmission from the sender to the receiver, such as the process of data transmission from the sender to the receiver via the coverage path, there is a common problem of data packet loss. In the face of packet loss, there are usually two common solutions from the perspective of network transmission, namely retransmission and redundant coding. Retransmission adds at least an additional round-trip time (RTT) end-to-end time overhead, which is likely to cause data transmission timeout. In contrast, redundant coding such as forward error correction coding (FEC) is more suitable for the transmission of delay-sensitive applications (applications requiring low latency) in overcoming the problem of increased latency caused by packet loss.
[0063] In order to use forward error correction coding, the sender usually divides the data stream to be transmitted (such as application data from the application layer) into a series of data packets of equal size during encoding, which are called original data packets. If the preset packet size is set to n, then n consecutive data packets are called a generation. The number of redundant data packets (number of coded packets) m to be encoded by the sender is usually determined by the sender's predicted value of the packet loss rate of the transmission path. In actual operation, the packet loss rate of the path / link is usually obtained by the packet loss rate prediction algorithm.
[0064] For example, Figure 1 As shown, forward error correction coding uses redundant coded packets for packet loss protection. With a packet size n of 4 and the number of redundant data packets m of 2, the sender encodes the four original data packets (p1-p4) in a packet according to the selected coding scheme (such as Reed-Solomon codes (RS code)) to obtain two redundant data packets (redundant coded packets c1 and c2). The sender then sends (n+m) data packets (i.e., the four original data packets p1-p4 and the two redundant coded packets c1-c2) to the receiver. Regardless of whether the data packet received by the receiver is a redundant data packet or an original data packet, as long as the number of data packets received by the receiver is not less than 4 (i.e., the size of a packet), the receiver can recover all the original data packets in the packet. As shown Figure 1 As shown in Figure 1. In terms of delay overhead, compared with the increased round-trip delay caused by retransmission technology to overcome packet loss, the encoding and decoding processing delay introduced by forward error correction coding is relatively small, so it is widely used in the transmission of real-time communication data over medium and long distances.
[0065] like Figure 1 As shown, for a group of n original data packets, when the value of the number of redundant data packets m is greater than the number of data packets that may be lost, that is, when the number of packet losses on the lossy link does not exceed the number of redundant data packets, the receiving end can recover the original data packets through forward error correction coding. One challenge faced by using forward error correction coding for packet loss protection is the inaccurate prediction of packet loss rate, such as the problem of underestimation of packet loss rate prediction. At present, there has been a lot of research on packet loss rate prediction algorithms, but due to the diversity and volatility of the network, there is no packet loss prediction algorithm that can achieve 100% prediction accuracy. Therefore, the situation of inaccurate prediction of packet loss rate during encoding always exists, that is, the situation of underestimation of packet loss rate prediction always exists.
[0066] There are two countermeasures for the failure of forward error correction coding recovery caused by underestimation of packet loss rate. The first is to rely on retransmission to obtain the missing data packets. This compensation method will cause a large tail delay, and compared with the pure use of retransmission technology for packet loss recovery, it also pays the additional computational cost of forward error correction coding. The second is to use a method similar to rateless coding to continuously send redundant data packets to the receiving end, that is, without specifying the value of the number of redundant data packets m, and continuously encode new coded packets and send them until a signal of successful packet recovery is received from the receiving end. The second method essentially abandons the guiding role of the packet loss rate on the coding rate, and both coding and sending are blind, requiring large computing and bandwidth costs. Therefore, the present application provides a packet loss protection method that can perform packet loss protection with lower latency and higher decoding success rate in an imperfect packet loss prediction environment.
[0067] Existing forward error correction coding schemes can be divided into two categories: group-independent coding schemes and cascade coding schemes, depending on whether there is a connection between different groups during encoding and decoding.
[0068] The encoding and decoding operations of the packet-independent coding scheme only involve the data packets in the current packet, and the packets are independent of each other.
[0069] Please also read Figure 2 (a) in Figure 2 (a) in the figure exemplifies the schematic diagram of group-independent coding. In the group-independent coding scheme, each group generates a coded packet independently during encoding. For example, the original data packet in group p-1 is independently encoded to obtain coded packet p-1, the original data packet in group p is independently encoded to obtain coded packet p, and the original data packet in group p+1 is independently encoded to obtain coded packet p+1. Based on the different data (original data packets) encoded from group p-1 to group p+1, and / or the different coefficient matrices used for group p-1 to group p+1, the subsequent coded packets p-1 to coded packets p+1 are different.
[0070] Taking group p as an example, the group-independent coding scheme is a coefficient matrix Linearly combine the n original data packets in group p to obtain m coded packets, namely E(p,A m×n )=A m×n p. The m coded packets are redundant packets of packet p, and then the m coded packets are sent to the receiving end together with the n original packets. Among them, n is the preset packet size, and the value of m is determined by the packet loss rate L of the link between the sending end and the receiving end, that is, Among them, the coefficient matrix A m×n It can be any custom matrix, where any two rows in the matrix are linearly independent, and the coefficient matrix A m×nIt can be a Vandermonde matrix, a Cauchy matrix, etc.
[0071] During decoding, the receiving end continuously receives data packets (original data packets and coded data packets) from the sending end. Once n (i.e., the preset packet size) data packets belonging to the same group (whether coded packets or original data packets) are received, the receiving end can recover the n original data packets in the group. Let q represent the n received data packets, then the decoding process is D(q) = (A ′ n×n (q)) -1 p, where A ′ n×n (q) is a coefficient matrix consisting of the coefficient information carried by the n received data packets. For example, Reese codes belong to the packet-independent coding scheme.
[0072] After setting the packet size appropriately, the encoding and decoding delay is low because the packet-independent coding scheme involves fewer packets each time. However, if the packet loss prediction of the packet-independent coding scheme is underestimated, that is, the actual number of packet losses is greater than the number of coded packets generated by the current group, it is very likely that decoding will fail.
[0073] In a broad sense, a cascade coding scheme refers to a coding scheme that is linked in coding and decoding, that is, each group is combined in coding and decoding. The cascade coding scheme has the process of generating inner code and outer code. The coding scheme used to generate the inner code and the outer code can be different or the same, which can be determined according to the actual situation. In actual coding, the cascade coding scheme is usually a two-level cascade, that is, a group-independent coding scheme is used for the original data packet in the current group to generate a number of coded packets, which are the inner code. After that, the inner code is jointly encoded with the data packets of other cascaded groups to generate the final coded packet. This type of final coded packet is usually called the outer code. When sending, only the outer code can be sent to ensure that no additional bandwidth overhead is added. Since the data packets of other groups are combined during encoding, correspondingly, the coded packet can protect the data packets of other groups during decoding.
[0074] When the concatenated coding scheme is used for joint coding, the objects to be coded include not only the data of the current group, but also the data of other groups. In addition to the data packets of the current group, the number of additional joint data packets (data packets from other groups other than the current group) is called the concatenated length.
[0075] For example, when performing joint coding on group A, the original data packet of group A is firstly coded to obtain an inner code. Then the inner code is concatenated (jointly) coded with data packets of other groups (groups other than group A). The number of data packets of the other groups is the concatenation length.
[0076] like Figure 2As shown in (b), taking the example that the transmitting end obtains the data of group p-1, group p and group p+1 in sequence and encodes them in sequence, the schematic diagram of multi-group joint coding (Multi-Generation Mixing, MGM) is introduced exemplarily. Multi-group joint coding is a typical scheme of cascading other groups for joint coding. The coding schemes for generating inner codes and outer codes in multi-group joint coding are both Reeso codes. The multi-group joint coding scheme cascades the data packets of other groups each time it encodes, and the other groups are the groups before the current group. When encoding the data in group p, it is necessary to jointly encode the original data packet in group p and the data of the group before group p (such as the coded packet A obtained after encoding the data in group p-1) to obtain coded packet B. When encoding the data in group p+1, it is necessary to jointly encode the original data packet in group p+1 and the data of the group before group p+1 (such as the coded packet B after encoding group p and the coded packet A after encoding group p-1) to obtain coded packet C. It can be seen from this that in multi-group joint coding, each time joint coding is performed, the concatenation length of the joint coding object is not fixed. Figure 2 As shown in (b) in FIG. 1 , for packet P, the concatenation length is two coded packets, and for packet P+1, the concatenation length is five coded packets. As the packet ID increases (i.e., the later the concatenation, the more packets), the number of data packets that need to be combined also increases.
[0077] The inventor discovered when implementing the embodiments of the present application that the larger the packet size (also referred to as the code length), the higher the overall decoding success rate, the stronger the ability to resist situations such as underestimated packet loss rate prediction, and especially the ability to resist sudden packet loss, which easily leads to underestimated packet loss rate prediction, but the encoding and decoding delay is also longer. Taking into account the computational complexity and encoding and decoding delay, the packet size cannot be increased indefinitely. Cascade coding uses the series or parallel connection of multiple short codes to approximate the decoding success rate effect of long codes, so it has a higher ability to resist underestimated packet loss rate prediction. However, as the cascade length of the cascade coding scheme increases, the number of joint data that needs to be jointly decoded during decoding also increases, thereby increasing the delay. The blind cascade length and forward cascade mode in the multi-group joint coding scheme cause the number of data packets that need to be jointly decoded during decoding to increase with the group ID, which in turn leads to the inability to meet the needs of delay-sensitive applications.
[0078] In view of this, the present application provides a packet loss protection method, system and related equipment. The packet loss protection method provided by the present application is based on the redundant coding idea to perform packet loss protection, by dynamically setting the cascade length corresponding to each group, and then obtaining the corresponding amount of data (joint data) from other groups according to the cascade length corresponding to the group, so as to perform joint coding based on the obtained joint data. When the cascade length corresponding to each group is dynamically set for the group, the sending end obtains the feedback information sent by the receiving end, and assists the redundant coding based on the feedback information, so as to achieve the packet loss protection on the next hop link (link) of the node with lower processing delay and higher decoding success rate in an environment where the link packet loss rate cannot be accurately predicted, wherein for a data packet of a group, the sum of the time required for encoding on the sending end side and the time required for decoding on the receiving end side is called a processing delay. Compared with the packet-independent coding scheme (such as RS), the end-to-end decoding success rate is improved, for example, the end-to-end decoding success rate can be increased to about 35%. Compared with the traditional cascade coding scheme (such as MGM), under the goal of maximizing the decoding success rate, the decoding delay meets the preset delay upper limit. The packet loss protection method provided in this application can also be called a feedback-assisted redundant coding scheme FACE (Feedback Assisted Concatenate Error correction), which can be used between the transmission layer and the application layer of the end-to-end transmission sending end and the receiving end.
[0079] See also Figure 3 (a) in the figure exemplarily introduces a packet loss protection system 100 provided in an embodiment of the present application. The packet loss protection system 100 includes a sending end 10, a receiving end 20 and a network 30. The sending end 10 communicates with the receiving end 20 through the network 30. The sending end 10 encodes the original data (i.e., data that has not yet been encoded) to obtain encoded data. The sending end 10 first transmits the original data to the receiving end 20 through the network 30, and then transmits the encoded data to the receiving end 20 through the network 30. The encoded data sent by the sending end 10 can be understood as redundant data of the original data.
[0080] After the communication link is established between the transmitting end 10 and the receiving end 20, data is transmitted between the transmitting end 10 and the receiving end 20. The process of establishing the communication link between the transmitting end 10 and the receiving end 20 can refer to the prior art and will not be described in detail here.
[0081] In some embodiments, the original data is data used for real-time communication, such as video data and audio data of real-time video, or audio data of real-time audio, etc. When solving the packet loss problem, based on the relatively low latency required by real-time communication data, the data encoded by the transmitter 10 includes the data of the current packet and also includes the data of other packets, such as the original data or encoded data of other packets.
[0082] In the specific implementation process, the above-mentioned sending end 10 and receiving end 20 can be network 30 devices such as routers and switches, or servers, or electronic devices, where the electronic devices can be terminal devices, which can also be called terminals, mobile terminals (Mobile Terminal) or mobile user devices, such as mobile phones (such as "cellular" phones) and computers with mobile terminals. For example, they can be portable, pocket-sized, handheld, computer-built-in or vehicle-mounted mobile devices, which exchange language and / or data with the wireless access network and can communicate with one or more core networks via the wireless access network.
[0083] In some embodiments, the sender 10 may be implemented as a server, and the receiver 20 may be implemented as a terminal device, an edge server, or a gateway, etc. In other embodiments, the sender 10 may be implemented as a terminal device, and the receiver 20 may be implemented as another terminal device, an edge server, a gateway, or a server, etc.
[0084] The network 30 may be Ethernet, a radio access network (RAN), a wireless local area network (WLAN) or various generations of mobile communication technologies (such as 4G (the 4th Generation), 5G, 3G or 2G, etc.), etc., and the embodiments of the present application are not limited thereto.
[0085] In the embodiment of the present application, when the network 30 is a wired network, the first link between the transmitting end 10 and the receiving end 20 is a physical line, and the first link may be a cable or an optical fiber, etc. When the network 30 is a wireless network, the first link between the transmitting end 10 and the receiving end 20 is a path space for propagating electromagnetic waves, and the present application does not specifically limit the first link.
[0086] In the embodiment of the present application, the transmitting end 10 obtains feedback information sent by the receiving end 20, and dynamically sets the cascade length of each packet according to the feedback information, wherein the feedback information indicates the packet loss situation of the first link.
[0087] It should be pointed out that the above-mentioned transmitting end 10 and receiving end 20 can also be chip systems with corresponding functions, that is, the transmitting end 10 can be a chip system with functions such as data processing and sending, and the receiving end 20 can be a chip system with functions such as data receiving and processing.
[0088] In some embodiments, Figure 3 As shown in (b) of FIG. 1 , the transmitting end 10 of the packet loss protection system 100 includes a first acquisition module 11, a first transmission module 12, a packet loss prediction module 13, a control module 14 and an encoding module 15. The receiving end 20 of the packet loss protection system 100 includes a second transmission module 21 and a decoding module 22.
[0089] The first acquisition module 11 is used to obtain original data, such as original data packets. The first acquisition module 11 is also used to transmit the original data to the encoding module 15, and transmit the relevant information corresponding to the original data (such as the preset delay upper limit) to the control module 14. The first transmission module 12 is used to obtain feedback information from the receiving end 20, and transmit the feedback information to the control module 14. The first transmission module 12 is also used to obtain network conditions (such as network packet loss conditions), and transmit the network conditions to the packet loss prediction module 13. The packet loss prediction module 13 is used to calculate the packet loss rate according to the network conditions and the built-in packet loss prediction algorithm, and transmit the packet loss rate to the control module 14. The control module 14 is used to update the cascade length and coding rate of each group. Specifically, the control module 14 obtains the preset delay upper limit. The control module 14 is used to update the coding rate of each group according to the packet loss rate, and then calculate the number of coding packets of each group according to the coding rate. The control module 14 is also used to determine and update the cascade length corresponding to each group according to the packet loss rate, feedback information and the preset delay upper limit. The control module 14 is also used to transmit the coding rate (or the number of coding packets) and the cascade length to the coding module 15. The coding module 15 is used to encode the received original data into redundant data of the original data according to the cascade length and the coding rate (or the number of coding packets), and the coding module 15 is also used to send the redundant data to the first transmission module 12. The first transmission module 12 is also used to transmit the original data and the redundant data to the decoding module 22 through the second transmission module 21. The decoding module 22 is used to restore the original data according to the received original data and the redundant data. The second transmission module 21 is used to transmit an acknowledgement character (Acknowledge character, ACK) to the first transmission module 12.
[0090] In some embodiments, the receiving end 20 further includes a second acquisition module 23. The decoding module 22 is further configured to transmit the obtained original data (such as the restored original data) to the second acquisition module.
[0091] The core idea of this application is to adopt a cascade coding encoding and decoding mode, and use feedback information (such as indicating the packet loss situation of the first link between the sending end 10 and the receiving end 20) to dynamically formulate the cascade length for each group during joint coding, so as to achieve a balance between the decoding success rate and the decoding delay, thereby improving the user experience.
[0092] Understandably, Figure 3 This is an exemplary system architecture diagram. The embodiments of the present application may also work in other communication systems and are not limited here.
[0093] It should be noted that the packet loss protection system 100 provided in the embodiment of the present application can be applied to communication scenarios with high latency requirements, such as the transmission of real-time messages in the Internet of Things, real-time communication between machines, interaction of keep-alive information between data centers, remote control of robots, and other scenarios.
[0094] The packet loss protection method of the present application is introduced from the perspective of the transmitting end 10. It should be understood that the following operations are not necessarily performed precisely in order. On the contrary, various steps can be processed in reverse order or simultaneously as needed. At the same time, other operations can also be added to these processes, or one or more operations can be removed from these processes.
[0095] See also Figure 4 , exemplarily introduces the packet loss protection method provided in the embodiment of the present application, which can be applied to Figure 3 The packet loss protection system 100 shown in FIG. Figure 3 The sending end 10 shown executes.
[0096] Step S40: the sending end obtains the first original data of the first group.
[0097] In an embodiment of the present application, the transmitting end obtains data (i.e., raw data) that is to be transmitted to the receiving end and has not yet been encoded. For example, the transmitting end obtains application data to be transmitted from its application layer, and the application data is raw data. The application data can be data for real-time communication. The data unit of the raw data can be a raw data packet or a message, etc.
[0098] In the embodiment of the present application, the sending end can pre-set the preset packet size n and the preset length s of the data packet. The sending end obtains the data stream to be transmitted from the application layer, and divides the data stream into a number of original data packets of the same size according to the preset length s, and the size of each original data packet is the preset length s. The sending end obtains the original data of a packet by obtaining n consecutive original data packets.
[0099] The first original data is the original data belonging to the first group, and the number of the first original data is the preset group size. It can be understood that the first group does not limit the group ID to the first, and it can correspond to any group.
[0100] In some embodiments, the group to which the data currently being processed by the transmitting end belongs (current group) is the first group. Exemplarily, when the transmitting end (such as the first acquisition module 11 or the encoding module 15) obtains the original data packet to be transmitted, the group to which the original data packet belongs is the first group, and the original data packet is the first original data, that is, the first group is the current group.
[0101] Step S42, the sending end obtains the first cascade length corresponding to the first group, where the first cascade length is used to indicate the amount of first joint data, the first joint data is data in other groups used for joint encoding with the data of the first group, the first cascade length is greater than or equal to 0 and less than or equal to the upper limit of the cascade length, the upper limit of the cascade length is determined according to a preset delay upper limit, and the preset delay upper limit is related to the first original data.
[0102] Among them, the preset delay upper limit value is related to the first original data, such as related to relevant information of the first original data, and the relevant information includes the service type to be transmitted corresponding to the first original data or the application corresponding to the first original data or the application type corresponding to the application.
[0103] In an embodiment of the present application, a preset delay upper limit value may be set in advance for the transmitted data, and the decoding delay of a group of data (the time required to wait for the cascaded data and the time required for the decoding operation) cannot exceed the corresponding preset delay upper limit value. Exemplarily, the transmitting end maintains a preset delay comparison table, which records the preset delay upper limit values corresponding to each application. Or records the preset delay upper limit values corresponding to each application type. Or records the preset delay upper limit values corresponding to each service type.
[0104] Specifically, the processing delay requirements corresponding to each service type or application or application type to be transmitted may be collected in advance, and then a preset delay upper limit value may be set according to the processing delay requirement. When the processing delay requirement is high, the corresponding preset delay upper limit value is low. Wherein the processing delay requirement may specify a processing delay upper limit value, the processing delay upper limit value is set to the preset delay upper limit value. The preset delay upper limit value may be set according to actual conditions, and this application does not make specific limitations on this.
[0105] In some embodiments, the preset delay upper limit value corresponding to the service type implementing real-time communication is smaller than the preset delay upper limit value corresponding to the data transmission service type. For another example, the preset delay upper limit value corresponding to the live broadcast application is smaller than the preset delay upper limit value corresponding to the file transfer application.
[0106] In some embodiments, various applications are classified and set as delay-sensitive application types and delay-insensitive application types. Applications that implement real-time communication, such as remote video or live broadcast, are set as delay-sensitive application types, and the preset delay upper limit value corresponding to the delay-sensitive application type can be several milliseconds to tens of milliseconds. File transfer applications are set as delay-insensitive application types, and the preset delay upper limit value corresponding to the delay-insensitive application type can be hundreds of milliseconds, seconds, or minutes.
[0107] In some embodiments, after the transmitting end obtains the preset delay upper limit value according to the relevant information of the first original data and the preset delay comparison table, the transmitting end determines the cascade length upper limit value according to the preset delay upper limit value. The preset delay upper limit value obtained by adjusting the delay on the current first link can also be used to obtain a final preset delay upper limit value, and the transmitting end determines the cascade length upper limit value according to the final preset delay upper limit value.
[0108] In some embodiments, after the sender obtains the preset upper delay limit value of application A as B, when the subsequently processed packet belongs to application A, the preset upper delay limit value of the packet is directly determined to be B.
[0109] In an embodiment of the present application, the first cascade length corresponds to the first group, and the first cascade length indicates the number of first joint data cascaded when the first group is cascaded (jointly) encoded. The first joint data is the original data or encoded data in other groups for joint encoding with the data of the first group, and the other groups jointly encoded with the first group are groups after the first group. Exemplarily, the first joint data can be the original data packet or encoded packet of the other group.
[0110] In an embodiment of the present application, the transmitting end obtains the cascade length corresponding to each group for the group. In other words, regardless of whether the group is finally jointly encoded, the cascade length corresponding to the group is obtained. Each group has its corresponding cascade length. When the cascade lengths of each group are different, the number of joint data combined when each group is jointly encoded is different. Each group has its corresponding joint data. When the cascade lengths of each group are the same, the cascade data of each group comes from the group after it, and when the data in the group after each group is different, the joint data is different.
[0111] The present application does not specifically limit the timing of obtaining the concatenation length corresponding to the group. Before actually performing the joint encoding operation on the grouped data, the concatenation length corresponding to the group can be obtained. For example, after the sender receives the original data of a group size, or after the sender receives the original data of a group size and encodes the original data to obtain a coding packet (inner code), the sender obtains the concatenation length corresponding to the group.
[0112] In the embodiment of the present application, the encoding and decoding mode of the cascade coding adopted by the transmitting end when executing the packet loss protection method provided in the embodiment of the present application is different from the cascade coding method in the prior art in at least the following aspects: First: the transmitting end sets the corresponding cascade length for each group, and each group has its corresponding cascade length, that is, when each group is jointly encoded, it is jointly encoded according to its corresponding number of joint data. The cascade lengths of each group can be the same or different. Second: When a group is jointly encoded, the joint data jointly encoded by the group comes from the group after the group, that is, backward cascade.
[0113] In an embodiment of the present application, when the transmitting end obtains the cascade length corresponding to each packet, the transmitting end determines the preset delay upper limit value according to the original data to be transmitted currently, and then determines the cascade length upper limit value according to the preset delay upper limit value, and then can be adjusted within the range of the cascade length upper limit value to obtain the cascade length of the packet pair. The cascade length corresponding to each packet is greater than or equal to 0 and less than or equal to the cascade length upper limit value, thereby ensuring that the processing delay of the packet data can be controlled within the preset delay upper limit value, and the processing delay of the packet data includes the delay required for joint encoding according to the cascade length corresponding to the packet and the delay required for decoding the encoded data after the joint encoding of the packet (the delay required for decoding includes the delay of waiting for the cascade data corresponding to the packet and the delay of performing the decoding operation), thereby meeting the processing delay requirements corresponding to the service type (or application or application type) to be transmitted, avoiding the increase of processing delay due to overcoming packet loss, and improving user experience.
[0114] In some embodiments, step S40 and step S42 may be performed simultaneously.
[0115] Step S44: The sending end encodes according to the first cascade length and the first original data to obtain first encoded data.
[0116] In an embodiment of the present application, after the transmitting end obtains the first original data of the first group, it determines whether it is necessary to perform joint encoding on the first group according to the first cascade length set by the transmitting end for the first group. When the first cascade length is 0, there is no need to perform joint encoding on the first group. The transmitting end encodes the first original data according to a preset coding scheme to obtain initial coded data, and uses the initial coded data as the first coded data. When the first cascade length is not 0, it is necessary to perform joint encoding on the first group. When it is necessary to perform joint encoding on the first group, the transmitting end also needs to continue to obtain the first joint data from other groups (groups after the first group). The transmitting end obtains the corresponding number of first joint data from other groups according to the first cascade length, and the transmitting end encodes the first original data according to the preset coding scheme to obtain initial coded data (inner code). The initial coded data is jointly encoded with the first joint data to obtain the first coded data.
[0117] The first coded data may be data after joint coding or data not after joint coding.
[0118] For example, after the transmitting end obtains the data of packet i, it determines that the first concatenation length of packet i is 3, and then the transmitting end continues to wait for the original data packet of packet i+1 sent by the application layer, and uses the first three original data packets in packet i+1 as the first joint data of packet i. For another example, after the transmitting end obtains the original data packet of packet i+1, it encodes the original data packet to obtain a coded packet, and uses the first three coded packets in packet i+1 as the first joint data of packet i.
[0119] In some embodiments, for a group, joint coding is performed only once. For a group, when the group obtains joint data of a corresponding cascade length from other groups and performs joint coding on the obtained joint data and the inner code of the group, the joint coding corresponding to the group is completed.
[0120] Step S46: The sending end sends the first encoded data and the first cascade length to the receiving end.
[0121] In an embodiment of the present application, based on the fact that the cascade length corresponding to each group can be different and not fixed, when the sending end sends the data (original data and encoded data) corresponding to each group to the receiving end, the sending end also sends the cascade length corresponding to the group.
[0122] In some embodiments, the transmitting end sends the first original data, the first encoded data and the first concatenation length of the first packet to the receiving end.
[0123] In an embodiment of the present application, when the first group is not jointly encoded in step S44, the decoding delay can be reduced to ensure that the decoding delay meets the preset delay upper limit. When the first group is jointly encoded in step S44, based on the first cascade length of the cascade operation on the first group is less than or equal to the cascade length upper limit, the decoding success rate can be improved while ensuring that the processing delay meets the preset delay upper limit. The transmitting end adopts the coding mode of cascade coding, and achieves a balance between the decoding success rate and the decoding delay by dynamically setting the corresponding cascade length for each group.
[0124] In an embodiment of the present application, the transmitting end obtains the cascade length upper limit value based on the decoding delay of the receiving end being less than or equal to the preset delay upper limit value, thereby ensuring that the decoding delay of the receiving end is controlled within the preset delay upper limit value, thereby improving the user experience.
[0125] See also Figure 5 , exemplarily introduces a method for obtaining an upper limit value of a cascade length provided in an embodiment of the present application, the method comprising the following steps:
[0126] Step S51: The transmitting end obtains a first formula according to the decoding delay of the receiving end being less than or equal to a preset delay upper limit value.
[0127] The first formula is as follows:
[0128] W(n+c)+(c*s) / b≤τ
[0129] Among them, W(n+c) is the first delay, n is the preset packet size, c is the size (quantity) of the joint data, W is the empirical function, s is the size of a single original data (such as a single original data packet), b is the sending rate, and τ is the preset delay upper limit value.
[0130] The preset delay upper limit value τ may be a value obtained according to a preset delay comparison table and data to be transmitted, or may be a value obtained according to a preset delay comparison table, data to be transmitted and the delay on a link (such as the delay on the first link).
[0131] The meaning of the first formula is that the decoding delay of the receiving end is ≤ the preset delay upper limit value, and the decoding delay of the receiving end is = the first delay + the waiting delay for waiting to receive the joint data with a length of c.
[0132] The first delay is the delay of the decoding operation. The first delay means the time taken by the inner coding scheme (i.e., the coding scheme for generating the inner code) and the outer coding scheme (i.e., the coding scheme for generating the outer code) selected by the codec to decode the data of length n+c at the receiving end. In other words, the time taken by the inner coding scheme (i.e., the coding scheme for generating the inner code) and the outer coding scheme (i.e., the coding scheme for generating the outer code) selected by the codec to decode the data of length n+c at the receiving end is the first delay. n+c is the current packet size plus the size of the cascaded data cascaded backward, that is, the number of data involved in the coding and decoding. W is an empirical function whose independent variable is the number of data (such as the number of data packets involved in the coding and decoding). The specific mapping relationship between the first delay and the number of data is related to the selected inner coding and decoding scheme, the outer coding and decoding scheme, and the hardware device. If the data of the independent variable of the empirical function W is historical data, the value of the empirical function W is an empirical value.
[0133] In some embodiments, an experience table may be pre-stored to record the selected inner and outer coding schemes, the hardware devices, the number (n+c) of data involved in coding and decoding, and the value of W(n+c).
[0134] The waiting delay for receiving the joint data of length c means that after the receiving end receives the last original data of the current packet (such as the original data packet or message), it is necessary to wait for an additional time of c*s / b to receive the cascaded joint data.
[0135] In step S52, the sending end uses c that satisfies the maximum value in the first formula as the upper limit of the cascade length.
[0136] In the embodiment of the present application, the transmitting end obtains the cascade length upper limit value according to the decoding delay of the receiving end being less than or equal to the preset delay upper limit value, ensuring that the decoding delay of the receiving end corresponding to the cascade length upper limit value does not exceed the preset delay upper limit value, thereby improving the user experience. Furthermore, the size of the joint data that satisfies the decoding delay of the receiving end being less than or equal to the maximum value in the preset delay upper limit value is used as the cascade length upper limit value, so as to ensure that the amount of cascade data is increased as much as possible when the decoding delay meets the preset delay upper limit value, thereby improving the decoding success rate.
[0137] In an embodiment of the present application, the transmitting end obtains feedback information sent by the receiving end, which indicates the packet loss situation of the first link between the transmitting end and the receiving end. The transmitting end sets the cascade length of each group within the cascade length upper limit according to the feedback information.
[0138] In some embodiments, see Figure 6, exemplarily introduces a method for obtaining a first cascade length corresponding to a first group provided in an embodiment of the present application, the method may include the following steps:
[0139] Step S61: The sending end obtains feedback information sent by the receiving end, where the feedback information is used to indicate packet loss on a first link, where the first link is a link between the sending end and the receiving end.
[0140] The packet loss of the first link can be determined based on the packet loss of the packet, and the packet is the packet transmitted by the first link. In some embodiments, when the transmitting end sets the first cascade length of the first packet based on the feedback information, the packet transmitted by the first link is the packet before the first packet.
[0141] In the embodiment of the present application, the transmitting end may obtain the feedback information sent by the receiving end by sending a request to the receiving end, so that after the receiving end receives the request, the receiving end returns the feedback information to the transmitting end in response to the request. Alternatively, the receiving end may actively send the feedback information to the transmitting end in real time.
[0142] In some embodiments, the receiving end actively returns feedback information to the sending end in real time, which may be: when the receiving end receives data sent by the sending end, after detecting that it has received data of a certain group, the receiving end returns feedback information of the group to the sending end. For example, after the receiving end receives a original data packet of group p+1, the receiving end returns feedback information of group p (the group before group p+1) to the sending end, where a is an integer greater than or equal to 1.
[0143] In some embodiments, the predicted number of packet losses can be obtained according to the predicted packet loss rate, and the actual number of packet losses can be compared with the predicted number of packet losses to determine the packet loss situation. In some embodiments, if the actual number of packet losses is greater than the predicted number of packet losses, the packet loss situation of the first link is judged to be serious. If the actual number of packet losses is less than or equal to the predicted number of packet losses, the packet loss situation of the first link is judged not to be serious.
[0144] Step S62: The transmitting end obtains the first cascade length corresponding to the first group according to the feedback information.
[0145] In the embodiment of the present application, the more serious the packet loss of the first link is, the closer the first cascade length is to the upper limit of the cascade length. In other words, when it is detected that the packet loss of the current first link is more serious, the more it is necessary to perform a cascade operation on the first packet. For this reason, the first cascade length is set close to the upper limit of the cascade length, so that the amount of the first joint data increases, so as to improve the decoding success rate.
[0146] In the embodiment of the present application, the feedback information may be a packet loss condition of an adjacent group, where the adjacent group is a group adjacent to the first group.
[0147] In some embodiments, see Figure 7 , exemplarily introduces a method flow for obtaining feedback information sent by a receiving end provided in an embodiment of the present application, the method may include the following steps:
[0148] Step S71: The transmitting end determines k adjacent packets, where the adjacent packets are packets adjacent to the first packet among packets sent by the transmitting end, and k is an integer greater than or equal to 2.
[0149] The number k of neighboring groups is determined based on actual network operation experience.
[0150] In some embodiments, the transmitting end may obtain adjacent packets according to a preset time period, such as taking packets within a preset time period before the current moment (eg, the moment when the transmitting end wants to obtain the concatenation length of the current packet) as adjacent packets.
[0151] Exemplarily, the receiving end actively returns feedback information to the sending end in real time, the preset time period is 3 seconds, and the first group is group p+1. For example, the sending end sends the data of group p-1, group p, and group P+1 to the receiving end in sequence. When the receiving end receives the data of group p-1 and group p, the feedback information of group p-1 is transmitted to the sending end. When the receiving end receives the data of group p and group p+1, the feedback information of group p is transmitted to the sending end. At the current moment T1, the sending end wants to obtain the first cascade length of the first group. Within 3 seconds between the moment T1 and the moment T0 (the moment of T1-3 seconds), the sending end receives the feedback information of group p-1 and group p fed back by the receiving end. The sending end determines that group p-1 and group p are adjacent groups of the group p+1, and k is 2. That is, the groups included in the feedback information received by the sending end in the preset time period are all adjacent groups of the first group, and the number k of the adjacent groups is related to the group size, the sending rate, and the preset time period.
[0152] Step S72: for each adjacent packet, the transmitting end obtains feedback information of the adjacent packet sent by the receiving end, wherein the feedback information includes a total packet loss length and a burst packet loss length.
[0153] In the embodiment of the present application, the transmitting end continuously obtains feedback information from the receiving end, and the feedback information fed back by the receiving end includes two attributes of the packet, one is the actual total packet loss length, and the other is the burst packet loss length of each packet. After determining the adjacent packets of the first packet, the transmitting end obtains the total packet loss length and the burst packet loss length of each adjacent packet.
[0154] The total packet loss length includes the burst packet loss length and the random packet loss length. In some embodiments, the total packet loss length may also include the congestion packet loss length and the like.
[0155] In the embodiment of the present application, after the transmitting end determines the adjacent packets of the current packet, the total packet loss length and the burst packet loss length of each adjacent packet are obtained, and then the cascade length of the current packet is assisted in setting according to the feedback information (total packet loss length and burst packet loss length) of the adjacent packets. The more serious the packet loss of the adjacent packets indicated by the feedback information, the larger the cascade length is set to maximize the decoding success rate.
[0156] As in the above example, the adjacent packets are determined to be packet p-1 and packet p, the sender obtains the actual total packet loss length and burst packet loss length of packet p-1, and the sender obtains the actual total packet loss length and burst packet loss length of packet p.
[0157] In the embodiment of the present application, the accuracy of the currently predicted packet loss rate can be determined according to the packet loss situation on the first link, and then the cascade length can be determined according to the accuracy of the predicted packet loss rate.
[0158] See also Figure 8 , exemplarily introduces a method flow for obtaining a first cascade length corresponding to a first group according to feedback information provided in an embodiment of the present application, the method may include the following steps:
[0159] Step S81: When the transmitting end determines according to the feedback information that the packet loss prediction underestimation does not occur, the first cascade length is obtained as 0.
[0160] In an embodiment of the present application, when the feedback information indicates that there is no underestimation of packet loss prediction, that is, based on the guiding effect of the current predicted packet loss rate on the coding rate, the number of redundant data m encoded is greater than the number of data packets that may be lost, which can ensure that the number of data packets received by the receiving end is not less than the preset packet size, that is, it is ensured that the receiving end can restore the original data based on the received data, then the first cascade length corresponding to the first packet is set to 0, and the first packet is not jointly encoded, thereby reducing the overhead caused by cascade coding, reducing costs, and reducing end-to-end delays, thereby improving user experience.
[0161] Step S82: When the transmitting end determines according to the feedback information that the packet loss prediction is underestimated, a first cascade length is obtained according to the feedback information and the upper limit of the cascade length, and the first cascade length is greater than 0.
[0162] In the embodiment of the present application, when the feedback information indicates that the packet loss prediction is underestimated, that is, the number of redundant data m encoded according to the current predicted packet loss rate to the coding rate is less than the number of data packets that may be lost, that is, the number of data packets received by the receiving end is less than the preset packet size, and the receiving end may not be able to restore the original data packet based on the received data. For this reason, the cascade length corresponding to the current packet (first packet) is set to be greater than 0. That is, when it is determined that the packet loss prediction is underestimated, the transmitting end performs joint encoding on the first packet to assist in recovering the excessively lost data based on the data of other combined packets, thereby improving the decoding success rate.
[0163] In the embodiment of the present application, the packet loss situation on the first link can be determined according to the packet loss prediction situation of each adjacent group, and then the accuracy of the currently predicted packet loss rate can be determined.
[0164] See also Fig. 9 , exemplarily introduces a method flow of a transmitter to estimate whether packet loss underestimation occurs, provided in an embodiment of the present application. The method may include the following steps:
[0165] Step S91: The sending end obtains the predicted packet loss length.
[0166] The sender calculates the predicted packet loss rate based on the network conditions and the built-in packet loss prediction algorithm, and then obtains the predicted packet loss length based on the predicted packet loss rate.
[0167] Step S92: For each adjacent group, the transmitting end obtains the packet loss prediction of the adjacent group according to the total packet loss length corresponding to the adjacent group and the predicted packet loss length.
[0168] In an embodiment of the present application, for each adjacent group, the transmitter compares the predicted packet loss length with the actual total packet loss length corresponding to the adjacent group, determines whether there is an error between the actual packet loss length of the adjacent group and the predicted packet loss length, and obtains the packet loss prediction of the adjacent group based on the error situation.
[0169] Exemplarily, for each adjacent group, the total packet loss length corresponding to the adjacent group is subtracted from the predicted packet loss length to obtain a difference σ, and the packet loss prediction of the adjacent group is obtained according to the difference σ. When the difference σ is less than 0, the packet loss prediction of the adjacent group is that the packet loss prediction of the adjacent group is underestimated. When the difference σ is greater than or equal to 0, the packet loss prediction of the adjacent group is that the packet loss prediction of the adjacent group is not underestimated.
[0170] Step S93: The transmitting end determines whether packet loss prediction underestimation occurs according to the packet loss prediction conditions of each adjacent packet.
[0171] In an embodiment of the present application, if the difference values σ of all adjacent groups of the current group are less than 0, that is, all adjacent groups have underestimated packet loss prediction, then it is determined that the packet loss situation on the first link is serious, that is, the accuracy of the previously predicted packet loss rate is low, and the packet loss prediction is underestimated. If the difference values σ of all adjacent groups of the current group are greater than 0, then it is determined that the packet loss prediction is not underestimated. In some embodiments, if L difference values σ of k adjacent groups are less than 0, that is, L adjacent groups have underestimated packet loss prediction, then it is determined that the packet loss situation on the first link is serious, that is, the accuracy of the previously predicted packet loss rate is low, and the packet loss prediction is underestimated. L is greater than 0 and less than k. Otherwise, it is determined that the packet loss prediction is not underestimated.
[0172] In an embodiment of the present application, when it is necessary to perform cascade coding on the first group, the first cascade length of the first group can be set according to the feedback information and the upper limit of the cascade length, so that the first cascade length does not exceed the upper limit of the cascade length, and the decoding success rate is improved as much as possible based on the setting of the first cascade length.
[0173] In some embodiments, see Fig.10 , exemplarily introduces a method flow for obtaining a first cascade length according to feedback information and an upper limit of the cascade length provided in an embodiment of the present application, the method may include the following steps:
[0174] Step S101: The transmitting end determines a first coefficient according to a burst packet loss length of each adjacent packet, wherein the first coefficient is greater than 0 and less than or equal to 1.
[0175] When implementing the embodiments of the present application, the inventors found that underestimation of packet loss prediction usually occurs in the case of burst packet loss, so the burst packet loss length is selected to confirm whether there is a burst packet loss. When the burst packet loss is more serious, the first coefficient is closer to 1, so as to cascade more joint data as much as possible, and enhance the ability to resist burst packet loss and other situations that easily lead to underestimation of packet loss rate prediction.
[0176] Step S102: The transmitting end obtains a first cascade length according to the first coefficient and an upper limit of the cascade length.
[0177] Based on the first coefficient being less than or equal to 1, the first cascade length is less than or equal to the cascade length upper limit.
[0178] See also Fig.11 , exemplarily introduces a method flow for determining a first coefficient by a transmitting end according to a burst packet loss length of each adjacent packet provided in an embodiment of the present application, the method may include the following steps:
[0179] Step S111: The transmitting end obtains a first coefficient function F, where the first coefficient function F is:
[0180]
[0181] Where k is the number of neighboring groups. i is the smoothing coefficient of the i-th group combination, and satisfies The combination is a combination of two adjacent groups among the k adjacent groups. i is the burst packet loss length of adjacent packet i. i is the number of coded packets of the adjacent group i. Among the k adjacent groups of the current group, the sender takes two adjacent adjacent groups in the k adjacent groups as a group of combinations, and can determine k-1 combinations.
[0182] The first coefficient function is set To ensure that the value of the first coefficient is not greater than 1. The physical meaning of is to obtain the burst packet loss length and the number of coded packets of each adjacent packet in a combination, and calculate the ratio of the maximum burst packet loss length to the sum of the number of coded packets in the combination. For example, the sender takes adjacent packet i and adjacent packet i+1 as a group i, and obtains the number of coded packets r of adjacent packet i. i , get the number of coded packets r of adjacent group i+1 i+1 , calculate the sum r of the number of coded packets of adjacent group i and adjacent group i+1 i +r i+1 The sender obtains the burst loss length b of packet i i and the burst loss length b of packet i+1 i+1 , select the maximum burst packet loss length max(b i , b i+1 ), such as max(b i , b i+1 ) is b i , the sender calculates Get the burst packet loss of the i-th group combination. When the burst packet loss length is b i The larger the ratio of the sum of the number of coded packets in the i-th group, the more serious the burst packet loss in the i-th group. Also bigger.
[0183] The first coefficient function F is used to make a trade-off between the decoding success rate and the decoding delay according to the burst packet loss length of the adjacent group. When the burst packet loss of each combination is more serious, the larger the first coefficient, the larger the cascade length (such as the first cascade length) obtained subsequently according to the first coefficient and the upper limit of the cascade length, and the more joint data cascaded according to the cascade length, the higher the decoding success rate. When the burst packet loss of the combination is not serious, the smaller the first coefficient, the shorter the cascade length (such as the first cascade length) obtained subsequently according to the first coefficient and the upper limit of the cascade length, the smaller the decoding delay.
[0184] Step S112: The sending end obtains a smoothing coefficient and the number of coding packets.
[0185] In an embodiment of the present application, after the transmitting end determines the k adjacent groups of the first group, for each adjacent group, the transmitting end determines the coding rate of the adjacent group according to the predicted packet loss rate, and then obtains the number of coded packets corresponding to the adjacent group according to the coding rate. The transmitting end obtains the corresponding smoothing coefficient set for each combination in the k adjacent groups. The closer the adjacent group in the combination is to the current group (such as the first group), the larger the smoothing coefficient α corresponding to the combination.
[0186] In some embodiments, the smoothing coefficients α of all neighboring groups may be set to an average value. For example, if k is 4, the smoothing coefficient α corresponding to each neighboring group is 0.25.
[0187] Step S113: The transmitting end determines the first coefficient according to the smoothing coefficient, the number of coded packets, the burst packet loss length and the first coefficient function F.
[0188] In an embodiment of the present application, the transmitting end determines k-1 combinations based on k adjacent groups of the first group, obtains the smoothing coefficient of each of the k-1 combinations, obtains the number of coded packets of each of the k adjacent groups, obtains the burst packet loss length of each of the k adjacent groups, obtains the first coefficient function F, and then substitutes the obtained smoothing coefficient, the number of coded packets, and the burst packet loss length into the first coefficient function to obtain the first coefficient corresponding to the first group.
[0189] Then obtaining the first cascade length according to the first coefficient and the upper limit of the cascade length includes:
[0190]
[0191] Among them, C1 is the first cascade length, C max The upper limit of the cascade length.
[0192] Exemplarily, if k is 4, and the four adjacent groups of the first group are group 1 to group 4, then it can be determined that among the k adjacent groups, two adjacent adjacent groups are group 1 and group 2, group 2 and group 3, and group 3 and group 4, and the smoothing coefficients corresponding to the two adjacent adjacent groups are α1 to α3, respectively, and the burst packet loss lengths corresponding to group 1 to group 4 are b1 to b4, respectively, and the number of coded packets corresponding to group 1 to group 4 are r1 to r4, respectively. Then, according to the first coefficient function F, the first coefficient f of the first group can be obtained as follows:
[0193]
[0194] Obtaining the first cascade length according to the first coefficient and the cascade length upper limit value includes:
[0195]
[0196] In the embodiment of the present application, when the burst packet loss of the adjacent packets indicates that the burst packet loss of the adjacent packets is serious, the cascade length is as close to the upper limit of the cascade length as possible, so as to improve the decoding success rate as much as possible while ensuring that the preset delay upper limit is met. The cascade length during encoding is dynamically formulated using the feedback information of the k nearest neighbor packets, so as to achieve a balance between the decoding success rate and the decoding delay.
[0197] See also Fig.12 , exemplarily introduces a method flow for encoding by a transmitting end according to a first cascade length and first original data provided in an embodiment of the present application, the method may include the following steps:
[0198] Step S121: The sending end encodes the first original data of the first group to obtain initial encoded data.
[0199] The transmitting end may encode the first original data of the first packet according to a preset encoding scheme to obtain initial encoded data (inner code).
[0200] Step S122: When the first cascade length is 0, the sending end uses the initial coded data as the first coded data.
[0201] When the transmitting end determines not to perform cascade coding according to the feedback information (ie, the first cascade length is 0), the transmitting end may use the initial coded data as the first coded data, and send the first coded data to the receiving end.
[0202] Step S123, when the first cascade length is not 0, the sending end obtains data in other groups according to the first cascade length, uses the obtained data in other groups as first joint data, and jointly encodes the initial encoded data and the first joint data to obtain first encoded data, wherein the other groups are groups after the first group.
[0203] When the sending end determines to perform cascade coding based on the feedback information (that is, the first cascade length is not 0), the sending end obtains data (such as original data or encoded data) of the first cascade length from other groups after the first group as the first joint data, and cascade codes the first joint data with the initial encoded data to obtain first encoded data, and sends the first encoded data to the receiving end.
[0204] In the embodiment of the present application, the cascade operation performed by the sending end in the embodiment of the present application is different from the existing conventional cascade coding scheme in at least the following ways: the sending end performs the cascade operation backwards, that is, when the first cascade length is not 0, the sending end continues to obtain data of other groups after the current group, and uses the data from other groups after the current group as the first joint data, which can be the original data or encoded data (such as inner code) of other groups, wherein the length (quantity) of the first joint data is the first cascade length.
[0205] The packet loss protection method of the present application is introduced below from the perspective of the receiving end 20.
[0206] See also Fig.13 , exemplarily introduces the packet loss protection method provided by this application, which can be applied to Fig.13 The packet loss protection system 100 shown in FIG. Fig.13 The receiving end 20 shown executes.
[0207] Step S131: The receiving end obtains the first encoded data and the first concatenation length of the first group, wherein the first encoded data is the data obtained by the transmitting end after encoding according to the first concatenation length and the first original data of the first group, the first concatenation length is used to indicate the number of first joint data, the first joint data is the data in other groups used for joint encoding with the data of the first group, the first concatenation length is greater than or equal to 0 and less than or equal to the upper limit of the concatenation length, the upper limit of the concatenation length is determined according to a preset delay upper limit, and the preset delay upper limit is related to the first original data.
[0208] Among them, the relevant contents of the first group, the first original data, the first encoded data, the first cascade length, the preset delay upper limit value, other groups and the first joint data can be referred to above and will not be repeated here.
[0209] In an embodiment of the present application, when the receiving end cannot recover the original data of the first packet based on the first native data of the received first packet, the receiving end continues to obtain the first encoded data of the first packet sent by the sending end.
[0210] Step S132: The receiving end decodes the first encoded data according to the first cascade length to obtain first decoded data.
[0211] In an embodiment of the present application, when the receiving end decodes the first encoded data of the first group, the receiving end needs to perform joint decoding according to the first cascade length corresponding to the first group.
[0212] Please also read Fig.14 , exemplarily introduces a method for decoding first encoded data according to a first cascade length provided in an embodiment of the present application, the method may include the following steps:
[0213] Step S141, when the first cascade length is 0, the receiving end decodes the first encoded data.
[0214] When the receiving end receives that the first cascade length is 0, the receiving end decodes the first coded data according to the coding scheme used to encode the first coded data.
[0215] Step S142: when the first cascade length is not 0, the receiving end obtains corresponding first joint data from other groups according to the first cascade length, where the other groups are groups after the first group.
[0216] The receiving end obtains first joint data of a number equal to the first concatenation length from other packets to perform joint decoding based on the first joint data.
[0217] Step S143: The receiving end performs decoding according to the first coded data and the first joint data.
[0218] The receiving end performs decoding based on the first coded data and the first joint data.
[0219] For the content related to joint decoding, reference may be made to the joint decoding of the existing cascade coding scheme, which will not be described in detail here.
[0220] Below from Figure 3 (b) in the figure explains the perspectives of each module. Please also refer to Figure 3 (b) and Fig.15 , an example is given to introduce the packet loss protection method provided by the implementation of this application.
[0221] Step S150: the first acquisition module 11 acquires the original data packet.
[0222] Exemplarily, the first acquisition module 11 continuously acquires original data packets from the application layer. The original data packets may be real-time communication data.
[0223] In step S151 , the first acquisition module 11 transmits the original data packet to the encoding module 15 , and transmits relevant information of the original data packet to the control module 14 .
[0224] Among them, the relevant information corresponding to the original data packet can refer to the above-mentioned related content, which can be a preset delay upper limit value, or the application corresponding to the original data packet, or the application type corresponding to the application (the application corresponding to the original data packet), or the service to be transmitted corresponding to the original data packet.
[0225] In some embodiments, the first acquisition module 11 determines the corresponding preset delay upper limit value according to the preset delay comparison table and the service to be transmitted (the corresponding application program or the corresponding application type) corresponding to the original data packet obtained by it.
[0226] In some embodiments, the first acquisition module 11 can be implemented as an application program, which continuously generates original data packets to be transmitted, transmits the generated original data packets to the encoding module 15 , and transmits corresponding related information to the control module 14 .
[0227] Step S152: the encoding module 15 encodes the original data packet transmitted by the first acquisition module 11 to obtain an inner code.
[0228] The encoding module 15 continuously receives the original data packets transmitted by the first acquisition module 11, and while sending the received original data packets to the downstream (such as the receiving end), the encoding module 15 caches the original data packets. Whenever the original data packets of a packet size are fully cached, the encoding module 15 encodes the number of inner layer coded data packets (inner codes) r according to the number of coded packets r determined by the control module 14 and the selected inner layer coding scheme, and the r inner codes are the initial coded data. If the cascade length corresponding to the current packet obtained by the encoding module 15 is 0 at this time, step S159 is executed. If the cascade length corresponding to the current packet obtained by the encoding module 15 is not 0 at this time, step S160 is executed.
[0229] In the embodiment of the present application, the control module 14 obtains the packet loss rate predicted by the packet loss prediction module 13, and then determines the number of coded packets according to the packet loss rate, and transmits the number of coded packets r to the coding module 15. The coding module 15 obtains the preset packet size to determine whether to cache the original data packets of a packet size according to the preset packet size.
[0230] In step S153 , the control module 14 determines a preset delay upper limit value according to the obtained relevant information, and then obtains a cascade length upper limit value according to the preset delay upper limit value.
[0231] The control module 14 determines a preset delay upper limit value of the current packet according to the obtained relevant information, and then obtains a cascade length upper limit value of the current packet according to the preset delay upper limit value.
[0232] In some embodiments, the control module 14 determines the corresponding preset delay upper limit value according to the preset delay comparison table and the relevant information corresponding to the original data packet obtained by it.
[0233] In some embodiments, the control module 14 obtains the preset upper delay limit value of the current packet according to the preset upper delay limit value transmitted by the first acquisition module 11 .
[0234] The details of step S153 can be found in the above Figure 4 and Figure 5 The relevant content will not be repeated here.
[0235] Step S154: the first transmission module 12 obtains feedback information sent by the receiving end.
[0236] The first transmission module 12 at the sending end continuously obtains feedback information from the receiving end. For details, please refer to the above Figure 6 and Figure 7 Related content.
[0237] Wherein, step S154 can be executed after the sending end 10 and the receiving end 20 establish communication.
[0238] In step S155 , the first transmission module 12 transmits the feedback information to the control module 14 .
[0239] Step S156: The control module 14 determines whether the current group needs joint coding according to the feedback information.
[0240] In the embodiment of the present application, the feedback information indicates the packet loss of the first link between the transmitting end 10 and the receiving end 20 before the transmitting end 10 sends the data of the current packet (such as coded data or original data) to the receiving end 20, and the control module 14 indicates whether the current packet needs to be jointly encoded according to the packet loss. When it is determined according to the feedback information that the packet loss prediction is not underestimated on the first link within the preset time period from the current packet, it is not necessary to jointly encode the current packet. Otherwise, it is necessary to jointly encode the current packet.
[0241] The content of step S156 can refer to Figure 6 , Figure 7 , Figure 8 , Fig. 9 The relevant content will not be repeated here.
[0242] In some embodiments, if there is no feedback information, such as no feedback information that meets a preset time period, the control module 14 may not perform cascading, or may perform cascading according to a default cascading length until feedback information is received.
[0243] If not, in step S157, the control module 14 obtains the cascade length of the current group as 0.
[0244] When it is determined according to step S155 that the current group does not need to be jointly encoded, the control module 14 sets the concatenation length of the current group to 0.
[0245] If yes, in step S158, the control module 14 obtains the concatenation length of the current group according to the feedback information and the first coefficient function, and the concatenation length is not zero.
[0246] When it is determined according to step S156 that the current group needs to be jointly encoded, the control module 14 sets the concatenation length of the current group to be non-0, and specifically sets the value of the concatenation length corresponding to the current group according to the feedback information and the first coefficient function.
[0247] The content of step S158 can refer to the above Fig.10 and Fig.11 The relevant content will not be repeated here.
[0248] In step S159 , the control module 14 transmits the concatenation length of the current group to the encoding module 15 .
[0249] It can be understood that the time when the control module 14 executes step S153, step S156 to step S159 and the time when the encoding module 15 executes step S152 can overlap, so that after the encoding module 15 encodes and obtains the initial encoded data (inner code), it can be directly determined whether to continue the joint encoding based on the cascade length of the current group transmitted by the control module 14.
[0250] Step S160: When the concatenation length corresponding to the current group is 0, the encoding module 15 uses the inner code as the first encoding data of the current group.
[0251] When the concatenation length is 0, the encoding module 15 transmits the inner code as the final encoded data packet (ie, the first encoded data) to the first transmission module 12 .
[0252] Step S161, when the cascade length corresponding to the current group is not 0, the encoding module 15 obtains the data in other groups according to the cascade length corresponding to the current group, uses the obtained data in other groups as joint data, and jointly encodes the inner code and the joint data to obtain the first encoded data of the current group, wherein the other groups are groups after the first group.
[0253] The cascade length corresponding to the current packet is not 0. The encoding module 15 obtains and caches data from other packets after the current packet (such as the original data packet from the application layer after the current packet) according to the size of the cascade length c corresponding to the current packet. When the size of the cached original data packet from other packets is the cascade length c, the cached original data packet is used as the joint data. The initial coded data (inner code) and the joint data with the cascade length c are encoded according to the selected outer coding scheme to generate an outer coding packet (outer code). The number of outer codes is r, and the r outer codes are the first coded data of the current packet.
[0254] In step S162 , the encoding module 15 transmits the first encoded data and the concatenation length of the current group to the first transmission module 12 .
[0255] When the encoding module 15 sends the first encoded data (inner code or outer code) downstream, it also sends four pieces of information: the packet ID of the current packet, the internal offset ID of the current packet, the coding rate of the current packet, and the cascade length of the current packet.
[0256] Step S163 : the second transmission module 21 obtains the first encoded data and the concatenation length transmitted by the first transmission module 12 .
[0257] In step S164 , the second transmission module 21 transmits the received first encoded data and the concatenation length to the decoding module 22 .
[0258] Step S165 , the decoding module 22 decodes the received first encoded data and the concatenation length to obtain decoded data.
[0259] Step S166 : the decoding module 22 transmits the decoded data to the second acquisition module 23 .
[0260] The second acquisition module 23 may be implemented as an application layer, and is used to present the received decoded data to the user.
[0261] Please also read Fig.16 , an exemplary introduction to the decoding method flow of the decoding module 22.
[0262] Step S171, the decoding module obtains the data packets sent by the transmitter, and reads the header of each data packet in turn to obtain the group ID, the offset ID within the group, the coding rate and the cascade length.
[0263] In the embodiment of the present application, when the cascade length of the current packet is 0, the decoding module obtains that the data packet sent by the transmitter is an inner code (i.e., an inner coding packet), and also obtains the packet ID, the offset ID within the group, the coding rate, and the cascade length of the current packet sent with the inner coding packet. When the cascade length of the current packet is not 0, the decoding module obtains that the data packet sent by the transmitter is an outer code (i.e., an outer coding packet after joint coding), and also obtains the packet ID, the offset ID within the group, the coding rate, and the cascade length of the current packet sent with the outer coding packet.
[0264] Step S172: the decoding module adds the data packet to the corresponding packet decoder.
[0265] The receiving end 20 continuously receives data packets (original data packets, inner codes, outer codes) from the sending end. The decoding module determines whether the received data packet belongs to a new packet based on the packet ID information of the data packet. If so, a new packet decoder is created for it. Otherwise, the data packet is added to the decoder of the existing corresponding packet.
[0266] Step S173: The decoding module determines whether the current packet is lost.
[0267] After receiving the data packet, the decoding module determines whether all the original data packets of the current group are received.
[0268] If not, in step S174, the decoding module outputs the data packet.
[0269] The decoding module determines that there is no packet loss in the current packet, indicating that the original data packets of the current packet have been received. Then, the process can proceed to step S174, and the decoding module can output the data of the current packet to the first acquisition module, such as delivering the real-time communication data of the current packet to the application layer.
[0270] If so, in step S175, the decoding module determines whether progressive decoding is satisfied.
[0271] The decoding module determines whether the current packet has packet loss. The decoding module determines whether the currently received data packet meets the progressive decoding requirements based on the inner code and outer code encoding scheme used during encoding, that is, whether the decoding operation can be performed only by the encoded packet of the current packet and the cascaded data packet. Among them, progressive decoding is an existing related technology and will not be described in detail here.
[0272] If yes, in step S176, the decoding module performs progressive decoding to recover the lost data packets.
[0273] When the decoding module performs progressive decoding, the decoding module performs outer layer decoding on the coded data packet of the current group and the coded data packet cascaded with the current group to obtain the inner layer coded packet, and then uses the inner layer coded packet to decode the lost data packet of the current group. If the decoding is successful, the lost data packet can be restored, and the process goes to step S174, otherwise, the process goes to step S177.
[0274] If not, in step S177, the decoding module determines whether joint decoding is satisfied.
[0275] The decoding module determines whether the currently received data packet meets the joint decoding requirements based on the inner code and outer code encoding schemes used during encoding, that is, whether the original data packets of two adjacent groups, the encoded data packets of each group and the joint data packet of the latter group can be jointly decoded.
[0276] When the decoding module performs joint decoding, it obtains data (ie, joint data) whose quantity is the concatenation length corresponding to the current group from other groups after the current group, so as to perform joint decoding based on the joint data.
[0277] If not, return to step S171, wait for the subsequent data packet, and execute again according to the received subsequent data packet Fig.16 Steps shown.
[0278] If so, in step S178, the decoding module performs joint decoding to recover the lost data packets.
[0279] Whether the decoding module can decode depends on the selected inner code and outer code encoding scheme. If the decoding is successful, the lost data packet can be recovered and the process goes to step S174. Otherwise, the process goes to step S171 and waits for the subsequent data packet. The process is executed again according to the received subsequent data packet. Fig.16 Steps shown.
[0280] Among them, joint coding is an existing related technology and will not be described in detail here.
[0281] Step S166: the decoding module transmits the data packet of the current group to the second acquisition module.
[0282] The decoding module transmits the decoded data packet of the current group to the second acquisition module, such as delivering the real-time communication data of the current group to the application layer.
[0283] See also Fig.17A , an example is given of the underestimated prediction of no packet loss, when the cascade length is 0 (i.e. no cascade) during encoding.
[0284] Initial parameter setting: Take the selected inner coding scheme and outer coding scheme as Reese (RS) code, the specified coding and decoding processing delay upper limit (preset delay upper limit) τ as 10ms, each packet size n is 50 data packets, each data packet size s=1400Byte, the sending rate b=100mbps, and the number of adjacent packets k=5 as an example.
[0285] The sending end (or control module) sets the upper limit of the cascade length, and the description is mainly based on the sending end.
[0286] The sender determines the cascade length upper limit to be 50Pkts based on the preset delay upper limit τ. Specifically, the sender obtains the existing empirical mapping relationship: the mapping relationship W between the time required for decoding operation using Reeso code and the number of data packets involved in decoding on the target server A is shown in Table 1.
[0287] Table 1
[0288] Number of packets (n+c) First delay W(n+c) 50pkts 1ms 100pkts 4ms 150pkts 8ms
[0289] According to the first formula of the upper limit of the cascade length:
[0290] W(50+c)+(c*1400Byte) / 100mbps≤10ms
[0291] It can be deduced that the maximum c value that satisfies the first formula above is 50 packets, so the upper limit of the cascade length Cmax =50.
[0292] The sending end dynamically sets the cascade length of the current group, and the description is based on the sending end.
[0293] The sender obtains feedback information from the receiver and collects the original data packets from the application layer. After receiving the feedback information from the receiver, it is found that there is no underestimation of packet loss prediction in the feedback information of adjacent packets, that is, the difference between the total packet loss length and the predicted packet loss length This indicates that the packet loss prediction algorithm is good in the current network environment. At this time, the cascade length is 0, which means that no additional cascade of other packet data is required to reduce the encoding and decoding processing delay. At the same time, according to the predicted packet loss rate, the number of coded packets in the current group is set to 3.
[0294] After collecting all the original data packets of a group size, the encoding module at the sending end encodes 3 encoding packets according to the number of encoding packets set by the control module, namely RS(50,3). Since the cascade length of the current group corresponds to 0, the inner encoding packet is directly sent to the receiving end as the final encoding result. At the same time, the four-element information corresponding to each encoding packet (packet ID, internal offset ID, coding rate, cascade length) is sent with the packet.
[0295] After receiving data packets of a preset grouping size (such as 50 data packets), the receiving end can directly decode these 50 data packets to obtain all original data packets of the current grouping because the packet cascade length is 0.
[0296] See also Fig. 17B , an example is given of a scenario where the packet loss of adjacent packets is underestimated, the sender dynamically decides the cascade length, and the receiver uses the joint data to assist in recovering the original data packets of the packets.
[0297] Fig. 17B The initial parameter settings and the upper limit of the cascade length are the same as Fig.17A resemblance, Fig. 17B and Fig.17A The difference is:
[0298] The feedback information received by the transmitter is different from that of the receiver. After receiving the feedback information from the receiver, the transmitter finds that the packet loss is underestimated in the feedback information of the adjacent group. The transmitter dynamically decides the cascade length c of the current group to be 20 based on the maximum burst packet loss length of the adjacent group and the number of coded packets corresponding to these groups. At the same time, the number of coded packets of the current group is set to 3 based on the packet loss rate predicted by the packet loss prediction module.
[0299] Specifically, because the number of adjacent groups to be fed back is 5, the five adjacent groups closest to the current group are determined to be G1 to G5. The feedback information of the five adjacent groups and the intermediate variables derived from the feedback information and the known information of the transmitter are shown in Table 2 below.
[0300] Table 2
[0301] Group id G1 G2 G3 G4 G5 <![CDATA[Predicted number of lost packets r i > 5 10 5 5 10 <![CDATA[Actual packet loss quantity l i > 4 11 4 3 10 <![CDATA[Packet loss prediction error σ i > -1 1 -1 -2 0 <![CDATA[Maximum burst packet loss length b i > 3 9 2 1 3
[0302] Because there is σ i >0, so combined coding is adopted, and 4 combinations are set in these five adjacent groups, namely the first combination (G1, G2), the second combination (G2, G3), the third combination (G3, G4), and the fifth combination (G4, G5). The smoothing coefficients of these groups of combinations are set equal, that is, α1=α2=α3=α4=0.25.
[0303] Then the cascade length of the current group is:
[0304]
[0305] After collecting all the original data packets of a group size, the encoding module at the transmitting end first performs inner encoding according to the number of encoding packets set by the control module, and encodes 3 encoding packets, namely RS (50, 3). After that, the cascade length corresponding to this group in this example is 20, and it continues to wait for the 20 original data packets after the current group. When the encoding module continues to collect all the 20 original data packets from other groups, it performs outer encoding on the 3 encoding packets obtained by the inner encoding and the 20 original data packets to be cascaded. The outer encoding scheme is RS, so the outer encoding is RS (3 + 20, 3), and 3 outer encoding packets are obtained. Finally, the three outer encoding packets are sent to the receiving end as the final encoding result, and at the same time, the four-element information corresponding to each encoding packet (packet ID, internal offset ID, coding rate, cascade length) is sent with the packet.
[0306] After receiving the current packet, the receiver can read the cascade length, coding rate and other information for synchronization. After collecting the original data packets of the packet, if it is found that the data packets are not lost, they can be delivered directly to the application layer. In this example, we show that the original data packet of the current packet is lost, and decoding is required to restore the original data. After reading the packet header, it is found that the cascade length of the packet is 20, so wait for the first 20 original data packets of the next packet, and decode them together with the coded packet of the current packet, that is, outer decoding, to obtain the inner coded packet, and then the inner coded packet is inner-decoded with the received data packet in the current packet to obtain all the original data packets.
[0307] See also Fig.18, the decoding success rate of the packet loss protection method provided in the embodiment of the present application is exemplified by the following test environment. The test environment is: a sender and a receiver are built using a virtual machine, and the link between the sender and the receiver is a lossy link, which can simulate random burst packet loss. Coding parameters: the packet size is 50, the size of each data packet is s=1400Byte, the coding rate is 10%, and the preset delay upper limit value τ is 10ms. Packet loss parameters: burst packet loss, the burst packet loss length is a random integer between [0, 10], and the probability of underestimation predicted by the sender is 0.5.
[0308] like Fig.18 As shown, the result of the decoding success rate is: the packet loss protection method provided in the embodiment of the present application can increase the average decoding success rate to 84.5% (an increase of about 35%) compared with the packet-independent coding scheme (such as RS) under the condition of meeting the preset delay upper limit value (the application's requirement for the coding and decoding processing delay). The cascade coding scheme MGM has a decoding success rate close to 100%, but it cannot meet the application's requirement for the coding and decoding processing delay.
[0309] See also Fig.19 , exemplarily introduces the electronic device structure diagram provided by the embodiment of the present application. The electronic device 190 may correspond to the transmitting end 10 or the receiving end 20 in some of the above embodiments, and may be used to execute the various processes and / or steps corresponding to the transmitting end 10 or the receiving end 20 in the above method embodiment. To avoid repetition, it will not be described in detail here. Fig. 9 As shown, the electronic device 190 includes a processor 1010, a memory 1020, a bus system 1030, a receiver 1040, and a transmitter 1050. The processor 1010, the memory 1020, the receiver 1040, and the transmitter 1050 are connected via the bus system 1030. The memory 1020 is used to store instructions, and the processor 1010 is used to execute the instructions stored in the memory 1020, and the execution of the instructions stored in the memory 1020 enables the processor 1010 to control the receiver 1040 to receive signals and control the transmitter 1050 to send signals. The processor 1010 can be used to execute the above Figures 4 to 16 The various processes and / or steps in.
[0310] Optionally, in the embodiment of the present invention, the processor 1010 may be a central processing unit (CPU), and the processor 1010 may also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. Among them, the general-purpose processor may be a microprocessor or any conventional processor, etc.
[0311] The memory 1020 may include a read-only memory and a random access memory, and provides instructions and data to the processor 1010. A portion of the memory 1020 may also include a nonvolatile random access memory. For example, the memory 1020 may also store information on the device type.
[0312] In addition to the data bus, the bus system 1030 may also include a power bus, a control bus, a status signal bus, etc. However, for the sake of clarity, various buses are labeled as the bus system 1030 in the figure.
[0313] In the implementation process, each step of the above method can be completed by an integrated logic circuit of hardware in the processor 1010 or an instruction in the form of software. The steps of the method disclosed in conjunction with the embodiment of the present invention can be directly embodied as being executed by a hardware processor, or can be executed by a combination of hardware and software modules in the processor. The software module can be located in a mature storage medium in the art such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory or an electrically erasable programmable memory, a register, etc. The storage medium is located in the memory 1020, and the processor 1010 reads the information in the memory 1020 and completes the steps of the above method in conjunction with its hardware. To avoid repetition, it will not be described in detail here.
[0314] An embodiment of the present application provides a chip system, which is applied to an electronic device; the chip system includes an interface circuit and a processor; the interface circuit and the processor are interconnected through lines; the processor includes a first processor core; the interface circuit is used to receive a signal from a memory of the electronic device and send a signal to the processor, the signal including a computer instruction stored in the memory; when the processor executes the computer instruction, the chip system executes the above-mentioned packet loss protection method.
[0315] The embodiment of the present application also provides a computer program product. When the computer program product is run on a computer, the computer executes the above-mentioned related steps to implement the packet loss protection method for the application in the above-mentioned method embodiments.
[0316] An embodiment of the present application also provides a computer storage medium, including computer instructions. When the computer instructions are executed on an electronic device, the electronic device executes the packet loss protection method as described in the above embodiment.
[0317] Among them, the electronic device, computer storage medium, computer program product or chip system provided in the embodiments of the present application are all used to execute the corresponding methods provided above. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding methods provided above, and will not be repeated here.
[0318] Through the description of the above implementation methods, technical personnel in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional modules is used as an example. In actual applications, the above-mentioned functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above.
[0319] In the several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the modules or units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another device, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0320] The unit described as a separate component may or may not be physically separated, and the component shown as a unit may be one physical unit or multiple physical units, that is, it may be located in one place or distributed in multiple different places. Some or all of the units may be selected according to actual needs to achieve the purpose of the embodiment.
[0321] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0322] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a readable storage medium. Based on this understanding, the technical solution of the embodiment of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium, including several instructions to enable a device (which can be a single-chip microcomputer, chip, etc.) or a processor (processor) to perform all or part of the steps of each embodiment method of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), disk or optical disk and other media that can store program code.
[0323] The above are only specific implementation methods of the present application, but the protection scope of the present application is not limited thereto, and any changes or substitutions within the technical scope disclosed in the present application should be included in the protection scope of the present application.
Claims
1. A packet loss protection method, characterized in that: Applied to the sending end, the method includes: Acquire first original data of the first group; Obtaining a first concatenation length corresponding to the first group, wherein the first concatenation length is used to indicate the amount of first joint data, the first joint data is data in other groups used for concatenation encoding with the data of the first group, the first concatenation length is greater than or equal to 0 and less than or equal to an upper limit of the concatenation length, the upper limit of the concatenation length is determined according to a preset upper limit of the delay, and the preset upper limit of the delay is related to the first original data; Encoding is performed according to the first concatenation length and the first original data to obtain first encoded data; The first encoded data and the first concatenation length are sent to a receiving end.
2. The packet loss protection method according to claim 1, characterized in that: The obtaining the first cascade length corresponding to the first group includes: Acquire feedback information sent by the receiving end, wherein the feedback information is used to indicate packet loss on a first link, where the first link is a link between the sending end and the receiving end; The first cascade length corresponding to the first group is obtained according to the feedback information.
3. The packet loss protection method according to claim 2, characterized in that: The method further comprises: The more serious the packet loss situation of the first link is, the closer the first cascade length is to the upper limit of the cascade length.
4. The packet loss protection method according to claim 2 or 3, characterized in that: The obtaining, according to the feedback information, the first cascade length corresponding to the first group includes: When it is determined according to the feedback information that packet loss prediction underestimation does not occur, obtaining the first cascade length as 0; When it is determined according to the feedback information that the packet loss prediction is underestimated, the first cascade length is obtained according to the feedback information and the upper limit of the cascade length, and the first cascade length is greater than 0.
5. The packet loss protection method according to claim 4, characterized in that: The obtaining of feedback information sent by the receiving end includes: Determine k adjacent groups, wherein the adjacent groups are groups adjacent to the first group among the groups sent by the sender, and k is an integer greater than or equal to 2; For each of the adjacent packets, feedback information of the adjacent packets sent by the receiving end is obtained, wherein the feedback information includes a total packet loss length and a burst packet loss length.
6. The packet loss protection method according to claim 5, characterized in that: The method further comprises: Get the predicted packet loss length; For each of the adjacent groups, according to the total packet loss length and the predicted packet loss length corresponding to the adjacent group, obtain the packet loss prediction of the adjacent group; Determine whether packet loss prediction underestimation occurs according to packet loss prediction conditions of each of the adjacent packets.
7. The packet loss protection method according to claim 5 or 6, characterized in that: The obtaining the first cascade length according to the feedback information and the cascade length upper limit includes: Determine a first coefficient according to the burst packet loss length of each of the adjacent packets, wherein the first coefficient is greater than 0 and less than or equal to 1; The first cascade length is obtained according to the first coefficient and the cascade length upper limit.
8. The packet loss protection method according to claim 7, characterized in that: Determining the first coefficient according to the burst packet loss length of each of the adjacent packets comprises: Obtain a first coefficient function F, wherein the first coefficient function F is: Wherein, k is the number of adjacent groups, and the α i is the smoothing coefficient of the i-th group combination, and The combination is a combination of two adjacent adjacent groups among the k adjacent groups, b i is the burst packet loss length of adjacent packet i, r i is the number of coded packets of adjacent group i; Obtaining the smoothing coefficient and the number of encoding packets; Determine a first coefficient according to the smoothing coefficient, the number of coded packets, the burst packet loss length, and the first coefficient function F; Then obtaining the first cascade length according to the first coefficient and the cascade length upper limit includes: Where C1 is the first cascade length, C max is the upper limit of the cascade length.
9. The packet loss protection method according to any one of claims 1 to 8, characterized in that: The method further comprises: The cascade length upper limit value is obtained according to that the decoding delay of the receiving end is less than or equal to the preset delay upper limit value, wherein the decoding delay of the receiving end includes a first delay and a waiting delay for waiting to receive the joint data, wherein the first delay is a delay corresponding to a decoding operation on the joint data and original data of a preset group size, and the preset group size is consistent with the group size of the first group.
10. The packet loss protection method according to claim 9, characterized in that: The obtaining the cascade length upper limit value according to the decoding delay of the receiving end being less than or equal to the preset delay upper limit value comprises: The first formula is obtained according to that the decoding delay of the receiving end is less than or equal to the preset delay upper limit value: W(n+c)+(c*s) / b≤τ Wherein, W(n+c) is the first delay, n is the preset packet size, c is the size of the joint data, W is an empirical function, s is the size of a single data, b is the sending rate, and τ is the preset delay upper limit value; c that satisfies the maximum value in the first formula is used as the upper limit of the cascade length.
11. The packet loss protection method according to any one of claims 1 to 10, characterized in that: The encoding according to the first cascade length and the first original data to obtain the first encoded data includes: Encoding the first original data of the first group to obtain initial encoded data; When the first cascade length is 0, using the initial encoded data as the first encoded data; When the first cascade length is not 0, the data in the other groups are obtained according to the first cascade length, and the data in the other groups obtained are used as the first joint data, and the initial encoded data and the first joint data are cascade encoded to obtain the first encoded data, wherein the other groups are groups after the first group.
12. A packet loss protection method, characterized in that: Applied to the receiving end, the method includes: Acquire first coded data and a first concatenation length of a first group, wherein the first coded data is data obtained after a transmitter encodes the first concatenation length and first original data of the first group, the first concatenation length is used to indicate the amount of first joint data, the first joint data is data in other groups used for concatenation coding with data of the first group, the first concatenation length is greater than or equal to 0 and less than or equal to an upper limit of the concatenation length, the upper limit of the concatenation length is determined according to a preset upper limit of a delay, and the preset upper limit of a delay is related to the first original data; The first encoded data is decoded according to the first cascade length to obtain first decoded data.
13. The packet loss protection method according to claim 12, characterized in that: The decoding of the first encoded data according to the first concatenation length comprises: When the first cascade length is 0, decoding the first encoded data; When the first cascade length is not 0, acquiring corresponding first joint data from the other groups according to the first cascade length, wherein the other groups are groups after the first group; Decoding is performed according to the first encoded data and the first joint data.
14. A transmitting end, characterized in that: include: A first acquisition module, used to acquire first original data of a first group; a control module, configured to obtain a first concatenation length corresponding to the first group, wherein the first concatenation length is used to indicate the amount of first joint data, the first joint data is data in other groups used for concatenation encoding with the data of the first group, the first concatenation length is greater than or equal to 0 and less than or equal to an upper limit of the concatenation length, the upper limit of the concatenation length is determined according to a preset upper limit of a delay, and the preset upper limit of the delay is related to the first original data; an encoding module, configured to perform encoding according to the first cascade length and the first original data to obtain first encoded data; The first transmission module is used to send the first encoded data and the first cascade length to a receiving end.
15. The transmitting end according to claim 14, characterized in that: The control module is used to execute the packet loss protection method as described in any one of claims 2 to 10.
16. The transmitting end according to claim 14 or 15, characterized in that: The encoding module is used to execute the packet loss protection method as described in claim 11.
17. The transmitting end according to any one of claims 14 to 16, characterized in that: The first transmission module is also used to obtain network status and feedback information, and transmit the feedback information to the control module; The transmitting end also includes: A packet loss prediction module, used for predicting a packet loss rate according to the network status, and transmitting the packet loss rate to the control module; The control module is further configured to obtain a preset upper limit value of the delay, and update the cascade length corresponding to each packet according to the packet loss rate, the feedback information and the preset upper limit value of the delay.
18. A receiving end, characterized in that: The receiving end comprises: A second transmission module, configured to obtain first coded data and a first concatenation length of a first packet, wherein the first coded data is data obtained after a transmitter encodes the first concatenation length and the first original data of the first packet, the first concatenation length is used to indicate the amount of first joint data, the first joint data is data in other packets used for concatenation coding with the data of the first packet, the first concatenation length is greater than or equal to 0 and less than or equal to an upper limit of the concatenation length, the upper limit of the concatenation length is determined according to a preset upper limit of a delay, and the preset upper limit of a delay is related to the first original data; A decoding module is used to decode the first encoded data according to the first cascade length to obtain first decoded data.
19. The receiving end according to claim 18, characterized in that: The decoding of the first encoded data according to the first concatenation length comprises: When the first cascade length is 0, decoding the first encoded data; When the first cascade length is not 0, acquiring corresponding first joint data from the other groups according to the first cascade length, wherein the other groups are groups after the first group; Decoding is performed according to the first encoded data and the first joint data.
20. A packet loss protection system, characterized in that: The method comprises a network, a sending end according to any one of claims 14 to 17, and a receiving end according to claims 18 and 19, wherein the sending end communicates with the receiving end through the network.
21. An electronic device, characterized in that: include: Processor and memory; The memory is used to store a computer program, wherein the computer program includes program instructions; The processor is used to call the computer program to execute the packet loss protection method as described in any one of claims 1 to 11, or to execute the packet loss protection method as described in claim 12 or 13.
22. A chip system, the chip system is applied to electronic equipment, characterized in that: The chip system includes an interface circuit and a processor; the interface circuit and the processor are interconnected through a line; the interface circuit is used to receive a signal from the memory of the electronic device and send a signal to the processor, the signal including a computer instruction stored in the memory; when the processor executes the computer instruction, The chip system executes the packet loss protection method as described in any one of claims 1 to 11, or executes the packet loss protection method as described in claim 12 or 13.
23. A computer storage medium, characterized in that It comprises computer instructions, which, when executed on an electronic device, enable the electronic device to execute the packet loss protection method as claimed in any one of claims 1 to 11, or execute the packet loss protection method as claimed in claim 12 or 13.
24. A computer program product, characterized in that When the computer program product runs on a computer, the computer is enabled to execute the packet loss protection method according to any one of claims 1 to 11, or the packet loss protection method according to claim 12 or 13.
