| Literature DB >> 25289699 |
Agnieszka Danek1, Sebastian Deorowicz1, Szymon Grabowski2.
Abstract
The availability of thousands of individual genomes of one species should boost rapid progress in personalized medicine or understanding of the interaction between genotype and phenotype, to name a few applications. A key operation useful in such analyses is aligning sequencing reads against a collection of genomes, which is costly with the use of existing algorithms due to their large memory requirements. We present MuGI, Multiple Genome Index, which reports all occurrences of a given pattern, in exact and approximate matching model, against a collection of thousand(s) genomes. Its unique feature is the small index size, which is customisable. It fits in a standard computer with 16-32 GB, or even 8 GB, of RAM, for the 1000GP collection of 1092 diploid human genomes. The solution is also fast. For example, the exact matching queries (of average length 150 bp) are handled in average time of 39 µs and with up to 3 mismatches in 373 µs on the test PC with the index size of 13.4 GB. For a smaller index, occupying 7.4 GB in memory, the respective times grow to 76 µs and 917 µs. Software is available at http://sun.aei.polsl.pl/mugi under a free license. Data S1 is available at PLOS One online.Entities:
Mesh:
Year: 2014 PMID: 25289699 PMCID: PMC4188820 DOI: 10.1371/journal.pone.0109384
Source DB: PubMed Journal: PLoS One ISSN: 1932-6203 Impact factor: 3.240
Pseudocode of the basic search algorithm.
| Algorithm 1 exactSearch( |
| { |
| 1 |
| 2 |
| 3 |
| 4 ( |
| 5 |
| 6 ( |
| 7 extend( |
Pseudocode of the algorithm extending the found seed in the basic search.
| Algorithm 2 extend( |
| { |
| 1 |
| 2 |
| 3 |
| 4 |
| 5 |
| 6 |
| 7 |
| 8 |
| 9 |
| 10 extend( |
| 11 |
| 12 |
| 13 |
| 14 |
| 15 |
| 16 |
| 17 extend( |
| 18 |
| 19 |
| 20 |
| 21 |
| 22 |
| 23 |
| 24 |
| 25 |
Index sizes.
| Sparsity | Size [GB] | ||||
|
|
|
|
|
| |
| 1 | 24.7 | 26.3 | 27.9 | 29.6 | 31.2 |
| 2 | 15.0 | 15.8 | 16.6 | 17.5 | 18.3 |
| 3 | 11.8 | 12.3 | 12.9 | 13.4 | 14.0 |
| 4 | 10.2 | 10.6 | 11.0 | 11.4 | 11.8 |
| 5 | 9.2 | 9.5 | 9.9 | 10.2 | 10.5 |
| 6 | 8.5 | 8.8 | 9.1 | 9.4 | 9.7 |
| 7 | 8.1 | 8.3 | 8.6 | 8.8 | 9.1 |
| 8 | 7.7 | 7.9 | 8.2 | 8.4 | 8.6 |
| 10 | 7.2 | 7.4 | 7.6 | 7.8 | 8.0 |
| 12 | 6.9 | 7.1 | 7.2 | 7.4 | 7.5 |
| 14 | 6.7 | 6.8 | 7.0 | 7.1 | 7.2 |
| 16 | 6.5 | 6.6 | 6.8 | 6.9 | 7.0 |
Figure 1Average query times vs. index sizes.
Simulated reads were used.
Query times for various variants of indexes for simulated data.
|
|
| size | Max. allowed mismatches | |||||
| [GB] | 0 | 1 | 2 | 3 | 4 | 5 | ||
| 25 | 1 | 24.7 | 214.2 | 450.8 | 699.5 | 971.5 | 1,438.3 | 2,976.8 |
| 25 | 3 | 11.8 | 225.0 | 481.2 | 751.6 | 1,024.3 | 1,599.9 | 3,647.1 |
| 25 | 4 | 10.2 | 229.8 | 493.1 | 754.0 | 1,050.9 | 1,676.4 | 4,004.2 |
| 25 | 8 | 7.7 | 243.1 | 528.3 | 814.6 | 1,158.5 | 2,341.4 | 6,790.4 |
| 25 | 12 | 6.9 | 257.2 | 558.3 | 868.0 | 1,337.8 | ||
| 25 | 16 | 6.5 | 268.8 | 588.6 | 916.6 | 1,787.9 | ||
| 30 | 1 | 26.3 | 85.4 | 193.4 | 303.0 | 456.0 | 1,036.4 | 3,004.6 |
| 30 | 3 | 12.3 | 95.7 | 220.8 | 340.6 | 520.4 | 1,258.0 | 3,716.2 |
| 30 | 4 | 10.6 | 100.4 | 227.8 | 351.5 | 544.0 | 1,376.5 | 4,104.5 |
| 30 | 8 | 7.9 | 121.8 | 267.0 | 414.5 | 713.6 | 2,215.2 | 6,994.5 |
| 30 | 12 | 7.1 | 134.0 | 291.4 | 456.4 | 959.4 | ||
| 30 | 16 | 6.6 | 149.2 | 319.3 | 506.8 | 1,490.4 | ||
| 35 | 1 | 27.9 | 41.4 | 98.0 | 152.0 | 301.8 | 1,033.4 | 3,114.6 |
| 35 | 3 | 12.9 | 53.6 | 121.2 | 193.0 | 380.4 | 1,280.8 | 3,861.2 |
| 35 | 4 | 11.0 | 58.6 | 130.2 | 206.3 | 419.2 | 1,411.7 | 4,277.6 |
| 35 | 8 | 8.2 | 77.2 | 166.1 | 260.3 | 608.3 | 2,224.4 | 7,120.4 |
| 35 | 12 | 7.2 | 93.3 | 196.2 | 314.6 | 905.3 | ||
| 35 | 16 | 6.8 | 107.0 | 222.2 | 382.4 | 1,506.4 | ||
| 40 | 1 | 29.6 | 28.8 | 65.2 | 102.3 | 291.0 | 1,109.9 | 3,348.8 |
| 40 | 3 | 13.4 | 39.4 | 85.5 | 136.1 | 372.5 | 1,334.0 | 4,021.0 |
| 40 | 4 | 11.4 | 43.4 | 94.4 | 151.4 | 412.2 | 1,471.1 | 4,461.1 |
| 40 | 8 | 8.4 | 61.0 | 128.9 | 210.3 | 615.4 | 2,297.9 | 7,350.3 |
| 40 | 12 | 7.4 | 76.3 | 160.0 | 271.8 | 917.0 | ||
| 40 | 16 | 6.9 | 90.4 | 184.4 | 344.3 | 1,514.1 | ||
| 45 | 2 | 18.3 | 25.9 | 56.2 | 97.9 | 329.6 | 1,207.0 | 3,687.2 |
| 45 | 3 | 14.0 | 31.3 | 67.7 | 116.5 | 375.5 | 1,353.3 | 4,115.0 |
| 45 | 4 | 11.8 | 36.3 | 77.2 | 132.6 | 421.2 | 1,490.9 | 4,525.3 |
| 45 | 8 | 8.6 | 54.2 | 112.4 | 196.2 | 625.8 | 2,394.4 | 7,523.9 |
| 45 | 12 | 7.5 | 70.4 | 142.9 | 262.5 | 942.0 | ||
| 45 | 16 | 7.0 | 82.1 | 168.4 | 342.3 | 1,531.9 | ||
| GEM mapper | 5.0 | 24.0 | 50.6 | 64.9 | 86.4 | 131.0 | 217.3 | |
All times in µs. We do not provide times for large sparsities and more errors than 3, since in such cases the internal queries would be for very short sequences and in turn result in numerous matches and significant times; thus, we do not recommend to use MuGI in such parameter configurations.
Figure 2Query time percentiles for exact and approximate matching, for max error up to 5.
For example, the 80th percentile for 1 error equal to 0.52 ms means that 80% of the test patterns were handled in time up to 0.52 ms each, allowing for 1 mismatch. Simulated reads were used.
Query times for simulated data for = 40 and sparsity = 3 (size 13.4 GB).
| Percentile | Max. allowed mismatches | |||||
| 0 | 1 | 2 | 3 | 4 | 5 | |
| 10% | 12.4 | 27.7 | 44.0 | 62.1 | 81.1 | 100.0 |
| 25% | 15.4 | 32.2 | 50.3 | 69.9 | 90.7 | 111.8 |
| 50% | 18.7 | 38.3 | 58.8 | 81.4 | 105.8 | 131.4 |
| 75% | 23.8 | 48.5 | 73.5 | 103.7 | 141.9 | 199.5 |
| 90% | 35.9 | 76.5 | 116.0 | 188.0 | 707.0 | 3,747.5 |
| 95% | 57.0 | 112.7 | 182.9 | 718.1 | 4,972.8 | 17,619.4 |
| average | 39.4 | 85.5 | 136.1 | 372.5 | 1,334.0 | 4,021.0 |
All times in µs.
Query times for various variants of indexes for real data.
|
|
| size | Max. allowed mismatches | ||||
| [GB] | 0 | 1 | 2 | 3 | 4 | ||
| 25 | 1 | 24.7 | 214.1 | 483.2 | 741.6 | 1,123.3 | 3,566.8 |
| 25 | 3 | 11.8 | 227.6 | 509.4 | 791.1 | 1,271.6 | 4,575.3 |
| 25 | 4 | 10.2 | 238.8 | 520.9 | 795.0 | 1,375.8 | 5,134.4 |
| 25 | 8 | 7.7 | 259.1 | 569.2 | 865.3 | 2,180.1 | 9,634.0 |
| 25 | 12 | 6.9 | 282.0 | 605.6 | 960.4 | 4,052.4 | |
| 25 | 16 | 6.5 | 292.6 | 644.0 | 1,264.0 | 9,888.8 | |
| 30 | 1 | 26.3 | 93.9 | 206.2 | 342.4 | 938.8 | 3,652.4 |
| 30 | 3 | 12.3 | 105.8 | 234.5 | 384.8 | 1,191.8 | 4,691.9 |
| 30 | 4 | 10.6 | 111.2 | 241.7 | 386.8 | 1,310.5 | 5,310.1 |
| 30 | 8 | 7.9 | 131.3 | 283.9 | 485.4 | 2,183.5 | 9,862.3 |
| 30 | 12 | 7.1 | 149.2 | 316.0 | 674.2 | 4,075.0 | |
| 30 | 16 | 6.6 | 161.1 | 343.7 | 1,051.7 | 10,128.0 | |
| 35 | 1 | 27.9 | 51.5 | 109.5 | 200.2 | 977.1 | 3,782.0 |
| 35 | 3 | 12.9 | 62.6 | 132.4 | 255.7 | 1,267.1 | 5,224.2 |
| 35 | 4 | 11.0 | 75.2 | 156.7 | 307.5 | 1,491.0 | 5,977.3 |
| 35 | 8 | 8.2 | 94.3 | 193.3 | 463.7 | 2,434.8 | 9,893.8 |
| 35 | 12 | 7.2 | 98.9 | 206.7 | 630.0 | 4,099.5 | |
| 35 | 16 | 6.8 | 113.2 | 230.7 | 1,018.4 | 10,267.9 | |
| 40 | 1 | 29.6 | 34.1 | 68.1 | 191.4 | 1,004.6 | 3,793.7 |
| 40 | 3 | 13.4 | 43.3 | 90.6 | 250.3 | 1,248.2 | 4,878.4 |
| 40 | 4 | 11.4 | 49.3 | 100.2 | 280.1 | 1,375.3 | 5,491.2 |
| 40 | 8 | 8.4 | 67.2 | 134.4 | 426.2 | 2,282.5 | 10,236.1 |
| 40 | 12 | 7.4 | 80.7 | 165.3 | 645.2 | 4,240.8 | |
| 40 | 16 | 6.9 | 95.1 | 193.3 | 1,055.9 | 10,497.4 | |
| 45 | 2 | 18.3 | 30.0 | 61.3 | 219.2 | 1,116.7 | 4,327.8 |
| 45 | 3 | 14.0 | 35.5 | 72.7 | 259.0 | 1,281.7 | 4,988.0 |
| 45 | 4 | 11.8 | 40.7 | 82.2 | 283.5 | 1,401.1 | 5,598.8 |
| 45 | 8 | 8.6 | 58.3 | 118.4 | 432.1 | 2,320.6 | 10,420.5 |
| 45 | 12 | 7.5 | 73.4 | 149.9 | 657.3 | 4,289.5 | |
| 45 | 16 | 7.0 | 86.4 | 182.4 | 1,072.4 | 10,647.0 | |
| GEM mapper | 5.0 | 22.1 | 56.5 | 78.5 | 126.2 | 221.6 | |
All times in µs. We do not provide times for large sparsities and more errors than 3, since in such cases the internal queries would be for very short sequences and in turn result in numerous matches and significant times; thus, we do not recommend to use MuGI in such parameter configurations.
Comparison of MuGI and JST on simulated and real data, both over 1092 individual sequences of chr1.
| Algorithm | Max. allowed mismatches | RAM usage | |||||
| 0 | 1 | 2 | 3 | 4 | 5 | [GB] | |
|
| |||||||
| JST-Horspool | 8.0 s | — | — | — | — | — | 2.58 |
| JST-Myers | 22.5 s | 24.0 s | 23.9 s | 24.3 s | 24.5 s | 24.9 s | 2.58 |
| MuGI, | 8.2 | 14.8 | 22.7 | 33.6 | 69.6 | 176.0 | 1.84 |
| MuGI, | 10.7 | 21.7 | 32.4 | 47.9 | 90.7 | 239.0 | 0.98 |
|
| |||||||
| JST-Horspool | 6.9 s | — | — | — | — | — | 2.58 |
| JST-Myers | 18.4 s | 19.1 s | 19.2 s | 20.0 s | 20.3 s | 20.3 s | 2.58 |
| MuGI, | 7.6 | 14.3 | 22.1 | 53.4 | 172.3 | 476.5 | 1.84 |
| MuGI, | 12.3 | 23.1 | 35.3 | 72.0 | 238.2 | 617.9 | 0.98 |
MuGI was executed for parameters = 30 and sparsities: 1 (index size 2.0 GB), 3 (index size 1.0 GB). Results for JST are averages from only 100 queries due to very long running times. JST times include block generation (blocks of 100K SNPs were used), but in our experiments they are at least an order of magnitude lower than pattern searching. JST-Horspool uses the Boyer–Moore–Horspool exact matching algorithm, while JST-Myers uses Myers' bit-parallel approximate matching algorithm, handling the Levenshtein distance (-differences). The JST index size was 468 MB, in addition to the 253 MB of the reference sequence. Note its memory use during the search is significantly higher than the index size and depends on the block size (e.g., its memory use grows to about 13 GB with blocks of 1 M SNPs).
Sizes of the index components.
|
|
| REF | VD | BV |
|
|
|
| Total |
| 25 | 1 | 1,548 | 698 | 2,704 | 11,502 | 8,021 | 84 | 123 | 24,680 |
| 25 | 3 | 1,548 | 698 | 2,704 | 3,879 | 2,731 | 84 | 123 | 11,767 |
| 25 | 4 | 1,548 | 698 | 2,704 | 2,926 | 2,070 | 84 | 123 | 10,153 |
| 25 | 8 | 1,548 | 698 | 2,704 | 1,496 | 1,078 | 84 | 123 | 7,732 |
| 25 | 12 | 1,548 | 698 | 2,704 | 1,020 | 747 | 84 | 123 | 6,925 |
| 25 | 16 | 1,548 | 698 | 2,704 | 782 | 582 | 84 | 123 | 6,521 |
| 30 | 1 | 1,548 | 698 | 2,704 | 11,502 | 9,634 | 85 | 137 | 26,307 |
| 30 | 3 | 1,548 | 698 | 2,704 | 3,879 | 3,270 | 85 | 137 | 12,320 |
| 30 | 4 | 1,548 | 698 | 2,704 | 2,926 | 2,474 | 85 | 137 | 10,571 |
| 30 | 8 | 1,548 | 698 | 2,704 | 1,496 | 1,281 | 85 | 137 | 7,948 |
| 30 | 12 | 1,548 | 698 | 2,704 | 1,020 | 883 | 85 | 137 | 7,074 |
| 30 | 16 | 1,548 | 698 | 2,704 | 782 | 684 | 85 | 137 | 6,637 |
| 35 | 1 | 1,548 | 698 | 2,704 | 11,502 | 11,254 | 85 | 151 | 27,942 |
| 35 | 3 | 1,548 | 698 | 2,704 | 3,879 | 3,810 | 85 | 151 | 12,875 |
| 35 | 4 | 1,548 | 698 | 2,704 | 2,926 | 2,880 | 85 | 151 | 10,992 |
| 35 | 8 | 1,548 | 698 | 2,704 | 1,496 | 1,484 | 85 | 151 | 8,167 |
| 35 | 12 | 1,548 | 698 | 2,704 | 1,020 | 1,019 | 85 | 151 | 7,225 |
| 35 | 16 | 1,548 | 698 | 2,704 | 782 | 786 | 85 | 151 | 6,754 |
| 40 | 1 | 1,548 | 698 | 2,704 | 11,502 | 12,881 | 86 | 166 | 29,584 |
| 40 | 3 | 1,548 | 698 | 2,704 | 3,879 | 4,354 | 86 | 166 | 13,434 |
| 40 | 4 | 1,548 | 698 | 2,704 | 2,926 | 3,288 | 86 | 166 | 11,415 |
| 40 | 8 | 1,548 | 698 | 2,704 | 1,496 | 1,689 | 86 | 166 | 8,387 |
| 40 | 12 | 1,548 | 698 | 2,704 | 1,020 | 1,156 | 86 | 166 | 7,377 |
| 40 | 16 | 1,548 | 698 | 2,704 | 782 | 889 | 86 | 166 | 6,872 |
| 45 | 1 | 1,548 | 698 | 2,704 | 11,502 | 14,515 | 86 | 181 | 31,234 |
| 45 | 2 | 1,548 | 698 | 2,704 | 5,784 | 7,303 | 86 | 181 | 18,305 |
| 45 | 4 | 1,548 | 698 | 2,704 | 2,926 | 3,697 | 86 | 181 | 11,840 |
| 45 | 8 | 1,548 | 698 | 2,704 | 1,496 | 1,894 | 86 | 181 | 8,608 |
| 45 | 12 | 1,548 | 698 | 2,704 | 1,020 | 1,293 | 86 | 181 | 7,531 |
| 45 | 16 | 1,548 | 698 | 2,704 | 782 | 993 | 86 | 181 | 6,992 |
All sizes in MBs.