Nucleic acid sequence determination method based on Bloom filter and electronic equipment

By constructing a Bloom filter to filter nucleic acid sequences and screen out false positive sequences, the accuracy problem of nucleic acid sequence determination in existing technologies is solved, and the target nucleic acid sequence can be read quickly and accurately from sequencing data.

CN121237217APending Publication Date: 2025-12-30SHENZHEN HUADA GENE INST
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410862975.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-28
Publication Date
2025-12-30

AI Technical Summary

Technical Problem

Existing technologies cannot accurately determine the required target nucleic acid sequence from massive amounts of nucleic acid data. The error detection and correction capabilities of check codes and error correction codes are limited, and clustering algorithms have high computational complexity, making them unsuitable for large-scale DNA storage.

Method used

A Bloom filter is used to construct a filter corresponding to the target nucleic acid sequence. The target nucleic acid sequence is stored through hash operation. The nucleic acid sequence is filtered based on the Bloom filter to screen out false positive sequences, thus achieving rapid and accurate determination of the target nucleic acid sequence.

Benefits of technology

This clustering algorithm, which eliminates the need for redundant error correction or time-consuming and memory-intensive processing, improves the efficiency and accuracy of target nucleic acid sequences from sequencing data. It achieves high efficiency and accuracy in extracting test nucleic acid sequences using Bloom filters, enabling rapid and accurate reading of all correct sequences from sequencing data. It also achieves high accuracy in extracting target nucleic acid sequences from sequencing data, measurement data, and measurement data.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121237217A_ABST
    Figure CN121237217A_ABST
Patent Text Reader

Abstract

The invention relates to the field of biological medicine, and provides a Bloom filter-based nucleic acid sequence determination method and electronic equipment, and the method comprises the following steps: constructing initial Bloom filters corresponding to a plurality of target nucleic acid sequences; storing the plurality of target nucleic acid sequences to the initial Bloom filter to obtain target filters corresponding to the plurality of target nucleic acid sequences; filtering non-target nucleic acid sequences in a plurality of nucleic acid sequences to be detected based on the target filter; and carrying out false positive detection on the to-be-detected nucleic acid sequence in the plurality of filtered to-be-detected nucleic acid sequences, determining a false positive sequence in the filtered to-be-detected nucleic acid sequences, and excluding the false positive sequence from the filtered to-be-detected nucleic acid sequences to obtain the target nucleic acid sequence. By utilizing the method, the efficiency and accuracy of determining the required target nucleic acid sequence from the sequencing data can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of biomedical technology, specifically to a method and electronic device for determining nucleic acid sequences based on a Bloom filter. Background Technology

[0002] In order to accurately retrieve the required target nucleic acid data from the stored data, related technologies usually add check codes and error correction codes when encoding and storing nucleic acid data. The retrieved data is then verified based on the check codes and error correction codes to determine whether the retrieved data is the required target nucleic acid data.

[0003] The methods described above heavily rely on the error detection capabilities of parity check codes and error-correcting codes. However, parity check codes can only detect whether errors have occurred in the nucleic acid sequence, and their error detection capability is limited; for example, parity check can only detect cases with an odd number of errors. Although error-correcting codes can correct errors in erroneous sequences, their error-correction capability is also limited, and for each nucleic acid sequence, the number of bases that can be corrected is related to the code distance of the error-correcting code. Therefore, these technologies cannot accurately determine the desired target nucleic acid sequence from massive amounts of nucleic acid data. Summary of the Invention

[0004] In view of the above, it is necessary to propose a nucleic acid sequence determination method and electronic device based on Bloom filter, which can solve the problem that related technologies cannot accurately determine the required target nucleic acid sequence from a large amount of nucleic acid data.

[0005] Embodiments of this application provide a method for determining nucleic acid sequences based on a Bloom filter. The method includes: constructing an initial Bloom filter corresponding to multiple target nucleic acid sequences; storing the multiple target nucleic acid sequences into the initial Bloom filter to obtain a target filter corresponding to the multiple target nucleic acid sequences; filtering non-target nucleic acid sequences in multiple test nucleic acid sequences based on the target filter; performing false positive detection on the test nucleic acid sequences in the filtered multiple test nucleic acid sequences to determine false positive sequences in the filtered test nucleic acid sequences, and excluding the false positive sequences from the filtered test nucleic acid sequences to obtain the target nucleic acid sequence.

[0006] In one embodiment, constructing an initial Bloom filter corresponding to multiple target nucleic acid sequences includes: calculating the array length and hash round number of the initial Bloom filter based on a preset false positive rate and the total number of sequences of the multiple target nucleic acid sequences, wherein the hash round number represents the number of hash functions corresponding to the initial Bloom filter; and constructing the initial Bloom filter based on the array length and the hash round number.

[0007] In one embodiment, the initial Bloom filter includes an array where all elements are first preset values. Storing the plurality of target nucleic acid sequences into the initial Bloom filter includes: storing each target nucleic acid sequence in the initial Bloom filter, which includes: determining a corresponding number of hash rounds based on the hash round number corresponding to the initial Bloom filter; performing a hash operation on the target nucleic acid sequence based on the determined number of hash rounds; and obtaining a target hash value for each hash operation; determining a target position in the array of the initial Bloom filter based on the target hash value for each hash operation; and updating the element in the initial Bloom filter located at the target position to a second preset value.

[0008] In one embodiment, performing each hash operation on the target nucleic acid sequence includes: converting each target data in the target nucleic acid sequence into a preset standard code value; and sequentially inputting the preset standard code value corresponding to each target data into the hash function of any number of hash operations according to the order of each target data in the target nucleic acid sequence, to obtain the target hash value of the hash operation corresponding to any number of hash operations.

[0009] In one embodiment, determining the target position in the array of the initial Bloom filter based on the target hash value of each hash operation includes: if the target hash value is less than or equal to the array length of the initial Bloom filter, determining the target position based on the target hash value; if the target hash value is greater than the array length of the initial Bloom filter, determining the target position based on the target hash value and the array length includes: determining the target position based on the remainder obtained by performing a modulo operation on the target hash value and the array length.

[0010] In one embodiment, a method for obtaining the plurality of nucleic acid sequences to be tested includes: synthesizing the plurality of target nucleic acid sequences to obtain a plurality of synthetic nucleic acid sequences; performing data amplification on the plurality of synthetic nucleic acid sequences based on polymerase chain reaction to obtain data-amplified nucleic acid sequences; and sequencing the data-amplified nucleic acid sequences to obtain the plurality of nucleic acid sequences to be tested.

[0011] In one embodiment, filtering non-target nucleic acid sequences among multiple test nucleic acid sequences based on the target filter includes: determining whether each test nucleic acid sequence among the multiple test nucleic acid sequences is a non-target nucleic acid sequence, including: determining the corresponding hash round number of the target filter; performing a hash operation on the test nucleic acid sequence a number of times corresponding to the hash round number to obtain the test hash value for each hash operation; determining the test position in the array of the target filter based on the test hash value for each hash operation; if the element at the test position in the target filter is a first preset value, determining that the test nucleic acid sequence is the non-target nucleic acid sequence.

[0012] In one embodiment, the step of performing false positive detection on the filtered multiple nucleic acid sequences to be tested and determining the false positive sequences in the filtered nucleic acid sequences to be tested includes: determining the coverage of each nucleic acid sequence to be tested in the filtered multiple nucleic acid sequences to be tested, and identifying nucleic acid sequences to be tested with a coverage less than a preset coverage threshold as the false positive sequences.

[0013] This application provides a method for determining nucleic acid sequences based on a Bloom filter. The method includes: constructing an initial counting Bloom filter corresponding to multiple target nucleic acid sequences of a preset version; storing the multiple target nucleic acid sequences of the preset version into the initial counting Bloom filter to obtain a target counting filter corresponding to the multiple target nucleic acid sequences of the preset version; filtering non-preset version target nucleic acid sequences among multiple test nucleic acid sequences based on the target counting filter; performing false positive detection on the filtered multiple test nucleic acid sequences, identifying false positive sequences among the filtered test nucleic acid sequences, and excluding the false positive sequences from the filtered test nucleic acid sequences to obtain the target nucleic acid sequence of the preset version.

[0014] In one embodiment, constructing an initial counting Bloom filter corresponding to multiple target nucleic acid sequences of a preset version includes: calculating the array length and hash round number of the initial counting Bloom filter based on a preset false positive rate and the total number of sequences of the multiple target nucleic acid sequences of the preset version, and constructing the initial counting Bloom filter based on the array length and hash round number.

[0015] In one embodiment, the initial counting Bloom filter includes an array where all elements are first preset values. Storing the multiple target nucleic acid sequences of the preset versions into the initial counting Bloom filter includes: storing each target nucleic acid sequence of the preset version into the initial counting Bloom filter, including: determining a corresponding number of hash rounds based on the hash round number corresponding to the initial counting Bloom filter; performing a hash operation on the target nucleic acid sequence of the preset version based on the determined number of hash rounds to obtain a target hash value for each hash operation; determining a target position in the array of the initial counting Bloom filter based on the target hash value for each hash operation; and updating the element at the target position in the initial counting Bloom filter, including: if the hash operation is the first hash operation, updating the element at the target position in the initial counting Bloom filter to a second preset value; if the hash operation is not the first hash operation, updating the element at the target position based on the sum of the element at the target position and the second preset value after the previous hash operation.

[0016] In one embodiment, the plurality of nucleic acid sequences to be tested includes multiple target nucleic acid sequences of different versions from the preset version. Filtering the non-preset version target nucleic acid sequences among the plurality of nucleic acid sequences to be tested based on the target counting filter includes: determining whether each nucleic acid sequence to be tested is a non-preset version target nucleic acid sequence, including: determining the corresponding number of hash rounds according to the number of hash rounds corresponding to the initial counting Bloom filter; performing a hash operation on the nucleic acid sequence to be tested according to the determined number of hash rounds to obtain the hash value to be tested for each hash operation; determining the position to be tested in the array of the target counting filter according to the hash value to be tested for each hash operation; if the element at the position to be tested in the target counting filter is a first preset value, determining that the nucleic acid sequence to be tested is the non-preset version target nucleic acid sequence.

[0017] In one embodiment, the step of performing false positive detection on the filtered plurality of nucleic acid sequences to be tested and determining the false positive sequences among the filtered nucleic acid sequences to be tested includes: based on the deletability of the target counting filter, performing a preset deletion operation on the target counting filter according to each nucleic acid sequence to be tested among the filtered plurality of nucleic acid sequences to be tested; determining the negative position corresponding to the negative value element of the array in the target counting filter after the preset deletion operation is performed; and determining the false positive sequences among the filtered plurality of nucleic acid sequences to be tested based on the negative position.

[0018] In one embodiment, the preset deletion operation includes: determining the test hash value of each test nucleic acid sequence in the filtered plurality of test nucleic acid sequences for each hash operation; determining the test position in the array of the target counting filter based on the test hash value of each hash operation; and updating the element at the test position based on the difference between the element at the test position and a second preset element.

[0019] In one embodiment, determining the false positive sequence among the filtered plurality of nucleic acid sequences to be tested based on the negative value position includes: determining the test hash value obtained by each test sequence in each hash operation among the filtered plurality of nucleic acid sequences to be tested, and the corresponding position of the test hash value in the array of the target counting filter; if the corresponding position of any test sequence among the filtered plurality of nucleic acid sequences to be tested is the negative value position, determining that any test sequence to be tested is the false positive sequence.

[0020] Embodiments of this application provide a nucleic acid sequence determination device based on a Bloom filter. The device includes: a filter construction module for constructing initial Bloom filters corresponding to multiple target nucleic acid sequences; a sequence storage module for storing the multiple target nucleic acid sequences into the initial Bloom filters to obtain target filters corresponding to the multiple target nucleic acid sequences; a sequence filtering module for filtering non-target nucleic acid sequences from multiple test nucleic acid sequences based on the target filters; and a false positive deletion module for performing false positive detection on the test nucleic acid sequences from the filtered multiple test nucleic acid sequences, identifying false positive sequences in the filtered test nucleic acid sequences, and excluding the false positive sequences from the filtered test nucleic acid sequences to obtain the target nucleic acid sequence.

[0021] An embodiment of this application provides an electronic device including a processor and a memory, wherein the processor is used to implement the nucleic acid sequence determination method based on a Bloom filter when executing a computer program stored in the memory.

[0022] Embodiments of this application provide a computer-readable storage medium storing a computer program that, when executed by a processor, implements the nucleic acid sequence determination method based on a Bloom filter.

[0023] In summary, the nucleic acid sequence determination method based on Bloom filters described in this application can rapidly and accurately extract all correct sequences from sequencing data containing both correct sequences (target nucleic acid sequences) and incorrect sequences (non-target nucleic acid sequences) by constructing filters corresponding to the target nucleic acid sequence. This application eliminates the need for adding extra redundancy to the nucleic acid sequence for sequence correction, or using time-consuming and memory-intensive clustering algorithms to cluster correct and incorrect sequences originating from each target nucleic acid sequence into one cluster, and then using error correction algorithms to correct the sequence for each cluster to obtain the correct sequence. This improves the efficiency and accuracy of determining the desired target nucleic acid sequence from sequencing data. Attached Figure Description

[0024] Figure 1 This is a structural diagram of an electronic device provided in an embodiment of this application.

[0025] Figure 2 This is a schematic diagram illustrating the principle of a nucleic acid sequence determination method based on a Bloom filter provided in an embodiment of this application.

[0026] Figure 3 This is a flowchart of a nucleic acid sequence determination method based on a Bloom filter provided in an embodiment of this application.

[0027] Figure 4 This is a schematic diagram illustrating the application principle of BF provided in an embodiment of this application.

[0028] Figure 5 This is an example diagram illustrating the effectiveness of the anti-fouling function based on a Bloom filter according to an embodiment of this application.

[0029] Figure 6 This is an example diagram illustrating the robustness of the anti-fouling function based on a Bloom filter according to an embodiment of this application.

[0030] Figure 7 This is a schematic diagram illustrating the principle of a nucleic acid sequence determination method based on a Bloom filter provided in another embodiment of this application.

[0031] Figure 8 This is a flowchart of a nucleic acid sequence determination method based on a Bloom filter provided in another embodiment of this application.

[0032] Figure 9 This is a schematic diagram illustrating the application principle of CBF provided in one embodiment of this application.

[0033] Figure 10 This is an example diagram illustrating the effectiveness of a counting Bloom filter in eliminating false positive sequences according to an embodiment of this application.

[0034] Figure 11This is a structural diagram of a nucleic acid sequence determination device based on a Bloom filter provided in an embodiment of this application. Detailed Implementation

[0035] To better understand the above-mentioned objectives, features, and advantages of this application, the application will be described in detail below with reference to the accompanying drawings and specific embodiments. It should be noted that, unless otherwise specified, the embodiments and features described herein can be combined with each other.

[0036] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used herein in the specification of this application is for the purpose of describing an embodiment in one instance only and is not intended to be limiting of the application.

[0037] It should be noted that in this application, "at least one" means one or more, and "more than one" means two or more. "And / or" describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A alone, A and B simultaneously, or B alone, where A and B can be singular or plural. The terms "first," "second," "third," "fourth," etc. (if present) in the specification, claims, and drawings of this application are used to distinguish similar objects, not to describe a specific order or sequence.

[0038] In the embodiments of this application, the terms "exemplary" or "for example" are used to indicate examples, illustrations, or descriptions. Any embodiment or design described as "exemplary" or "for example" in the embodiments of this application should not be construed as being more preferred or advantageous than other embodiments or design solutions. Specifically, the use of terms such as "exemplary" or "for example" is intended to present the relevant concepts in a specific manner. Unless otherwise specified, the following embodiments and features described herein can be combined with each other.

[0039] In one embodiment, in order to accurately read the required target nucleic acid data from the stored data, related technologies typically add check codes and error correction codes when encoding and storing the nucleic acid data. The read data is then verified based on the check codes and error correction codes during data reading to determine whether the read data is the required target nucleic acid data.

[0040] Specifically, nucleic acid data can include deoxyribonucleic acid (DNA) sequence data, ribonucleic acid (RNA) sequence data, etc. Taking DNA sequence data as an example, to ensure the accuracy of DNA data decoding, relevant DNA sequence encoding and decoding methods often incorporate error check codes or error correction codes. During DNA sequence encoding, the binary data to be stored is converted into a DNA sequence. Each DNA sequence, in addition to a data payload area for recording data information and a necessary index area to record the order of each DNA sequence, also stores a check code or error correction code in an appropriate location. During decoding, the DNA sequence obtained after synthesis and sequencing is first converted into a binary stream by the corresponding encoding and decoding method. Then, the check code or error correction code can be separated to check and correct errors in the DNA sequence. Error detection using the check code can determine whether an error has occurred in the current DNA sequence; error correction codes can locate the position of the erroneous base in the current DNA sequence and correct it.

[0041] For example, in related encoding and decoding algorithms, Goldman's Huffman coding uses simple parity checking to detect errors, and also uses the principle of segmented repeated storage to improve the stability of the algorithm; Grass uses two-dimensional RS error correction codes to realize single-base error correction of DNA sequences and recovery of lost sequences; Erlich's DNA fountain code uses two bytes of RS error correction codes for each sequence to protect the random seed and data payload area.

[0042] The aforementioned methods based on parity check codes and error-correcting codes heavily rely on their error-detection capabilities. However, parity check codes can only detect errors in nucleic acid sequences, and their error-detection capability is limited; for example, parity check can only detect an odd number of errors. While error-correcting codes can correct erroneous sequences, their error-correction capability is also limited, and for each nucleic acid sequence, the number of bases they can correct is related to the code distance. Furthermore, error-correcting codes often only correct base substitution errors; if the parity check code or error-correcting code itself is faulty, its verification or correction capability cannot be guaranteed. Additionally, DNA sequences require additional storage space, which increases redundancy and reduces DNA storage density.

[0043] Clustering algorithms are another commonly used method for obtaining correct DNA sequences from sequencing data. Clustering algorithms typically measure the similarity between DNA sequences by calculating their similarity, thus grouping relatively similar DNA sequences into the same cluster. For example, the CD-HIT algorithm uses the smallest unit of the same short string shared between two sequences as their similarity function; the SEED algorithm uses hashing to more efficiently select neighboring sequences that satisfy a certain similarity parameter; and the MeShClust algorithm replaces the greedy algorithm commonly used to determine sequence similarity in clusters with an unsupervised machine learning algorithm—the mean-shift algorithm—thereby reducing parameter sensitivity.

[0044] However, the similarity threshold setting in clustering algorithms can affect the stability of the clustering results. Furthermore, in the field of DNA storage, it is inappropriate to cluster erroneous sequences and correct sequences originating from the same correct sequence into the same class based on the similarity between DNA sequences, because the differences between DNA sequences do not follow a specific pattern and depend on the specific encoding / decoding method. In addition, the sheer volume of DNA sequence data in DNA storage makes computationally complex and memory-intensive clustering algorithms unsuitable; clustering algorithms often require additional error correction algorithms to correct errors in each cluster, thereby obtaining a more accurate representation of the original DNA sequence for each cluster.

[0045] Based on the above analysis, the relevant technologies cannot accurately determine the required target nucleic acid sequence from a large amount of nucleic acid data.

[0046] To address the aforementioned issues, this application provides a method for determining nucleic acid sequences based on a Bloom filter. This method constructs a filter corresponding to the target nucleic acid sequence, enabling the rapid and accurate extraction of all correct sequences from sequencing data containing both correct (target) and incorrect (non-target) sequences. This approach eliminates the need for adding extra redundancy to the nucleic acid sequences for sequence correction, or for using time-consuming and memory-intensive clustering algorithms to group correct and incorrect sequences originating from each target nucleic acid sequence into one cluster before applying a correction algorithm to each cluster to obtain the correct sequence. This significantly improves the efficiency and accuracy of determining the desired target nucleic acid sequence from sequencing data.

[0047] Figure 1 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. The electronic device 10 can be a mobile phone, tablet computer, smart wearable device, augmented reality (AR) / virtual reality (VR) device, laptop computer, netbook, energy storage device, power distribution equipment, vehicle-mounted equipment, self-moving device, etc. This application embodiment does not limit the specific type of electronic device.

[0048] like Figure 1 As shown, the electronic device 10 may include a communication module 101, a memory 102, a processor 103, an input / output (I / O) interface 104, and a bus 105. The processor 103 is coupled to the communication module 101, the memory 102, and the I / O interface 104 via the bus 105.

[0049] Communication module 101 may include a wired communication module and / or a wireless communication module. The wired communication module may provide one or more wired communication solutions such as Universal Serial Bus (USB) and Controller Area Network (CAN). The wireless communication module may provide one or more wireless communication solutions such as Wireless Fidelity (Wi-Fi), Bluetooth (BT), mobile communication networks, Frequency Modulation (FM), Near Field Communication (NFC), and Infrared (IR).

[0050] Memory 102 may include one or more random access memory (RAM) and one or more non-volatile memory (NVM). The RAM can be directly read and written by the processor 103, and can be used to store executable programs (e.g., machine instructions) of the operating system or other running programs, as well as user and application data. The RAM may include static random-access memory (SRAM), dynamic random-access memory (DRAM), synchronous dynamic random-access memory (SDRAM), double data rate synchronous dynamic random-access memory (DDR SDRAM), etc.

[0051] Non-volatile memory can also store executable programs and user and application data, and can be pre-loaded into random access memory for direct reading and writing by the processor 103. Non-volatile memory can include disk storage devices and flash memory.

[0052] Memory 102 is used to store one or more computer programs. The one or more computer programs are configured to be executed by processor 103. The one or more computer programs include multiple instructions that, when executed by processor 103, enable a Bloom filter-based nucleic acid sequence determination method to be executed on electronic device 10.

[0053] In other embodiments, the electronic device 10 further includes an external memory interface for connecting to an external memory to expand the storage capacity of the electronic device 10.

[0054] Processor 103 may include one or more processing units, such as application processor (AP), modem processor, graphics processing unit (GPU), image signal processor (ISP), controller, video codec, digital signal processor (DSP), baseband processor, and / or neural network processing unit (NPU). These different processing units may be independent devices or integrated into one or more processors.

[0055] The processor 103 provides computing and control capabilities, for example, the processor 103 is used to execute computer programs stored in memory 102 to implement the above-described Bloom filter-based nucleic acid sequence determination method.

[0056] I / O interface 104 is used to provide a channel for user input or output. For example, I / O interface 104 can be used to connect various input and output devices, such as mouse, keyboard, touch device, display screen, etc., so that users can enter information or visualize information.

[0057] Bus 105 is used at least to provide a channel for communication between communication modules 101, memory 102, processor 103, and I / O interface 104 in electronic device 10.

[0058] It is understood that the structures illustrated in the embodiments of this application do not constitute a specific limitation on the electronic device 10. In other embodiments of this application, the electronic device 10 may include more or fewer components than illustrated, or combine some components, or split some components, or have different component arrangements. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.

[0059] refer to Figure 2 The diagram shown illustrates the principle of a nucleic acid sequence determination method based on a Bloom filter according to an embodiment of this application. Various types of information (e.g., document data, image data, audio data, video data, etc.) are first encoded into DNA sequences (e.g., ...). Figure 2 The target DNA sequence shown on the left is used to replace the original binary data with various bases in the DNA (e.g., adenine (A), thymine (T), guanine (G), and cytosine (C)). These DNA sequences are then synthesized, for example, by gradually adding bases to the DNA strand. Encoding and synthesis enable the storage and writing of various types of information into DNA sequences.

[0060] Subsequently, when this stored information needs to be retrieved again, the synthesized DNA sequence will undergo polymerase chain reaction (PCR) and sequencing. For example, PCR exponentially increases the number of specific DNA fragments through repeated thermal cycles (e.g., denaturation, annealing, and extension). The amplified DNA sequence is then sent to a sequencer for sequencing. The sequencer reads the base sequence in the DNA sequence and converts it into digital data. The PCR and sequencing process can obtain a large amount of sequencing information from DNA sequences, which, in addition to containing the target DNA sequence, also includes a large number of sequences generated by various random errors that occurred during the storage stage (e.g., ...). Figure 2 The lighter gray sequence shown on the right).

[0061] In one embodiment, to successfully decode the target DNA sequence information and obtain accurate results, the sequencing data needs to be filtered to determine the target DNA sequence. A Bloom filter can be generated, and based on the principles of Bloom filters (BF), the sequencing data can be filtered by a Bloom filter to determine the target DNA sequence.

[0062] Specifically, a Bitwise Field (BF) can be viewed as a combination of a long binary vector (or bit array, array) and a series of random mapping functions (or hash functions, such as hash functions). Initially, the BF array is an array where all elements are 0. When data is stored in the BF, it can be mapped to k positions in the BF array using k hash functions, and the elements at these k positions are updated to 1. To determine if data exists in the BF, we can check if all k positions corresponding to the data in the BF array are 1. If all k positions are 1, the data is likely in the set, with a certain false positive rate. If any one of the k positions in the BF array corresponding to the data is 0, then the data is definitely not in the set.

[0063] In one embodiment, the remaining non-target DNA sequences (false positive sequences) can be further screened out based on the coverage difference between the target DNA sequence and the non-target DNA sequence.

[0064] Next, according to Figure 2 The principle illustrated here describes the nucleic acid sequence determination method based on Bloom filters provided in the embodiments of this application. (Refer to...) Figure 3 The diagram shows a flowchart of a nucleic acid sequence determination method based on a Bloom filter according to an embodiment of this application. This Bloom filter-based nucleic acid sequence determination method is applied in electronic devices, for example... Figure 1 The electronic device 10 in the process includes the following steps. Depending on different needs, the order of the steps in the flowchart can be changed, and some steps can be omitted.

[0065] S301, construct initial Bloom filters corresponding to multiple target nucleic acid sequences.

[0066] In one embodiment, the following embodiments will use the target nucleic acid sequence as the target DNA sequence for example. Specifically, the target DNA sequence can be regarded as a data sequence, which may include a data load region and an index region. The data load region can be used to store DNA sequence data, for example, it may include 120 base data (e.g., binary encoded data); the index region can be used to store the index number of the target DNA sequence, for example, it may include 20 index characters (e.g., binary encoded data), and the index number can be used to indicate the order of different target DNA sequences. For example, if the number of target DNA sequences is 100,000, the index range in the index region can be from 1 to 100,000, with each target DNA sequence corresponding to an index number.

[0067] In one embodiment, based on the application principle of BF described above, a corresponding Bloom filter can be generated using the initial target DNA sequence. Then, the sequencing data can be initially filtered based on this Bloom filter to remove most of the non-target DNA sequences. After that, the remaining non-target DNA sequences (false positive sequences) are screened out, thereby achieving accurate identification of the target DNA sequence from the sequencing data.

[0068] In one embodiment, a method for constructing an initial Bloom filter corresponding to multiple target nucleic acid sequences includes: calculating the array length and hash round number of the initial Bloom filter based on a preset false positive rate (e.g., 0.001) and the total number of sequences of the multiple target nucleic acid sequences (e.g., total number n = 100,000), wherein the hash round number represents the number of hash functions corresponding to the initial Bloom filter; and constructing the initial Bloom filter based on the array length and the hash round number. The initial Bloom filter includes an array in which all elements are a first preset value (e.g., 0).

[0069] In one example, the false positive rate fp can be preset to 0.001, which is then used as the minimum false positive rate in the current state. Combined with the total number of target DNA sequences n, a Bloom filter (BF) of length L and number of hash rounds k can be determined. The initial Bloom filter is an array containing all zeros, and the BF is stored as a Python NumPy array. The formula for calculating the false positive rate of the Bloom filter is: Where fp is a preset known parameter, and the total number of target DNA sequences n is a known parameter. Therefore, the array length L of BF (e.g., 1437760) and the number of hash rounds k (e.g., 10) can be calculated based on this formula.

[0070] Through the above embodiments, initial Bloom filters corresponding to multiple target nucleic acid sequences can be constructed, so that multiple target nucleic acid sequences can be stored in the initial Bloom filters in subsequent processes, and the sequencing data can be filtered and screened based on the application principle of Bloom filters to accurately determine the target nucleic acid sequences from the sequencing data.

[0071] S302, store multiple target nucleic acid sequences into the initial Bloom filter to obtain target filters corresponding to multiple target nucleic acid sequences.

[0072] In one embodiment, each of the plurality of target nucleic acid sequences can be stored in the initial Bloom filter, including: determining a corresponding number of hash rounds based on the number of hash rounds corresponding to the initial Bloom filter; performing a hash operation on the target nucleic acid sequence based on the determined number of hash rounds; and obtaining the target hash value for each hash operation; determining the target position in the array of the initial Bloom filter based on the target hash value for each hash operation; and updating the element in the initial Bloom filter located at the target position to a second preset value (e.g., 1).

[0073] In one embodiment, when performing each hash operation on the target nucleic acid sequence, each target data (e.g., each base of a DNA sequence represented in character form) in the target nucleic acid sequence can be converted into a preset standard code value (e.g., an ASCII code value); according to the order of each target data in the target nucleic acid sequence, the preset standard code value corresponding to each target data is sequentially input into the hash function of any number of hash operations to obtain the target hash value of the hash operation corresponding to any number of hash operations.

[0074] In one embodiment, determining the target position in the array of the initial Bloom filter based on the target hash value of each hash operation includes: if the target hash value is less than or equal to the length of the array of the initial Bloom filter, determining the target position based on the target hash value, for example, taking the H-th position in the array of the initial Bloom filter as the target position, where H = the target hash value; if the target hash value is greater than the length of the array of the initial Bloom filter, determining the target position based on the target hash value and the array length includes: determining the target position based on the remainder obtained after performing a modulo operation on the target hash value and the array length, for example, taking the (H mod L)-th position in the array of the initial Bloom filter as the target position, where H = the target hash value, L = the array length, and (H mod L) represents performing a modulo operation on H and L.

[0075] In one example, k rounds of hashing are performed on each target DNA sequence. The position of the hash value obtained in each round corresponding to the BF array is recorded as 1, thus completing the storage of a DNA sequence information in the BF. During the specific hash operation, the index value of the current hash round (an integer from 0 to k, e.g., the number of hash rounds) is used as the initial input value for the hash function calculation in that round. Each base of the DNA sequence represented in character form (e.g., the target data) is converted into an ASCII code value and passed sequentially into the hash function to obtain the hash value of the current target DNA sequence in the current round of hashing. If the hash value is greater than or equal to the array length L of the Bloom filter, the element at the Bloom filter array position corresponding to the remainder obtained by dividing the hash value by the array length L is updated to 1.

[0076] In one example, when each base is converted to its ASCII code value, adenine can be converted to ASCII code value 65, thymine to ASCII code value 84, cytosine to ASCII code value 67, and guanine to ASCII code value 71. The hash function can be set according to actual needs; for example, the hash function can be an accumulation function, a multiplication function, or a combination of accumulation and multiplication functions. This application does not impose specific restrictions on the hash function.

[0077] refer to Figure 4 The diagram shown illustrates the application principle of BF provided in this application embodiment. When storing sequences a, b, and c in BF, k = 3 hash functions (including hash(1), hash(2), and hash(3)) are used to map sequences a, b, and c in sequence, respectively, to determine the three positions of each sequence mapped to the BF array, and the element of each mapped position is updated from 0 to 1. The positions mapped to the BF array of different sequences may overlap.

[0078] In one example, the Bloom filter that stores all the target DNA sequence information is stored as a Python NumPy array, where each element of the array is either 0 or 1.

[0079] Through the above embodiments, multiple target nucleic acid sequences can be stored in an initial Bloom filter to obtain target filters corresponding to multiple target nucleic acid sequences, which facilitates subsequent processes to filter non-target nucleic acid sequences based on the target filters.

[0080] S303 filters non-target nucleic acid sequences from multiple test nucleic acid sequences based on a target filter.

[0081] In one embodiment, the plurality of nucleic acid sequences to be tested may be nucleic acid sequences that are associated with a certain extent with a plurality of target nucleic acid sequences. The method for obtaining the plurality of nucleic acid sequences to be tested includes: synthesizing the plurality of target nucleic acid sequences to obtain a plurality of synthetic nucleic acid sequences; performing data amplification on the plurality of synthetic nucleic acid sequences based on polymerase chain reaction to obtain data-amplified nucleic acid sequences; and sequencing the data-amplified nucleic acid sequences to obtain the plurality of nucleic acid sequences to be tested.

[0082] In one embodiment, determining whether each of the plurality of nucleic acid sequences to be tested is the non-target nucleic acid sequence includes: determining the corresponding hash round number of the target filter; performing a hash operation on the nucleic acid sequence to be tested for the number of hash rounds corresponding to the hash round number to obtain the hash value to be tested for each hash operation; determining the position to be tested in the array of the target filter based on the hash value to be tested for each hash operation; and determining that the nucleic acid sequence to be tested is the non-target nucleic acid sequence if the element at the position to be tested in the target filter is a first preset value.

[0083] In one example, the Bloom filters for the target DNA sequences to be read are obtained. The NumPy array file containing the Bloom filters for the target DNA sequences is read to obtain the Bloom filters for this batch of target DNA sequences. Each sequence is checked to see if it has been stored in the Bloom filter: Each DNA sequence in the input sequencing data to be filtered undergoes 1 to k rounds of hashing. After each round, the position of the Bloom filter corresponding to the current hash value is checked to see if it has been marked as 1. If it is 1, the next round of hashing continues; if it is 0, the current sequence is checked and determined not to belong to the target DNA sequences. When a DNA sequence has undergone k rounds of hashing and all k Bloom filter positions corresponding to these hash values ​​are marked as 1, it is determined to be the target DNA sequence.

[0084] refer to Figure 4 As shown, when determining whether sequences a, b, c, d, e, and f are stored in BF for verification, three hash functions (including hash(1), hash(2), and hash(3)) can be used to map sequences a to f in turn, determine the three positions of each sequence mapped to the BF array, and determine whether the element corresponding to each position of the BF array mapped to each sequence is 1. Among them, there are elements with 0 in the positions of the BF array mapped to sequence d, which can be used to determine that sequence d is not stored in BF, that is, sequence d is a non-target sequence.

[0085] In other embodiments, the multiple nucleic acid sequences to be tested may also be nucleic acid sequences that are not related to the multiple target nucleic acid sequences. For example, the multiple nucleic acid sequences to be tested may include nucleic acid sequences of the target category and nucleic acid sequences of other categories. Therefore, the method provided in this application embodiment can be applied not only to filtering erroneous data in stored data, but also to determining nucleic acid sequences of the same type.

[0086] Through the above embodiments, non-target nucleic acid sequences in multiple nucleic acid sequences to be tested can be filtered based on the target filter, thereby achieving the first filtering and deletion of non-target nucleic acid sequences.

[0087] S304, perform false positive detection on the multiple filtered nucleic acid sequences to be tested, identify the false positive sequences in the filtered nucleic acid sequences to be tested, and exclude the false positive sequences from the filtered nucleic acid sequences to be tested to obtain the target nucleic acid sequence.

[0088] In one embodiment, due to the one-way false positive nature of Bloom filters, the target DNA sequence identified after Bloom filter detection may contain a small portion of non-target DNA sequences in addition to the true target DNA sequence. The one-way false positive nature of Bloom filters means that while they can identify all correct sequences, they may also incorrectly identify some sequences as correct. These incorrectly identified sequences are called false positive sequences, and the probability of such incorrect identification depends on the false positive rate of the Bloom filter.

[0089] refer to Figure 4 As shown, when detecting sequences a, b, c, e, and f based on BF, all positions in the BF array mapped to sequences a, b, c, e, and f are 1. Therefore, the BF detection result indicates that sequences a, b, c, e, and f are stored target sequences. However, sequences e and f are not actually stored in BF, so sequences e and f are false positive sequences.

[0090] In one embodiment, false positive detection can be performed on the target nucleic acid sequences among the filtered multiple target nucleic acid sequences based on the coverage difference between the target DNA sequence and the non-target DNA sequence, and false positive sequences can be excluded from the filtered target nucleic acid sequences.

[0091] Specifically, when performing PCR on a synthesized DNA sequence, the DNA sequence may be copied multiple times in order to increase the number of specific DNA fragments. Since the DNA sequence may contain both target DNA sequences and non-target DNA sequences, both target DNA sequences and non-target DNA sequences will be copied multiple times.

[0092] However, since non-target DNA sequences are randomly generated after errors occur during the synthesis, storage, and sequencing of target DNA sequences, the coverage of multiple erroneous sequences originating from the same correct sequence will be much smaller than that of the correct sequence. Therefore, this difference can be used to achieve separation. Coverage represents the repetition rate of a sequence across all sequencing data. For example, in every 100 copies of the sequence, there might be 20 non-target DNA sequences and 80 target DNA sequences. The coverage of the non-target DNA sequences could be equal to 20, and the coverage of the target DNA sequences could be equal to 80.

[0093] In one embodiment, the coverage of each nucleic acid sequence to be tested among the filtered plurality of nucleic acid sequences to be tested can be determined, and nucleic acid sequences to be tested with a coverage less than a preset coverage threshold are identified as false positive sequences. The coverage threshold can be set according to actual needs, for example, 12, and this application does not impose specific limitations on it.

[0094] Through the above embodiments, false positive sequences can be excluded from the filtered nucleic acid sequences to be tested based on the coverage difference between the target nucleic acid sequence and the non-target nucleic acid sequence, thereby achieving accurate determination of the target nucleic acid sequence.

[0095] In one embodiment, a corresponding instantiated object can be constructed according to the method provided in the above embodiments, so as to facilitate direct calling of the object to implement the above methods. In one example, an instantiated "anti-contamination" object can be constructed according to the method provided in the above embodiments. The specific method may include: (1) giving a file of the target DNA sequence required to generate the Bloom filter and reading it into a suitable format (list) as the input parameter for the subsequent instantiation of the "anti-contamination" object; (2) the parameters of the instantiation of the "anti-contamination" object also include: the number of target DNA sequence types, the specified hash function (e.g., "FNV1a"), the specified false positive rate of the Bloom filter (e.g., 0.001), the specific name of the Bloom filter corresponding to the file when saving it, the file root directory, and whether to use The settings for the counting Bloom filter (e.g., no by default), the length of the Bloom filter, and the number of hash rounds (e.g., no specific settings by default, because these two variables can be calculated once the false positive rate of the Bloom filter is given. These two parameters are only set when the length of the Bloom filter and the number of hash rounds must be specified); (3) The above parameters are passed to an instantiated "anti-contamination" object, and the "training" method is used: the Bloom filter is initialized based on the false positive rate of the Bloom filter and the number of target DNA sequences, and then a Bloom filter specific to this file is generated based on the base information of the target DNA sequence, the hash function, and the Bloom filter that has just been initialized, and then saved (e.g., saved as a ".npy" file).

[0096] When calling the above object to implement the above method, it may include: (1) providing a file of sequencing data and reading it into a suitable format (data frame) for the input parameters of the next step of Bloom filter detection; (2) providing a coverage threshold for the subsequent process of removing false positive sequences based on the coverage threshold; (3) using the "checking" method of the "anti-contamination" object: reading the ".npy" file of the corresponding Bloom filter to obtain the Bloom filter, and then filtering the incoming sequencing data based on this Bloom filter to obtain the target DNA sequence containing false positive sequences. Finally, based on the coverage difference threshold, removing all DNA sequences below the threshold to obtain a more accurate target DNA sequence, and saving it as input.

[0097] The nucleic acid sequence determination method based on Bloom filter provided in this application can quickly and accurately read all correct DNA sequences from sequencing data containing correct sequences (target DNA sequences) and incorrect sequences (non-target DNA sequences) without adding extra redundancy to the DNA sequences for sequence correction, or using time-consuming and memory-intensive clustering algorithms to cluster the correct and incorrect sequences originating from each target DNA sequence into one class, and then using an error correction algorithm to perform sequence correction for each cluster to obtain the correct sequence.

[0098] refer to Figure 5 The diagram illustrates the effectiveness of the anti-contamination function based on the Bloom filter provided in this application. Sequences A, C, and E are obtained using the YYC encoding method, while sequences B, D, and F are randomly generated. A and B represent the proportion of target DNA sequences to non-target DNA sequences in the sequencing data without any processing; C and D represent the proportion of target DNA sequences to non-target DNA sequences after Bloom filter filtering; and F represents the number of target DNA sequences (type number) after Bloom filter filtering and coverage threshold removal of false positive sequences. It can be seen that the number of non-target DNA sequences is significantly reduced after Bloom filter filtering, and the remaining false positive sequences can be removed using coverage differences, demonstrating the effectiveness of Bloom filter-based anti-contamination reading to some extent. Furthermore, the YYC-encoded sequences and the same number (100,000) of randomly generated DNA sequences show similar trends, indicating that this method is not affected by the encoding method. In addition, E represents the coverage distribution of target DNA sequences and non-target DNA sequences at simulated sequencing depths of 10–100. It can be seen that when the sequencing depth reaches 30, the coverage of target DNA sequences and non-target DNA sequences no longer overlaps. As the sequencing depth increases, the coverage difference also increases accordingly. This phenomenon can provide a certain reference for the subsequent use of anti-contamination functions.

[0099] refer to Figure 6The diagram shown illustrates the robustness of the anti-contamination function based on the Bloom filter provided in this application embodiment. A represents the pre-set false positive rate of the Bloom filter, the change of which affects the configuration of the Bloom filter and thus the number of false positive sequences; B represents the file size, indicating the number of different initial target DNA sequences; C represents the file type, with different file formats representing different byte frequency distributions; and D represents different visualization formats (BMP images) under the same file format. The minimum coverage (M) of the target DNA sequence under various conditions is discussed. t The maximum coverage difference between the target DNA sequence and the non-target DNA sequence (M) nt The stability of the presence of the coverage difference, to some extent, demonstrates the feasibility of using coverage differences to remove false positive sequences, as well as the robustness or robustness of the anti-contamination function.

[0100] In other embodiments, for false positive sequences included in the Bloom filter's misjudgment mechanism during anti-contamination reading, in addition to using methods based on significant coverage differences between target and non-target DNA sequences, other methods can be used instead. For example, a first-step screening can be performed by detecting the index numbers of all DNA sequences obtained after Bloom filter filtering. Specifically, the sequence index region is decoded to determine whether the index number is within the range of the total number of target DNA sequences. If not, the sequence can be directly identified as a false positive sequence. Next, the remaining DNA sequences are clustered, and the centroid of each cluster is the final target DNA sequence to be obtained; the remaining sequences are considered false positive sequences.

[0101] In other embodiments, for multiple batches of data that need to be filtered using the same Bloom filter, an interface for batch-wise data input and filtering can be further designed. Then, the results of multiple data inputs are combined to uniformly remove false positive sequences based on coverage differences. The advantage of this approach is that it makes the coverage difference between the target DNA sequence and non-target DNA sequences more significant. This is because inputting multiple batches of data can enhance the coverage of the target DNA sequence, while since the non-target DNA sequences are random and different in each batch, the coverage of non-target DNA sequences will not be significantly improved. This effectively widens the coverage gap between the target DNA sequence and non-target DNA sequences. This is significant when there is no coverage difference between the target DNA sequence and non-target DNA sequences within the same batch of data.

[0102] In other embodiments, the above-described anti-contamination reading method can also be used as a preprocessing step before error correction methods or clustering algorithms, which can remove a large number of non-target DNA sequences, thereby improving the accuracy of error correction methods or greatly reducing the time and memory consumption during clustering.

[0103] The method provided in the above embodiments can rapidly and accurately extract all correct DNA sequences from sequencing data containing both correct sequences (e.g., target DNA sequences) and incorrect sequences (e.g., non-target DNA sequences). Furthermore, based on the variant structure of a Bloom filter—a counting Bloom filter (CBF)—it can also extract DNA sequences (e.g., target DNA sequences) from sequencing data containing information from different version files. This functionality allows DNA sequences from different version files to be synthesized simultaneously and stored in the same DNA pool, or only the modified portions of each version can be synthesized, thereby significantly reducing synthesis costs. For example, different version files may include a first version file (or version 1), a second version file (or version 2), a third version file (or version 3), etc., of the target DNA sequence; this application does not impose a specific limit on the number of different versions.

[0104] refer to Figure 7 The diagram illustrates the principle of a nucleic acid sequence determination method based on a Bloom filter according to another embodiment of this application. Different versions of the files are encoded to obtain the corresponding DNA sequences. These initial DNA sequences are used as input information for generating a counting Bloom filter for the corresponding version files. Version 1 is the original version of the files, while versions 2 and 3 are two different modified versions of the original version of the files. During synthesis, only all DNA sequences from version 1 and the modified DNA sequences from versions 2 and 3 are synthesized, and then stored in the same DNA pool. Before obtaining information from a specific version of the file, the entire DNA pool is sequenced.

[0105] To obtain the accurate target DNA sequence of the desired version for successful decoding of the file information, a Generating Counting Bloom Filter (CBF) can be generated. The file version control function will filter the sequencing data based on the corresponding CBF. Taking a deletion operation on the CBF based on the generated CBF will obtain all target DNA sequences belonging to that version and a small number of non-target DNA sequences (target DNA sequences from other versions and sequences that were incorrectly stored) from the sequencing data (screening out the false positive sequences). Eliminating false positive sequences yields the desired version of the target DNA sequence.

[0106] Specifically, a counting BF can be viewed as a combination of a long binary vector (or bit array, array) and a series of random mapping functions (or hash functions, such as hash functions). The initial counting BF array is an array where all elements are 0. When data is stored in a counting BF, it can be mapped to k positions in the counting BF array using k hash functions, and the elements at these k positions are incremented by 1.

[0107] When determining whether a data exists in a counting BF array, if any of the k positions in the counting BF array corresponding to the data is 0, then the data is definitely not in the set; if it is determined that none of the k positions in the counting BF array corresponding to the data are 0, then the data is very likely in the set, with a certain false positive rate.

[0108] Because the target DNA sequences of different versions of the file are stored in the same DNA pool, for a given version, the target DNA sequences of other versions are considered non-target DNA sequences. Furthermore, since the synthesis process of the target DNA sequences in each version is consistent, the coverage of DNA sequences in different versions within the same DNA pool should also be similar. Therefore, in the implementation of file version control, it is no longer possible to use coverage differences to separate target DNA sequences from non-target DNA sequences. These non-target DNA sequences (false positive sequences) can be identified based on the deletion capability of count-based BF (Browser Filter), thus obtaining the accurate target DNA sequence of the desired version.

[0109] Next, according to Figure 7 The principle illustrated here describes the nucleic acid sequence determination method based on Bloom filters provided in the embodiments of this application. (Refer to...) Figure 8 The diagram shown is a flowchart of a nucleic acid sequence determination method based on a Bloom filter, provided in another embodiment of this application. This Bloom filter-based nucleic acid sequence determination method is applied in electronic devices, for example... Figure 1 The electronic device 10 in the process includes the following steps. Depending on different needs, the order of the steps in the flowchart can be changed, and some steps can be omitted.

[0110] S801, construct the initial counting Bloom filter corresponding to multiple target nucleic acid sequences in a preset version.

[0111] In one embodiment, multiple target nucleic acid sequences of a preset version can be determined as needed; for example, the preset version could be version 1. Multiple target DNA sequences of the preset version can be considered correct sequences, while target DNA sequences of other versions can be considered incorrect sequences.

[0112] In one example, the following embodiments will use a target nucleic acid sequence as the target DNA sequence. Specifically, the target DNA sequence can be considered as a data sequence, which may include a data load region and an index region. The data load region can be used to store DNA sequence data, for example, it may include 120 bases (e.g., binary encoded data); the index region can be used to store the index number of the target DNA sequence, for example, it may include 20 index characters (e.g., binary encoded data), and the index number can be used to indicate the order of different target DNA sequences. For example, if the number of target DNA sequences is 100,000, the index range in the index region can be from 1 to 100,000, with each target DNA sequence corresponding to one index number.

[0113] In one embodiment, a corresponding counting type BF can be generated using multiple target nucleic acid sequences of a preset version. Then, based on this counting type BF, the DNA pool is initially filtered to remove most of the non-preset version target DNA sequences. After that, the remaining non-preset version target DNA sequences (false positive sequences) are screened out, thereby achieving accurate identification of the preset version target DNA sequence from the DNA pool.

[0114] In one embodiment, the array length and hash rounds of the initial counting Bloom filter can be calculated based on a preset false positive rate and the total number of sequences of multiple target nucleic acid sequences of the preset version, and the initial counting Bloom filter can be constructed based on the array length and hash rounds. The initial counting Bloom filter includes an array in which all elements are a first preset value (e.g., 0).

[0115] In one example, a false positive rate fp (e.g., 0.001) for a counting Bloom filter can be preset and used as the minimum false positive rate in the current state. Combined with the total number of target DNA sequences n, a counting Bloom filter of length l and number of hash rounds k can be determined. The initialized counting Bloom filter is an array where all elements are zero, and its storage format is a Python NumPy array. The formula for calculating the false positive rate of the counting Bloom filter is: Where fp is a preset known parameter, and the total number n of multiple target DNA sequences in the preset version is a known parameter. Therefore, the array length l (e.g., 1437760) and the number of hash rounds k (e.g., 10) of the counting type BF can be calculated based on this formula.

[0116] Through the above embodiments, an initial counting Bloom filter corresponding to multiple target nucleic acid sequences of a preset version can be constructed. In subsequent processes, multiple target nucleic acid sequences of the preset version can be stored in the initial counting Bloom filter. Then, based on the application principle of the counting Bloom filter, the sequencing data can be filtered and screened to accurately determine the target nucleic acid sequence of the preset version from the DNA pool.

[0117] S802, the multiple target nucleic acid sequences of the preset version are stored in the initial counting Bloom filter to obtain the target counting filter corresponding to the multiple target nucleic acid sequences of the preset version.

[0118] In one embodiment, each of the preset versions of target nucleic acid sequences from a plurality of preset versions can be stored in the initial counting Bloom filter, including: determining a corresponding number of hash rounds according to the number of hash rounds corresponding to the initial counting Bloom filter; performing a hash operation on the preset version of the target nucleic acid sequence according to the determined number of hash rounds to obtain the target hash value of each hash operation; determining the target position in the array of the initial counting Bloom filter according to the target hash value of each hash operation; and updating the element at the target position in the initial counting Bloom filter, including: if the hash operation is the first hash operation, updating the element at the target position in the initial counting Bloom filter to a second preset value (e.g., 1); if the hash operation is not the first hash operation, updating the element at the target position according to the sum of the element at the target position after the previous hash operation and the second preset value.

[0119] In one embodiment, k rounds of hashing are performed on each preset version of the target DNA sequence. The value obtained from each round of hashing is incremented by 1 at the corresponding position in the counting BF array, thereby completing the storage of a DNA sequence information in the counting BF.

[0120] In one embodiment, determining the target position in the array of the initial counting Bloom filter based on the target hash value of each hash operation includes: if the target hash value is less than or equal to the array length of the initial counting Bloom filter, determining the target position based on the target hash value, for example, taking the H-th position in the array of the initial counting Bloom filter as the target position, where H = the target hash value; if the target hash value is greater than the array length of the initial counting Bloom filter, determining the target position based on the target hash value and the array length includes: determining the target position based on the remainder obtained after performing a modulo operation on the target hash value and the array length, for example, taking the (H mod l)-th position in the array of the initial Bloom filter as the target position, where H = the target hash value, l = the array length, and (H mod l) represents performing a modulo operation on H and l).

[0121] In one example, during a specific hash operation, the index of the current hash round (starting from 0) is used as the initial input value for that round's hash function calculation. Each base of the DNA sequence, represented as a character, is converted to an ASCII code value and sequentially passed into the hash function to obtain the hash value of the current target DNA sequence in that round. If the hash value is greater than or equal to the length l of the counting Bloom filter, the value at the position in the Bloom filter array corresponding to the remainder obtained by dividing the hash value by the length l is incremented by 1.

[0122] In one example, when storing sequences a, b, and c in the CBF, k = 3 hash functions (including hash(1), hash(2), and hash(3)) are used to map sequences a, b, and c in turn to determine the 3 positions of each sequence in the CBF array. The element of each mapped position is incremented by 1. Different sequences may be mapped to positions in the CBF array that overlap. The number of overlaps of the overlapping positions is the element value.

[0123] In one example, when each base is converted to its ASCII code value, adenine can be converted to ASCII code value 65, thymine to ASCII code value 84, cytosine to ASCII code value 67, and guanine to ASCII code value 71. The hash function can be set according to actual needs; for example, the hash function can be an accumulation function, a multiplication function, or a combination of accumulation and multiplication functions. This application does not impose specific restrictions on the hash function.

[0124] In one example, the Bloom filter that stores all the target DNA sequence information is stored as a Python NumPy array, where each element is a positive integer of 0 or greater than or equal to 1.

[0125] Through the above embodiments, multiple target nucleic acid sequences of a preset version can be stored in an initial counting Bloom filter to obtain a counting target filter corresponding to the multiple target nucleic acid sequences of the preset version, which facilitates subsequent processes to filter non-preset version target nucleic acid sequences based on the target filter.

[0126] S803, based on the target counting filter, filter the non-preset version of the target nucleic acid sequence among multiple nucleic acid sequences to be tested.

[0127] In one embodiment, the plurality of nucleic acid sequences to be tested includes multiple target nucleic acid sequences of different versions from the preset version. The filtering of the non-preset version target nucleic acid sequences among the plurality of nucleic acid sequences to be tested based on the target counting filter includes: determining whether each nucleic acid sequence to be tested is the non-preset version target nucleic acid sequence, including: determining the corresponding number of hash rounds according to the number of hash rounds corresponding to the initial counting Bloom filter; performing a hash operation on the nucleic acid sequence to be tested according to the determined number of hash rounds to obtain the hash value to be tested for each hash operation; determining the position to be tested in the array of the target counting filter according to the hash value to be tested for each hash operation; if the element at the position to be tested in the target counting filter is a first preset value (e.g., 0), the nucleic acid sequence to be tested is determined to be the non-preset version target nucleic acid sequence.

[0128] In one example, a counting Bloom filter for the target DNA sequence of a specific version of the file is obtained. The NumPy array file containing the counting Bloom filter for the current version of the target DNA sequence is read to obtain the counting Bloom filter for that version of the file. Each sequence is checked to see if it is already stored in the counting Bloom filter: each DNA sequence in the input sequencing data to be filtered undergoes k rounds of hashing. After each round, the value of the counting Bloom filter corresponding to the current hash value is checked. If the value is 0, it is determined that it does not belong to the target DNA sequence. If, after k rounds of hashing, no hash value corresponding to a counting Bloom filter position is found to be 0, then it can be determined that it is the target DNA sequence of the required version of the file. Unlike anti-contamination reading, k rounds of hashing must be performed regardless of whether the DNA sequence is determined to be the target DNA sequence.

[0129] refer to Figure 9As shown, when determining whether sequences a, b, and c are stored in the CBF for verification, three hash functions (including hash(1), hash(2), and hash(3)) can be used to map sequences a to c in turn, determining the three positions of each sequence mapped to the CBF array, and determining whether each element corresponding to each position of the CBF array mapped to each sequence is not zero. Since there are no zero elements in the positions of the CBF array mapped to sequences a to c, it can be determined that sequences a to c are all stored in the CBF.

[0130] In one example, when determining whether a sequence d is stored in a CBF for verification, three hash functions (including hash(1), hash(2), and hash(3)) can be used to map the sequence d sequentially to determine the three positions of the CBF array to which the sequence d is mapped, and to determine whether the element corresponding to each position of the CBF array to which the sequence d is mapped is not 0. If there is an element with a value of 0 in the position of the CBF array to which the sequence d is mapped, it can be determined that the sequence d is not stored in the CBF.

[0131] Through the above embodiments, non-preset versions of target nucleic acid sequences among multiple nucleic acid sequences to be tested can be filtered based on a target counting filter, thereby achieving the first filtering and deletion of non-preset versions of nucleic acid sequences.

[0132] S804, perform false positive detection on the filtered multiple nucleic acid sequences to be tested, identify the false positive sequences in the filtered nucleic acid sequences to be tested, and exclude the false positive sequences from the filtered nucleic acid sequences to be tested, to obtain the preset version of the target nucleic acid sequence.

[0133] In one embodiment, due to the one-way false positive nature of CBF, the target DNA sequence identified by CBF as the desired preset version may contain a small portion of non-preset version target DNA sequences in addition to the true preset version. The one-way false positive nature of CBF means that while it can identify all correct sequences, it will also identify some incorrect sequences as correct. These incorrectly identified sequences are called false positive sequences, and the probability of such false positives depends on the false positive rate of the counting Bloom filter.

[0134] refer to Figure 9As shown, when detecting sequences a, b, c, e, and f based on CBF, all elements in the CBF array mapped to sequences a, b, c, e, and f are not 0. Therefore, the CBF detection result indicates that sequences a, b, c, e, and f are stored target sequences. However, sequences e and f are not actually stored in the CBF array, so sequences e and f are false positive sequences.

[0135] In one embodiment, since the DNA sequence coverage of different versions of files in the same DNA pool is similar, it is no longer possible to use the coverage difference to separate the target DNA sequence from the non-target DNA sequence. False positive sequence filtering can be achieved based on the deleteability of CBF.

[0136] In one embodiment, the step of performing false positive detection on the filtered plurality of nucleic acid sequences to be tested and determining the false positive sequences among the filtered nucleic acid sequences to be tested includes: based on the deletability of the target counting filter, performing a preset deletion operation on the target counting filter according to each nucleic acid sequence to be tested among the filtered plurality of nucleic acid sequences to be tested; determining the negative position corresponding to the negative value element of the array in the target counting filter after the preset deletion operation is performed; and determining the false positive sequences among the filtered plurality of nucleic acid sequences to be tested based on the negative position.

[0137] In one embodiment, the preset deletion operation includes: determining the test hash value of each test nucleic acid sequence in the filtered plurality of test nucleic acid sequences for each hash operation; determining the test position in the array of the target counting filter based on the test hash value of each hash operation; and updating the element at the test position based on the difference between the element at the test position and a second preset element.

[0138] In one example, sequences detected as target DNA sequences are deleted from a counting Bloom filter: Before detecting suspected false positives in the input sequencing data to be filtered, a counting Bloom filter storing the required version file information is copied for the subsequent deletion operation. Next, the input sequencing data to be filtered is tested and screened (see S803), and for the detected target DNA sequences, deletion is performed simultaneously. The specific deletion operation includes: subtracting 1 from the value of the position in the array of the copied counting Bloom filter corresponding to the hash calculation value of each DNA sequence in each round. When the DNA sequence to be deleted is the same as the DNA sequence originally stored in the counting Bloom filter, the counting filter will return to its initial state, that is, all positions in the array are marked as 0. When the DNA sequence to be deleted contains non-target DNA sequences in addition to all the already stored target DNA sequences, the array of the counting filter will have negative values ​​in many positions, that is, the array at this time is a non-positive integer array containing 0 and negative integers. Meanwhile, the results of the k rounds of hashing corresponding to the sequence detected as the target DNA sequence are saved in an additional dictionary for subsequent searching of false positive sequences, thus avoiding repeated hashing operations.

[0139] refer to Figure 9 As shown, based on the filtered sequences a, b, c, e, and f obtained from S803, a deletion operation is performed on the CBF array. That is, the elements at the corresponding array positions of sequences a, b, c, e, and f in the CBF array are decremented by 1 multiple times according to the corresponding number of overlaps. After the deletion operation, the CBF array is a non-positive integer array containing 0 and negative integers.

[0140] In one embodiment, determining the false positive sequence among the filtered plurality of nucleic acid sequences to be tested based on the negative value position includes: determining the test hash value obtained by each test sequence in each hash operation among the filtered plurality of nucleic acid sequences to be tested, and the corresponding position of the test hash value in the array of the target counting filter; if the corresponding position of any test sequence among the filtered plurality of nucleic acid sequences to be tested is the negative value position, determining that any test sequence to be tested is the false positive sequence.

[0141] In one example, false positive sequences are identified from the counting Bloom filter after the deletion operation: based on the non-positive integer array obtained from the deletion operation and the dictionary storing the k rounds of hash values ​​of each DNA sequence, DNA sequences whose values ​​at the non-positive integer array positions corresponding to the k rounds of hash values ​​are all negative are identified as non-target DNA sequences, i.e., false positive sequences, and the remaining sequences are recorded as the target DNA sequence of the specified version to be obtained in the end.

[0142] refer to Figure 9As shown, after the deletion operation, there are no negative values ​​at the positions corresponding to sequence a and sequence b in the CBF array, while the positions corresponding to sequences c, e, and f are negative. Therefore, sequences c, e, and f can be identified as false positive sequences. However, sequence c is actually stored in the CBF array; therefore, sequence c is actually the target sequence, but it is incorrectly identified as a false positive sequence. Thus, the method for identifying false positive sequences has a certain false negative rate. Sequence c is a false negative sequence; sequences e and f are correctly identified false positive sequences.

[0143] Through the above embodiments, based on the deletability of CBF, false positive sequences can be excluded from the filtered nucleic acid sequences to be tested, thereby achieving accurate determination of the target nucleic acid sequence of the preset version.

[0144] In one embodiment, a corresponding instantiated object can be constructed according to the method provided in the above embodiments, so as to directly call the object to implement the above methods. In one example, an instantiated "file_version_control" object can be constructed according to the method provided in the above embodiments. The specific method may include: (1) giving a file of a specific version of the target DNA sequence required to generate a counting Bloom filter, and reading it into a suitable format (list) as the input parameter for the subsequent instantiation of the "file_version_control" file version control object. (2) The parameters for instantiating the "file_version_control" object also include: the number of target DNA sequence types, the specified hash function (e.g., "FNV1a"), the specified false positive rate of the counting Bloom filter (e.g., 0.001), a specific name tag for saving the counting Bloom filter corresponding to this version file, the root directory, whether to use the counting Bloom filter (e.g., yes), and the settings for the length of the counting Bloom filter and the number of hash rounds (no specific settings by default, because these two variables can be calculated when the false positive rate of the counting Bloom filter is given. These two parameters are only set when it is necessary to specify the length of the counting Bloom filter and the number of hash rounds). (3) The above parameters are passed to instantiate the "file_version_control" object, and the "training" method is used to generate a counting Bloom filter specific to this version file and save it (.npy file).

[0145] When calling the above object to implement the above method, it may include: (1) a given sequencing data file, and read it into a suitable format (data frame) for the input parameters of the next step of counting Bloom filter detection. (2) using the "checking" method of the "file_version_control" object: read the corresponding counting Bloom filter's npy file to obtain the counting Bloom filter, and then filter the incoming sequencing data based on this counting Bloom filter to obtain the target DNA sequence containing false positive sequences. Then, based on the counting Bloom filter that has been deleted and the dictionary that stores hash values ​​obtained synchronously during the detection process, the false positive sequences are quickly identified and removed to obtain the target DNA sequence of the version file that is finally required.

[0146] The nucleic acid sequence determination method based on Bloom filters provided in this application allows target DNA sequences from different versions of the file to be synthesized, stored, and sequenced simultaneously. It also allows for the design of new DNA sequences encoding only the parts that differ between versions during sequence design, thus requiring only the resynthesis of the modified DNA sequences from different versions. This significantly reduces synthesis or storage costs, and the ability to extract information from multiple versions of the file in a single sequencing operation also reduces sequencing costs to some extent.

[0147] refer to Figure 10The diagram illustrates an example of the effectiveness of a counting Bloom filter in eliminating false positive sequences according to an embodiment of this application. Figure A shows the coverage distribution of different categories of DNA sequences (other versions sequences) obtained after filtering mixed sequencing data of target DNA sequences from different versions of files stored in the same DNA pool using the corresponding counting Bloom filters. It can be seen that for each version, in addition to its own target DNA sequences, there are target DNA sequences from other versions of files and error sequences. The coverage distribution of target DNA sequences from other versions of files is included within the coverage distribution of target DNA sequences from this version of file. This phenomenon confirms that target DNA sequences from other versions of files cannot be removed using coverage differences. Figure B shows the distribution and number of target DNA sequences (with eliminating false positive sequences) remaining after filtering with the counting Bloom filters corresponding to different versions of files and further identifying false positive sequences using the deleteable feature of the counting Bloom filters. As can be seen, the counting Bloom filter can completely identify and remove false positive sequences, thereby obtaining the complete version of the target DNA sequence and achieving precise file version control.

[0148] Figure 11 This is a structural diagram of a nucleic acid sequence determination device based on a Bloom filter provided in an embodiment of this application.

[0149] In some embodiments, the Bloom filter-based nucleic acid sequence determination device 120 may include multiple functional modules composed of computer program segments. The computer programs for each program segment in the Bloom filter-based nucleic acid sequence determination device 120 may be stored in the memory of an electronic device and executed by at least one processor to perform (see details). Figure 3 (Description) Functionality of nucleic acid sequence determination based on Bloom filter.

[0150] In this embodiment, the Bloom filter-based nucleic acid sequence determination device 120 can be divided into multiple functional modules according to its functions. These functional modules may include: a filter construction module 1201, a sequence storage module 1202, a sequence filtering module 1203, and a false positive deletion module 1204. As used in this application, a module refers to a series of computer program segments that can be executed by at least one processor and perform a fixed function, stored in memory. In this embodiment, the functional implementation of each module in the Bloom filter-based nucleic acid sequence determination device 120 can be found in the above description of the Bloom filter-based nucleic acid sequence determination method, and will not be repeated here.

[0151] The filter construction module 1201 is used to construct initial Bloom filters corresponding to multiple target nucleic acid sequences;

[0152] The sequence storage module 1202 is used to store the plurality of target nucleic acid sequences into the initial Bloom filter to obtain the target filter corresponding to the plurality of target nucleic acid sequences;

[0153] The sequence filtering module 1203 is used to filter non-target nucleic acid sequences from multiple nucleic acid sequences to be tested based on the target filter;

[0154] The false positive deletion module 1204 is used to perform false positive detection on the multiple filtered nucleic acid sequences to be tested, identify the false positive sequences in the filtered nucleic acid sequences to be tested, and exclude the false positive sequences from the filtered nucleic acid sequences to be tested to obtain the target nucleic acid sequence.

[0155] This application also provides a computer-readable storage medium storing a computer program, the computer program including program instructions, and the method implemented when the program instructions are executed can refer to the methods in the above embodiments of this application.

[0156] The computer-readable storage medium can be the internal memory of the electronic device described in the above embodiments, such as the hard disk or memory of the electronic device. Alternatively, the computer-readable storage medium can be an external storage device of the electronic device, such as a plug-in hard disk, smart media card (SMC), secure digital (SD) card, flash card, etc., equipped on the electronic device.

[0157] In some embodiments, the computer-readable storage medium may include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application program required for at least one function, etc.; and the data storage area may store data created based on the use of the electronic device, etc.

[0158] In the above embodiments, the descriptions of each embodiment have different focuses. For parts that are not described in detail or recorded in a certain embodiment, please refer to the relevant descriptions of other embodiments.

[0159] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0160] In the embodiments provided in this application, it should be understood that the disclosed devices / terminal equipment and methods can be implemented in other ways. For example, the device / terminal equipment embodiments described above are merely illustrative. For instance, the division of modules or units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the displayed or discussed mutual coupling or direct coupling or communication connection may be through some interfaces; the indirect coupling or communication connection between devices or units may be electrical, mechanical, or other forms.

[0161] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0162] The above-described embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application, and should all be included within the protection scope of this application.

Claims

1. A method for determining nucleic acid sequences based on a Bloom filter, characterized in that, The method includes: Construct initial Bloom filters corresponding to multiple target nucleic acid sequences; The plurality of target nucleic acid sequences are stored in the initial Bloom filter to obtain the target filter corresponding to the plurality of target nucleic acid sequences; The target filter is used to filter out non-target nucleic acid sequences from multiple nucleic acid sequences to be tested; False positive detection is performed on the multiple filtered nucleic acid sequences to be tested to identify false positive sequences in the filtered nucleic acid sequences to be tested, and the false positive sequences are excluded from the filtered nucleic acid sequences to be tested to obtain the target nucleic acid sequence.

2. The nucleic acid sequence determination method based on a Bloom filter according to claim 1, characterized in that, The initial Bloom filter includes an array where all elements are first preset values. Storing the plurality of target nucleic acid sequences into the initial Bloom filter includes: storing each target nucleic acid sequence in the plurality of target nucleic acid sequences into the initial Bloom filter, including: The number of hash rounds corresponding to the initial Bloom filter is determined, and the target nucleic acid sequence is hashed according to the determined number of hash rounds to obtain the target hash value for each hash operation. Based on the target hash value of each hash operation, the target position in the array of the initial Bloom filter is determined, and the element in the initial Bloom filter located at the target position is updated to a second preset value.

3. The nucleic acid sequence determination method based on a Bloom filter according to claim 1, characterized in that, The filtering of non-target nucleic acid sequences among multiple test nucleic acid sequences based on the target filter includes: determining whether each test nucleic acid sequence among the multiple test nucleic acid sequences is a non-target nucleic acid sequence, including: Determine the corresponding hash round number of the target filter, perform hash operation on the nucleic acid sequence to be tested for the number of hash rounds corresponding to the hash round number, and obtain the hash value to be tested for each hash operation; The position to be tested in the array of the target filter is determined based on the hash value to be tested in each hash operation. If the element at the position to be tested in the target filter is a first preset value, the nucleic acid sequence to be tested is determined to be the non-target nucleic acid sequence.

4. The nucleic acid sequence determination method based on a Bloom filter according to claim 1, characterized in that, The step of performing false positive detection on the filtered multiple nucleic acid sequences to be tested, and identifying false positive sequences among the filtered nucleic acid sequences to be tested, includes: The coverage of each nucleic acid sequence to be tested in the filtered plurality of nucleic acid sequences to be tested is determined, and the nucleic acid sequences to be tested with a coverage of less than a preset coverage threshold are regarded as false positive sequences.

5. A method for determining nucleic acid sequences based on a Bloom filter, characterized in that, The method includes: Construct initial counting Bloom filters corresponding to multiple target nucleic acid sequences in a pre-defined version; The preset version of multiple target nucleic acid sequences is stored in the initial counting Bloom filter to obtain the target counting filter corresponding to the preset version of multiple target nucleic acid sequences; The target counting filter filters out non-preset versions of target nucleic acid sequences from multiple nucleic acid sequences to be tested; False positive detection is performed on multiple filtered nucleic acid sequences to be tested to identify false positive sequences in the filtered nucleic acid sequences to be tested, and the false positive sequences are excluded from the filtered nucleic acid sequences to be tested to obtain the target nucleic acid sequence of the preset version.

6. The nucleic acid sequence determination method based on a Bloom filter according to claim 5, characterized in that, The initial counting Bloom filter corresponding to the multiple target nucleic acid sequences in the pre-defined version includes: Based on the preset false positive rate and the total number of multiple target nucleic acid sequences in the preset version, the array length and hash rounds of the initial counting Bloom filter are calculated, and the initial counting Bloom filter is constructed based on the array length and hash rounds.

7. The nucleic acid sequence determination method based on a Bloom filter according to claim 5, characterized in that, The initial counting Bloom filter includes an array where all elements are first preset values. Storing the multiple target nucleic acid sequences of the preset versions into the initial counting Bloom filter includes: storing each preset version of the target nucleic acid sequence from the multiple preset versions into the initial counting Bloom filter, including: The number of hash rounds corresponding to the initial counting Bloom filter is determined, and a hash operation is performed on the target nucleic acid sequence of the preset version according to the determined number of hash rounds to obtain the target hash value for each hash operation. Based on the target hash value of each hash operation, determine the target position in the array of the initial counting Bloom filter, and update the element at the target position in the initial counting Bloom filter, including: If the hash operation is the first hash operation, the element located at the target position in the initial counting Bloom filter is updated to the second preset value; If the hash operation is not the first hash operation, the element at the target position is updated based on the sum of the element at the target position and the second preset value after the previous hash operation.

8. The nucleic acid sequence determination method based on a Bloom filter according to claim 5, characterized in that, The plurality of nucleic acid sequences to be tested includes multiple target nucleic acid sequences of different versions from the preset version. The filtering of non-preset versions of target nucleic acid sequences among the plurality of nucleic acid sequences based on the target counting filter includes: determining whether each nucleic acid sequence to be tested in the plurality of nucleic acid sequences is a non-preset version of the target nucleic acid sequence, including: The number of hash rounds corresponding to the initial counting Bloom filter is determined, and the hash operation is performed on the nucleic acid sequence to be tested according to the determined number of hash rounds to obtain the hash value of the test for each hash operation. The position to be tested in the array of the target counting filter is determined based on the hash value to be tested in each hash operation. If the element in the target counting filter located at the position to be tested is a first preset value, the nucleic acid sequence to be tested is determined to be the non-preset version of the target nucleic acid sequence.

9. The nucleic acid sequence determination method based on a Bloom filter according to claim 8, characterized in that, The step of performing false positive detection on multiple filtered nucleic acid sequences to be tested, and identifying false positive sequences among the filtered nucleic acid sequences to be tested, includes: Based on the removability of the target counting filter, a preset deletion operation is performed on the target counting filter according to each of the multiple nucleic acid sequences to be tested after filtering; Determine the position of the negative value corresponding to the negative value element in the array of the target counting filter after the preset deletion operation is performed; The negative value position is used to determine the false positive sequence among the filtered multiple nucleic acid sequences to be tested.

10. An electronic device, characterized in that, The electronic device includes a processor and a memory, the processor being configured to execute a computer program stored in the memory to implement the nucleic acid sequence determination method based on a Bloom filter as described in any one of claims 1 to 9.