Channel coding method, system and equipment based on weighted probability model and medium
Through the channel encoding method based on the weighted probability model, the shortcomings of channel encoding in forward error correction and data verification retransmission are solved, and more efficient data transmission and better lossless transmission effects are achieved.
Patent Information
- Application Number
- CN202410116246.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-01-26
- Publication Date
- 2025-07-22
AI Technical Summary
The existing channel encoding technology cannot adapt to channel interference and cannot effectively perform forward error correction and data verification retransmission, resulting in poor performance of code rate and polarized code parameters.
The channel encoding method based on the weighted probability model is adopted to realize lossless data transmission through source processing, weighted probability algorithm encoding, decoding and forward error correction.
It improves the accuracy and efficiency of data transmission, adapts to different channel conditions, meets the needs of multi-task scenarios, and optimizes the code rate and polarized code parameters.
Smart Images

Figure CN120357997A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of channel coding, and in particular, to a channel coding method, system, device and medium based on a weighted probability model. Background Art
[0002] In existing service scenarios, traditional arithmetic coding cannot adapt to the interference situation of the channel, and at the same time, the error correction rate cannot be controlled by control parameters. Therefore, it is impossible to perform channel coding that integrates forward error correction and data verification retransmission well, resulting in poor performance of parameters such as the code rate and polarization code of the existing channel coding in the integration of forward error correction and data verification retransmission. Summary of the Invention
[0003] The present invention aims to solve at least one of the technical problems existing in the prior art. For this purpose, the present invention provides a channel coding method, system, device and medium based on a weighted probability model, which can perform channel coding that integrates forward error correction and data verification retransmission, and at the same time well optimizes parameters such as the code rate and polarization code, improves the accuracy of data transmission, and realizes better lossless transmission.
[0004] In a first aspect, an embodiment of the present invention provides a channel coding method based on a weighted probability model, and the channel coding method based on a weighted probability model includes:
[0005] Obtain first source sequence data;
[0006] Perform source processing on the first source sequence data to obtain second source sequence data;
[0007] Encode the second source sequence data through a weighted probability algorithm to obtain compressed data corresponding to the second source sequence data;
[0008] Transmit the compressed data to a receiving end;
[0009] Decode the compressed data to obtain third source sequence data;
[0010] Perform forward error correction on the third source sequence data to obtain fourth source sequence data;
[0011] Perform inverse source processing on the fourth source sequence data to obtain lossless transmission data corresponding to the first source sequence data.
[0012] According to the method of the embodiment of the present invention, it has at least the following beneficial effects:
[0013] This method first processes the first source sequence data through source processing, enabling the second source sequence data to have more context relationships and corresponding verification conditions, while being able to perform a certain degree of data compression, providing lower load occupancy and more verification conditions for data transmission, and improving the efficiency of data transmission; secondly, encodes the second source sequence data through a weighted probability algorithm to obtain compressed data, which can make the compressed data applicable to different verification conditions, and at the same time the coding rate of the compressed data is higher; then decodes the compressed data to obtain the third source sequence data. Since the compressed data is encoded through a weighted probability algorithm, the decoding can also be implemented based on the weighted probability algorithm, with a simple method and easy to be implemented by software and hardware; finally, performs forward error correction on the third source sequence data, which can adapt to different verification conditions, meet the needs of more task scenarios, and improve the generalization ability.
[0014] According to some embodiments of the present invention, the obtaining of the second source sequence data by performing source processing on the first source sequence data includes:
[0015] Performing source processing on the first source sequence data through a preset symbol replacement method to obtain the second source sequence data;
[0016] Formulating corresponding data verification conditions through the symbol replacement method; the data verification conditions are used for performing forward error correction on the third source sequence data.
[0017] According to some embodiments of the present invention, the encoding of the second source sequence data through a weighted probability algorithm to obtain the compressed data corresponding to the second source sequence data includes:
[0018] Initializing the real number operation variables and loop control variables of the weighted probability algorithm encoding;
[0019] Obtaining the first symbol of the second source sequence data, encoding the first symbol through a weighted probability algorithm to obtain a second symbol. If the first serial number of the first symbol is less than the loop control variable, adding one to the first serial number to obtain a second serial number, and encoding the third symbol corresponding to the second serial number through a weighted probability algorithm to obtain a fourth symbol, until the Nth serial number is greater than or equal to the loop control variable to obtain the compressed data; wherein, the N represents a positive integer, and the calculation formula of the weighted probability algorithm includes:
[0020]
[0021] Wherein, both R and L represent real number operation variables, i represents the serial number, represents the weighted probability mass function, and F() represents the weighted cumulative distribution function.
[0022] According to some embodiments of the present invention, the forward error correction of the third source sequence data to obtain the fourth source sequence data includes:
[0023] Performing linear error detection and decoding on the third source sequence data according to the data check condition to obtain the error position in decoding and the bit error sequence number;
[0024] Performing forward error correction decoding based on bit flipping through the error position in decoding and the bit error sequence number to obtain the fourth source sequence data.
[0025] According to some embodiments of the present invention, after the inverse source processing of the fourth source sequence data to obtain the lossless transmission data corresponding to the first source sequence data, the channel coding method based on the weighted probability model further includes:
[0026] Calculating the coding information entropy, coding rate, and average decoding error probability corresponding to the weighted probability algorithm;
[0027] Performing channel capacity reachability analysis according to the coding information entropy, the coding rate, and the average decoding error probability to obtain the channel capacity analysis result.
[0028] According to some embodiments of the present invention, the performing forward error correction decoding based on bit flipping through the error position in decoding and the bit error sequence number to obtain the fourth source sequence data includes:
[0029] Dividing the error position in decoding and the bit error sequence number by different signal-to-noise ratios to obtain a plurality of forward error correction batches;
[0030] Independently performing forward error correction decoding based on bit flipping on each forward error correction batch to obtain the fourth source sequence data.
[0031] According to some embodiments of the present invention, the forward error correction decoding based on bit flipping includes:
[0032] Obtaining a quality control parameter;
[0033] Setting an error correction range according to the error position in decoding;
[0034] Performing cyclic bit flipping on all the error positions in decoding according to the bit error sequence number, and controlling the end of bit flipping of each error position in decoding through the quality control parameter and the error correction range until the bit error sequence number reaches a threshold value, and ending the loop.
[0035] In a second aspect, an embodiment of the present invention provides a channel coding system based on a weighted probability model, and the channel coding system based on the weighted probability model includes:
[0036] A transmitting - end data acquisition module, configured to acquire first source sequence data;
[0037] A transmitting - end source processing module, configured to perform source processing on the first source sequence data to obtain second source sequence data;
[0038] A transmitting - end weighted probability algorithm encoding module, configured to encode the second source sequence data through a weighted probability algorithm to obtain compressed data corresponding to the second source sequence data;
[0039] A channel transmission module, configured to transmit the compressed data to a receiving end;
[0040] A receiving - end decoding module, configured to decode the compressed data to obtain third source sequence data;
[0041] A receiving - end forward error correction module, configured to perform forward error correction on the third source sequence data to obtain fourth source sequence data;
[0042] A receiving - end inverse source processing module, configured to perform inverse source processing on the fourth source sequence data to obtain lossless transmission data corresponding to the first source sequence data.
[0043] In a third aspect, an embodiment of the present invention provides an electronic device, including at least one control processor and a memory communicatively connected to the at least one control processor; the memory stores instructions executable by the at least one control processor, and when the instructions are executed by the at least one control processor, the at least one control processor is enabled to execute the channel coding method based on a weighted probability model as described in the first aspect.
[0044] In a fourth aspect, an embodiment of the present invention provides a computer storage medium, where the computer - readable storage medium stores computer - executable instructions, and the computer - executable instructions are used to enable a computer to execute the channel coding method based on a weighted probability model as described in the first aspect.
[0045] It should be noted that the beneficial effects of the second and third aspects of the present invention are the same as those of the plug - in quick access method in the first aspect compared with the prior art, and will not be elaborated here.
[0046] Other features and advantages of the present invention will be described in the subsequent description, and some of them will become obvious from the description or be understood by implementing the present invention. BRIEF DESCRIPTION OF THE DRAWINGS
[0047] The above - mentioned and / or additional aspects and advantages of the present invention will become obvious and easy to understand from the description of the embodiments in conjunction with the following drawings, where:
[0048] Figure 1 It is a flowchart of a channel coding method based on a weighted probability model provided by an embodiment of the present invention;
[0049] Figure 2 It is a flowchart of obtaining second source sequence data by performing source processing on first source sequence data provided by an embodiment of the present invention;
[0050] Figure 3 It is a flowchart of encoding second source sequence data through a weighted probability algorithm to obtain compressed data corresponding to the second source sequence data provided by an embodiment of the present invention;
[0051] Figure 4 It is a flowchart of performing forward error correction on third source sequence data to obtain fourth source sequence data provided by an embodiment of the present invention;
[0052] Figure 5 It is a flowchart of a channel coding method based on a weighted probability model after obtaining lossless transmission data corresponding to the first source sequence data by performing inverse source processing on the fourth source sequence data provided by an embodiment of the present invention;
[0053] Figure 6 It is a flowchart of performing forward error correction decoding based on bit flipping through a decoding error position and a bit error sequence number to obtain fourth source sequence data provided by an embodiment of the present invention;
[0054] Figure 7 It is a flowchart of forward error correction decoding based on bit flipping provided by an embodiment of the present invention;
[0055] Figure 8 It is a schematic diagram of a channel coding method based on a weighted probability model provided by an embodiment of the present invention;
[0056] Figure 9 It is a schematic diagram of a weighted model coding process that can be losslessly restored provided by an embodiment of the present invention;
[0057] Figure 10 It is a schematic diagram of weighted model coding that may not be restorable provided by an embodiment of the present invention;
[0058] Figure 11 It is an experimental result graph of the relationship between R and n provided by an embodiment of the present invention;
[0059] Figure 12 It is an experimental result graph of FER provided by an embodiment of the present invention;
[0060] Figure 13 It is an experimental result graph of the comparison between a specific embodiment and a polar code provided by an embodiment of the present invention;
[0061] Figure 14 It is a schematic structural diagram of a channel coding system based on a weighted probability model provided by an embodiment of the present invention;
[0062] Figure 15 It is a structural diagram of an electronic device provided by an embodiment of the present invention. Detailed implementation manners
[0063] The embodiments of the present invention will be described in detail below. The examples of the embodiments are shown in the accompanying drawings, where the same or similar reference numerals denote the same or similar elements or elements having the same or similar functions throughout. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present invention, and should not be construed as a limitation of the present invention.
[0064] In the description of the present invention, if the first, second, etc. are described only for the purpose of distinguishing technical features, they should not be construed as indicating or implying relative importance or implicitly indicating the quantity of the indicated technical features or implicitly indicating the sequence of the indicated technical features.
[0065] In the description of the present invention, it should be understood that for the orientation description, such as up, down, etc., the orientation or positional relationship indicated is based on the orientation or positional relationship shown in the accompanying drawings, and is only for the convenience of describing the present invention and simplifying the description, rather than indicating or implying that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of the present invention.
[0066] In the description of the present invention, it should be noted that unless otherwise clearly defined, words such as setting, installing, connecting, etc. should be understood in a broad sense, and those skilled in the art can reasonably determine the specific meanings of the above words in the present invention in combination with the specific content of the technical solution.
[0067] Refer to Figure 1 , in some embodiments of the present invention, a channel coding method based on a weighted probability model is provided. The channel coding method based on a weighted probability model includes:
[0068] Step S100: Obtain the first source sequence data.
[0069] It should be noted that the first source sequence data represents a binary source sequence. For the convenience of subsequent description, the first source sequence data is represented by the symbol X.
[0070] Step S200: Perform source processing on the first source sequence data to obtain the second source sequence data.
[0071] It should be noted that source processing refers to performing a lossless transformation on any source sequence X. For the convenience of subsequent description, the second source sequence data is represented by the symbol Y.
[0072] Step S300: Encode the second source sequence data through a weighted probability algorithm to obtain the compressed data corresponding to the second source sequence data.
[0073] It should be noted that for the convenience of subsequent description, the compressed data is represented by the symbol V.
[0074] Step S400: Transmit the compressed data to the receiving end.
[0075] It should be noted that the compressed data is transmitted to the receiving end through a DMC channel. For the convenience of distinguishing whether the compressed data is at the sending end or the receiving end, the compressed data is represented by the symbol U at the receiving end.
[0076] Step S500: Decode the compressed data to obtain the third source sequence data.
[0077] It should be noted that decoding the compressed data to obtain the third source sequence data is the same as the traditional decoding principle. According to the weighted probability algorithm, inverse processing is performed to obtain the third source sequence data decoded by the weighted probability algorithm.
[0078] It should be noted that for the convenience of subsequent description, the third source sequence data is represented by the symbol Z.
[0079] Step S600: Perform forward error correction on the third source sequence data to obtain the fourth source sequence data.
[0080] Step S700: Perform inverse source processing on the fourth source sequence data to obtain the lossless transmission data corresponding to the first source sequence data.
[0081] First, through source processing, the first source sequence data is processed so that the second source sequence data has more context relationships and corresponding check conditions, and at the same time, certain data compression can be performed, providing lower load occupancy and more check conditions for data transmission and improving the efficiency of data transmission. Secondly, encoding the second source sequence data through a weighted probability algorithm to obtain compressed data can make the compressed data applicable to different check conditions, and at the same time, the coding rate of the compressed data is higher. Then, decoding the compressed data to obtain the third source sequence data. Since the compressed data is encoded through a weighted probability algorithm, decoding can also be implemented based on the weighted probability algorithm, with a simple method and easy to implement through software and hardware. Finally, performing forward error correction on the third source sequence data can adapt to different check conditions, meet the needs of more task scenarios, and improve the generalization ability.
[0082] Refer to Figure 2, in some embodiments of the present invention, performing source processing on the first source sequence data to obtain second source sequence data includes:
[0083] Step S201: Performing source processing on the first source sequence data through a preset symbol replacement method to obtain second source sequence data.
[0084] Step S202: Formulating corresponding data verification conditions through the symbol replacement method; the data verification conditions are used for forward error correction of the third source sequence data.
[0085] It should be noted that performing lossless transformation through the symbol replacement method and formulating corresponding data verification conditions through the symbol replacement method include:
[0086] (a) Replacing symbol 1 in X with "10" from left to right to obtain sequence Y, then Y = (0, 1, 0, 1, 0, 0, 1, 0, 0, 0, 1, 0, 1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0...), and X can be restored by replacing "10" in Y with 1 from left to right.
[0087] (b) Replacing symbol 1 in X with "101" and symbol 0 with "01" from left to right to obtain sequence Y, then
[0088] Y = (0, 1, 1, 0, 1, 1, 0, 1, 0, 1, 1, 0, 1, 0, 1, 0, 1, 1, 0, 1, 1, 0, 1, 1, 0, 1...)
[0089] X can be restored by replacing "101" in Y with 1 and "01" with 0 from left to right.
[0090] (c) Replacing symbol 1 in X with "010" and symbol 0 with "10" from left to right to obtain sequence Y, then
[0091] Y = (1, 0, 0, 1, 0, 0, 1, 0, 1, 0, 0, 1, 0, 1, 0, 1, 0, 0, 1, 0, 0, 1, 0, 0, 1, 0...)
[0092] X can be restored by replacing "010" in Y with 1 and "10" with 0 from left to right.
[0093] Denote the length of Y as l. The purpose of sequence conversion is to make Y meet the data verification conditions. Therefore, correspondingly, the data verification condition for (a) is: no more than 1 adjacent 1; the data verification condition for (b) is: no more than 1 adjacent 0 and no more than 2 adjacent 1s; the data verification condition for (c) is: no more than 2 adjacent 0s and no more than 1 adjacent 1.
[0094] Since (b) and (c) have one more check condition than (a), different transformation methods make the sequence Y have more check conditions, and the transformation method is called source processing. Source processing makes a large amount of redundant information exist in Y. Because there is an obvious linear context relationship among the symbols in Y, common entropy coding (such as run-length coding, dictionary coding, Huffman coding, or arithmetic coding, etc.) can be selected to compress Y. Different bit-length codewords need to be assigned to "0", "10" or "101", "01" or "010", "10", but the data check conditions will be lost during decoding. Therefore, the weighted probability algorithm is used to encode and decode losslessly while still meeting the data check conditions.
[0095] Through the symbol replacement method and the corresponding data check conditions of the symbol replacement method, a channel coding method integrating forward error correction and data check retransmission can be constructed, which can greatly improve the error correction rate and at the same time improve the channel coding efficiency.
[0096] Refer to Figure 3 , in some embodiments of the present invention, encoding the second source sequence data through a weighted probability algorithm to obtain the compressed data corresponding to the second source sequence data, including:
[0097] Step S301, initialize the real number operation variables and loop control variables for weighted probability algorithm encoding.
[0098] Step S302, obtain the first symbol of the second source sequence data, encode the first symbol through a weighted probability algorithm to obtain the second symbol. If the first serial number of the first symbol is less than the loop control variable, add 1 to the first serial number to obtain the second serial number, and encode the third symbol corresponding to the second serial number through a weighted probability algorithm to obtain the fourth symbol until the Nth serial number is greater than or equal to the loop control variable to obtain the compressed data; wherein, N represents a positive integer, and the calculation formula of the weighted probability algorithm includes:
[0099]
[0100] Wherein, both R and L represent real number operation variables, i represents the serial number, represents the weighted probability mass function, and F() represents the weighted cumulative distribution function.
[0101] It should be noted that the definition of the weighted probability mass function is as follows:
[0102] Let Y=(y1, y2,..., y l ), then the weighted probability mass function is Wherein, p(y i ) represents the probability mass function, 0≤p(y i )≤1, r represents the weight coefficient, and the probability mass functions of all serial numbers are defined as follows:
[0103]
[0104] Then the weighted cumulative distribution function is defined as follows:
[0105]
[0106] Therefore, correspondingly, during decoding, when the receiver knows r, l, p(0) or p(1), according to the calculation formula of the weighted probability algorithm, if y i = 0, F(0 - 1, r) = rF(-1), because so F(-1) = 0. L i = L i-1 and when y i = 1 and Since L i is non-decreasing, so if it can be determined that y i = 1, otherwise it can be determined that y i = 0. Thus, when decoding y i let
[0107] Through the control of real number operation variables and loop control variables, it can adapt to the interference of the channel, improve the error correction rate, and can also meet the requirements of different task scenarios, improving the universality of the coding method.
[0108] Referring to Figure 4 , in some embodiments of the present invention, forward error correction is performed on the third source sequence data to obtain the fourth source sequence data, including:
[0109] Step S610, perform linear error detection and decoding on the third source sequence data according to the data verification condition to obtain the error position of decoding and the bit error number.
[0110] It should be noted that the error detection and decoding process is also the verification decoding process in forward error correction, and the linear decoding process can terminate the decoding in time.
[0111] Step S620, perform forward error correction decoding based on bit flipping through the error position of decoding and the bit error number to obtain the fourth source sequence data.
[0112] Since the forward error correction decoding based on bit flipping is based on each bit of data, the forward error correction decoding based on bit flipping can not only adapt to the error correction decoding of the weighted probability algorithm, correct each bit step by step, but also set the bit error of each batch process, reduce the decoding error probability, and meet the conditions of lossless transmission.
[0113] Referring to Figure 5, in some embodiments of the present invention, after performing inverse source processing on the fourth source sequence data to obtain the lossless transmission data corresponding to the first source sequence data, the channel coding method based on the weighted probability model further includes:
[0114] Step S800, calculate the coding information entropy, coding rate, and average decoding error probability corresponding to the weighted probability algorithm.
[0115] Step S900, perform channel capacity reachability analysis based on the coding information entropy, coding rate, and average decoding error probability to obtain the channel capacity analysis result.
[0116] It should be noted that in this embodiment, the calculation of the coding information entropy, coding rate, and average decoding error probability is combined with the weighted probability algorithm, which can intuitively reflect the effectiveness of the weighted probability algorithm.
[0117] Performing channel capacity reachability analysis through the coding information entropy, coding rate, and average decoding error probability can not only reflect the effectiveness of the weighted probability algorithm for coding, but also limit the parameters in the coding method through the calculation of the coding information entropy, coding rate, and average decoding error probability, so as to achieve lossless transmission.
[0118] Refer to Figure 6 , in some embodiments of the present invention, performing forward error correction decoding based on bit flipping through the decoding error position and bit error sequence number to obtain the fourth source sequence data includes:
[0119] Step S621, divide the decoding error position and bit error sequence number through different signal-to-noise ratios to obtain multiple forward error correction batches.
[0120] It should be noted that the more decoding error positions included in the forward error correction batch, the greater the number of repeated error detection and decoding times. Therefore, the number of decoding error positions in the forward error correction batch can be set according to different signal-to-noise ratios, and the traversal times can also be limited to control the error correction operation time. Since each traversal step is independent, the loop scheme can be parallelized.
[0121] Step S622, independently perform forward error correction decoding based on bit flipping on each forward error correction batch to obtain the fourth source sequence data.
[0122] Controlling the error correction operation time through multiple forward error correction batches, since each traversal is independent, the loop scheme can be parallelized, which can improve the efficiency of forward error correction and reduce the decoding error probability at the same time.
[0123] Refer to Figure 7 , in some embodiments of the present invention, the forward error correction decoding based on bit flipping includes:
[0124] Step S601: Obtain quality control parameters.
[0125] Step S602: Set the error correction range according to the position of the decoding error.
[0126] Step S603: Perform cyclic bit flipping on all decoding error positions according to the bit error sequence number, and control the end of bit flipping for each decoding error position through the quality control parameter and the error correction range until the bit error sequence number reaches the threshold, and then end the loop.
[0127] It should be noted that performing cyclic bit flipping on all decoding error positions according to the bit error sequence number, and controlling the end of bit flipping for each decoding error position through the quality control parameter and the error correction range until the bit error sequence number reaches the threshold, and then ending the loop, the specific steps include:
[0128] (1) Forward error correction decoding when the bit error sequence number is 1:
[0129] 1) Set the error correction range and quality control parameters; a total of 4 parameters: ρ, σ, θ, where r and ρ are used to define the error correction range, and σ and θ are used to limit the error correction quality, and the values of ρ and σ, θ are set with reference to the average decoding error probability.
[0130] 2) Calculate the theoretical error bit position pos through the decoding error position;
[0131] 3) Set the error correction range of sequence U based on pos, end←pos+ρ, that is, i∈[start,end]; the ← symbol represents assignment;
[0132] 4) Execute i←end;
[0133] 5) Flip the i-th bit of U, that is
[0134] 6) Redetect and decode U;
[0135] 7) If then it is determined that all errors in are corrected, and end; if and, then it is determined that the first error from left to right in is corrected, and end.
[0136] 8)
[0137] 9) If i<start, repeat steps 5) to 9);
[0138] 10) Jump to the forward error correction decoding when the bit error sequence number is 2.
[0139] (2) Forward error correction decoding when the bit error sequence number is 2:
[0140] 1) Set the error correction range and quality control parameters; a total of 4 parameters: r, ρ, σ, θ, where r and ρ are used to limit the error correction range, and σ and θ are used to limit the error correction quality;
[0141] 2) Calculate the theoretical error bit position pos through the decoding error position;
[0142] 3) Set the error correction range of the sequence U based on pos, end ← pos + ρ, that is, i ∈ [start, end]; the ← symbol represents assignment;
[0143] 4) i ← end;
[0144] 5)
[0145] 6) j ← i - 1;
[0146] 7)
[0147] 8) Redetect and decode U;
[0148] 9) If Then it is determined that All errors in are corrected, and the process ends; if Then it is determined that The first error from left to right in is corrected, and the process ends;
[0149] 11) j ← j - 1;
[0150] 12) If j < start - 1, repeat steps 7 to 11;
[0151] 13) i ← i - 1;
[0152] 14) If i < start, repeat steps 5 to 14;
[0153] 15) Start error correction for bit error sequence number 3.
[0154] Subsequent until the bit error sequence number reaches the threshold, and the loop ends.
[0155] End by controlling the bit flip of each decoding error position through the quality control parameters and error correction range, which ensures the error correction quality and provides loop control at the same time, enabling effective error correction for each decoding error position and avoiding the possibility of missed detection and false detection.
[0156] Refer to Figure 8, for the convenience of those skilled in the art to understand, a specific embodiment of the present invention provides a channel coding method based on a weighted probability model, including the following steps:
[0157] I. Data preparation:
[0158] Let the binary source sequence X have n bits, then there are 2 n possibilities for the sequence X. If it is agreed that the sequence X must satisfy conditions such as "each symbol 1 is separated by one or more 0s", "each 0 is separated by one or two 1s", or similar conditions, then these conditions become the error detection decision conditions during channel transmission. For any source sequence X, it can meet the above conditions through lossless transformation. Taking X = (0, 1, 1, 0, 1, 0, 0, 1, 1, 1, 0, 1, 0, 0, 0, 0, …) as an example, the lossless transformation and inverse transformation methods are as follows:
[0159] (a) Replace the symbol 1 in X with "10" from left to right to obtain the sequence Y, then Y = (0, 1, 0, 1, 0, 0, 1, 0, 0, 0, 1, 0, 1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, …). Replacing "10" in Y with 1 from left to right can restore X.
[0160] (b) Replace the symbol 1 in X with "101" and the symbol 0 with "01" from left to right to obtain the sequence Y, then Y = (0, 1, 1, 0, 1, 1, 0, 1, 0, 1, 1, 0, 1, 0, 1, 0, 1, 1, 0, 1, 1, 0, 1, 1, 0, 1, …). Replacing "101" in Y with 1 and "01" with 0 from left to right can restore X.
[0161] (c) Replace the symbol 1 in X with "010" and the symbol 0 with "10" from left to right to obtain the sequence Y, then Y = (1, 0, 0, 1, 0, 0, 1, 0, 1, 0, 0, 1, 0, 1, 0, 1, 0, 0, 1, 0, 0, 1, 0, 0, 1, 0, …). Replacing "010" in Y with 1 and "10" with 0 from left to right can restore X.
[0162] Denote the length of Y as l. The purpose of the sequence conversion is to make Y meet the data verification conditions. Therefore, correspondingly:
[0163] The data verification condition for (a) is: no more than 1 adjacent 1.
[0164] The data verification condition for (b) is: no more than 1 adjacent 0, and no more than 2 adjacent 1s.
[0165] The data verification condition for (c) is: no more than 2 adjacent 0s, and no more than 1 adjacent 1.
[0166] Since (b) and (c) have one more parity check condition than (a), different transformation methods make the sequence Y have more parity check conditions, and the transformation method is called source processing. Source processing makes a large amount of redundant information exist in Y. Because there is an obvious linear context relationship among the symbols in Y, common entropy coding (such as run-length coding, dictionary coding, Huffman coding, or arithmetic coding, etc.) can be selected to compress Y. Different bit lengths of codewords need to be assigned to "0", "10", or "101", "01", or "010", "10", but the data parity check conditions will be lost during decoding. Therefore, a weighted probability algorithm is used to encode while still satisfying the data parity check conditions during lossless decoding. Thus, a new arithmetic coding method is constructed based on weighted probability, which is defined as weighted probability arithmetic coding. When this method performs lossless decoding, Y can still satisfy the data parity check conditions, and the code rate of weighted probability arithmetic coding is significantly better than that of standard arithmetic coding.
[0167] Therefore, the channel transmission model based on weighted probability arithmetic encoding and decoding is as Figure 1 shown. The sender uses weighted probability arithmetic coding to perform lossless compression on Y, and the receiver realizes data parity check and error correction check through the data parity check conditions of (a), (b), and (c) during decoding. The coding result L of the sequence Y l is converted into a binary sequence V=(v1, v2, …, v m ) with length m. V is transmitted through the DMC channel, and U=(u1, u2, …, u m ) is the received binary sequence. When there is no error in transmission, U = V.
[0168] II. Weighted Probability Arithmetic Encoding and Decoding:
[0169] 1. Weighted Probability Arithmetic Encoding:
[0170] Let the discrete memoryless source Y=(y1, y2, …, y l ), y i ∈A={0, 1, …, k}, i = 1, 2, …, l, then the weighted probability mass function is p(y i ) is the probability mass function of, 0 ≤ p(y i ) ≤ 1, r is the weight coefficient, so there is:
[0171]
[0172] The weighted cumulative distribution function is defined as:
[0173]
[0174] Since Y is a binary sequence, so A={0, 1}, then y i ∈{0, 1}, when y i = 0, F(yi -1, r) = rF(y i -1) = rp(-1) = 0; y i When y = 1 Let R0 = 1, L0 = 0, then for the i-th (i = 1, 2, 3,...) symbol y i The weighted probability arithmetic coding operation formula is defined as:
[0175]
[0176] L i = L i-1 + R i-1 F(y i -1, r)
[0177] H i = L i + R i (2 - 3)
[0178] Among them, R i 、L i and H i are real number operation variables, y l After encoding, L l is the encoding result, which is equivalent to Figure 1 V in. According to (2 - 3), the weighted probability arithmetic coding steps are as shown in Table 1 below:
[0179] Table 1 Weighted Probability Arithmetic Coding Based on Y
[0180]
[0181] 2. Weighted Probability Arithmetic Decoding:
[0182] When the receiving end knows e, l, p(0) or p(1), according to (2 - 3), if y i = 0, F(0 - 1, r) = rF(-1), because so F(-1) = 0. L i = L i-1 and When y i = 1 and Since L ii is non-decreasing, so if then it can be determined that y i = 1, otherwise it can be determined that y i = 0. Thus, when decoding y i let:
[0183]
[0184] Among them, T i is the decision threshold of the decoding y i . For the binary sequence U at the receiving end, when lossless decoding is performed, U is equivalent to the real number L in (2 - 3) l , then the decoding steps are shown in Table 2 below:
[0185] Table 2 Weighted Probability Arithmetic Decoding Based on U
[0186]
[0187]
[0188] When U = V, lossless encoding and decoding can be performed, and X is obtained by inverse source processing of Y. There are three basic cases for the weight coefficient r: 0 < r < 1; r = 1; r > 1. Let r > 1. Taking (a) as an example, at this time Y satisfies (1 - 1), and the probabilities of symbol 0 and symbol 1 in sequence Y are p(0) = p and p(1) = 1 - p respectively. Encode y according to (2 - 3) i+1 = 0, y i+2 = 1, and the process of y i+3 = 0 is as shown in Figure 9 and Figure 10 .
[0189] Figure 10 In i , since L l is non - decreasing, when L i+1 ≥ H i+1 , y is determined to be 1 by (2 - 4), and the decoding is incorrect. Under the premise of lossless encoding and decoding, there is a maximum value for r. According to Figure 9 , L i+3 = L i + R i r 2 p 2 , R i+3 = R i r 3 p 2 (1 - p), H i+3 = L i + R i r 2 p 2 + R i r 3 p 2 (1 - p). Since y i+1 = 0 and F(-1) = 0, so L i+1 = L i , R i+1 = R i rp, H i+1 = L i + R i rp. Let Hi+3 ≤H i+1 It can be obtained that:
[0190]
[0191] Let the equation ar 2 + br + c = 0, where a = p(1 - p), b = p, c = -1, and r > 0. The positive real root that satisfies the equation is Simplify:
[0192]
[0193] Therefore, according to weighted probability arithmetic coding and weighted probability arithmetic decoding, there exist Theorem 1 and Theorem 2:
[0194] Theorem 1: The source sequence Y satisfies (1 - 1), p is the probability of symbol 0 in Y. When the weighted probability arithmetic coding can losslessly decode the sequence Y through V.
[0195] Proof: Assume that L i (i ≥ 1, i ∈ Z) can losslessly decode y1, y2,..., y i , since the sequence Y satisfies (1 - 1), it is proved by induction in two cases.
[0196] (1) y i = 1, there does not exist y i+1 = 1. When y i+1 = 0, according to (2 - 3) coding, we can get L i+1 = L i , R i+1 = R i rp. Because L i+1 = L i , so L i+1 can losslessly decode y1, y2,..., y i . Also, since R i rp > 0, L i+1 < L i + R i rp, so the decoded y i+1 = 0.
[0197] (2) y i = 0, according to (2 - 3) coding, we can get L i = L i-1 , R i = R i-1 rp, L i-1 can losslessly decode y1, y2,..., y i . When y i+1 = 0, according to (2 - 3) coding, we can get L i+1 = Li , R i+1 = R i rp, because L i+1 = L i , so L i+1 can losslessly decode y1, y2, …, y i . Also because L i+1 < L i + R i rp, so the decoded y i+1 = 0.
[0198] When y i+1 = 1, according to the encoding in (2 - 3), we can get L i+1 = L i + R i r 2 p 2 , R i+1 = R i-1 r 2 p(1 - p). Because rp < 1, so L i+1 < L i + R i rp, the decoded y i = 0. Because y i = 0, and L i+1 + R i+1 rp = L i + R i r 2 p 2 , so L i+1 = L i+1 + R i+1 rp, the decoded y i+1 = 1. When y i = 0, y i+1 = 1, if it can be proved that y i-1 can be correctly decoded, then by induction, we can get L i+1 can losslessly decode y1, y2, …, y i , y i+1 .
[0199] When y i-1 = 0, y i = 0, y i+1 = 1, the encoding can get L i = L i-1 = L i-2 , L i+1 = L i-2 + R i-2 r 3 p 3 . Because rp < 1, so L i+1 < L i-2 + R i-2Decode rp to get y i-1 = 0. When y i-1 = 1, y i = 0, y i+1 = 1, encoding can obtain L i-1 = L i-2 + R i-2 rp, L i = L i-1 , L i+1 = L i + R i rp = L i-2 + R i-2 rp + R i-1 r 3 p 2 (1 - p). Obviously, L i+1 > L i-2 + R i-2 Decode rp to get y i-1 = 1. That is, y i-1 can be correctly decoded.
[0200] Extended Theorem of Theorem 1: Let there be t + 2 (t = 1, 2, 3,...) symbols from the (i + 1)-th position in sequence Y as 0, 1,..., 1, 0, where the number of adjacent symbols 1 is t. According to (2 - 3), we have:
[0201]
[0202]
[0203] From H i+t+2 ≤ H i+1 we can get:
[0204]
[0205] When :
[0206]
[0207] By solving equation (2 - 7), we can obtain the value of r max when t ≥ 1. The larger t is in Table 1, the closer r max is to 1. Table 1 is as follows:
[0208] Table 3 shows the relationship between t and r max when p(0) = p(1) in sequence Y
[0209]
[0210] Theorem 2: Let the adjacent 1s in sequence Y not exceed t (t ≥ 1). When and The time-weighted probability arithmetic coding can losslessly decode the sequence Y through V.
[0211] Proof: Let d be the number of consecutive symbols 1 in the sequence Y, where 0 ≤ d ≤ t. When d = 0, according to (2-3), we have L i+t+2 = L i+t+1 = L i+t = … = L i , because So y i+1 = y i+2 = … = y i+t+2 = 0. When 1 ≤ d ≤ t, According to (2-3), we have During decoding, because So L i+d+2 can accurately decode y i+1 = 0. Because y i+1 = 0, so Because So L i+d+2 can accurately decode y i+2 = 1. When d ≥ 2 L i+d+2 can accurately decode y i+d+1 = 1. Also, because L i+d+2 = L i+d+1 and So L i+d+2 can accurately decode y i+d+2 = 0. When d = t + 1 So y i+1 = 1, decoding error; because when d = t + 1 + c (c ≥ 1) So y i+1 = 1, decoding error. It can be obtained that when 0 ≤ d ≤ t, V can losslessly decode the sequence Y. When and , according to the above proof steps, it can be obtained that when 0 ≤ d ≤ t, V can losslessly decode the sequence Y.
[0212] 3. Improvement of weighted probability arithmetic coding:
[0213] When the lengths n of the sequences X at the sending and receiving ends are known, according to Theorem 2, the source processing method (a) adopts to perform lossless encoding and decoding, and the source processing method (b) adopts to perform lossless encoding and decoding. Taking the source processing method (b) as an example, when , the encoding steps are shown in Table 4 below:
[0214] Table 4 Improvement of weighted probability arithmetic coding based on Y
[0215]
[0216] Modifying Steps 3 and 4 above according to Theorem 2 can be adapted to various source processing methods. Since the length n of the sequence X is known during decoding at the receiving end, and is known, only V needs to be transmitted.
[0217] 4. Error Detection and Decoding:
[0218] According to the error detection conditions of the source processing method (b), decoding synchronously completes the inverse source processing process, that is, the output of "101" is 1 and the output of "01" is 0. Thus, the linear error detection and decoding steps at the receiving end are shown in Table 5 below:
[0219] Table 5 Weighted Probability Arithmetic Error Detection and Decoding Based on U
[0220]
[0221]
[0222] The above error detection and decoding process is also the process of parity check decoding in forward error correction. The linear decoding process can timely abort the decoding, giving the theoretical position of the error bits in U calculated through c as Combined with the theoretical error position, different forward error correction methods or retransmission methods are given according to the DMC channel model.
[0223] The above linear error detection and decoding is performed through forward error correction decoding based on bit flipping. The specific steps are as follows:
[0224] Let the sequence U = {u1, u2,..., u m} and there are τ bit errors. When τ = 1, the forward error correction decoding steps are shown in Table 6 below:
[0225] Table 6 Forward Error Correction Decoding with 1 Bit Error
[0226]
[0227] When τ = 2, the forward error correction decoding steps are shown in Table 7 below:
[0228] Table 7 Forward Error Correction Decoding with 2 Bit Errors
[0229]
[0230]
[0231] Among them, r and ρ are used to limit the error correction range, and σ and θ are used to limit the error correction quality. The values of ρ, σ, and θ are set with reference to the average decoding error probability. When τ = 1, step 5 is repeated times. When τ ≥ 2, multiple bit flips need to be implemented through nested loops. At this time, step 5 needs to be repeated times. Therefore, when correcting τ bits, the number of times step 5 is repeated is:
[0232]
[0233] Obviously, the larger τ is, the larger the number of repeated error detection and decoding is. The value of τ can be set according to different signal-to-noise ratios, or the number of traversals can be limited to control the error correction operation time. Since each traversal is independent, the loop scheme can be parallel.
[0234] III. Mathematical analysis of weighted probability arithmetic coding:
[0235] 1. Calculate the information entropy of weighted probability arithmetic coding:
[0236] The source sequence Y = (y1, y2,..., y l )(y i ∈ A = {0, 1}, i = 1, 2,..., l). When r = 1, According to the definition of Shannon information entropy, the entropy of Y is:
[0237] H(X) = -p(0)log2p(0) - p(1)log2p(1) (3 - 1);
[0238] When r ≠ 1, define the self-information amount of the random variable y with probability i as:
[0239]
[0240] Suppose the sequence Y has c0 symbols 0 and c1 symbols 1, and c0 + c1 = l. When r is known, the total information amount of the source sequence Y is:
[0241]
[0242] Therefore, the information amount per symbol on average is:
[0243]
[0244] Denote the information entropy of weighted probability arithmetic coding as H(Y, r):
[0245]
[0246] According to the weighted probability arithmetic coding information entropy, after r is determined, the length of V obtained by weighted probability arithmetic coding is nH(Y, r) (bit). Thus, the minimum limit of weighted probability arithmetic lossless coding is:
[0247]
[0248] Proof: According to Theorem 1, r max is the maximum value of weighted probability arithmetic lossless coding, and r max > 1. When r > r max , V cannot restore the sequence Y. Therefore, H(Y, r max ) is the minimum limit of weighted probability arithmetic lossless coding.
[0249] Suppose that each symbol of the binary source sequence X with length n is uniformly distributed. After being processed by method (b), c0 = n in the sequence Y. When using for coding:
[0250]
[0251] The total amount of information is The self-information of symbol 1 is 0. Therefore, the symbol 0 in the sequence Y determines the length of V after coding. So, for error detection and decoding, the number c of symbol 0 is counted, and the position of the error bit in U is obtained through .
[0252] 2. Calculate the coding rate:
[0253] The amount of information carried by each bit in the sequence Y is H(Y, r) (bit / symbol). The amount of information carried by each bit in the source sequence X is H(X) (bit / symbol). The coding rate of weighted probability arithmetic coding can be obtained as:
[0254]
[0255] When H(X) = 1, at this time When H(X) = 1, at this time Different source processing methods can obtain different weighted probability arithmetic coding rates.
[0256] 3. Calculate the average decoding error probability:
[0257] Let E represent the set of binary sequences that satisfy (1 - 1). There are f(l) sequences in E and When l = 1, E = (0, 1), f(l = 1) = 2, and the complementary event is When l = 2, E = (00, 01, 10), f(l = 2) = 3, When l = 3, E = (000, 001, 010, 100, 101), f(l = 3) = 5, When l ≥ 3:
[0258] f(l) = f(l - 1) + f(l - 2) (3 - 7);
[0259] The probability of obtaining E is:
[0260]
[0261] Among the f(l) sequences Y in E, they are uniformly distributed, then:
[0262]
[0263] Therefore, the probability that Q ∈ E and Q ≠ Y is:
[0264]
[0265] P(Q ≠ Y|Q ∈ E) is the average decoding error probability, so P err = P(Q ≠ Y|Q ∈ E), P err is the probability of error in error - detecting decoding.
[0266] Theorem 3: lim l→∞ P err = lim l→∞ (Q ≠ Y|Q ∈ E) = 0.
[0267] Proof: As l → ∞, then P(Y ≠ Q) → 1, and it follows that P(Y ≠ Q|Y ∈ E) → P(E). According to the Fibonacci sequence, let F(0) = 0, F(1) = 1, and when l ≥ 2, l ∈ N * F(l) = F(l - 1) + F(l - 2). So when l ≥ 1, l ∈ N * f(l) = F(l) + F(l + 1). From the general formula of the Fibonacci sequence, we get:
[0268]
[0269] We can obtain:
[0270]
[0271] Since So when l → ∞, P(E) → 0, that is, lim l→∞ P(Q ≠ Y|Q ∈ E) = 0.
[0272] Let E denote the set of binary sequences satisfying (1 - 2), F has g(l) sequences and When l = 1, F = (0, 1), g(l = 1) = 2, and the complementary event is When l = 2, F = (01, 10, 11), g(l = 2) = 3, When l = 3, F = (010, 101, 011, 110), f(l = 3) = 4, When l ≥ 4:
[0273] g(l) = g(l - 2) + g(l - 3) (3 - 11);
[0274] It is obtained that:
[0275]
[0276] Both f(l) and g(l) are monotonically increasing, and g(l) ≤ f(l), that is When l → ∞ P err = P(Q ≠ Y|Q ∈ F), and it can be obtained that lim l→∞ P etr = 0. According to (3 - 10) and (3 - 12), P can be calculated err As shown in Table 8:
[0277] Table 8 Calculate P(Q ≠ Y|Q ∈ E) and P(Q ≠ Y|Q ∈ F) according to l
[0278]
[0279] Table 8 shows that the larger l is, the lower the probability of error in error - detecting decoding. Different source - processing methods can obtain different weighted - probability arithmetic - coding average decoding error probabilities. Therefore, in the error - correction process, on the premise of considering the operation efficiency, The larger the values of ρ, σ, and θ are, the smaller P err is, and the lower the probability of error in step (5). According to the above reasoning and proof, when the source - processing method is determined, the code rate and transmission rate of weighted - probability arithmetic coding are also determined. When l approaches infinity, the error probability after error - correction decoding in this paper is 0, that is, the channel capacity can be achieved.
[0280] IV. Simulation Experiments and Result Analysis
[0281] As Figure 11 shown, for the simulation experiment of AWGN - channel BPSK signals, considering error - free transmission, it is obtained that when r ≤ r max , lossless encoding and decoding can be achieved, and when r > r max , decoding errors occur. Based on method (b) to process randomly generated binary sequences, lossless encoding and decoding can be achieved. When the length n of the source sequence X is large enough, then l is large enough. The experiment shows that the actual coding rate R approaches the theoretical value Figure 11 When n = 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024, 2048 respectively, the corresponding actual coding rate. Obviously, the longer the code length, the closer it is to the limit of theoretical calculation.
[0282] As Figure 12 shown, the experiment has incorrect transmission. Let the length of random data per frame be n = 160, and the length after coding be 320, denoted as N = (320, 160). According to Figure 11 at this time R = 0.5, E b / N0(dB) the initial value is 1.0, increasing by 0.5 each time and testing 10 6 frames, respectively τ = 5, ρ = 64, σ = 32, θ = 24 and set τ = 4, ρ = 64, σ = 32, θ = 24.
[0283] Figure 12 In -6 increasing τ can reduce the decoding error probability, and the operation time required for decoding in the experiment also increases accordingly. The frame error rate of the unmarked part in the figure is already lower than 10 . When τ = 5, b ρ = 64, σ = 32, θ = 24, N = (1360, 800), at this time the code rate is R = 0.6, E -3 . When τ = 8, ρ = 64, σ = 32, θ = 24, N = (1360, 8192), at this time the code rate is R = 0.627836, E b / N0(dB) ≥ 4.0 when FER ≤ 10 -3 . When τ = 5, ρ = 64, σ = 32, θ = 24, N = (96, 24), at this time the code rate is R = 0.25, E b / N0(dB) ≥ 1.0 when FER ≤ 10 -5 .
[0284] Comparing this embodiment with Polar Fast-SSC, the experimental code rate is 0.5. This embodiment adopts and τ = 5, ρ = 64, σ = 32, θ = 24, N = (320, 160); the code length of Polar Fast-SSC is N = (256, 128), and the experimental results are as Figure 13 shown.
[0285] Referring to Figure 14, an embodiment of the present invention further provides a channel coding system based on a weighted probability model, including a sending - end data acquisition module 1001, a sending - end source processing module 1002, a sending - end weighted probability algorithm coding module 1003, a channel transmission module 1004, a receiving - end decoding module 1005, a receiving - end forward error correction module 1006, and a receiving - end inverse source processing module 1007, where:
[0286] The sending - end data acquisition module 1001 is used to acquire first source sequence data.
[0287] The sending - end source processing module 1002 is used to perform source processing on the first source sequence data to obtain second source sequence data.
[0288] The sending - end weighted probability algorithm coding module 1003 is used to encode the second source sequence data through a weighted probability algorithm to obtain compressed data corresponding to the second source sequence data.
[0289] The channel transmission module 1004 is used to transmit the compressed data to the receiving end.
[0290] The receiving - end decoding module 1005 is used to decode the compressed data to obtain third source sequence data.
[0291] The receiving - end forward error correction module 1006 is used to perform forward error correction on the third source sequence data to obtain fourth source sequence data.
[0292] The receiving - end inverse source processing module 1007 is used to perform inverse source processing on the fourth source sequence data to obtain lossless transmission data corresponding to the first source sequence data.
[0293] It should be noted that since the channel coding system based on a weighted probability model in this embodiment and the above - mentioned channel coding method based on a weighted probability model are based on the same inventive concept, the corresponding content in the method embodiment also applies to this device embodiment and will not be elaborated here.
[0294] Reference Figure 15 , another embodiment of the present invention further provides an electronic device. The electronic device 6000 can be any type of intelligent terminal, such as a mobile phone, a tablet computer, a personal computer, etc.
[0295] Specifically, the electronic device 6000 includes: one or more control processors 6001 and a memory 6002. Figure 15 Taking one control processor 6001 and one memory 6002 as an example, the control processor 6001 and the memory 6002 can be connected through a bus or other means. Figure 15 Taking the connection through a bus as an example.
[0296] The memory 6002, as a non-transitory computer-readable storage medium, can be used to store non-transitory software programs, non-transitory computer-executable programs, and modules, such as program instructions / modules corresponding to an electronic device in an embodiment of the present invention;
[0297] The control processor 6001 executes various functional applications and data processing of a channel coding method based on a weighted probability model by running the non-transitory software programs, instructions, and modules stored in the memory 6002, that is, implements a channel coding method based on a weighted probability model in the above method embodiment.
[0298] The memory 6002 may include a program storage area and a data storage area. Among them, the program storage area can store an operating system and application programs required for at least one function; the data storage area can store data created by using a channel coding method based on a weighted probability model, etc. In addition, the memory 6002 may include high-speed random access memory, and may also include non-transitory memory, such as at least one magnetic disk storage device, a flash memory device, or other non-transitory solid-state storage devices. In some embodiments, the memory 6002 optionally includes a memory remotely set relative to the control processor 6001, and these remote memories can be connected to the electronic device 6000 through a network. Examples of the above network include but are not limited to the Internet, an enterprise intranet, a local area network, a mobile communication network, and combinations thereof.
[0299] When one or more modules are stored in the memory 6002 and executed by the one or more control processors 6001, a channel coding method based on a weighted probability model in the above method embodiment is executed, for example, execute the Figures 1 to 7 method steps described above.
[0300] The memory, as a non-transitory computer-readable storage medium, can be used to store non-transitory software programs and non-transitory computer-executable programs. In addition, the memory may include high-speed random access memory, and may also include non-transitory memory, such as at least one magnetic disk storage device, a flash memory device, or other non-transitory solid-state storage devices. In some embodiments, the memory optionally includes a memory remotely set relative to the processor, and these remote memories can be connected to the processor through a network. Examples of the above network include but are not limited to the Internet, an enterprise intranet, a local area network, a mobile communication network, and combinations thereof.
[0301] It should be noted that since an electronic device in this embodiment and the above channel coding method based on a weighted probability model are based on the same inventive concept, the corresponding content in the method embodiment also applies to the device embodiment of the present invention, and will not be elaborated here.
[0302] An embodiment of the present invention further provides a computer-readable storage medium storing computer-executable instructions for executing the channel coding method based on the weighted probability model as described in the above embodiments.
[0303] It should be noted that since a computer-readable storage medium in this embodiment and the above-mentioned channel coding method based on the weighted probability model are based on the same inventive concept, the corresponding content in the method embodiment also applies to this apparatus embodiment and will not be elaborated here.
[0304] Those of ordinary skill in the art can understand that all or some of the steps and systems in the methods disclosed above can be implemented as software, firmware, hardware, and their appropriate combinations. Some physical components or all physical components can be implemented as software executed by a processor, such as a central processing unit, a digital signal processor, or a microprocessor, or as hardware, or as an integrated circuit, such as an application-specific integrated circuit. Such software can be distributed on a computer-readable medium, which can include a computer storage medium (or a non-transitory medium) and a communication medium (or a transitory medium). As is well known to those of ordinary skill in the art, the term computer storage medium includes volatile and non-volatile, removable and non-removable media implemented in any method or technology for storing data, such as computer-readable instructions, data structures, program modules, or other data. Computer storage media includes, but is not limited to, RAM, ROM, EEPROM, flash memory, or other memory technologies, CD-ROM, digital versatile disk (DVD), or other optical disk storage, magnetic cassettes, tapes, magnetic disk storage, or other magnetic storage devices, or any other medium that can be used to store the desired data and can be accessed by a computer. In addition, as is well known to those of ordinary skill in the art, a communication medium generally includes computer-readable instructions, data structures, program modules, or other data in a modulated data signal such as a carrier wave or other transmission mechanism, and can include any data delivery medium.
[0305] In the description of this specification, the descriptions referring to the terms "one embodiment", "some embodiments", "illustrative embodiments", "examples", "specific examples", or "some examples", etc. mean that the specific features, structures, materials, or characteristics described in connection with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials, or characteristics described can be combined in any one or more embodiments or examples in a suitable manner.
[0306] Although embodiments of the present invention have been shown and described, those of ordinary skill in the art can understand that various changes, modifications, substitutions, and variations can be made to these embodiments without departing from the principles and spirit of the present invention. The scope of the present invention is defined by the claims and their equivalents.
Claims
1. A channel coding method based on a weighted probability model, characterized in that, The channel coding method based on the weighted probability model includes: Obtain the first source sequence data; Perform source processing on the first source sequence data to obtain the second source sequence data; Encode the second source sequence data through a weighted probability algorithm to obtain the compressed data corresponding to the second source sequence data; Transmit the compressed data to the receiving end; Decode the compressed data to obtain the third source sequence data; Perform forward error correction on the third source sequence data to obtain the fourth source sequence data; Perform inverse source processing on the fourth source sequence data to obtain the lossless transmission data corresponding to the first source sequence data.
2. The channel coding method based on the weighted probability model according to claim 1, wherein The performing source processing on the first source sequence data to obtain the second source sequence data includes: Perform source processing on the first source sequence data through a preset symbol replacement method to obtain the second source sequence data; Formulate corresponding data check conditions through the symbol replacement method; the data check conditions are used for forward error correction of the third source sequence data.
3. The channel coding method based on a weighted probability model according to claim 1, wherein The encoding the second source sequence data through a weighted probability algorithm to obtain the compressed data corresponding to the second source sequence data includes: Initialize the real number operation variable and the loop control variable of the weighted probability algorithm encoding; Obtain the first symbol of the second source sequence data, encode the first symbol through the weighted probability algorithm to obtain the second symbol. If the first sequence number of the first symbol is less than the loop control variable, add 1 to the first sequence number to obtain the second sequence number, and encode the third symbol corresponding to the second sequence number through the weighted probability algorithm to obtain the fourth symbol until the Nth sequence number is greater than or equal to the loop control variable to obtain the compressed data; where N represents a positive integer, and the calculation formula of the weighted probability algorithm includes: where both R and L represent real arithmetic variables, and i represents the sequence number, represents the weighted probability mass function, and F() represents the weighted cumulative distribution function.
4. The channel coding method based on the weighted probability model according to claim 2, wherein The performing forward error correction on the third source sequence data to obtain the fourth source sequence data includes: Perform linear error detection decoding on the third source sequence data according to the data check conditions to obtain the decoding error position and the bit error sequence number; Perform forward error correction decoding based on bit flipping through the decoding error position and the bit error sequence number to obtain the fourth source sequence data.
5. The channel coding method based on the weighted probability model according to claim 1, wherein After the performing inverse source processing on the fourth source sequence data to obtain the lossless transmission data corresponding to the first source sequence data, the channel coding method based on the weighted probability model further includes: Calculate the coding information entropy, coding rate, and average decoding error probability corresponding to the weighted probability algorithm; Perform channel capacity reachability analysis according to the coding information entropy, the coding rate, and the average decoding error probability to obtain the channel capacity analysis result.
6. The channel coding method based on a weighted probability model according to claim 4, wherein The performing forward error correction decoding based on bit flipping through the decoding error position and the bit error sequence number to obtain the fourth source sequence data includes: Divide the decoding error position and the bit error sequence number through different signal-to-noise ratios to obtain multiple forward error correction batches; Independently perform forward error correction decoding based on bit flipping on each forward error correction batch to obtain the fourth source sequence data.
7. The channel coding method based on the weighted probability model according to claim 6, wherein The forward error correction decoding based on bit flipping includes: Obtain quality control parameters; Set the error correction range according to the decoding error positions; Perform cyclic bit flipping on all the decoding error positions according to the bit error sequence numbers, and control the end of bit flipping for each decoding error position through the quality control parameters and the error correction range until the bit error sequence number reaches the threshold, and then end the loop.
8. A channel coding system based on a weighted probability model, characterized in that, The channel coding system based on the weighted probability model includes: A sending-end data acquisition module, configured to acquire first source sequence data; A sending-end source processing module, configured to perform source processing on the first source sequence data to obtain second source sequence data; A sending-end weighted probability algorithm coding module, configured to code the second source sequence data through a weighted probability algorithm to obtain compressed data corresponding to the second source sequence data; A channel transmission module, configured to transmit the compressed data to a receiving end; A receiving-end decoding module, configured to decode the compressed data to obtain third source sequence data; A receiving-end forward error correction module, configured to perform forward error correction on the third source sequence data to obtain fourth source sequence data; A receiving-end inverse source processing module, configured to perform inverse source processing on the fourth source sequence data to obtain lossless transmission data corresponding to the first source sequence data.
9. An electronic device, characterized in that: Comprising at least one control processor and a memory for communicatively connecting with the at least one control processor; the memory stores instructions executable by the at least one control processor, and the instructions are executed by the at least one control processor to enable the at least one control processor to execute the channel coding method based on the weighted probability model according to any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-executable instructions for causing a computer to execute the channel coding method based on the weighted probability model according to any one of claims 1 to 7.