A decoding method, apparatus, device, medium, and product for multi-hop network BATS codes.

CN122578091APending Publication Date: 2026-08-1410TH RES INST OF CETC
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-07-16
Publication Date
2026-08-14

AI Technical Summary

Technical Problem

[0005]本申请旨在提供一种多跳网络BATS码的译码方法、装置、设备、介质及产品,以解决译码效率低的问题

Benefits of technology

[0007]本申请提供的技术方案至少带来以下有益效果:通过中继节点发送的多个批次的编码包,计算获取各批次中全部编码包能够直接成功译出数据的概率,根据各译码概率,确定多个批次的译码顺序,基于译码顺序,对多个批次的编码包进行译码。如此,通过各批次的译码概率,对多个批次进行译码,使得译码概率高的批次能够优先被译码,以较大译码概率进行少量迭代,降低了迭代次数,从而降低了BP迭代译码所消耗的时间,进而提高了译码效率。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122578091A_ABST
    Figure CN122578091A_ABST
Patent Text Reader

Abstract

This invention belongs to the field of wireless communication and provides a decoding method, apparatus, device, medium, and product for BATS codes in multi-hop networks to improve decoding efficiency. The invention calculates the probability that all encoded packets in each batch can be successfully decoded directly from multiple batches sent by relay nodes. Based on these decoding probabilities, the decoding order of the multiple batches is determined. Decoding is then performed on the multiple batches of encoded packets based on this decoding order, thereby reducing the time consumed by BP iterative decoding and thus improving decoding efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of wireless communication, and more specifically, to a decoding method, apparatus, device, medium, and product for BATS codes in multi-hop networks. Background Technology

[0002] In multi-hop wireless communication networks, packet loss is possible at each relay stage due to the need for multiple relays. Therefore, transmitting the complete data packet from the source node to the destination node requires additional redundant data packet transmission, increasing network latency. Batched Sparse Network Coding (BATS) is a solution aimed at addressing the high decoding overhead and latency of network coding.

[0003] Batch sparse network coding refers to selecting a certain number of packets from the original data packets for each coding batch, multiplying them with a random matrix, and outputting a fixed number of packets. The degree distribution determines the number of data packets transmitted in each batch. For example, selecting 10 data packets and multiplying them with a random coding matrix of 10 rows and 7 columns results in 7 coded data packets for transmission.

[0004] However, after receiving a certain batch of data packets, the decoding end attempts to decode them, typically using backpropagation (BP) iterative decoding. This involves continuously performing Gaussian elimination and degree reduction matrix processing on these batches of data packets until all data packets are decoded, or until effective Gaussian elimination can no longer be performed. The numerous iterative processes significantly increase decoding time and reduce decoding efficiency. Summary of the Invention

[0005] This application aims to provide a decoding method, apparatus, device, medium, and product for multi-hop network BATS codes to solve the problem of low decoding efficiency.

[0006] Firstly, this application provides a decoding method for multi-hop network BATS codes, including: Obtain multiple batches of encoded packets sent by the relay node; where each batch corresponds to multiple encoded packets, and the encoded packets are used to indicate the data packets obtained by encoding the original data through random sparse linear combination; Obtain the decoding probability for each batch; where the decoding probability indicates the probability that all encoded packets in the corresponding batch can be successfully decoded directly. The decoding order of multiple batches is determined based on the decoding probabilities of each batch. Based on the decoding order, multiple batches of encoded packets are decoded.

[0007] The technical solution provided in this application offers at least the following advantages: By calculating the probability that all encoded packets in each batch can be successfully decoded directly from multiple batches sent by relay nodes, the decoding order of the multiple batches is determined based on the decoding probabilities, and the encoded packets in the multiple batches are decoded based on this decoding order. In this way, by decoding multiple batches based on their decoding probabilities, batches with higher decoding probabilities are decoded first, allowing for fewer iterations with a higher decoding probability, thus reducing the number of iterations and the time consumed by BP iterative decoding, thereby improving decoding efficiency.

[0008] One possible implementation involves obtaining the decoding probability for each batch, including: In multiple batches, the target batch set and candidate batch set are determined based on the number of rows and columns of the encoding matrix where the encoded packet is located; Among them, the target batches in the target batch set can be directly and successfully translated into data, the candidate batches in the candidate batch set cannot be directly and successfully translated into data, and the target batch set includes at least one target batch; The decoding probability of a batch in the target batch set is less than or equal to one.

[0009] One possible implementation involves determining a target batch set and a candidate batch set based on the number of rows and columns of the encoding matrix of the encoded packets across multiple batches, including: For a coding matrix consisting of multiple coding packets in the same batch, if the number of columns in the coding matrix is ​​greater than or equal to the number of rows in the coding matrix, the corresponding batch is marked as the target batch. If the number of columns in the encoding matrix is ​​less than the number of rows in the encoding matrix, the corresponding batch is marked as a candidate batch; Update the target batch set based on the intersection of the original data packet numbers of the candidate batches in the candidate batch set and the target numbers; The original data packet is the unencoded data corresponding to the encoded packet, and the intersection of the target numbers is used to indicate the original data packet number in the candidate batch and the original data packet number in the target batch.

[0010] One possible implementation involves updating the target batch set based on the intersection of the original data packet numbers of the candidate batches in the candidate batch set and the target numbers, including: When the difference between the number of original data packets in the candidate batch and the number of original data packets with the same number in the intersection of the target number is less than or equal to the number of rows in the encoding matrix of the corresponding candidate batch, the current candidate batch is marked as the target batch, and the decoding probability of the current target batch is updated to the target batch set. If the difference between the number of original data packets in the candidate batch and the number of original data packets with the same number in the intersection of the target number is greater than the number of rows in the encoding matrix of the corresponding candidate batch, it is determined that the decoding probability of the corresponding candidate batch cannot be obtained, and the candidate batch is not updated to the target batch set.

[0011] In one possible implementation, the decoding probability of the current target batch is calculated using the following formula: ; in, For decoding probability, This represents the number of original data packets in the candidate batch. This represents the number of original data packets with the same ID in the intersection of the target IDs. This represents the number of batches sent by the relay node. It is the product of the decoding probabilities of each target batch in the target batch set. The target batch number is the number of each target batch in the intersection of target numbers.

[0012] One possible implementation involves determining the decoding order of multiple batches based on each decoding probability, including: In the target batch set, the target batches are sorted in descending order according to their decoding probability. The sorted order of each target batch is marked as the decoding order, so that the matrix degree reduction and Gaussian elimination are performed on each target batch in sequence based on the decoding order to achieve decoding.

[0013] Secondly, this application provides a decoding apparatus for multi-hop network BATS codes, comprising: The acquisition module is used to acquire multiple batches of encoded packets sent by the relay node; each batch corresponds to multiple encoded packets, and the encoded packets are used to indicate the data packets obtained by encoding the original data through random sparse linear combination. The processing module is used to obtain the decoding probability of each batch; the decoding probability is used to indicate the probability that all encoded packets in the corresponding batch can be successfully decoded directly. The processing module is also used to determine the decoding order of multiple batches based on the decoding probabilities of each batch. The processing module is also used to decode multiple batches of encoded packets based on the decoding order.

[0014] Thirdly, this application provides an electronic device comprising: a processor and a memory; the memory storing processor-executable instructions; when the processor is configured to execute the instructions, causing the electronic device to implement the method of the first aspect described above.

[0015] Fourthly, this application provides a computer-readable storage medium comprising: computer software instructions; which, when executed in an electronic device, cause the electronic device to implement the method described in the first aspect.

[0016] Fifthly, this application provides a computer program product comprising a computer program that, when run on an electronic device, causes the electronic device to perform the method described in the first aspect.

[0017] The beneficial effects of the second to fifth aspects mentioned above are described in the corresponding description of the first aspect and will not be repeated here. Attached Figure Description

[0018] Figure 1 A flowchart illustrating a decoding method for a multi-hop network BATS code provided in this application embodiment; Figure 2 A schematic diagram of a system framework provided for an embodiment of this application; Figure 3 A schematic diagram illustrating the composition of a decoding device for a multi-hop network BATS code provided in this application embodiment; Figure 4 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation

[0019] In this article, the term "and / or" is merely a description of the relationship between related objects, indicating that there can be three relationships. For example, A and / or B can represent three situations: A exists alone, A and B exist simultaneously, and B exists alone.

[0020] Furthermore, the terms "comprising" and "having," and any variations thereof, used in the description of this application are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or apparatus that includes a series of steps or units is not limited to the steps or units listed, but may optionally include other steps or units not listed, or may optionally include other steps or units inherent to such process, method, product, or apparatus.

[0021] It should be noted that in the embodiments of this application, the words "exemplary" or "for example" are used to indicate examples, illustrations, or explanations. Any embodiment or design scheme described as "exemplary" or "for example" in the embodiments of this application should not be construed as being more preferred or advantageous than other embodiments or design schemes. Specifically, the use of the words "exemplary" or "for example" is intended to present the relevant concepts in a specific manner.

[0022] In the description of this application, unless otherwise stated, "a plurality of" means two or more.

[0023] First, let's introduce some typical BATS code application scenarios: the encoding is separated into different parts, and the original data packet is... ,in, , , K is the number of original data packets, and L is the number of symbols in a data packet.

[0024] Encoding each batch involves randomly selecting a certain number of original data packets from the original data packets according to a certain degree distribution and encoding them. Let the number of selected packets be... If there are 1, then select randomly. Encode each raw data packet, assuming the selected data packet is... The encoding matrix is ​​a randomly generated full-rank matrix. , ,in To determine the number of encoded data packets generated after encoding, the encoding process is as follows: ; One encoded data packet, also known as an encoded packet, can be represented as: ,in, , , .

[0025] The BP decoding process at the decoding end is as follows: First, based on the coding coefficient matrix of each batch, calculate the equivalent coding coefficient matrix for that batch. Taking the first batch as an example... Taking batch as an example, the coding coefficient matrix is ​​as follows: .

[0026] Secondly, find batches whose equivalent coding coefficient matrices are invertible. If such a batch exists, invert the equivalent coding coefficient matrix of that batch to recover the original data packets contained in that batch. (The text then repeats the first step.) Taking batches as an example, if the equivalent coding coefficient matrix Reversible, then .if Once all the original data packets have been decoded, the receiving end sends a decoding success signal to the sending end, and the decoding process ends.

[0027] Next, the recovered original data packets are used to downgrade other batches. If any original data packets are decoded, for each batch with an invertible equivalent coding coefficient matrix, if the batch contains decoded original data packets, these original data packets are removed from the corresponding coded data packets in that batch, until these batches no longer contain decoded original data packets, and then a batch with an invertible equivalent coding coefficient matrix is ​​searched again. (The process continues with the example of the first batch.) Taking batches as an example, if the equivalent coding coefficient matrix Irreversible, and the first Some raw data packets included in the batch Since it has already been translated, then for the first... Batch downgrading, downgraded encoded data packets ,in express middle The corresponding row vector.

[0028] The decoding process iterates between the steps described above until it can no longer be reduced or the decoding process ends.

[0029] However, after receiving multiple batches of data packets, the decoding end usually uses BP iterative decoding. In BP iterative decoding, when the data packets are large, Gaussian elimination and degree reduction processing will take up a lot of time, thus increasing the decoding time and reducing the decoding efficiency.

[0030] To address the aforementioned technical problems, this application provides a method, apparatus, device, medium, and product for decoding BATS codes in multi-hop networks. It calculates the probability that all encoded packets in each batch can be successfully decoded directly from multiple batches sent by relay nodes. Based on these decoding probabilities, the decoding order of the multiple batches is determined, and the encoded packets in each batch are decoded according to this order. By decoding multiple batches based on their decoding probabilities, batches with higher decoding probabilities are decoded first, allowing for fewer iterations with higher decoding probabilities. This reduces the number of iterations, thereby reducing the time consumed by BP iterations and improving decoding efficiency.

[0031] The following description, in conjunction with the accompanying drawings, details a decoding method for a multi-hop network BATS code provided in this application.

[0032] Figure 1 This is a flowchart illustrating a decoding method for a multi-hop network BATS code provided in an embodiment of this application. Figure 2 This is a schematic diagram of a system framework provided for an embodiment of this application. (In conjunction with...) Figure 1 and Figure 2 The following describes the decoding method for multi-hop network BATS codes provided in the embodiments of this application: S101. Obtain multiple batches of encoded packets sent by the relay node.

[0033] Each batch corresponds to multiple encoding packets, which are used to indicate data packets obtained by encoding the original data through random sparse linear combinations.

[0034] For example, such as Figure 2As shown, the DDR (Double Data Rate SDRAM) stores a total of L batches, and their encoding matrices... Each matrix has 10 rows. The number of columns is Participating in coding The indices of the raw data packets are respectively .

[0035] For example, when decoding begins, the DDR first outputs all stored batches to the pre-decoding unit, calculates the decoding probability of each batch, then arranges the decoding order according to the decoding probability, reads the batch with the highest decoding probability in advance, performs matrix reduction, performs Gaussian elimination, stores the decoded data packets in RAM, and participates in the next matrix reduction.

[0036] S102. Obtain the decoding probability of each batch.

[0037] The decoding probability indicates the probability that all encoded packets in the corresponding batch can be successfully decoded directly.

[0038] In one possible implementation, the pre-decoding unit determines the target batch set and the candidate batch set in multiple batches based on the number of rows and columns of the encoding matrix where the encoded packet is located.

[0039] Among them, the target batches in the target batch set can be directly and successfully decoded, the candidate batches in the candidate batch set cannot be directly and successfully decoded, and the target batch set includes at least one target batch; the decoding probability of the batches in the target batch set is less than or equal to one.

[0040] Furthermore, regarding the determination of the target batch set and candidate batch set based on the row and column numbers of the encoding matrix where the encoded packets reside across multiple batches, the following explanation is provided: For a coding matrix consisting of multiple coding packets in the same batch, if the number of columns in the coding matrix is ​​greater than or equal to the number of rows in the coding matrix, the corresponding batch is marked as the target batch.

[0041] For example, select all batch matrices with a number of columns greater than the number of rows, and set their decoding probability to 1, i.e., for... ,make The encoding of the original data packets corresponding to these matrices is then incorporated into the pre-decoded data packet set, i.e., the target batch set. .

[0042] For a coding matrix consisting of multiple coding packets in the same batch, if the number of columns in the coding matrix is ​​less than the number of rows in the coding matrix, the corresponding batch is marked as a candidate batch.

[0043] Update the target batch set based on the intersection of the original data packet numbers of the candidate batches in the candidate batch set and the target numbers.

[0044] The original data packet is the unencoded data corresponding to the encoded packet, and the intersection of the target numbers is used to indicate the original data packet number in the candidate batch and the original data packet number in the target batch.

[0045] Furthermore, the following explanation is provided regarding updating the target batch set based on the intersection of the original data packet numbers of the candidate batches in the candidate batch set and the target numbers: When the difference between the number of original data packets in the candidate batch and the number of original data packets with the same number in the intersection of the target number is less than or equal to the number of rows in the encoding matrix of the corresponding candidate batch, the current candidate batch is marked as the target batch, and the decoding probability of the current target batch is updated in the target batch set.

[0046] The decoding probability of the current target batch is calculated using the following formula: ; in, For decoding probability, This represents the number of original data packets in the candidate batch. This represents the number of original data packets with the same ID in the intersection of the target IDs. This represents the number of batches sent by the relay node. It is the product of the decoding probabilities of each target batch in the target batch set. The target batch number is the number of each target batch in the intersection of target numbers.

[0047] If the difference between the number of original data packets in the candidate batch and the number of original data packets with the same number in the intersection of the target number is greater than the number of rows in the encoding matrix of the corresponding candidate batch, it is determined that the decoding probability of the corresponding candidate batch cannot be obtained, and the candidate batch is not updated to the target batch set.

[0048] For example, traversing the remaining batches, i.e., the candidate batch set, if... Corresponding original data packet index and target batch set The intersection is the intersection of the target numbers, and the number of intersections is . One. If That is, when the difference between the number of original data packets in the candidate batch and the number of original data packets with the same number in the intersection of the target number is less than or equal to the number of rows in the encoding matrix of the corresponding candidate batch, the indices of the intersection are first calculated from... There are batches, and the decoding probability of each batch is as follows: (If the data comes from multiple batches, the batch with the highest decoding probability is selected), then the decoding probability is calculated using the above decoding probability calculation formula. The decoding probability is also the decoding probability of the corresponding batch.

[0049] Will The encoding of the corresponding original data packet is included in the pre-decoded data packet set, which is also the target batch set. .

[0050] Furthermore, after detecting that the decoding probability of the matrix corresponding to the batch cannot be assigned a value, in order to prevent negative probabilities from occurring, all previous probabilities are normalized and the decoding probability of the remaining batch is assigned to zero.

[0051] S103. Determine the decoding order of multiple batches based on the decoding probabilities of each batch.

[0052] In one possible implementation, in the target batch set, the target batches are sorted in descending order according to their decoding probability, and the sorted order of the target batches is marked as the decoding order.

[0053] S104. Decode multiple batches of encoded packets based on the decoding order.

[0054] Specifically, based on the decoding order obtained above, the matrix degree of each target batch is reduced and Gaussian elimination is performed sequentially to achieve decoding.

[0055] In this embodiment, the probability that all encoded packets in each batch can be successfully decoded is calculated from multiple batches sent by the relay node. Based on the decoding probabilities, the decoding order of the multiple batches is determined, and the encoded packets in the multiple batches are decoded according to the decoding order. In this way, by decoding multiple batches based on the decoding probabilities of each batch, batches with higher decoding probabilities are decoded first, and fewer iterations are performed with a higher decoding probability, reducing the number of iterations and thus reducing the time consumed by BP iteration, thereby improving decoding efficiency, increasing throughput, and effectively increasing the transmission efficiency of multi-hop networks.

[0056] Regarding step S102 above, which involves obtaining the decoding probability for each batch, the following explanation uses a specific example: When the receiver receives 8 batches, that is The information is as follows: The matrix of the first batch It consists of 4 rows and 6 columns, with each row corresponding to the original data packet numbered 1, 3, 4, and 7 respectively; The matrix of the second batch It consists of 7 rows and 6 columns, with each row corresponding to the original data packet numbered 1, 2, 4, 7, 9, 10, and 11 respectively; The matrix of the third batch It consists of 5 rows and 6 columns, with each row corresponding to the original data packet numbered 1, 5, 6, 9, and 17 respectively; The matrix of the 4th batch It consists of 9 rows and 6 columns, with the original data packet numbers corresponding to each row being 2, 3, 14, 15, 16, 18, 19, 20, and 32, respectively; The matrix of the 5th batch It consists of 10 rows and 6 columns, with the original data packet numbers corresponding to each row being 2, 5, 10, 13, 21, 22, 24, 25, 26, and 30, respectively; The matrix of the 6th batch It consists of 8 rows and 6 columns, with the original data packet numbers corresponding to each row being 3, 20, 23, 27, 28, 32, 33, and 45, respectively; The matrix of the 7th batch It consists of 7 rows and 6 columns, with the original data packet numbers corresponding to each row being 1, 17, 23, 27, 29, 32, and 42, respectively; The matrix of the 8th batch It consists of 7 rows and 6 columns, with the original data packet numbers corresponding to each row being 14, 20, 37, 38, 41, 43, and 44, respectively.

[0057] Firstly, because and If the number of columns in the encoding matrix is ​​greater than or equal to the number of rows in the encoding matrix, then... and The corresponding batch is marked as the target batch, and and The decoding probability is set to ,make .

[0058] Secondly, during the first traversal, for Matrix, and The intersection of these, i.e., the intersection of the target numbers, has the numbers 1, 4, 7, and 9. The numbers 1, 4, and 7 in the intersection originate from... The intersection of the matrix, 1 and 9, originates from... Therefore, the matrix has 7 - 4 < 6. Thus, using the decoding probability calculation formula described above, the corresponding decoding probability can be calculated. , .

[0059] for matrix, The intersections are 2 and 3, therefore 9 - 2 > 6, and the probability cannot be obtained.

[0060] for matrix, The intersections are 2, 5, and 10, therefore 10 - 3 > 6, and the probability cannot be obtained.

[0061] for matrix, The intersection of the two sets is 3, therefore 8-1>6, and the probability cannot be obtained.

[0062] for matrix, The intersection of the two sets of matrices is 1 and 17, therefore 7 - 2 < 6, where 1 and 17 originate from the matrix. Therefore, the corresponding decoding probability can be calculated using the above decoding probability calculation formula. , .

[0063] for matrix, The intersection of the two sets is empty, so the probability cannot be obtained.

[0064] Next, iterate a second time, for Matrix, and The intersections are 2, 3, and 32, therefore we have 9 - 3 = 6, where the 2 in the intersection comes from... The intersection of the matrix 3 originates from The intersection of the matrix 32 originates from... Matrix, therefore calculate , .

[0065] for matrix, The intersections are 2, 5, and 10, therefore 10 - 3 > 6, and the probability cannot be obtained.

[0066] for Matrix, and The intersections are 3, 20, 23, 27, and 32, therefore 7 - 5 < 6, where the 3 in the intersection comes from... The intersection of the matrix 20 originates from The intersection of the matrices, 23, 27, and 32, originates from... Matrix, therefore calculate , .

[0067] for matrix, The intersection of these two numbers is 14 and 20, therefore 7 - 2 < 6. The intersection of 14 and 20 originates from... Matrix, therefore calculate , .

[0068] Then, for the third time, traversing... matrix, The intersections are 2, 5, and 10, therefore 10 - 3 > 6, and the probability cannot be obtained.

[0069] The traversal is complete, let Since there are no negative probabilities, no normalization is required.

[0070] In a practical application example, the BATS decoder implemented in the XC7Z100 chip uses a 100MHz master clock. Each batch of BATS codes consists of 32 data packets, each packet containing 1500 bytes of data. The encoding matrix is ​​located in... The original BP decoding method, with 512 original data packets, performed calculations on 120 batches. With a packet loss rate of 0%, the original BP decoding method averaged 85.8ms in 1000 tests, achieving a throughput of 71.6Mbps. Using the multi-hop network BATS code decoding method provided in this application, the average time was 33.2ms in 1000 tests, with a throughput of 185.06Mbps. In a scenario with a 10% packet loss rate, the original BP decoding averaged 103.2ms in time, with a throughput of 59.5Mbps. This new method averaged 69.3ms in time, with a throughput of 88.53Mbps.

[0071] In some embodiments, this application also provides a decoding apparatus for multi-hop network BATS codes. The decoding apparatus may include one or more functional modules for implementing a multi-hop network BATS code decoding method according to the above method embodiments.

[0072] For example, Figure 3 This is a schematic diagram illustrating the composition of a decoding device for a multi-hop network BATS code provided in an embodiment of this application. Figure 3 As shown, the decoding device for the multi-hop network BATS code includes: an acquisition module 201 and a processing module 202.

[0073] The acquisition module 201 is used to acquire multiple batches of encoded packets sent by the relay node; wherein each batch corresponds to multiple encoded packets, and the encoded packets are used to indicate the data packets obtained by encoding the original data through random sparse linear combination.

[0074] The processing module 202 is used to obtain the decoding probability of each batch; wherein, the decoding probability is used to indicate the probability that all encoded packets in the corresponding batch can be successfully decoded directly.

[0075] The processing module 202 is also used to determine the decoding order of multiple batches based on the decoding probabilities.

[0076] The processing module 202 is also used to decode multiple batches of encoded packets based on the decoding order.

[0077] In some embodiments, the processing module 202 is specifically used to determine a target batch set and a candidate batch set in multiple batches based on the number of rows and columns of the encoding matrix where the encoding packet is located; Among them, the target batches in the target batch set can be directly and successfully translated into data, the candidate batches in the candidate batch set cannot be directly and successfully translated into data, and the target batch set includes at least one target batch; The decoding probability of a batch in the target batch set is less than or equal to one.

[0078] In some embodiments, the processing module 202 is specifically used to mark the corresponding batch as the target batch if the number of columns in the encoding matrix is ​​greater than or equal to the number of rows in the encoding matrix composed of multiple encoding packets in the same batch. If the number of columns in the encoding matrix is ​​less than the number of rows in the encoding matrix, the corresponding batch is marked as a candidate batch; Update the target batch set based on the intersection of the original data packet numbers of the candidate batches in the candidate batch set and the target numbers; The original data packet is the unencoded data corresponding to the encoded packet, and the intersection of the target numbers is used to indicate the original data packet number in the candidate batch and the original data packet number in the target batch.

[0079] In some embodiments, the processing module 202 is specifically used to mark the current candidate batch as the target batch and update the decoding probability of the current target batch to the target batch set when the difference between the number of original data packets in the candidate batch and the number of original data packets with the same number in the intersection of the target number is less than or equal to the number of rows of the encoding matrix of the corresponding candidate batch. If the difference between the number of original data packets in the candidate batch and the number of original data packets with the same number in the intersection of the target number is greater than the number of rows in the encoding matrix of the corresponding candidate batch, it is determined that the decoding probability of the corresponding candidate batch cannot be obtained, and the candidate batch is not updated to the target batch set.

[0080] In some embodiments, the processing module 202 is specifically used to sort the target batches in descending order according to the decoding probability of each target batch in the target batch set. The sorted order of each target batch is marked as the decoding order, so that the matrix degree reduction and Gaussian elimination are performed on each target batch in sequence based on the decoding order to achieve decoding.

[0081] Figure 4This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. The electronic device includes: a processor 302, a communication interface 303, and a bus 304. Optionally, the electronic device may also include a memory 301.

[0082] Processor 302 may implement or execute various exemplary logic blocks, modules, and circuits described in conjunction with the disclosure of this application. Processor 302 may be a central processing unit, a general-purpose processor, a digital signal processor, an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, transistor logic devices, hardware components, or any combination thereof. It may implement or execute various exemplary logic blocks, modules, and circuits described in conjunction with the disclosure of this application. Processor 302 may also be a combination of functions implementing computing capabilities, such as a combination including CPU0 and CPU1, a DSP, and a microprocessor.

[0083] The communication interface 303 includes a receiving unit and a transmitting unit, and is used to connect with other devices via a communication network. This communication network can be Ethernet, a wireless access network, a wireless local area network (WLAN), etc.

[0084] The memory 301 may be a read-only memory (ROM) or other type of static storage device capable of storing static information and instructions, random access memory (RAM) or other type of dynamic storage device capable of storing information and instructions, or electrically erasable programmable read-only memory (EEPROM), disk storage medium or other magnetic storage device, or any other medium capable of carrying or storing desired program code in the form of instructions or data structures and accessible by a computer, but is not limited thereto.

[0085] As one possible implementation, the memory 301 can exist independently of the processor 302. The memory 301 can be connected to the processor 302 via a bus 304 and is used to store instructions or program code. When the processor 302 calls the instructions or program code stored in the memory 301, it can implement the decoding method of the multi-hop network BATS code provided in this embodiment of the invention.

[0086] In another possible implementation, the memory 301 can also be integrated with the processor 302.

[0087] Bus 304 can be an extended industry standard architecture (EISA) bus, etc. Bus 304 can be divided into address bus, data bus, control bus, etc. For ease of representation, Figure 4 The bus is represented by a single thick line, but this does not mean that there is only one bus or one type of bus.

[0088] Through the above description of the implementation methods, those skilled in the art can clearly understand that, for the sake of convenience and brevity, only the division of the above functional modules is used as an example. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the service calling device can be divided into different functional modules to complete all or part of the functions described above.

[0089] This application also provides a computer-readable storage medium. All or part of the processes in the above method embodiments can be executed by computer instructions instructing related hardware. The program can be stored in the aforementioned computer-readable storage medium, and when executed, it can include the processes of the above method embodiments. The computer-readable storage medium can be any of the foregoing embodiments or memory. The aforementioned computer-readable storage medium can also be an external storage device of the aforementioned service invocation device, such as a plug-in hard drive, smart media card (SMC), secure digital (SD) card, flash card, etc., equipped on the aforementioned service invocation device. Further, the aforementioned computer-readable storage medium can include both internal storage units of the aforementioned service invocation device and external storage devices. The aforementioned computer-readable storage medium is used to store the aforementioned computer program and other programs and data required by the aforementioned service invocation device. The aforementioned computer-readable storage medium can also be used to temporarily store data that has been output or will be output.

[0090] This application also provides a computer program product comprising a computer program that, when run on a computer, causes the computer to execute the decoding method for the multi-hop network BATS code provided in the above embodiments.

[0091] The above are merely specific embodiments of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions within the technical scope disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.

Claims

1. A decoding method for BATS codes in multi-hop networks, characterized in that, The method includes: Obtain multiple batches of encoded packets sent by the relay node; wherein each batch corresponds to multiple encoded packets, and the encoded packets are used to indicate data packets obtained by encoding the original data through random sparse linear combination; Obtain the decoding probability of each batch; wherein, the decoding probability is used to indicate the probability that all encoded packets in the corresponding batch can be successfully decoded directly; The decoding order of multiple batches is determined based on the decoding probabilities described above; Based on the decoding order, the encoded packets in multiple batches are decoded.

2. The decoding method for a multi-hop network BATS code according to claim 1, characterized in that, The process of obtaining the decoding probability for each batch includes: In the multiple batches, the target batch set and the candidate batch set are determined according to the number of rows and columns of the encoding matrix where the encoded packet is located; Wherein, the target batch in the target batch set can be directly and successfully translated into data, the candidate batch in the candidate batch set cannot be directly and successfully translated into data, and the target batch set includes at least one target batch; The decoding probability of a batch in the target batch set is less than or equal to one.

3. The decoding method for a multi-hop network BATS code according to claim 2, characterized in that, The step of determining the target batch set and the candidate batch set based on the number of rows and columns of the encoding matrix of the encoded packet among the multiple batches includes: For an encoding matrix consisting of multiple encoding packets in the same batch, if the number of columns in the encoding matrix is ​​greater than or equal to the number of rows in the encoding matrix, the corresponding batch is marked as the target batch. If the number of columns in the encoding matrix is ​​less than the number of rows in the encoding matrix, the corresponding batch is marked as the candidate batch; The target batch set is updated based on the intersection of the original data packet numbers of the candidate batches in the candidate batch set and the target numbers; Wherein, the original data packet is the unencoded data corresponding to the encoded packet, and the target number intersection is used to indicate the original data packet number in the candidate batch and the original data packet number in the target batch.

4. The decoding method for a multi-hop network BATS code according to claim 3, characterized in that, The step of updating the target batch set based on the intersection of the original data packet numbers of the candidate batches in the candidate batch set and the target numbers includes: When the difference between the number of original data packets in the candidate batch and the number of original data packets with the same number in the intersection of the target number is less than or equal to the number of rows in the encoding matrix of the corresponding candidate batch, the current candidate batch is marked as the target batch, and the decoding probability of the current target batch is updated to the target batch set. If the difference between the number of original data packets in the candidate batch and the number of original data packets with the same number in the intersection of the target number is greater than the number of rows in the encoding matrix of the corresponding candidate batch, it is determined that the decoding probability of the corresponding candidate batch cannot be obtained, and the candidate batch is not updated to the target batch set.

5. The decoding method for a multi-hop network BATS code according to claim 4, characterized in that, The decoding probability of the current target batch is calculated using the following formula: ; in, For decoding probability, The number of original data packets in the candidate batch. The number of original data packets with the same ID in the intersection of the target IDs. This represents the number of batches sent by the relay node. It is the product of the decoding probabilities of each target batch in the target batch set. The target batch number is the number of each target batch in the intersection of the target numbers.

6. The decoding method for a multi-hop network BATS code according to claim 2, characterized in that, Determining the decoding order of multiple batches based on the decoding probabilities includes: In the target batch set, the target batches are sorted in descending order according to their decoding probabilities. The sorted order of the target batches is marked as the decoding order, so that the target batches are sequentially matrix-degree reduction and Gaussian elimination based on the decoding order to achieve decoding.

7. A decoding device for BATS codes in a multi-hop network, characterized in that, include: The acquisition module is used to acquire multiple batches of encoded packets sent by the relay node; wherein each batch corresponds to multiple encoded packets, and the encoded packets are used to indicate data packets obtained by encoding the original data through random sparse linear combination; The processing module is used to obtain the decoding probability of each batch; wherein the decoding probability is used to indicate the probability that all encoded packets in the corresponding batch can be directly and successfully decoded into data; The processing module is also used to determine the decoding order of multiple batches based on the decoding probabilities of each batch. The processing module is also used to decode multiple batches of the encoded packets based on the decoding order.

8. An electronic device, characterized in that, It includes a processor and a memory, the processor being coupled to the memory; the memory is used to store computer instructions, which are loaded and executed by the processor to enable the computer device to perform the method as described in any one of claims 1 to 6.

9. A computer-readable storage medium, characterized in that, The computer-readable storage medium includes computer-executable instructions that, when executed on a computer, cause the computer to perform the method according to any one of claims 1 to 6.

10. A computer program product, characterized in that, The computer program product includes a computer program that, when run on an electronic device, causes the electronic device to perform the method as described in any one of claims 1 to 6.