Calculation method and system for low Hamming weight code word number of polarization code, and terminal

By modifying the path measurement and decoding method of the Fano decoder, the low-Hamming weight code word count of the polarized code is calculated using the path measurement based on the Hanming weight, which solves the problem of high computational complexity in the prior art, and achieves fast and accurate calculation and decoding performance characterization of the low-Hamming weight code word count and decoding performance.

CN120238137APending Publication Date: 2025-07-01HARBIN INSTITUTE OF TECHNOLOGY (SHENZHEN) (INSTITUTE OF SCIENCE AND TECHNOLOGY INNOVATION HARBIN INSTITUTE OF TECHNOLOGY SHENZHEN)
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202510202355.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-02-24
Publication Date
2025-07-01

AI Technical Summary

Technical Problem

When calculating the number of low-Hamming weight codes, the existing polarization codes and polarization-adjusted convolutional codes have high computational complexity and spatial complexity, and cannot be quickly and accurately calculated, resulting in the inability to accurately characterize the decoding performance of the maximum likelihood decoder.

Method used

By modifying the serial offset path metric and decoding of the Fano decoder, the path metric method based on the Hanming weight is used to directly calculate the number of low Hanming weight code words, including modifying the path bias term and code weight information of the Fano decoder, performing path selection and counting, and intuitively verifying the Hanming weight characteristics.

Benefits of technology

It reduces the computational complexity and spatial complexity, can quickly and accurately calculate the number of low-Hamming weight code words, and directly characterizes the decoding performance of the maximum likelihood decoder.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120238137A_ABST
    Figure CN120238137A_ABST
Patent Text Reader

Abstract

The invention discloses a method, a system and a terminal for calculating the word number of a low Hamming weight code of a polarization code, and the method comprises the steps: obtaining a serial offset path metric and a serial offset decoding of a Fano decoder, carrying out the modification processing of the serial offset path metric, and obtaining a target serial offset path metric, modifying the serial offset decoding to obtain a target serial offset decoding; performing node selection according to the target serial cancellation decoding to obtain a target node, and selecting a corresponding target path according to the target serial cancellation path metric; if the target path is a low-weight path, counting the code weight value of the target path to obtain a counting result; and performing path backtracking according to the counting result to obtain a backtracking result, obtaining a corresponding target counting result according to the backtracking result, and obtaining a low Hamming weight code word number according to the target counting result. According to the method, the low Hamming weight code word number is calculated from the perspective of a decoder, and the calculation complexity and the space complexity are lower.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of channel coding, and in particular to a method, system, terminal and computer-readable storage medium for calculating the number of low Hamming weight codewords of a polar code. Background Art

[0002] The polar code is the first channel coding scheme that is theoretically strictly proven to reach the Shannon limit. It has advantages such as a clear construction method, low encoding and decoding complexity, no error floor, and flexible rate, and is determined as the coding scheme for the control channel in the 5G eMBB scenario. Subsequently, based on the polar code, the polar adjusted convolutional code was proposed. By performing a convolutional pre-transformation on the polar code, the problem of channel capacity loss caused by incomplete channel polarization in the case of short code lengths was improved, and the number of low Hamming weight codewords of the polar code was reduced, realizing a further improvement in the decoding performance of the polar code under short code lengths.

[0003] The Maximum Likelihood Decoder (MLD) is the theoretically optimal decoder, but its excessive complexity in medium and long codes makes it difficult to be practically applied; in the case of short code lengths, due to the relatively simple codeword structure, near-MLD decoders such as the SCL decoder and the Fano decoder have been widely studied in polar codes and polar adjusted convolutional codes. And the number of low Hamming weight codewords, as an important structural characteristic of the codeword, can directly characterize the decoding performance of the MLD.

[0004] However, when calculating the number of low Hamming weight codewords of existing polar codes and polar adjusted convolutional codes, the required computational complexity and space complexity are both relatively high, which is not conducive to the calculation of the number of low Hamming weight codewords.

[0005] Therefore, the existing technology still needs to be improved and developed. Summary of the Invention

[0006] The main purpose of the present invention is to provide a method, system and terminal for calculating the number of low Hamming weight codewords of a polar code, aiming to solve the problem that when calculating the number of low Hamming weight codewords of existing polar codes and polar adjusted convolutional codes, the required computational complexity and space complexity are both relatively high, and it is impossible to quickly and accurately calculate the number of low Hamming weight codewords, resulting in the inability to accurately characterize the decoding performance calculation of the MLD.

[0007] To achieve the above object, the present invention provides a method for calculating the number of low Hamming weight codewords of a polar code, and the method for calculating the number of low Hamming weight codewords of the polar code includes the following steps:

[0008] Obtain the serial cancellation path metric and serial cancellation decoding of the Fano decoder, perform modification processing on the serial cancellation path metric to obtain the target serial cancellation path metric, and perform modification processing on the serial cancellation decoding to obtain the target serial cancellation decoding;

[0009] Perform node selection according to the target serial cancellation decoding to obtain the target node, and select the target path corresponding to the target node according to the target serial cancellation path metric;

[0010] When it is detected that the target node reaches the end point of the target path, determine the path type of the target path. If the target path is a low-weight path, perform counting processing on the code weight value of the target path to obtain a counting result;

[0011] Perform path backtracking according to the counting result to obtain a backtracking result, obtain a corresponding target counting result according to the backtracking result, and obtain the number of low Hamming weight codewords according to the target counting result.

[0012] Optionally, the method for calculating the number of low Hamming weight codewords of the polar code, wherein the target serial cancellation path metric includes a first serial cancellation path metric and a second serial cancellation path metric;

[0013] The performing modification processing on the serial cancellation path metric to obtain the target serial cancellation path metric specifically includes:

[0014] Modify the Fano decoder to obtain a metric counter, and compare the branch path codeword of the metric counter with the decoding result of the Fano decoder;

[0015] If the branch path codeword matches the decoding result, modify the path bias term of the serial cancellation path metric to obtain the first serial cancellation path metric;

[0016] If the branch path codeword does not match the decoding result, modify the serial cancellation path metric according to the metric counter to obtain the second serial cancellation path metric.

[0017] Optionally, the method for calculating the number of low Hamming weight codewords of the polar code, wherein the performing modification processing on the serial cancellation decoding to obtain the target serial cancellation decoding specifically includes:

[0018] Obtain the parent node of the serial cancellation decoding, and perform child node calculation according to the log-likelihood ratio information of the parent node to obtain the first code weight information of the left child node and the second code weight information of the right child node;

[0019] Modify the serial cancellation decoding according to the first code weight information and the second code weight information to obtain the target serial cancellation decoding.

[0020] Optionally, a method for calculating the number of low Hamming weight codewords of the polar code, wherein, selecting nodes according to the target serial cancellation decoding to obtain target nodes, and selecting a target path corresponding to the target nodes according to the target serial cancellation path metric, specifically includes:

[0021] Obtain the branch path metrics of a preset number of the target serial cancellation decoding, and calculate metric values for all the branch path metrics to obtain a plurality of path metric values;

[0022] Sort all the path metric values in size to obtain a path metric value list, take the node corresponding to the maximum path metric value in the path metric value list as the target node, and select the target path corresponding to the target node according to the target serial cancellation path metric.

[0023] Optionally, a method for calculating the number of low Hamming weight codewords of the polar code, wherein, selecting nodes according to the target serial cancellation decoding to obtain target nodes, and selecting a target path corresponding to the target nodes according to the target serial cancellation path metric, and then further includes:

[0024] Obtain the forward node metric value of the target node, compare the forward node metric value with a threshold to obtain a first comparison result, and judge whether the target node moves forward on the target path according to the first comparison result;

[0025] If the first comparison result is that the forward node metric value is less than the threshold, it is determined that the target node needs to perform backtracking processing;

[0026] If the first comparison result is that the forward node metric value is greater than or equal to the threshold, it is determined that the target node moves forward on the target path.

[0027] Optionally, a method for calculating the number of low Hamming weight codewords of the polar code, wherein, when it is detected that the target node reaches the end point of the target path, determining the path type of the target path, and if the target path is a low weight path, performing a counting process on the code weight value of the target path to obtain a counting result, specifically includes:

[0028] When it is detected that the target node moves forward and moves to the end point of the target path, obtain the path metric value of the target path, and compare the path metric value with a preset expected code weight to obtain a second comparison result;

[0029] If the second comparison result is that the path metric value is less than the preset expected code weight, it is determined that the target path is a low-weight path, and the code weight value of the target path is counted to obtain a counting result.

[0030] Optionally, for the method of calculating the number of low Hamming weight codewords of the polar code, wherein, performing path backtracking according to the counting result to obtain a backtracking result, obtaining a corresponding target counting result according to the backtracking result, and obtaining the number of low Hamming weight codewords according to the target counting result, specifically including:

[0031] Performing node backtracking on the remaining path metric values in the path metric value list in sequence according to the counting result to obtain a backtracking result, and obtaining the paths corresponding to the low-weight paths in the backtracking result;

[0032] Counting the code weight values of all the paths to obtain a target counting result, obtaining a low Hamming weight codeword distribution result according to the counting information of the target counting result, and performing quantity statistics according to the low Hamming weight codeword distribution result to obtain the number of low Hamming weight codewords.

[0033] Optionally, for the method of calculating the number of low Hamming weight codewords of the polar code, wherein the calculation system for the number of low Hamming weight codewords of the polar code includes:

[0034] An information modification module, configured to obtain the serial cancellation path metric and serial cancellation decoding of a Fano decoder, perform modification processing on the serial cancellation path metric to obtain a target serial cancellation path metric, and perform modification processing on the serial cancellation decoding to obtain a target serial cancellation decoding;

[0035] A node determination module, configured to perform node selection according to the target serial cancellation decoding to obtain a target node, and select a target path corresponding to the target node according to the target serial cancellation path metric;

[0036] A code weight calculation module, configured to determine the path type of the target path when it is detected that the target node reaches the end point of the target path, and if the target path is a low-weight path, count the code weight value of the target path to obtain a counting result;

[0037] A result output module, configured to perform path backtracking according to the counting result to obtain a backtracking result, obtain a corresponding target counting result according to the backtracking result, and obtain the number of low Hamming weight codewords according to the target counting result.

[0038] In addition, to achieve the above object, the present invention further provides a terminal, wherein the terminal includes: a memory, a processor, and a calculation program for the number of low Hamming weight codewords of a polar code stored in the memory and executable on the processor. When the calculation program for the number of low Hamming weight codewords of the polar code is executed by the processor, the steps of the method for calculating the number of low Hamming weight codewords of the polar code as described above are implemented.

[0039] In addition, to achieve the above object, the present invention further provides a computer-readable storage medium, wherein the computer-readable storage medium stores a calculation program for the number of low Hamming weight codewords of a polar code. When the calculation program for the number of low Hamming weight codewords of the polar code is executed by a processor, the steps of the method for calculating the number of low Hamming weight codewords of the polar code as described above are implemented.

[0040] In the present invention, the serial cancellation path metric and serial cancellation decoding of a Fano decoder are obtained, the serial cancellation path metric is modified to obtain a target serial cancellation path metric, and the serial cancellation decoding is modified to obtain a target serial cancellation decoding; node selection is performed according to the target serial cancellation decoding to obtain a target node, and a target path corresponding to the target node is selected according to the target serial cancellation path metric; when it is detected that the target node reaches the end point of the target path, the path type of the target path is determined. If the target path is a low-weight path, the code weight value of the target path is counted to obtain a counting result; path backtracking is performed according to the counting result to obtain a backtracking result, a corresponding target counting result is obtained according to the backtracking result, and the number of low Hamming weight codewords is obtained according to the target counting result. By calculating the number of low Hamming weight codewords from the perspective of the decoder, the present invention has lower computational complexity and space complexity. And the number of low Hamming weight codewords, as an important structural characteristic of the codeword, can directly characterize the decoding performance of MLD. Moreover, the serial cancellation path metric method based on Hamming weight can not only directly give the Hamming weight of the path through the metric, but also intuitively verify the Hamming weight characteristics of the polar code or polar-modulated convolutional code. BRIEF DESCRIPTION OF THE DRAWINGS

[0041] Figure 1 is a flowchart of a preferred embodiment of the method for calculating the number of low Hamming weight codewords of the polar code of the present invention;

[0042] Figure 2 is an overall flowchart of a preferred embodiment of the method for calculating the number of low Hamming weight codewords of the polar code of the present invention;

[0043] Figure 3 is a structural diagram of a preferred embodiment of the system for calculating the number of low Hamming weight codewords of the polar code of the present invention;

[0044] Figure 4 It is a schematic diagram of the operating environment of a preferred embodiment of the terminal of the present invention. Specific Embodiments

[0045] To make the objectives, technical solutions and advantages of the present invention clearer and more definite, the following further describes the present invention in detail with reference to the accompanying drawings and by way of examples. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.

[0046] It should be noted that if there are directional indications (such as up, down, left, right, front, back...) involved in the embodiments of the present invention, such directional indications are only used to explain the relative positional relationship and movement conditions between components in a specific posture (as shown in the drawings). If the specific posture changes, the directional indications will also change accordingly.

[0047] In addition, if there are descriptions involving "first", "second", etc. in the embodiments of the present invention, such descriptions of "first", "second", etc. are only for descriptive purposes and cannot be understood as indicating or implying their relative importance or implicitly indicating the quantity of the indicated technical features. Thus, the features defined with "first", "second" may explicitly or implicitly include at least one such feature. In addition, the technical solutions between various embodiments can be combined with each other, but it must be based on the ability of those of ordinary skill in the art to implement. When the combination of technical solutions is contradictory or cannot be implemented, it should be considered that such a combination of technical solutions does not exist and is not within the scope of protection required by the present invention.

[0048] The calculation method of the number of low Hamming weight codewords of the polar code described in the preferred embodiment of the present invention is as Figure 1 shown. The calculation method of the number of low Hamming weight codewords of the polar code includes the following steps:

[0049] Step S10: Obtain the serial cancellation path metric and serial cancellation decoding of the Fano decoder, modify the serial cancellation path metric to obtain a target serial cancellation path metric, and modify the serial cancellation decoding to obtain a target serial cancellation decoding.

[0050] The step S10 includes:

[0051] Step S11: Modify the Fano decoder to obtain a metric counter, and compare the branch path codeword of the metric counter with the decoding result of the Fano decoder;

[0052] Step S12: If the branch path codeword is consistent with the decoding result, modify the path bias term of the serial cancellation path metric to obtain a first serial cancellation path metric;

[0053] Step S13: If the branch path codeword does not match the decoding result, modify the successive cancellation path metric according to the metric counter to obtain a second successive cancellation path metric;

[0054] Step S14: Obtain the parent node of the successive cancellation decoding, and calculate the child nodes according to the log-likelihood ratio information of the parent node to obtain the first code weight information of the left child node and the second code weight information of the right child node;

[0055] Step S15: Modify the successive cancellation decoding according to the first code weight information and the second code weight information to obtain a target successive cancellation decoding.

[0056] Specifically, in order to solve the problem that the existing polar codes and polar-adjusted convolutional codes have high computational complexity and space complexity when calculating the number of low Hamming weight codewords, which is not conducive to the calculation of the number of low Hamming weight codewords, in the present invention, a method for calculating the number of low Hamming weight codewords of polar codes is proposed, which can be used in arbitrarily constructed polar codes or polar-adjusted convolutional codes; by modifying the successive cancellation (SC) path metric based on the log-likelihood ratio (LLR) in the Fano decoder of the polar code or polar-adjusted convolutional code to a SC path metric based on the Hamming weight, and modifying the original forward search module in the Fano decoder, so that the decoder searches along the codeword path once according to the path metric to find the number of low Hamming weight codewords; furthermore, modify the original path backtracking module and the original decoding termination decision module in the Fano decoder, so that the decoder runs repeatedly along the candidate codeword path without repetition to achieve the counting of all codewords with a Hamming weight lower than a given value.

[0057] Specifically, as Figure 2As shown, the overall system architecture of the present invention includes a forward search module, a decoding termination decision module, and a path backtracking module. The forward search module provides the decoding branch path metric through SC decoding, selects the path corresponding to the appropriate node and continuously moves forward, and updates the metric. After reaching the end of the path, it enters the decoding termination decision module. If the path is a low-weight path, the code weight counter corresponding to the weight is incremented. Then it enters the path backtracking module, performs backtracking through the stored metric values, and conducts forward search again. If the candidate path metrics of the forward search do not meet the requirements, backtracking is performed again. In the embodiment of the present invention, for a (N, K) polar code or a polar adjusted convolutional code with a length of N and the number of information bits of K, in order to analyze the number of low Hamming weight codewords of the polar code or the polar adjusted convolutional code using a Fano decoder, the original Fano decoder needs to be modified. First, the serial cancellation path metric of the Fano decoder is modified to a path metric based on Hamming code weight, that is, the target serial cancellation path metric. Among them, the target serial cancellation path metric includes a first serial cancellation path metric and a second serial cancellation path metric. The proposed path metric based on Hamming code weight aims to directly give the codeword weight information through the metric value. The specific modification process is to modify the Fano decoder to obtain a metric counter, and compare and process the branch path codeword of the metric counter with the decoding result of the Fano decoder; if the branch path codeword is consistent with the decoding result, modify the path offset term of the serial cancellation path metric to obtain the first serial cancellation path metric. Because when the Fano decoder is used for code weight analysis, the weights of all full-length codewords are studied, and there is no comparison of paths of different lengths, so the path offset term in the Fano path metric is modified to a fixed value of 0; if the branch path codeword is inconsistent with the decoding result, modify the serial cancellation path metric according to the metric counter to obtain the second serial cancellation path metric; the path metric based on Hamming code weight can be expressed in the following form:

[0058]

[0059] where PM i is the metric value when the decoder executes to the i-th bit, which is the basis for the decoder to select the branch path, and w i is the result output by the serial cancellation decoding based on Hamming code weight.

[0060] Secondly, modify the serial cancellation decoding of the Fano decoder to serial cancellation decoding based on Hamming code weight, that is, the target serial cancellation decoding; make the following modifications to the operations: retain the positive and negative signs of the LLR of the parent node for discriminating the codeword; directly set the LLR value to the codeword value of this bit, that is, after BPSK modulation: {0, 1} → {1, -1}, directly use {1, -1} instead of LLR as the input of the serial cancellation decoding, and obtain the leaf node metric through f operation and g operation, which is w i ; Among them, the key operations of the serial cancellation decoding are the f operation and g operation along the polarization code tree. The f operation is used to calculate the left child node from the LLR of the parent node, and the g operation is used to calculate the right child node from the LLR of the parent node. Specifically, obtain the parent node of the serial cancellation decoding, and perform child node calculation according to the log-likelihood ratio information of the parent node to obtain the first code weight information of the left child node and the second code weight information of the right child node. For a polarization code of length 2, let the log-likelihood ratios of the received codewords (y1, y2) be L1 and L2, then the f operation is expressed as:

[0061]

[0062] The g operation is expressed as:

[0063]

[0064] Among them, |L1| and |L2| are the absolute values of the log-likelihood ratios, and the approximate equation (a) is the hardware-friendly form of the f operation, is the decoding estimate value of the left child node u1 after the f operation.

[0065] Furthermore, in the embodiment of the present invention, some decoding logics are also modified. Specifically, first, the threshold tightening part in the Fano decoder is deleted. Since the correct codeword reward is 0, the path metric will continuously decrease; secondly, when the decoding reaches the end, judge whether this path is a low-weight codeword that meets the requirements according to the current path metric. If so, increment the counter by one and set the path metric value to -inf to make the decoder continue to search for subsequent codewords; finally, the initial threshold T is modified from 0 to the negative value of the expected code weight d, and the threshold increment Δ is deleted. The algorithm terminates when all path metric values are greater than the threshold. At this time, all paths with code weights less than the expected code weight d have been explored.

[0066] Step S20: Select nodes according to the target serial cancellation decoding to obtain target nodes, and select the target path corresponding to the target nodes according to the target serial cancellation path metric.

[0067] The step S20 includes:

[0068] Step S21: Obtain the preset number of branch path metrics of the target serial cancellation decoding, and calculate the metric values for all the branch path metrics to obtain multiple path metric values;

[0069] Step S22: Sort all the path metric values in ascending order to obtain a path metric value list, take the node corresponding to the maximum path metric value in the path metric value list as the target node, and select the target path corresponding to the target node according to the target serial cancellation path metric.

[0070] Specifically, it is necessary to search for the optimal node (i.e., the target node) through the forward search module. In the embodiment of the present invention, obtain the preset number (for example, 2) of branch path metrics of the target serial cancellation decoding, and calculate the metric values for all the branch path metrics to obtain multiple path metric values; sort all the path metric values in ascending order to obtain a path metric value list, take the node corresponding to the maximum path metric value in the path metric value list as the target node, and select the target path corresponding to the target node according to the target serial cancellation path metric.

[0071] Further, after obtaining the target path, it is necessary to select the path corresponding to the target node to continuously move forward and update the metric. Specifically, obtain the forward node metric value of the target node, compare the forward node metric value with a threshold to obtain a first comparison result, and determine whether the target node moves forward on the target path according to the first comparison result; if the first comparison result is that the forward node metric value is less than the threshold, it is determined that the target node needs to perform a backtracking process, that is, backtrack the next node to the previous node; if the first comparison result is that the forward node metric value is greater than or equal to the threshold, it indicates that the target node moves forward on the target path.

[0072] Step S30: When it is detected that the target node reaches the end point of the target path, determine the path type of the target path. If the target path is a low-weight path, count the code weight value of the target path to obtain a count result.

[0073] The step S30 includes:

[0074] Step S31: When it is detected that the target node moves forward and moves to the end point of the target path, obtain the path metric value of the target path, and compare the path metric value with a preset expected code weight to obtain a second comparison result;

[0075] Step S32: If the second comparison result is that the path metric value is less than the preset expected code weight, determine that the target path is a low-weight path, and perform a counting process on the code weight value of the target path to obtain a counting result.

[0076] Specifically, in the embodiment of the present invention, when it is detected that the target node moves forward, it is determined whether the target node moves to the path end point of the target path. If the target node has not moved to the path end point of the target path, continue to search for the optimal node along the path; when the target node moves to the path end point of the target path, enter the decoding termination decision module, obtain the path metric value of the target path, and compare the path metric value with the preset expected code weight to obtain a second comparison result, where Figure 2 the "negative sign" before the preset expected code weight has no actual effect because the code weight information is provided through the "decoding result error" situation, and the sign represents applying a negative penalty for the "error" situation; if the second comparison result is that the path metric value is less than the preset expected code weight, determine that the target path is a low-weight path, and perform a counting process on the code weight value of the target path to obtain a counting result. The purpose of counting is that the finally returned low-weight codeword distribution is the counting information in the metric counter, and the counting information is the number of codewords corresponding to each weight value.

[0077] Step S40: When it is detected that the target node reaches the end point of the target path, determine the path type of the target path. If the target path is a low-weight path, perform a counting process on the code weight value of the target path to obtain a counting result.

[0078] The step S40 includes:

[0079] Step S41: Perform a marking process on the target path according to the counting result, and sequentially perform node backtracking on the remaining path metric values in the path metric value list to obtain a backtracking result, and obtain the paths corresponding to the low-weight paths in the backtracking result until all the paths corresponding to the low-weight codewords are found;

[0080] Step S42: Perform a counting process on the code weight values of all the paths to obtain a target counting result, obtain a low Hamming weight codeword distribution result according to the counting information of the target counting result, and perform a quantity statistics according to the low Hamming weight codeword distribution result to obtain the number of low Hamming weight codewords.

[0081] Specifically, in the embodiments of the present invention, after counting the code weight value of the target path to obtain a counting result, it is necessary to perform a marking process on the target path to prevent returning to this target path after backtracking; then enter the path backtracking module, perform backtracking through the stored metric values, and perform forward search again; among them, backtracking is performed bit by bit. If the metrics of the two forward branches of the current node do not meet the requirements, it will backtrack to the previous node to find whether there is a forward branch metric that meets the requirements. If not, it will backtrack again; specifically, according to the counting result, perform node backtracking on the remaining path metric values in the path metric value list in sequence to obtain a backtracking result. For example, backtrack the sub-optimal node in the path metric value list; then, obtain the paths corresponding to the low-weight paths in the backtracking result until all the paths corresponding to the low-weight codewords are found; count the code weight values of all the paths to obtain a target counting result, obtain the distribution result of the low Hamming weight codewords according to the counting information of the target counting result, and perform quantity statistics according to the distribution result of the low Hamming weight codewords to obtain the number of low Hamming weight codewords.

[0082] Further, as Figure 3 shown, based on the above method for calculating the number of low Hamming weight codewords of the polar code, the present invention also correspondingly provides a system for calculating the number of low Hamming weight codewords of the polar code. Among them, the system for calculating the number of low Hamming weight codewords of the polar code includes:

[0083] An information modification module 51, configured to obtain the serial cancellation path metric and serial cancellation decoding of the Fano decoder, perform modification processing on the serial cancellation path metric to obtain a target serial cancellation path metric, and perform modification processing on the serial cancellation decoding to obtain a target serial cancellation decoding;

[0084] A node determination module 52, configured to perform node selection according to the target serial cancellation decoding to obtain a target node, and select a target path corresponding to the target node according to the target serial cancellation path metric;

[0085] A code weight calculation module 53, configured to determine the path type of the target path when it is detected that the target node reaches the end of the target path. If the target path is a low-weight path, count the code weight value of the target path to obtain a counting result;

[0086] A result output module 54, configured to perform path backtracking according to the counting result to obtain a backtracking result, obtain a corresponding target counting result according to the backtracking result, and obtain the number of low Hamming weight codewords according to the target counting result.

[0087] Further, as Figure 4As shown, based on the above method for calculating the number of low Hamming weight codewords of a polar code, the present invention also correspondingly provides a terminal, which includes a processor 10, a memory 20, and a display 30. Figure 4 Only some components of the terminal are shown, but it should be understood that it is not required to implement all the shown components, and more or fewer components can be alternatively implemented.

[0088] In some embodiments, the memory 20 may be an internal storage unit of the terminal, such as the hard disk or memory of the terminal. In other embodiments, the memory 20 may also be an external storage device of the terminal, such as a plug-in hard disk equipped on the terminal, a Smart Media Card (SMC), a Secure Digital (SD) card, a Flash Card, etc. Further, the memory 20 may also include both the internal storage unit and the external storage device of the terminal. The memory 20 is used to store application software installed on the terminal and various types of data, such as program codes installed on the terminal. The memory 20 may also be used to temporarily store data that has been output or will be output. In one embodiment, a program 40 for calculating the number of low Hamming weight codewords of a polar code is stored on the memory 20, and this program 40 for calculating the number of low Hamming weight codewords of a polar code can be executed by the processor 10, thereby implementing the method for calculating the number of low Hamming weight codewords of a polar code in the present application.

[0089] In some embodiments, the processor 10 may be a central processing unit (CPU), a microprocessor, or other data processing chips, and is used to run the program codes stored in the memory 20 or process data, such as executing the method for calculating the number of low Hamming weight codewords of a polar code.

[0090] In some embodiments, the display 30 may be an LED display, a liquid crystal display, a touch liquid crystal display, and an OLED (Organic Light-Emitting Diode) toucher, etc. The display 30 is used to display information on the terminal and to display a visual user interface. The components of the terminal communicate with each other through a system bus.

[0091] In one embodiment, when the processor 10 executes the program 40 for calculating the number of low Hamming weight codewords of a polar code in the memory 20, the following steps are implemented:

[0092] Obtain the serial cancellation path metric and serial cancellation decoding of the Fano decoder, perform modification processing on the serial cancellation path metric to obtain a target serial cancellation path metric, and perform modification processing on the serial cancellation decoding to obtain a target serial cancellation decoding;

[0093] Perform node selection according to the target serial cancellation decoding to obtain a target node, and select a target path corresponding to the target node according to the target serial cancellation path metric;

[0094] When it is detected that the target node reaches the end point of the target path, determine the path type of the target path. If the target path is a low-weight path, perform counting processing on the code weight value of the target path to obtain a counting result;

[0095] Perform path backtracking according to the counting result to obtain a backtracking result, obtain a corresponding target counting result according to the backtracking result, and obtain the number of low Hamming weight codewords according to the target counting result.

[0096] Among them, the target serial cancellation path metric includes a first serial cancellation path metric and a second serial cancellation path metric;

[0097] The modification processing of the serial cancellation path metric to obtain the target serial cancellation path metric specifically includes:

[0098] Modify the Fano decoder to obtain a metric counter, and compare the branch path codeword of the metric counter with the decoding result of the Fano decoder;

[0099] If the branch path codeword matches the decoding result, modify the path offset term of the serial cancellation path metric to obtain a first serial cancellation path metric;

[0100] If the branch path codeword does not match the decoding result, modify the serial cancellation path metric according to the metric counter to obtain a second serial cancellation path metric.

[0101] Among them, the modification processing of the serial cancellation decoding to obtain the target serial cancellation decoding specifically includes:

[0102] Obtain the parent node of the serial cancellation decoding, perform child node calculation according to the log-likelihood ratio information of the parent node to obtain the first code weight information of the left child node and the second code weight information of the right child node;

[0103] Perform modification processing on the serial cancellation decoding according to the first code weight information and the second code weight information to obtain a target serial cancellation decoding.

[0104] Among them, the node selection according to the target serial cancellation decoding to obtain a target node, and the selection of a target path corresponding to the target node according to the target serial cancellation path metric specifically includes:

[0105] Obtain the branch path metrics of a preset number of the target serial cancellation decoding, and calculate the metric values for all the branch path metrics to obtain a plurality of path metric values;

[0106] Sort all the path metric values in size to obtain a path metric value list, take the node corresponding to the maximum path metric value in the path metric value list as the target node, and select the target path corresponding to the target node according to the target serial cancellation path metric.

[0107] Among them, after the node selection according to the target serial cancellation decoding to obtain a target node, and the selection of a target path corresponding to the target node according to the target serial cancellation path metric, it further includes:

[0108] Obtain the forward node metric value of the target node, compare the forward node metric value with a threshold to obtain a first comparison result, and judge whether the target node makes a forward move on the target path according to the first comparison result;

[0109] If the first comparison result is that the forward node metric value is less than the threshold, it is determined that the target node needs to perform backtracking processing;

[0110] If the first comparison result is that the forward node metric value is greater than or equal to the threshold, it is determined that the target node makes a forward move on the target path.

[0111] Among them, when it is detected that the target node reaches the end point of the target path, determine the path type of the target path. If the target path is a low-weight path, perform a counting process on the code weight value of the target path to obtain a counting result, specifically including:

[0112] When it is detected that the target node makes a forward move and moves to the end point of the target path, obtain the path metric value of the target path, and compare the path metric value with a preset expected code weight to obtain a second comparison result;

[0113] If the second comparison result is that the path metric value is less than the preset expected code weight, it is determined that the target path is a low-weight path, and perform a counting process on the code weight value of the target path to obtain a counting result.

[0114] Among them, performing path backtracking according to the counting result to obtain a backtracking result, obtaining a corresponding target counting result according to the backtracking result, and obtaining the number of low Hamming weight codewords according to the target counting result specifically includes:

[0115] Performing node backtracking on the remaining path metric values in the path metric value list in sequence according to the counting result to obtain a backtracking result, and obtaining the paths corresponding to the low-weight paths in the backtracking result until all the paths corresponding to the low-weight codewords are found;

[0116] Performing counting processing on the code weight values of all the paths to obtain a target counting result, obtaining a distribution result of low Hamming weight codewords according to the counting information of the target counting result, and performing quantity statistics according to the distribution result of the low Hamming weight codewords to obtain the number of low Hamming weight codewords.

[0117] The present invention also provides a computer-readable storage medium, wherein the computer-readable storage medium stores a calculation program for the number of low Hamming weight codewords of a polar code, and when the calculation program for the number of low Hamming weight codewords of the polar code is executed by a processor, the steps of the above-mentioned calculation method for the number of low Hamming weight codewords of the polar code are implemented.

[0118] In summary, the present invention provides a calculation method, system and terminal for the number of low Hamming weight codewords of a polar code. The method includes: obtaining the serial cancellation path metric and serial cancellation decoding of a Fano decoder, performing modification processing on the serial cancellation path metric to obtain a target serial cancellation path metric, and performing modification processing on the serial cancellation decoding to obtain a target serial cancellation decoding; performing node selection according to the target serial cancellation decoding to obtain a target node, and selecting a target path corresponding to the target node according to the target serial cancellation path metric; when it is detected that the target node reaches the end point of the target path, determining the path type of the target path, and if the target path is a low-weight path, performing counting processing on the code weight value of the target path to obtain a counting result; performing path backtracking according to the counting result to obtain a backtracking result, obtaining a corresponding target counting result according to the backtracking result, and obtaining the number of low Hamming weight codewords according to the target counting result.

[0119] It should be noted that in this article, the term "including", "comprising" or any other variant thereof is intended to cover non-exclusive inclusion, so that a process, method, article or terminal including a series of elements not only includes those elements, but also includes other elements not expressly listed, or further includes elements inherent to such process, method, article or terminal. Without further limitation, an element defined by the statement "including one..." does not exclude the existence of another identical element in the process, method, article or terminal including that element.

[0120] Of course, those of ordinary skill in the art can understand that all or part of the processes in the methods of the above embodiments can be completed by instructing relevant hardware (such as a processor, a controller, etc.) through a computer program. The program can be stored in a computer-readable storage medium that can be read by a computer. When the program is executed, it can include the processes of the above method embodiments. The computer-readable storage medium can be a memory, a magnetic disk, an optical disc, etc.

[0121] It should be understood that the application of the present invention is not limited to the above examples. For those of ordinary skill in the art, improvements or transformations can be made according to the above description. All such improvements and transformations should fall within the protection scope of the appended claims of the present invention.

Claims

1. A method for calculating the number of low Hamming weight codewords of a polar code, characterized in that: The method for calculating the number of low Hamming weight codewords of the polar code comprises: Acquire a serial cancellation path metric and a serial cancellation decoding of a Fano decoder, modify the serial cancellation path metric to obtain a target serial cancellation path metric, and modify the serial cancellation decoding to obtain a target serial cancellation decoding; Perform node selection according to the target serial cancellation decoding to obtain a target node, and select a target path corresponding to the target node according to the target serial cancellation path metric; When it is detected that the target node arrives at the end point of the target path, the path type of the target path is determined, and if the target path is a low-weight path, the code weight value of the target path is counted to obtain a counting result; Perform path backtracking according to the counting result to obtain a backtracking result, obtain a corresponding target counting result according to the backtracking result, and obtain the number of low Hamming weight codewords according to the target counting result.

2. The method for calculating the number of low Hamming weight codewords of the polar code according to claim 1, characterized in that: The target serial cancellation path metric includes a first serial cancellation path metric and a second serial cancellation path metric; The modifying process of the serial cancellation path metric to obtain the target serial cancellation path metric specifically includes: Modifying the Fano decoder to obtain a metric counter, and comparing the branch path codeword of the metric counter with the decoding result of the Fano decoder; If the branch path codeword is consistent with the decoding result, modifying the path offset item of the serial cancellation path metric to obtain a first serial cancellation path metric; If the branch path codeword does not match the decoding result, the serial cancellation path metric is modified according to the metric counter to obtain a second serial cancellation path metric.

3. The method for calculating the number of low Hamming weight codewords of the polar code according to claim 1, characterized in that: The modifying process of the serial offset decoding to obtain the target serial offset decoding specifically includes: Obtaining the parent node of the serial offset decoding, performing child node calculation according to the log-likelihood ratio information of the parent node, and obtaining the first code weight information of the left child node and the second code weight information of the right child node; The serial offset decoding is modified according to the first code weight information and the second code weight information to obtain a target serial offset decoding.

4. The method for calculating the number of low Hamming weight codewords of the polar code according to claim 1, characterized in that: The step of performing node selection according to the target serial offset decoding to obtain a target node, and selecting a target path corresponding to the target node according to the target serial offset path metric, specifically includes: Obtaining a preset number of branch path metrics of the target serial offset decoding, and performing metric value calculation on all the branch path metrics to obtain multiple path metric values; All the path metric values ​​are sorted by size to obtain a path metric value list, the node corresponding to the maximum path metric value in the path metric value list is used as the target node, and the target path corresponding to the target node is selected according to the target serial offset path metric.

5. The method for calculating the number of low Hamming weight codewords of polar codes according to claim 1, characterized in that: The node selection is performed according to the target serial offset decoding to obtain a target node, and a target path corresponding to the target node is selected according to the target serial offset path metric, and then the following is further included: Obtaining a forward node metric value of the target node, comparing the forward node metric value with a threshold value to obtain a first comparison result, and determining whether the target node is moving forward on the target path according to the first comparison result; If the first comparison result is that the forward node metric value is less than the threshold value, it is determined that the target node needs to be backtracked; If the first comparison result is that the forward node metric value is greater than or equal to the threshold, it is determined that the target node is moving forward on the target path.

6. The method for calculating the number of low Hamming weight codewords of polar codes according to claim 5, characterized in that: When it is detected that the target node arrives at the end point of the target path, the path type of the target path is determined, and if the target path is a low-weight path, the code weight value of the target path is counted to obtain a counting result, specifically including: When it is detected that the target node moves forward and moves to the end point of the target path, a path metric value of the target path is obtained, and the path metric value is compared with a preset expected code weight to obtain a second comparison result; If the second comparison result is that the path metric value is less than the preset expected code weight, the target path is determined to be a low-weight path, and the code weight value of the target path is counted to obtain a counting result.

7. The method for calculating the number of low Hamming weight codewords of polar codes according to claim 4, characterized in that: The path backtracking is performed according to the counting result to obtain a backtracking result, a corresponding target counting result is obtained according to the backtracking result, and the number of low Hamming weight codewords is obtained according to the target counting result, specifically including: Perform node backtracking on the remaining path metric values ​​in the path metric value list in turn according to the counting result to obtain a backtracking result, and obtain a path corresponding to a low-weight path in the backtracking result; The code weight values ​​of all the paths are counted to obtain a target counting result, a low Hamming weight codeword distribution result is obtained based on the counting information of the target counting result, and a quantity is counted based on the low Hamming weight codeword distribution result to obtain the number of low Hamming weight codewords.

8. A system for calculating the number of low Hamming weight codewords of polar codes, characterized in that: The calculation system of the number of low Hamming weight codewords of the polar code comprises: An information modification module is used to obtain a serial cancellation path metric and a serial cancellation decoding of a Fano decoder, modify the serial cancellation path metric to obtain a target serial cancellation path metric, and modify the serial cancellation decoding to obtain a target serial cancellation decoding; A node determination module, configured to perform node selection according to the target serial offset decoding to obtain a target node, and select a target path corresponding to the target node according to the target serial offset path metric; A code weight calculation module, for determining the path type of the target path when it is detected that the target node has arrived at the end of the target path, and if the target path is a low-weight path, counting the code weight value of the target path to obtain a counting result; The result output module is used to perform path backtracking according to the counting result to obtain a backtracking result, obtain a corresponding target counting result according to the backtracking result, and obtain the number of low Hamming weight codewords according to the target counting result.

9. A terminal, characterized in that: The terminal includes: a memory, a processor, and a calculation program for the number of low Hamming weight codewords of the polar code stored in the memory and executable on the processor, wherein when the calculation program for the number of low Hamming weight codewords of the polar code is executed by the processor, the steps of the method for calculating the number of low Hamming weight codewords of the polar code are implemented.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a calculation program for the number of low Hamming weight codewords of the polar code, and when the calculation program for the number of low Hamming weight codewords of the polar code is executed by the processor, the steps of the method for calculating the number of low Hamming weight codewords of the polar code are implemented.

Citation Information

Cited By

  • Polarization adjustment convolutional code construction method and device, terminal and storage medium

    CN121585186A