A python-based high-throughput sequencing sequence intelligent analysis method

CN122551893APending Publication Date: 2026-08-11HEBEI AGRICULTURAL UNIV.
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-04-13
Publication Date
2026-08-11

AI Technical Summary

Technical Problem

[0002]高通量测序技术的普及产生了海量测序数据,但序列分析流程仍存在诸多痛点:传统方法依赖多工具手动拼接,各环节参数需人工调整,操作繁琐且重复性差;序列比对与变异检测多采用单一算法,难以兼顾效率与准确性,尤其针对向日葵等特定植物的测序数据缺乏针对性适配;分析结果缺乏标准化注释与可视化输出,临床转化及农业生产应用(如向日葵病害检测)难度大

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122551893A_ABST
    Figure CN122551893A_ABST
Patent Text Reader

Abstract

This invention discloses a high-throughput sequencing sequence intelligent analysis method based on Python. This method automates the analysis of sequencing data using Python code, enabling rapid identification of viral sequences and discovery of new viruses or hosts from high-throughput sequencing results. It is applicable to plant virus detection fields such as high-throughput data analysis, genetic variation analysis, and microbiome research. The core program is developed based on Python, integrating bioinformatics tools such as minimap2, samtools, and BLAST. It optimizes memory adaptation logic and analysis workflow, allowing for efficient operation in an 8GB RAM virtual machine environment, significantly shortening the analysis cycle and solving the problems of fragmented workflows, reliance on manual parameter adjustment, and high false positive rates in traditional analyses.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of high-throughput sequencing technology, specifically relating to a Python-based intelligent analysis method for high-throughput sequencing sequences. Background Technology

[0002] The widespread adoption of high-throughput sequencing technology has generated massive amounts of sequencing data, but the sequence analysis process still has many pain points: traditional methods rely on manual assembly using multiple tools, and parameters at each stage need to be manually adjusted, making the operation cumbersome and with poor repeatability; sequence alignment and variant detection often use a single algorithm, making it difficult to balance efficiency and accuracy, especially for sequencing data of specific plants such as sunflowers, which lacks targeted adaptation; the analysis results lack standardized annotation and visualization output, making clinical translation and agricultural production applications (such as sunflower disease detection) difficult.

[0003] The existing high-throughput sequencing has the following disadvantages and deficiencies: (1) Fragmented process: Traditional methods require manual execution of each step, parameter adjustment depends on professional skills, poor repeatability and easy to make mistakes; (2) High resource dependence: Conventional analysis tools have large memory consumption, and memory shortage is easy to occur in low-configuration virtual machine environments such as 8GB RAM, making it impossible to complete index construction and sequence alignment; (3) Low efficiency: Sequence assembly steps must be performed, and the analysis cycle is as long as 8-10 hours, which is difficult to meet the needs of rapid detection; (4) Insufficient flexibility: Poor adaptability, making it difficult to adjust the process and parameters according to the characteristics of sequencing data (such as read length, platform) and analysis needs (such as rapid screening, new virus discovery); (5) Complex result interpretation: Lack of standardized report output, requiring manual sorting of analysis results, which is not conducive to the rapid identification of new viruses / new hosts. Summary of the Invention

[0004] The purpose of this invention is to provide a high-throughput sequencing sequence intelligent analysis method based on Python.

[0005] A high-throughput sequencing sequence intelligent analysis method based on Python includes the following steps: (1) Environment and data preparation: Deploy a Linux virtual machine environment, install Python3 and minimap2, samtools, and BLAST tools; download the plant reference genome and plant virus database from NCBI, and prepare clean reads sequencing data after pre-quality control; (2) Parameter configuration: The sequencing data path, reference sequence and virus database path, output directory and number of threads can be configured through Python scripts, and the alignment and BLAST screening parameters can be adjusted according to the analysis scenario; (3) File verification: Run the built-in Python script module to check the existence of input data and file size; (4) Reference sequence index construction: The index is constructed using two sets of parameters based on the minimap2 tool. In normal scenarios, k=15 and w=10 parameters are used. In low memory scenarios, k=13, w=5 and -H parameters are automatically switched. It supports skipping existing index files. (5) Sequence alignment: The minimap2 tool was used to align clean reads with the sunflower reference genome. It supports two modes: "index alignment" and "direct FASTA alignment". The alignment parameters are adapted to short read data. (6) Extraction of unaligned sequences: The samtools tool was used to extract sequences that were not aligned to the sunflower reference genome and converted them to FASTQ format; (7) BLAST analysis: The unaligned sequences were converted into FASTA format and compared with the plant virus database for homology. The results were filtered using parameters e-value=1e-10, perc_identity=70%, and max_target_seqs=5. (8) Result classification and report generation: Sort and classify the BLAST results by bitscore, and generate CSV summary and structured HTML report; (9) Process trimming: Supports selectively skipping SPAdes sequence assembly steps.

[0006] The plant reference genome is the sunflower reference genome.

[0007] The Linux virtual machine environment is configured as follows: 8GB RAM + 31GB swap.

[0008] The clean reads sequencing data are in .fq format.

[0009] The memory uses an adaptive optimization mechanism, including dual-set index construction parameters, dual-mode comparison strategy, and swap expansion anomaly alerts, to adapt to low-configuration environments with 8GB RAM.

[0010] In the process trimming described in step (9), the rapid screening scenario skips the SPAdes assembly to shorten the analysis time by 3-4 hours, while the new virus verification scenario retains this step to obtain a complete virus contig.

[0011] The rules for classifying the results in step (8) are as follows: similarity ≥ 90% is determined to be a known virus, 70%-90% is determined to be a related virus, and < 70% is determined to be a potential new virus.

[0012] The beneficial effects of this invention are as follows: The method significantly improves efficiency, allowing for the skipping of the SPAdes assembly step, reducing analysis time from 8-10 hours using traditional methods to 3-4 hours, an efficiency improvement of over 50%; the entire process is automated, requiring no manual intervention and reducing operational time costs. It is adaptable to low-configuration environments: through a memory adaptive optimization mechanism, it can run stably in an 8GB RAM virtual machine environment, solving the problem of high resource dependence in traditional tools and reducing hardware costs. It offers high detection accuracy: optimized BLAST parameters (e-value=1e-10, perc_identity=70%) improve specificity and sensitivity. It offers strong flexibility and scalability: it supports parameter adjustment based on sequencing data characteristics (read length, platform) and analytical needs (rapid screening, new virus discovery), and the reference sequence library can be updated and iterated with plant varieties. It has a low operational threshold: analysis can be started with a single click by configuring only basic path parameters; standardized reports reduce the difficulty of result interpretation; and no professional bioinformatics skills are required to operate it. Attached Figure Description

[0013] Figure 1 This is a schematic diagram of the method flow of the present invention. Detailed Implementation

[0014] To facilitate understanding of the present invention, a more comprehensive description will be given below. However, the present invention can be implemented in many different forms and is not limited to the embodiments described herein. Rather, these embodiments are provided to provide a thorough and complete understanding of the disclosure of the present invention. Example 1

[0015] A high-throughput sequencing sequence intelligent analysis method based on Python includes the following steps: (1) Environment and data preparation: Deploy a Linux virtual machine environment (Linux CentOS 7 virtual machine, 8GB RAM, 31GB swap, 80GB disk space), software environment: Python 3.8, minimap2 2.24, samtools 1.17, BLAST 2.14.0, seqtk 1.4; install Python 3 and minimap2, samtools, BLAST tools; download the sunflower reference genome from NCBIRefSeq, download the virus database from NCBI viral.1.1.genomic.fna, and prepare clean reads sequencing data (.fq format) after quality control in advance; (2) Parameter configuration: The sequencing data path, reference sequence and virus database path, output directory and number of threads are configured through Python scripts. It supports adjusting the alignment and BLAST screening parameters according to the analysis scenario. The sunflower sequencing data are clean reads generated by the Illumina platform. The R1 file path is / root / plant_virus / data / H_R1.clean.fq (3.6GB) and the R2 file path is / root / plant_virus / data / H_R2.clean.fq (3.6GB). The core parameters are: THREADS=4, minimap2 alignment parameters (-x sr, -k 15, -w 10, --secondary=no), BLAST parameters (e-value=1e-10, perc_identity=70%, max_target_seqs=5), and SPAdes assembly is skipped. (3) File verification: Run the built-in Python script module to check the existence of input data and file size; (4) Reference sequence index construction: The index is constructed using two sets of parameters based on the minimap2 tool. In normal scenarios, k=15 and w=10 parameters are used. In low memory scenarios, k=13, w=5 and -H parameters are automatically switched. It supports skipping existing index files. The memory adopts an adaptive optimization mechanism, including two sets of index construction parameters, dual-mode comparison strategy and swap expansion anomaly prompt, to adapt to low configuration environment with 8GB RAM. (5) Sequence alignment: The minimap2 tool was used to align clean reads with the sunflower reference genome. It supports two modes: "index alignment" and "direct FASTA alignment". The alignment parameters are adapted to short read data. (6) Extraction of unaligned sequences: The samtools tool was used to extract sequences that were not aligned to the sunflower reference genome and converted them to FASTQ format; (7) BLAST analysis: The unaligned sequences were converted into FASTA format and compared with the plant virus database for homology. The results were filtered using parameters e-value=1e-10, perc_identity=70%, and max_target_seqs=5. (8) Result classification and report generation: Sort and classify the BLAST results by bitscore, and generate CSV summary and structured HTML report; The rules for result classification are: similarity ≥90% is judged as known virus, 70%-90% is judged as related virus, and <70% is judged as potential new virus; (9) Process trimming: Supports selectively skipping the SPAdes sequence assembly step; in the process trimming, the rapid screening scenario skips the SPAdes assembly to shorten the analysis time by 3-4 hours, while the new virus verification scenario retains this step to obtain the complete virus contig. Example 2

[0016] A high-throughput sequencing sequence intelligent analysis method based on Python includes the following steps: (1) Environment and data preparation: Deploy a Linux virtual machine environment (8GB RAM + 31GB swap), install Python3 and minimap2, samtools, and BLAST tools; download the sunflower reference genome and plant virus database from NCBI, and prepare clean reads sequencing data (.fq format) after pre-quality control; execute the dependency installation commands (yum install python3 python3-pip -y; conda install -c bioconda minimap2samtools blast seqtk -y), configure swap space (fallocate -l 31G / swapfile && chmod600 / swapfile && mkswap / swapfile && swapon / swapfile); download the sunflower reference genome and virus database using the wget command, decompress it and store it in the specified directory; (2) Parameter configuration: Configure the sequencing data path, reference sequence and virus database path, output directory and number of threads through Python scripts. It supports adjusting the alignment and BLAST screening parameters according to the analysis scenario. Modify the "Configuration Section" in the Python script to set the CLEAN_R1, CLEAN_R2, REFERENCE, VIRUS_DB, RESULTS and THREADS parameters. (3) File verification: Run the built-in module of the Python script to check the existence and file size of the input data; grant the script execution permission (chmod +x sunflower_virus_detection.py) and run the script (python3sunflower_virus_detection.py); the script automatically checks the existence of the input file and outputs the size of each file (e.g., sunflower reference genome 2.84GB, virus database 0.5GB). (4) Reference sequence index construction: The index is constructed using a dual set of parameters based on the minimap2 tool. In normal scenarios, k=15 and w=10 parameters are used. In low memory scenarios, k=13, w=5 and -H parameters are automatically switched, and existing index files can be skipped. The memory is optimized using an adaptive mechanism, including dual set of index construction parameters, dual-mode comparison strategy and swap expansion anomaly prompt, to adapt to low configuration environments with 8GB RAM. The reference sequence index is constructed using the default parameters (k=15, w=10), which takes 1 hour and 15 minutes. (5) Sequence alignment: The minimap2 tool was used to align clean reads with the sunflower reference genome. It supports two modes: "index alignment" and "direct FASTA alignment". The alignment parameters are adapted to short read data. The minimap2 alignment was performed with a total of 10,000,000 reads, 8,500,000 mapped reads, an alignment rate of 85.0%, and a time of 1 hour and 20 minutes. (6) Extraction of unaligned sequences: Use samtools to extract sequences that are not aligned to the sunflower reference genome and convert them to FASTQ format; extract unaligned reads into unmapped_R1.fastq (50MB) and unmapped_R2.fastq (50MB); (7) BLAST analysis: Convert the unaligned sequences to FASTA format, compare them with the plant virus database for homology, and filter the results using parameters e-value=1e-10, perc_identity=70%, and max_target_seqs=5; construct the virus database index, and perform BLAST on the unaligned sequences, which takes 30 minutes. (8) Result grading and report generation: Sort and grade the BLAST results by bitscore, and generate CSV summary and structured HTML report; The result grading rules are: similarity ≥90% is judged as known virus, 70%-90% is judged as related virus, and <70% is judged as potential new virus; In the results, the E-value is as low as 6.97e-73 and the bitscore is 278, which is judged as a high-confidence known sunflower virus infection; (9) Workflow trimming: Supports selectively skipping the SPAdes sequence assembly step; In the workflow trimming, the rapid screening scenario skips the SPAdes assembly to shorten the analysis time by 3-4 hours, while the new virus verification scenario retains this step to obtain a complete virus contig; Automatically generates structured reports, including the time spent on each step, the comparison rate, virus matching details, grading conclusions, and PCR verification suggestions.

[0017] The embodiments described above are merely illustrative of several implementations of the present invention, and while the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the invention patent. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of the present invention, and these all fall within the protection scope of the present invention. Therefore, the protection scope of this invention patent should be determined by the appended claims.

Claims

1. A high-throughput sequencing sequence intelligent analysis method based on Python, characterized in that, Includes the following steps: (1) Environment and data preparation: Deploy a Linux virtual machine environment, install Python3 and minimap2, samtools, and BLAST tools; download the plant reference genome and plant virus database from NCBI, and prepare clean reads sequencing data after pre-quality control; (2) Parameter configuration: The sequencing data path, reference sequence and virus database path, output directory and number of threads can be configured through Python scripts, and the alignment and BLAST screening parameters can be adjusted according to the analysis scenario; (3) File verification: Run the built-in Python script module to check the existence of input data and file size; (4) Reference sequence index construction: The index is constructed using two sets of parameters based on the minimap2 tool. In normal scenarios, k=15 and w=10 parameters are used. In low memory scenarios, k=13, w=5 and -H parameters are automatically switched. It supports skipping existing index files. (5) Sequence alignment: The minimap2 tool was used to align clean reads with the sunflower reference genome. It supports two modes: "index alignment" and "direct FASTA alignment". The alignment parameters are adapted to short read data. (6) Extraction of unaligned sequences: The samtools tool was used to extract sequences that were not aligned to the sunflower reference genome and converted them to FASTQ format; (7) BLAST analysis: The unaligned sequences were converted into FASTA format and compared with the plant virus database for homology. The results were filtered using parameters e-value=1e-10, perc_identity=70%, and max_target_seqs=5. (8) Result classification and report generation: Sort and classify the BLAST results by bitscore, and generate CSV summary and structured HTML report; (9) Process trimming: Supports selectively skipping SPAdes sequence assembly steps.

2. The high-throughput sequencing sequence intelligent analysis method based on Python according to claim 1, characterized in that, The plant reference genome is the sunflower reference genome.

3. The high-throughput sequencing sequence intelligent analysis method based on Python according to claim 1, characterized in that, The Linux virtual machine environment is configured as follows: 8GB RAM + 31GB swap.

4. The high-throughput sequencing sequence intelligent analysis method based on Python according to claim 1, characterized in that, The clean reads sequencing data are in .fq format.

5. The high-throughput sequencing sequence intelligent analysis method based on Python according to claim 1, characterized in that, The memory uses an adaptive optimization mechanism, including dual-set index construction parameters, dual-mode comparison strategy, and swap expansion anomaly alerts, to adapt to low-configuration environments with 8GB RAM.

6. The high-throughput sequencing sequence intelligent analysis method based on Python according to claim 1, characterized in that, In the process trimming described in step (9), the rapid screening scenario skips the SPAdes assembly to shorten the analysis time by 3-4 hours, while the new virus verification scenario retains this step to obtain a complete virus contig.

7. The high-throughput sequencing sequence intelligent analysis method based on Python according to claim 1, characterized in that, The rules for classifying the results in step (8) are as follows: similarity ≥ 90% is determined to be a known virus, 70%-90% is determined to be a related virus, and < 70% is determined to be a potential new virus.