Non-binary sequence coding method and device, storage medium and program product
By using convolutional coding methods for non-binary data sequences, and generating original sequence codes through partitioning and encoding subsets, the problems of low sequencing accuracy and high error correction complexity in high-throughput sequencing are solved, achieving efficient error detection and correction.
Patent Information
- Application Number
- CN202411040150.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-31
- Publication Date
- 2026-02-03
AI Technical Summary
In high-throughput sequencing, the accuracy of sequencing results is low and the error correction is complex, mainly due to the difficulty in detecting and correcting errors caused by channel noise.
The convolutional coding method for non-binary data sequences is adopted. By dividing the non-binary data sequence to be encoded into several subsets, traversing them one by one and calculating the number of symbols in each subset, configuring the corresponding coding type and information content, the original sequence code is generated, and the complexity of error detection and correction is reduced by direct product coding.
This improved the accuracy of sequencing results, reduced the complexity of error detection and correction, and enabled efficient coding in high-throughput sequencing.
Smart Images

Figure CN121462005A_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of wireless communication technology, and in particular to a method, apparatus, storage medium, and program product for encoding non-binary sequences. Background Technology
[0002] Convolutional codes are one of the two basic methods of error correction coding. They are characterized by using more than one bit of information in the source sequence for computation and then outputting the result as a code. Thus, they can construct an efficient coding method by utilizing the relationship between the same source at different time points or different sources.
[0003] High-throughput sequencing can be viewed as a coding process, with the DNA sequence as its source and the sequencing result as its output. The entire process of sample preparation and sequencing can be understood as a channel. Noise in the channel causes the final sequencing result to differ from the source, making it more difficult to detect or correct errors in the sequencing result, resulting in a lower accuracy of the sequencing result. Summary of the Invention
[0004] In view of this, embodiments of the present disclosure provide a method, apparatus, storage medium, and program product for encoding non-binary sequences, which can realize a convolutional code encoding method for high-throughput sequencing. The convolutional code encoding method for non-binary data sequences can be used to encode sequences composed of different symbol systems, thereby reducing the complexity of detecting or correcting errors in sequencing results and improving the accuracy of sequencing results.
[0005] In a first aspect, embodiments of this disclosure provide an encoding method for non-binary sequences, employing the following technical solution:
[0006] YY+242126P
[0007] Obtain the non-binary data sequence to be encoded;
[0008] The complete set of symbols contained in the non-binary data sequence to be encoded is divided into several subsets to obtain the target sequence;
[0009] Starting from the beginning of the target sequence, traverse the symbols corresponding to each subset one by one;
[0010] Based on the symbol type corresponding to the symbols in each subset, the number of symbols in each subset is calculated;
[0011] Encode the symbols in each subset sequentially until the end of the target sequence, thus obtaining the original sequence encoding of the non-binary data sequence.
[0012] In some embodiments, the number of symbols in each subset is calculated based on the symbol type of the symbols corresponding to each subset, including:
[0013] The symbol type of the symbol is incremented by the preset symbol type stored in the register;
[0014] When the symbol type of the symbol is the same as the preset symbol type stored in the register, the number of preset symbols stored in the register is incremented by 1.
[0015] When the symbol type of the symbol is different from the preset symbol type stored in the register, the number of preset symbols stored in the register is set to 1, and the preset symbol type is modified to the symbol type.
[0016] In some embodiments, the method further includes:
[0017] The symbol type output after the increment operation is XORed with the preset symbol type stored in the register;
[0018] When the symbol type output by the increment operation is the same as the preset symbol type stored in the register, the symbol type and the number of symbols output by the increment operation are stored in the register.
[0019] When the symbol type output by the increment operation is different from the preset symbol type stored in the register, the preset symbol type and preset symbol number stored in the register are output, and then the symbol type and symbol data output by the increment operation are stored in the register.
[0020] In some embodiments, encoding is performed sequentially according to the number of symbols in each subset until the end position of the target sequence, thereby obtaining the original sequence encoding of the non-binary data sequence, including:
[0021] Obtain the cardinality of the complete set of symbols and the cardinality of the target subset among the plurality of subsets; wherein, the cardinality of the complete set of symbols represents the number of elements in the complete set of symbols, the cardinality of the plurality of subsets represents the number of elements in the plurality of subsets, and the cardinality of the target subset is the smallest among the plurality of subsets;
[0022] The original sequence encoding is represented by a tuple consisting of the cardinality of the entire symbol set and the cardinality of the target subset;
[0023] Based on the encoding type of the original sequence encoding, the information content of a corresponding unit length is configured for the original sequence encoding.
[0024] In some embodiments, based on the encoding type of the original sequence encoding, the information content per unit length is configured for the original sequence encoding, including:
[0025] When the encoding types of the original sequence codes are different, different information units of length are configured for each of the original sequence codes of different encoding types;
[0026] When the encoding types of the original sequence codes are the same and the cardinality of the subsets are different, different unit lengths of information are configured for the odd and even bits of the original sequence codes respectively.
[0027] In some embodiments, the method further includes:
[0028] The original sequences are encoded into a direct product code;
[0029] When each symbol in each subset corresponding to the original sequence encoding can be represented by an intersection, union, or difference operation of a finite number of codewords, the direct product encoding is determined to be a uniquely decodable code.
[0030] When any symbol in any subset corresponding to the original sequence encoding cannot be represented by the intersection, union, or difference operations of a finite number of codewords, the direct product encoding is determined to be a non-unique decodable code.
[0031] Wherein, the uniquely decodable code corresponds to a unique original signal source information; the non-uniquely decodable code corresponds to multiple different original signal source information.
[0032] In some embodiments, the method further includes:
[0033] Obtain the number of sign transitions or register clears for each of the original sequence codes that make up the direct product code;
[0034] Based on the number of symbol transitions or the number of register clears, additional information is configured for the direct product code to obtain information redundancy of the direct product code; wherein, the additional information is positively correlated with the number of symbol transitions, and negatively correlated with the number of register clears.
[0035] Calculate the total information content of the direct product encoding based on the information redundancy of the direct product encoding;
[0036] When the total information content of the direct product encoding is greater than or equal to the original information content of the original sequence encoding, the first combination in the encoding space that can be uniquely translated into a signal sequence is determined as a codeword, and the second combination in the encoding space that cannot be translated into any kind of signal sequence is determined as a non-codeword.
[0037] Secondly, this disclosure also provides an encoding device for non-binary sequences, employing the following technical solution:
[0038] The acquisition unit is configured to acquire a sequence of non-binary data to be encoded.
[0039] The partitioning unit is configured to divide the complete set of symbols contained in the non-binary data sequence to be encoded into several subsets to obtain the target sequence;
[0040] The traversal unit is configured to start from the beginning of the target sequence and traverse the symbols corresponding to each subset one by one;
[0041] The calculation unit is configured to calculate the number of symbols in each subset based on the symbol type of the symbols corresponding to each subset;
[0042] The encoding unit is configured to encode sequentially according to the number of symbols in each subset until the end position of the target sequence, thereby obtaining the original sequence encoding of the non-binary data sequence.
[0043] Thirdly, this disclosure also provides a computer device, which adopts the following technical solution:
[0044] The computer device includes:
[0045] At least one processor; and,
[0046] A memory communicatively connected to the at least one processor; wherein,
[0047] The memory stores instructions executable by the at least one processor, which, when executed by the at least one processor, enable the at least one processor to perform YY+242126P.
[0048] The encoding method for any of the above-mentioned non-binary sequences.
[0049] Fourthly, embodiments of this disclosure also provide a computer-readable storage medium storing computer instructions for causing a computer to execute any of the above-described encoding methods for non-binary sequences.
[0050] Fifthly, embodiments of this disclosure also provide a computer program product, including a computer program / instructions that, when executed by a processor, implement the steps of any of the methods described above.
[0051] This disclosure provides a non-binary sequence encoding method that enables high-throughput sequencing convolutional code encoding. By using convolutional code encoding of non-binary data sequences, sequences composed of different symbol systems can be encoded, thereby reducing the complexity of detecting or correcting errors in sequencing results and improving the accuracy of sequencing results.
[0052] The above description is merely an overview of the technical solution disclosed herein. In order to better understand the technical means of this disclosure and to implement it in accordance with the contents of the specification, and to make the above and other objects, features and advantages of this disclosure more apparent and understandable, preferred embodiments are described below in detail with reference to the accompanying drawings. Attached Figure Description
[0053] To more clearly illustrate the technical solutions of the embodiments of this disclosure, the drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this disclosure. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0054] Figure 1 A flowchart illustrating a non-binary sequence encoding method provided in this embodiment of the disclosure;
[0055] Figure 2 A schematic diagram of the register structure provided in the embodiments of this disclosure;
[0056] Figure 3 This is a schematic diagram of the encoder state provided in an embodiment of the present disclosure;
[0057] Figure 4 A schematic diagram illustrating the number of sign transitions in a direct product encoding provided in this embodiment of the present disclosure;
[0058] Figure 5 A schematic diagram illustrating the number of sign transitions for another direct product encoding provided in this embodiment of the disclosure;
[0059] Figure 6 A schematic diagram of the structure of an encoding device for a non-binary sequence provided in an embodiment of this disclosure;
[0060] Figure 7 This is a schematic diagram of the structure of a computer device provided in an embodiment of the present disclosure. Detailed Implementation
[0061] The embodiments of this disclosure will now be described in detail with reference to the accompanying drawings.
[0062] It should be understood that the following specific examples illustrate the implementation of this disclosure, and those skilled in the art can easily understand other advantages and effects of this disclosure from the content disclosed in this specification. Obviously, the described embodiments are only a part of the embodiments of this disclosure, and not all of them. This disclosure can also be implemented or applied through other different specific implementation methods, and the details in this specification can also be modified or changed based on different viewpoints and applications without departing from the spirit of this disclosure. It should be noted that, in the absence of conflict, the following embodiments and features in the embodiments can be combined with each other. Based on the embodiments in this disclosure, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this disclosure.
[0063] It should be noted that various aspects of embodiments within the scope of the appended claims are described below. It will be apparent that the aspects described herein can be embodied in a wide variety of forms, and any particular structure and / or function described herein is merely illustrative. Based on this disclosure, those skilled in the art will understand that one aspect described herein can be implemented independently of any other aspect, and two or more of these aspects can be combined in various ways. For example, any number of aspects set forth herein can be used to implement the device and / or practice the method. Additionally, this device and / or method can be implemented using structures and / or functionalities other than one or more of the aspects set forth herein.
[0064] It should also be noted that the illustrations provided in the following embodiments are only schematic representations of the basic concept of this disclosure. The drawings only show the components related to this disclosure and are not drawn according to the number, shape and size of the components in actual implementation. In actual implementation, the form, quantity and proportion of each component can be arbitrarily changed, and the layout of the components may also be more complex.
[0065] Furthermore, specific details are provided in the following description to facilitate a thorough understanding of the examples. However, those skilled in the art will understand that the described aspects can be practiced without these specific details.
[0066] Figure 1 This is a flowchart illustrating a non-binary sequence encoding method provided in an embodiment of the present disclosure. The non-binary sequence encoding method provided in this embodiment includes the following steps:
[0067] S101. Obtain the non-binary data sequence to be encoded.
[0068] The sequence of non-binary data to be encoded can be understood as a collection of non-binary data to be encoded.
[0069] S102. Divide the complete set of symbols contained in the non-binary data sequence to be encoded into several subsets to obtain the target sequence.
[0070] For example, the resulting subsets are α, β, and γ, and the target sequence is constructed using the subsets α, β, and γ.
[0071] Optionally, different methods of partitioning the entire symbol set will result in different subsets, and the original sequence encoding of the final non-binary data sequence will also be different.
[0072] It should be noted that users can divide the symbol set according to actual business needs based on the complete set of symbols contained in the non-binary data sequence to be encoded and the distribution of symbols in the complete set of symbols. The comparison of the embodiments disclosed herein is not limited.
[0073] S103. Starting from the beginning position of the target sequence, traverse the symbols corresponding to each subset one by one.
[0074] For example, starting with the first symbol of the target sequence, iterate through all symbols belonging to subset α until one symbol does not belong to subset α. Record the number of symbols currently belonging to subset α as the first bit of the code. Starting with the first symbol not belonging to subset α, iterate through all symbols belonging to subset β until one symbol does not belong to subset β. Record the number of symbols currently belonging to subset β as the second bit of the code. Starting with the first symbol not belonging to subset γ, iterate through all symbols belonging to subset γ until one symbol does not belong to subset γ. Record the number of symbols currently belonging to subset γ as the third bit of the code.
[0075] S104. Based on the symbol type corresponding to the symbols in each subset, calculate the number of symbols in each subset.
[0076] For example, in this embodiment of the disclosure, the entire set of symbols (including 2α, 5β, 3α, 6β, etc.) is divided into several subsets α, β and γ, where the symbols corresponding to the subsets are 2, 5, 3, 6, etc. For example, the number of symbols in subset α refers to the total number of subsets α in the entire set of symbols. In this embodiment, the number of symbols in subset α is 5.
[0077] S105. Encode the symbols in each subset sequentially until the end of the target sequence, and then end the traversal to obtain the original sequence encoding of the non-binary data sequence.
[0078] For example, the symbols corresponding to subsets α, β, and γ are traversed one by one until all subsets of the symbol set are traversed, and the number of symbols belonging to subsets α, β, and γ is encoded. When the target sequence ends, the original sequence encoding of the non-binary data sequence is obtained.
[0079] Optionally, the first bit of the obtained original sequence code can be 0, and the other bits of the original sequence code are positive integers.
[0080] This disclosure provides a non-binary sequence encoding method that enables high-throughput sequencing convolutional code encoding. By using convolutional code encoding of non-binary data sequences, sequences composed of different symbol systems can be encoded, thereby reducing the complexity of detecting or correcting errors in sequencing results and improving the accuracy of sequencing results.
[0081] In some embodiments, the number of symbols in each subset is calculated based on the symbol type of the symbols corresponding to each subset, including:
[0082] The symbol type is incremented by the preset symbol type stored in the register;
[0083] When the symbol type of a symbol is the same as the preset symbol type stored in the register, the number of preset symbols stored in the register is incremented by 1.
[0084] When the symbol type of a symbol is different from the preset symbol type stored in the register, the number of preset symbols stored in the register is set to 1, and the preset symbol type is modified to the symbol type.
[0085] like Figure 2 As shown, Figure 2 The diagram below shows the structure of a register provided in an embodiment of this disclosure. In this embodiment, the register stores a preset symbol type (0 or 1) and a preset number of symbols (a non-negative integer). Users can set the preset number of symbols according to actual business needs, and this embodiment does not limit this setting.
[0086] In some embodiments, the method further includes:
[0087] Perform an XOR operation between the sign type output after the increment operation and the preset sign type stored in the register;
[0088] When the symbol type output by the increment operation is the same as the preset symbol type stored in the register, the symbol type and the number of symbols output by the increment operation are stored in the register.
[0089] When the symbol type output by the increment operation is different from the preset symbol type stored in the register, the preset symbol type and preset number of symbols stored in the register are output, and then the symbol type and symbol data output by the increment operation are stored in the register.
[0090] like Figure 3 As shown, Figure 3This is a schematic diagram of the encoder state provided in an embodiment of the present disclosure. In this embodiment, the original sequence encoding of the output non-binary data sequence is related to the state over a historical period of indefinite time. It can be understood that the original sequence encoding output in this embodiment is a recursive convolutional code. Furthermore, the output original sequence encoding is different from the original input type. Therefore, it can be understood that the original sequence encoding output in this embodiment is a non-systematic encoding.
[0091] In some embodiments, encoding is performed sequentially according to the number of symbols in each subset until the end position of the target sequence, thus obtaining the original sequence encoding of the non-binary data sequence, including:
[0092] Obtain the cardinality of the entire symbol set and the cardinality of the target subset among several subsets; where the cardinality of the entire symbol set represents the number of elements in the entire symbol set, the cardinality of several subsets represents the number of elements in several subsets, and the cardinality of the target subset is the smallest among several subsets.
[0093] The original sequence is encoded using a tuple composed of the cardinality of the entire symbol set and the cardinality of the target subset;
[0094] Based on the encoding type of the original sequence encoding, the corresponding unit length of information is configured for the original sequence encoding.
[0095] As shown in Table 1, Table 1 is a schematic diagram of the original sequence encoding provided in the embodiments of this disclosure. The original sequence encoding (3,1) indicates that the complete set of symbols contains a total of three symbols, one subset contains one symbol, and the other subset contains two symbols. The subset containing one symbol is the target subset. When the cardinality of the two subsets is equal, different permutations of the subsets do not provide substantial additional information, and the two subsets are encoded into the same original sequence encoding. For example, the original sequence encoding (4,2) in Table 1 corresponds to the three seed sets (AB,CD), (AC,BD), and (AD,BC).
[0096] Table 1. Schematic diagram of the original sequence encoding
[0097]
[0098]
[0099] As shown in Table 2, Table 2 is a schematic diagram of the information content configuration of the original sequence encoding provided in the embodiments of this disclosure. In this embodiment, the unit of information content is bits. Each original sequence encoding with different encoding types contains information content of different unit lengths. In the original sequence encoding of the same encoding type, if the cardinality of the two subsets corresponding to the original sequence encoding is different, then the odd-numbered bits and even-numbered bits of the original sequence encoding are configured with information content of different unit lengths respectively.
[0100] Table 2. Schematic diagram of information content configuration for original sequence encoding
[0101]
[0102]
[0103] In some embodiments, based on the encoding type of the original sequence encoding, the information content per unit length is configured for the original sequence encoding, including:
[0104] When the encoding types of the original sequences are different, different information units of length are configured for each original sequence encoding of different encoding types;
[0105] When the encoding types of the original sequences are the same and the cardinality of several subsets are different, different unit lengths of information are allocated to the odd and even bits of the original sequence encoding.
[0106] In some embodiments, the method further includes:
[0107] Multiple original sequences are encoded into a direct product code;
[0108] When each symbol in each subset corresponding to the original sequence encoding can be represented by an intersection, union, or difference operation of a finite number of codewords, the direct product encoding is determined to be a uniquely decodable code.
[0109] When any symbol in any subset corresponding to the original sequence encoding cannot be represented by the intersection, union, or difference operations of a finite number of codewords, the direct product encoding is determined to be a non-unique decodable code.
[0110] Among them, a uniquely decodable code corresponds to a unique original signal source information; a non-uniquely decodable code corresponds to multiple different original signal source information.
[0111] Optionally, embodiments of this disclosure can encode data into various non-binary, non-systematic recursive convolutional codes. These non-binary, non-systematic recursive convolutional codes, forming direct product codes, and the information they carry can be used to reconstruct the original signal source information. By selecting an efficient encoding method, lossy or lossless data compression can be achieved. Depending on the selected direct product code, the symbols or combinations of symbols in the original signal source information may be separable or inseparable. Any direct product code that guarantees the separability of all symbols in the original signal source information can also guarantee the lossless nature of the direct product code.
[0112] Provided that it does not cause encoding ambiguity, the simplest description of the symbol classification set can be chosen. For example, {'a','e','ae','ea'} and {'a','e'} are the same symbol classification set, but the former is not the simplest description.
[0113] Select a symbol classification set and construct a direct product code as follows to achieve lossless compression of the original signal source information within a finite computation time:
[0114] a) Initialize the upper limit of the length of the symbol combination;
[0115] b) Traverse all symbols in the original signal source information, and insert symbols into the empty set to form a symbol classification set. The complement of this set is used as another symbol classification set to maximize the length of the separable between sets.
[0116] c) Move new, separable elements into sets with fewer elements until the length of the separable elements in the set can no longer be increased.
[0117] d) Repeat steps b) and c) until the entire data length is divisible or the algorithm's preset upper limit is reached;
[0118] e) If other encodings exist, adjust the existing symbol classification pairs to maximize the length of conditionally separable pairs;
[0119] f) Record the unseparated parts of the current encoding and data, and repeat steps a), b), c), d), and e) until the entire data length can be separated;
[0120] g) For each code description, adjust its description to the simplest possible form;
[0121] h) Perform Burrows-Wheeler (Block-Ordered Compression, BWT) transformation on the description of each code and each code separately;
[0122] i) Use Huffman coding (a lossless compression coding algorithm commonly used for data file compression) to perform the final encoding on the transformed data classification code.
[0123] As shown in Table 3, which is a comparison diagram of non-uniquely decodable codes and uniquely decodable codes provided in the embodiments of this disclosure, since the amount of information per unit length is usually less than the amount of information per symbol, generally, multiple original sequence codes are needed to reconstruct all the information of the original signal source. A direct product code can be composed of multiple original sequence codes representing the same or different information. When each symbol in the alphabet can be represented as an intersection, union, or difference operation of a finite number of codewords, the direct product code is a uniquely decodable code; conversely, when any symbol in any subset corresponding to the original sequence code cannot be represented as an intersection, union, or difference operation of a finite number of codewords, the direct product code is determined to be a non-uniquely decodable code, meaning that the same set of original sequence codes may correspond to multiple different original signal source information.
[0124] Table 3. Comparison examples of non-uniquely decodable codes and uniquely decodable codes
[0125]
[0126]
[0127] In some embodiments, the method further includes:
[0128] Obtain the number of sign transitions or register clears for each original sequence encoding that makes up the direct product code;
[0129] Additional information is configured for direct product coding based on the number of symbol transitions or the number of register clears, resulting in information redundancy in direct product coding. The additional information is positively correlated with the number of symbol transitions and negatively correlated with the number of register clears.
[0130] Calculate the total information content of direct coding based on the information redundancy of direct product coding;
[0131] When the total information content of the direct product coding is greater than or equal to the original information content of the original sequence coding, the first combination in the coding space that can be uniquely translated into a signal sequence is determined as a codeword, and the second combination in the coding space that cannot be translated into any kind of signal sequence is determined as a non-codeword.
[0132] This disclosure embodiment assigns an invariant amount of information to each bit of the direct product code, depending on the type of the direct product code. Furthermore, each direct product code type carries additional information, as the type of the direct product code is known and provides information about the first letter of the sequence. Essentially, this disclosure embodiment re-encodes the original sequence code into a combination of two elements: letter type and length. The amount of information carried by each codeword is related to the type of its corresponding letter, but not to its length. A direct product code composed of a sufficiently large number of different original sequence codes can provide more information than the original sequence code.
[0133] The embodiments disclosed herein use direct product encoding (3,1) respectively. 2 And direct product encoding (4,2) 3 To illustrate the information redundancy of direct product coding, consider the following example: Figure 4 As shown, Figure 4 This diagram illustrates the number of sign transitions for a direct product encoding provided in an embodiment of this disclosure. The direct product encoding is (3,1). 2 It provides a total of log26 = 2.5850 bits of information. Any symbol transformation in the original sequence encoding may cause one or both of the two codes that make up the direct product code to perform a clear and transformation register operation (that is, generate a one-bit codeword). The more symbol transformations, the more additional information the direct product code can carry. For the same original sequence encoding, the number of symbol transformations will also be different depending on the arrangement of the symbols in the original sequence encoding.
[0134] like Figure 5 As shown, Figure 5 This diagram illustrates the number of sign transitions for another direct product encoding provided in this embodiment of the disclosure, where the direct product encoding is (4,2). 3 It provides a total of log26 = 2.5850 bits of information. Any symbol conversion in the original sequence encoding will cause two of the three codes that make up the direct product code to perform a clear and conversion register operation (that is, generate a one-bit codeword). The number of times the register is cleared is related to the number of symbol conversions, but not to the order of the symbols.
[0135] This disclosure uses the processing of DNA sequencing data as an example for illustration. Deoxyribonucleic acid (DNA) is the genetic material of the vast majority of life forms. DNA in organisms is usually chain-like, with its backbone composed of phosphate-deoxyribose molecules linked by 3',5'-phosphodiester bonds. The 2'-hydroxyl hydrogen of the ribose is replaced by a base, forming the internal structure of the chain. In many organisms, two DNA chains form a double helix structure through hydrogen bonds between nucleotides, enhancing their physicochemical stability. There are four bases that make up DNA: adenine, cytosine, guanine, and thymine. These bases are usually represented by their first letters. The chemical basis for DNA carrying genetic information is the sequence of bases; therefore, determining the DNA base sequence is crucial for interpreting the genetic information of organisms. The process of determining the DNA base sequence through physical or chemical methods is called DNA sequencing.
[0136] When the encoding method of this disclosure is applied to DNA sequencing, DNA, as an information carrier, is essentially a sequence composed of the alphabet ACGT. In the sequencing method of sequencing by synthesis, the above four bases are divided into two groups. Each combination of substrates corresponds to a corresponding signal, which is the non-binary non-systematic recursive convolution code described in this disclosure. By changing these combinations, different signals can be obtained, forming a direct product code.
[0137] The DNA to be tested is prepared as a single strand using a sequencing-by-synthesis encoder and placed into a reaction vessel. Annealed sequencing primers are prepared for use. Before each sequencing reaction, DNA synthase, reaction buffer, and the selected substrate combination are added to the vessel. Under appropriate reaction conditions, the reaction is initiated. If the base complementary to the first base at the 5' end of the single-stranded DNA to be tested is in the selected substrate combination, it will be ligated to the complementary strand of the DNA to be tested. This process is repeated until the next base is not in the selected substrate combination. The signal emitted by the synthesis reaction at this point is collected, which is one bit of the codeword. After signal collection, the reaction vessel is rinsed to remove the current substrate, and then the next set of substrates is added to initiate the next round of reaction. Because the type of substrate has changed, and the two combinations constitute a division of all bases, the reaction will continue. This process is repeated to obtain each bit of the codeword.
[0138] For example, sequencing a combination of two letters (bases) from the alphabet ACGT yields a (4,2) encoding; sequencing a combination of one letter (base) from the alphabet ACGT with the remaining three letters (bases) yields a (4,1) encoding. Arbitrary direct product encodings of DNA sequences result in (4,2) encodings. 2 Or (4,1) 3 They are all uniquely decodable.
[0139] Optionally, during DNA sequencing, impurities may be present in the reactants, the signals emitted by the physicochemical reactions are random, and errors may be introduced during signal acquisition and processing. The combined effect of these noises can cause the results of a single sequencing run to deviate from the true value. Utilizing the information redundancy provided by direct product coding can detect sequencing errors present during the coding process, reduce the complexity of detecting or correcting errors in the sequencing results, and improve the accuracy of the sequencing results.
[0140] like Figure 6 As shown, Figure 6 This is a schematic diagram of the structure of a non-binary sequence encoding device provided in an embodiment of the present disclosure. The non-binary sequence encoding device provided in an embodiment of the present disclosure includes:
[0141] Acquisition unit 61 is configured to acquire a non-binary data sequence to be encoded;
[0142] The partitioning unit 62 is configured to divide the complete set of symbols contained in the non-binary data sequence to be encoded into several subsets to obtain the target sequence;
[0143] Traversal unit 63 is configured to traverse each subset of symbols one by one, starting from the beginning of the target sequence.
[0144] Computation unit 64 is configured based on the symbol type of the symbol corresponding to each subset, YY+242126P
[0145] The number of symbols in each subset is calculated;
[0146] Encoding unit 65 is configured to encode sequentially according to the number of symbols in each subset until the end position of the target sequence is reached, thus obtaining the original sequence encoding of the non-binary data sequence.
[0147] A computer device according to an embodiment of this disclosure includes a memory and a processor. The memory is used to store non-transitory computer-readable instructions. Specifically, the memory may include one or more computer program products, which may include various forms of computer-readable storage media, such as volatile memory and / or non-volatile memory. The volatile memory may, for example, include random access memory (RAM) and / or cache memory. The non-volatile memory may, for example, include read-only memory (ROM), hard disk, flash memory, etc.
[0148] The processor may be a central processing unit (CPU) or other form of processing unit with data processing capabilities and / or instruction execution capabilities, and may control other components in the computer device to perform desired functions. In one embodiment of this disclosure, the processor is used to execute computer-readable instructions stored in the memory, causing the computer device to perform all or part of the steps of the encoding methods for non-binary sequences described in the foregoing embodiments of this disclosure.
[0149] Those skilled in the art will understand that, in order to solve the technical problem of how to achieve a good user experience, this embodiment may also include well-known structures such as communication buses and interfaces, and these well-known structures should also be included within the protection scope of this disclosure.
[0150] like Figure 7 This is a schematic diagram of a computer device provided for an embodiment of the present disclosure. It illustrates a structural schematic diagram suitable for implementing the computer device in the embodiments of the present disclosure. Figure 7 The computer device shown is merely an example and should not be taken as a general description of the functionality and operation of the embodiments described herein.
[0151] Use range to impose any limitations.
[0152] like Figure 7As shown, a computer device may include a processor (e.g., a central processing unit, a graphics processing unit, etc.), which can perform various appropriate actions and processes based on programs stored in read-only memory (ROM) or programs loaded from storage devices into random access memory (RAM). The RAM also stores various programs and data required for the operation of the computer device. The processor, ROM, and RAM are interconnected via a bus. Input / output (I / O) interfaces are also connected to the bus.
[0153] Typically, the following devices can be connected to the I / O interface: input devices, such as sensors or visual information acquisition devices; output devices, such as displays; storage devices, such as magnetic tapes or hard drives; and communication devices. Communication devices allow the computer device to communicate wirelessly or wiredly with other devices (such as edge computing devices) to exchange data. Although Figure 7 A computer apparatus with various devices is shown, but it should be understood that it is not required to implement or have all of the devices shown. More or fewer devices may be implemented or included alternatively.
[0154] In particular, according to embodiments of this disclosure, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments of this disclosure include a computer program product comprising a computer program carried on a non-transitory computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via a communication device, or installed from a storage device, or installed from a ROM. When the computer program is executed by a processor, all or part of the steps of the encoding method for non-binary sequences according to embodiments of this disclosure are performed.
[0155] For a detailed description of this embodiment, please refer to the corresponding descriptions in the foregoing embodiments, which will not be repeated here.
[0156] A computer-readable storage medium according to embodiments of the present disclosure stores non-transitory computer-readable instructions. When the non-transitory computer-readable instructions are executed by a processor, all or part of the steps of the encoding methods for non-binary sequences described in the foregoing embodiments of the present disclosure are performed.
[0157] The aforementioned computer-readable storage media include, but are not limited to: optical storage media (e.g., CD-ROM and DVD), magneto-optical storage media (e.g., MO), magnetic storage media (e.g., magnetic tape or portable hard drive), media with built-in rewritable non-volatile memory (e.g., memory card), and media with built-in ROM (e.g., ROM cartridge).
[0158] For a detailed description of this embodiment, please refer to the corresponding descriptions in the foregoing embodiments, which will not be repeated here.
[0159] The basic principles of this disclosure have been described above with reference to specific embodiments. However, it should be noted that the advantages, benefits, and effects mentioned in this disclosure are merely examples and not limitations, and should not be considered as essential features of each embodiment of this disclosure. Furthermore, the specific details disclosed above are for illustrative and facilitative purposes only, and are not limitations. These details do not limit the scope of this disclosure to the necessity of employing the aforementioned specific details for implementation.
[0160] In this disclosure, relational terms such as "first" and "second" are used merely to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. The block diagrams of devices, apparatuses, devices, and systems involved in this disclosure are merely illustrative examples and are not intended to require or imply that they must be connected, arranged, or configured in the manner shown in the block diagrams. As those skilled in the art will recognize, these devices, apparatuses, devices, and systems can be connected, arranged, and configured in any manner. Words such as "comprising," "including," "having," etc., are open-ended terms meaning "including but not limited to," and are used interchangeably with them. The terms "or" and "and" as used herein refer to the terms "and / or," and are used interchangeably with them unless the context clearly indicates otherwise. The term "such as" as used herein refers to the phrase "such as but not limited to," and is used interchangeably with it.
[0161] Additionally, as used herein, the “or” used in a list of items beginning with “at least one” indicates a separate list, such that a list of, for example, “at least one of A, B, or C” means A or B or C, or AB or AC or BC, or ABC (i.e., A and B and C). Furthermore, the word “exemplary” does not imply that the described example is preferred or better than other examples.
[0162] It should also be noted that in the systems and methods of this disclosure, the components or steps can be decomposed and / or recombined. These decompositions and / or recombinations should be considered as equivalent solutions to this disclosure.
[0163] Various changes, substitutions, and modifications can be made to the technology described herein without departing from the teachings defined by the appended claims. Furthermore, the scope of the claims of this disclosure is not limited to the specific aspects of the processes, machines, manufactures, events, means, methods, and actions described above. Currently existing or later-developed processes, machines, manufactures, events, means, methods, or actions that perform substantially the same function or achieve substantially the same result as the corresponding aspects described herein can be utilized. Therefore, the appended claims include such processes, machines, manufactures, events, means, methods, or actions within their scope.
[0164] YY+242126P
[0165] The above description of the disclosed aspects is provided to enable any person skilled in the art to make or use this disclosure. Various modifications to these aspects will be readily apparent to those skilled in the art, and the general principles defined herein may be applied to other aspects without departing from the scope of this disclosure. Therefore, this disclosure is not intended to be limited to the aspects shown herein, but rather to be carried out within the widest scope consistent with the principles and novel features disclosed herein.
[0166] The above description has been given for purposes of illustration and description. Furthermore, this description is not intended to limit the embodiments of this disclosure to the forms disclosed herein. Although numerous exemplary aspects and embodiments have been discussed above, those skilled in the art will recognize certain variations, modifications, alterations, additions, and sub-combinations therein.
Claims
1. A method for encoding non-binary sequences, characterized in that, include: Obtain the non-binary data sequence to be encoded; The complete set of symbols contained in the non-binary data sequence to be encoded is divided into several subsets to obtain the target sequence; Starting from the beginning of the target sequence, traverse the symbols corresponding to each subset one by one; Based on the symbol type of the symbols corresponding to each subset, the number of symbols in each subset is calculated; Encode the symbols in each subset sequentially until the end of the target sequence, thus obtaining the original sequence encoding of the non-binary data sequence.
2. The encoding method for non-binary sequences according to claim 1, characterized in that, Based on the symbol type of the symbols corresponding to each subset, the number of symbols in each subset is calculated, including: The symbol type of the symbol is incremented by the preset symbol type stored in the register; When the symbol type of the symbol is the same as the preset symbol type stored in the register, the number of preset symbols stored in the register is incremented by 1. When the symbol type of the symbol is different from the preset symbol type stored in the register, the number of preset symbols stored in the register is set to 1, and the preset symbol type is modified to the symbol type.
3. The encoding method for non-binary sequences according to claim 2, characterized in that, The method further includes: The symbol type output after the increment operation is XORed with the preset symbol type stored in the register; When the symbol type output by the increment operation is the same as the preset symbol type stored in the register, the symbol type and the number of symbols output by the increment operation are stored in the register. When the symbol type output by the increment operation is different from the preset symbol type stored in the register, the preset symbol type and preset symbol number stored in the register are output, and then the symbol type and symbol data output by the increment operation are stored in the register.
4. The encoding method for non-binary sequences according to claim 1, characterized in that, Encoding is performed sequentially based on the number of symbols in each subset until the end of the target sequence, at which point the traversal ends, yielding the original sequence encoding of the non-binary data sequence, including: Obtain the cardinality of the complete set of symbols and the cardinality of the target subset among the plurality of subsets; wherein, the cardinality of the complete set of symbols represents the number of elements in the complete set of symbols, the cardinality of the plurality of subsets represents the number of elements in the plurality of subsets, and the cardinality of the target subset is the smallest among the plurality of subsets; The original sequence encoding is represented by a tuple consisting of the cardinality of the entire symbol set and the cardinality of the target subset; Based on the encoding type of the original sequence encoding, configure phase YY+242126P for the original sequence encoding. The amount of information per unit length.
5. The encoding method for non-binary sequences according to claim 1, characterized in that, Based on the encoding type of the original sequence encoding, configure the information content of a corresponding unit length for the original sequence encoding, including: When the encoding types of the original sequence codes are different, different information units of length are configured for each of the original sequence codes of different encoding types; When the encoding types of the original sequence codes are the same and the cardinality of the subsets are different, different unit lengths of information are configured for the odd and even bits of the original sequence codes respectively.
6. The encoding method for non-binary sequences according to claim 5, characterized in that, The method further includes: The original sequences are encoded into a direct product code; When each symbol in each subset corresponding to the original sequence encoding can be represented by an intersection, union, or difference operation of a finite number of codewords, the direct product encoding is determined to be a uniquely decodable code. When any symbol in any subset corresponding to the original sequence encoding cannot be represented by the intersection, union, or difference operations of a finite number of codewords, the direct product encoding is determined to be a non-unique decodable code. Wherein, the uniquely decodable code corresponds to a unique original signal source information; the non-uniquely decodable code corresponds to multiple different original signal source information.
7. The encoding method for non-binary sequences according to claim 6, characterized in that, The method further includes: Obtain the number of sign transitions or register clears for each of the original sequence codes that make up the direct product code; Based on the number of symbol transitions or the number of register clears, additional information is configured for the direct product code to obtain information redundancy of the direct product code; wherein, the additional information is positively correlated with the number of symbol transitions, and negatively correlated with the number of register clears. Calculate the total information content of the direct product encoding based on the information redundancy of the direct product encoding; When the total information content of the direct product encoding is greater than or equal to the original information content of the original sequence encoding, the first combination in the encoding space that can be uniquely translated into a signal sequence is determined as a codeword, and the second combination in the encoding space that cannot be translated into any kind of signal sequence is determined as a non-codeword.
8. A computer device, characterized in that, The computer device includes: At least one processor; and, A memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor to enable the at least one processor to perform the encoding method of the non-binary sequence according to any one of claims 1 to 7.
9. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions for causing a computer to perform the encoding method of the non-binary sequence as described in any one of claims 1 to 7.
10. A computer program product comprising computer instructions, characterized in that, When executed by a processor, the computer instructions implement the steps of the encoding method for the non-binary sequence YY+242126P column as described in any one of claims 1 to 7.