CRANE: Correcting Errors in Raw Nanopore Signals Using Hidden Markov Models
Organizations: University of Maryland · ETH Zurich · Bilkent University
Abstract
Nanopore sequencing can read substantially longer sequences of nucleic acid molecules, called reads, than other sequencing methods, which has led to advances in genomic analysis such as the gapless human genome assembly. By analyzing the raw electrical signal reads that nanopore sequencing generates from molecules, existing works can map these reads without translating them into DNA characters (i.e., basecalling), allowing for quick and efficient analysis of sequencing data. However, raw signals often contain errors due to noise and processing errors, which limits the overall accuracy of raw signal analysis. Our goal in this work is to detect and correct errors in raw signals to improve the accuracy of raw signal analyses. To this end, we propose CRANE, a mechanism that trains and utilizes a Hidden Markov Model (HMM) to accurately correct signal errors. Our extensive evaluation on various datasets shows that CRANE 1) consistently improves the overall accuracy of the underlying raw signal analysis tools, 2) minimizes the burden of optimizing analysis pipelines for newer nanopore technologies, and 3) does not introduce substantial computational overhead. We conclude that CRANE provides an effective mechanism to systematically identify and correct the errors in raw nanopore signals before further analysis, which can enable the development of a new class of error correction mechanisms purely designed for raw nanopore signals. Source Code: CRANE is available at https://github.com/STORMgroup/CRANE. We also provide the scripts to fully reproduce our results on our GitHub page
Figures & tables
| Organism | Chemistry | Flow Cell | Reads | Avg. Length | Basecaller | Data Source | |
| D0 | E. coli CFT073 | R10.4.1 e8.2 | FLO-MIN114 | 12,000 | 794 | Dorado SUP v1.4.0 | [ 81 ] |
| D1 | E. coli CFT073 | R10.4.1 e8.2 | FLO-MIN114 | 10,000 | 764 | Dorado SUP v1.4.0 | [ 81 ] |
| D2 | D. melanogaster | R10.4.1 e8.2 | FLO-MIN114 | 10,000 | 5,998 | Dorado SUP v0.9.2 | [ 82 ] |
| D3 | H. sapiens (HG002) | R10.4.1 e8.2 | FLO-PRO114M | 10,000 | 16,943 | Dorado SUP v1.4.0 | [ 83 ] |
| All datasets use R10.4.1 e8.2 nanopore chemistry at 400 bases/sec translocation speed. | |||||||
| D0, D1 and D3 are sampled at 5,000 Hz; D2 at 4,000 Hz. | |||||||
| Segmentation | Parameter | CRANE | CRANE-H |
| Scrappie (R9.4) | HMM States | 128 | 16 |
| 0.3 | 0.2 | ||
| 0.02 | 0 | ||
| Scrappie (R10.4.1) | HMM States | 128 | 16 |
| 0.05 | 0.01 | ||
| 0.02 | 0 |
| Dataset | Segmentation | Baseline | CRANE |
| D1 ( E. coli ) | Scrappie (R9.4) | 0.177 | 0.726 |
| Scrappie (R10.4.1) | 0.611 | 0.652 | |
| Campolina | 0.810 | 0.821 | |
| D2 (Fruit Fly) | Scrappie (R9.4) | 0.321 | 0.840 |
| Scrappie (R10.4.1) | 0.744 | 0.758 | |
| Campolina | 0.858 | 0.862 |
| Dataset | Segmentation | Baseline + HPC | CRANE-H + HPC |
| D1 ( E. coli ) | Scrappie (R9.4) | 0.697 | 0.823 |
| Scrappie (R10.4.1) | 0.776 | 0.797 | |
| Campolina | 0.876 | 0.885 | |
| D2 (Fruit Fly) | Scrappie (R9.4) | 0.798 | 0.883 |
| Scrappie (R10.4.1) | 0.834 | 0.846 | |
| Campolina | 0.882 | 0.892 |
| Dataset | Segmentation | CRANE | CRANE + RH2 | Baseline RH2 |
| D1 (E. coli) | Campolina | 2.99 | 13.03 (22.95%) | 9.75 |
| Scrappie (R9.4) | 8.00 | 18.27 (43.79%) | 14.07 | |
| Scrappie (R10.4.1) | 3.43 | 10.81 (31.73%) | 7.09 | |
| D2 (Fruit Fly) | Campolina | 31.80 | 4,231.24 (0.75%) | 4,248.04 |
| Scrappie (R9.4) | 49.43 | 4,046.91 (1.22%) | 5,719.84 | |
| Scrappie (R10.4.1) | 43.29 | 3,390.91 (1.28%) | 3,312.10 |
| Dataset | Segmentation | CRANE-H | CRANE-H + RH2 | Baseline RH2 |
| D1 (E. coli) | Campolina | 0.27 | 18.84 (1.43%) | 17.79 |
| Scrappie (R9.4) | 0.43 | 20.46 (2.10%) | 20.15 | |
| Scrappie (R10.4.1) | 0.27 | 15.39 (1.75%) | 14.60 | |
| D2 (Fruit Fly) | Campolina | 2.26 | 4,975.73 (0.05%) | 4,931.82 |
| Scrappie (R9.4) | 6.49 | 4,799.88 (0.14%) | 4,640.95 | |
| Scrappie (R10.4.1) | 3.14 | 3,956.69 (0.08%) | 3,831.61 |
| Tool | E. coli | D. melanogaster | H. sapiens |
| Minimap2 | -x map-ont | -x map-ont | -x map-ont |
| Dorado GPU (SUP) | basecaller dna_r10.4.1_e8.2_400bps_sup@ v4.1.0 / 4.1.0 / 5.0.0 | ||
| RawHash2 | -x r10 -w 0 | -x r10 -w 0 | -x r10fast -w 0 |
| Tool | Version | Link to the Source Code |
| RawHash2 | 2.5 | https://github.com/STORMgroup/RawHash2/commit/92366af |
| Minimap2 | 2.24-r1122 | https://github.com/lh3/minimap2/releases/tag/v2.24 |
| Dorado | 0.9.2 | https://github.com/nanoporetech/dorado/releases/tag/v0.9.2 |
| Dorado | 1.4.0 | https://github.com/nanoporetech/dorado/releases/tag/v1.4.0 |
| Uncalled4 | 4.1.0 | https://github.com/skovaka/uncalled4/releases/tag/4.1.0 |
| Dataset | Segmenter | HPC | Corrected | F1 | Precision | Recall | Time to Map (ms) |
| E. coli | Campolina | ✓ | ✓ | 0.885 | 0.993 | 0.799 | 18.57 |
| D. melanogaster | Campolina | ✓ | ✓ | 0.892 | 0.982 | 0.818 | 4,973.47 |
| H. sapiens | Campolina | ✓ | ✓ | 0.882 | 0.982 | 0.800 | 15,351.05 |
| Segmenter | HPC | Corrected | F1 | Precision | Recall | Time to Map (ms) |
| Campolina | ✗ | ✓ | 0.821 | 0.991 | 0.701 | 10.04 |
| Campolina | ✗ | ✗ | 0.810 | 0.987 | 0.687 | 9.75 |
| Campolina | ✓ | ✓ | 0.885 | 0.993 | 0.799 | 18.57 |
| Campolina | ✓ | ✗ | 0.876 | 0.992 | 0.785 | 17.79 |
| Scrappie (R9.4) | ✗ | ✓ | 0.726 | 0.979 | 0.577 | 10.27 |
| Scrappie (R9.4) | ✗ | ✗ | 0.177 | 0.743 | 0.100 | 14.07 |
| Segmenter | HPC | Corrected | F1 | Precision | Recall | Time to Map (ms) |
| Campolina | ✗ | ✓ | 0.862 | 0.974 | 0.773 | 4,199.44 |
| Campolina | ✗ | ✗ | 0.858 | 0.958 | 0.777 | 4,248.04 |
| Campolina | ✓ | ✓ | 0.892 | 0.982 | 0.818 | 4,973.47 |
| Campolina | ✓ | ✗ | 0.882 | 0.982 | 0.801 | 4,931.82 |
| Scrappie (R9.4) | ✗ | ✓ | 0.840 | 0.980 | 0.736 | 3,997.48 |
| Scrappie (R9.4) | ✗ | ✗ | 0.321 | 0.593 | 0.220 | 5,719.84 |
| Segmenter | HPC | Corrected | F1 | Precision | Recall | Time to Map (ms) |
| Campolina | ✗ | ✓ | 0.856 | 0.986 | 0.756 | 17,574.19 |
| Campolina | ✗ | ✗ | 0.853 | 0.985 | 0.752 | 16,791.35 |
| Campolina | ✓ | ✓ | 0.882 | 0.982 | 0.800 | 15,351.05 |
| Campolina | ✓ | ✗ | 0.875 | 0.982 | 0.788 | 14,954.14 |
| Scrappie (R9.4) | ✗ | ✓ | 0.774 | 0.988 | 0.636 | 19,365.81 |
| Scrappie (R9.4) | ✗ | ✗ | 0.001 | 0.006 | 0.001 | 29,062.97 |
| Dataset | Segmenter | Corrected | F1 | Precision | Recall | Time to Map (ms) |
| E. coli | Campolina | ✓ | +0.065 | +0.001 | +0.099 | +8.53 |
| Campolina | ✗ | +0.066 | +0.005 | +0.098 | +8.04 | |
| Scrappie (R9.4) | ✓ | +0.097 | +0.010 | +0.128 | +9.76 | |
| Scrappie (R9.4) | ✗ | +0.521 | +0.231 | +0.443 | +6.08 | |
| Scrappie (R10.4.1) | ✓ | +0.144 | +0.016 | +0.177 | +7.74 | |
| Scrappie (R10.4.1) | ✗ | +0.165 | +0.032 | +0.191 | +7.51 |
| Dataset | Segmenter | HPC | F1 | Precision | Recall | Time to Map (ms) |
| E. coli | Campolina | ✗ | +0.011 | +0.004 | +0.014 | +0.29 |
| Campolina | ✓ | +0.009 | +0.000 | +0.014 | +0.78 | |
| Scrappie (R9.4) | ✗ | +0.550 | +0.236 | +0.477 | -3.80 | |
| Scrappie (R9.4) | ✓ | +0.126 | +0.016 | +0.162 | -0.12 | |
| Scrappie (R10.4.1) | ✗ | +0.041 | +0.017 | +0.042 | +0.29 | |
| Scrappie (R10.4.1) | ✓ | +0.020 | +0.001 | +0.028 | +0.52 |
| Number of States | Baseline | 8 | 16 | 32 | 64 | 96 | 128 | 192 | 256 |
| Scrappie R9 | |||||||||
| Parameter Search Runtime | - | 826 | 691 | 652 | 658 | 644 | 713 | 705 | 839 |
| P(stay) | - | 0.250 | 0.270 | 0.280 | 0.275 | 0.340 | 0.300 | 0.280 | 0.315 |
| P(skip) | - | 0.010 | 0.000 | 0.000 | 0.000 | 0.000 | 0.020 | 0.000 | 0.005 |
| F1 | 0.104 | 0.596 | 0.730 | 0.754 | 0.784 | 0.787 | 0.792 | 0.788 | 0.794 |
| Scrappie R10 | |||||||||
| Number of States | Baseline | 8 | 16 | 32 | 64 | 96 | 128 | 192 | 256 |
| Scrappie R9 | |||||||||
| Parameter Search Runtime | - | 854 | 747 | 897 | 783 | 797 | 893 | 987 | 1024 |
| P(stay) | - | 0.200 | 0.200 | 0.190 | 0.215 | 0.290 | 0.325 | 0.290 | 0.325 |
| P(skip) | - | 0.045 | 0.000 | 0.105 | 0.000 | 0.000 | 0.025 | 0.030 | 0.005 |
| F1 | 0.727 | 0.832 | 0.866 | 0.859 | 0.863 | 0.860 | 0.863 | 0.862 | 0.865 |
| Scrappie R10 | |||||||||
| Number of States | Baseline | 8 | 16 | 32 | 64 | 96 | 128 | 192 | 256 |
| Scrappie R9 (Only Stay Removal) | |||||||||
| Parameter Search Runtime | - | 843 | 724 | 762 | 759 | 668 | 815 | 833 | 920 |
| P(stay) | - | 0.220 | 0.230 | 0.255 | 0.250 | 0.300 | 0.340 | 0.290 | 0.320 |
| P(skip) | - | 0.005 | 0.050 | 0.005 | 0.005 | 0.025 | 0.010 | 0.005 | 0.030 |
| F1 | 0.104 | 0.604 | 0.717 | 0.747 | 0.775 | 0.780 | 0.785 | 0.783 | 0.787 |
| Scrappie R10 (Only Stay Removal) | |||||||||
Genomics
Genomics uses computational and experimental methods to study genomes, genetic variation, gene regulation, and their links to traits and disease.
See all 125 papers