quast
quast copied to clipboard
QUAST ignoring bam files
Hello,
I am having some trouble when I try to give QUAST pre-computed alignments with the --bam option. The run completes successfully, but does not produce any stats about read mapping.
I am using QUAST version 5.0.2 on Linux, and the command I run is:
quast assembly_result_sub/contigs.fasta assembly_result_sub/scaffolds.fasta -o assembly_result_sub/QUAST/ -m 1 -t 1 --bam assembly_result_sub/quast_align_contig.sort.bam,assembly_result_sub/quast_align_scaff.sort.bam
I've also tried:
quast assembly_result_sub/contigs.fasta assembly_result_sub/scaffolds.fasta -o assembly_result_sub/QUAST/ -m 1 -t 1 --bam assembly_result_sub/quast_align_contig.sort.bam --bam assembly_result_sub/quast_align_scaff.sort.bam
and got the same result.
If I provide fastq files with --pe1 --pe2, everything works fine and I get the expected stats.
My bam files were created with BWA mem (default parameters) and then sorted and indexed with samtools.
Here is the run STDOUT:
Version: 5.0.2
System information: OS: Linux-3.10.0-514.el7.x86_64-x86_64-with-centos-7.3.1611-Core (linux_64) Python version: 3.6.7 CPUs number: 16
Started: 2019-12-07 11:28:39
Logging to /groups/itay_mayrose/nosnap/liorglic/NGS_course/master/lesson6/assembly_result_sub/QUAST/quast.log NOTICE: Output directory already exists and looks like a QUAST output dir. Existing results can be reused (e.g. previously generated alignments)!
CWD: /groups/itay_mayrose/nosnap/liorglic/NGS_course/master/lesson6 Main parameters: MODE: default, threads: 1, minimum contig length: 1, minimum alignment length: 65,
ambiguity: one, threshold for extensive misassembly size: 1000Contigs: Pre-processing... 1 assembly_result_sub/contigs.fasta ==> contigs 2 assembly_result_sub/scaffolds.fasta ==> scaffolds
2019-12-07 11:28:44 Running Reads analyzer... Logging to files /groups/itay_mayrose/nosnap/liorglic/NGS_course/master/lesson6/assembly_result_sub/QUAST/reads_stats/reads_stats.log and /groups/itay_mayrose/nosnap/liorglic/NGS_course/master/lesson6/assembly_result_sub/QUAST/reads_stats/reads_stats.err... Creating total report... saved to /groups/itay_mayrose/nosnap/liorglic/NGS_course/master/lesson6/assembly_result_sub/QUAST/reads_stats/reads_report.txt, reads_report.tsv, and reads_report.tex Done.
2019-12-07 11:28:45 Running Basic statistics processor... Contig files: 1 contigs 2 scaffolds Calculating N50 and L50... 1 contigs, N50 = 93659, L50 = 38, Total length = 11542038, GC % = 38.10, # N's per 100 kbp = 0.00 2 scaffolds, N50 = 99480, L50 = 34, Total length = 11544180, GC % = 38.10, # N's per 100 kbp = 20.96 Drawing Nx plot... saved to /groups/itay_mayrose/nosnap/liorglic/NGS_course/master/lesson6/assembly_result_sub/QUAST/basic_stats/Nx_plot.pdf Drawing cumulative plot... saved to /groups/itay_mayrose/nosnap/liorglic/NGS_course/master/lesson6/assembly_result_sub/QUAST/basic_stats/cumulative_plot.pdf Drawing GC content plot... saved to /groups/itay_mayrose/nosnap/liorglic/NGS_course/master/lesson6/assembly_result_sub/QUAST/basic_stats/GC_content_plot.pdf Drawing contigs GC content plot... saved to /groups/itay_mayrose/nosnap/liorglic/NGS_course/master/lesson6/assembly_result_sub/QUAST/basic_stats/contigs_GC_content_plot.pdf Drawing scaffolds GC content plot... saved to /groups/itay_mayrose/nosnap/liorglic/NGS_course/master/lesson6/assembly_result_sub/QUAST/basic_stats/scaffolds_GC_content_plot.pdf Drawing Coverage histogram (bin size: 1x)... saved to /groups/itay_mayrose/nosnap/liorglic/NGS_course/master/lesson6/assembly_result_sub/QUAST/basic_stats/coverage_histogram.pdf Drawing contigs coverage histogram (bin size: 1x)... saved to /groups/itay_mayrose/nosnap/liorglic/NGS_course/master/lesson6/assembly_result_sub/QUAST/basic_stats/contigs_coverage_histogram.pdf Drawing scaffolds coverage histogram (bin size: 1x)... saved to /groups/itay_mayrose/nosnap/liorglic/NGS_course/master/lesson6/assembly_result_sub/QUAST/basic_stats/scaffolds_coverage_histogram.pdf Done.
NOTICE: Genes are not predicted by default. Use --gene-finding or --glimmer option to enable it.
2019-12-07 11:28:52 Creating large visual summaries... This may take a while: press Ctrl-C to skip this step.. 1 of 2: Creating Icarus viewers... 2 of 2: Creating PDF with all tables and plots... Done
2019-12-07 11:28:54 RESULTS: Text versions of total report are saved to /groups/itay_mayrose/nosnap/liorglic/NGS_course/master/lesson6/assembly_result_sub/QUAST/report.txt, report.tsv, and report.tex Text versions of transposed total report are saved to /groups/itay_mayrose/nosnap/liorglic/NGS_course/master/lesson6/assembly_result_sub/QUAST/transposed_report.txt, transposed_report.tsv, and transposed_report.tex HTML version (interactive tables and plots) is saved to /groups/itay_mayrose/nosnap/liorglic/NGS_course/master/lesson6/assembly_result_sub/QUAST/report.html PDF version (tables and plots) is saved to /groups/itay_mayrose/nosnap/liorglic/NGS_course/master/lesson6/assembly_result_sub/QUAST/report.pdf Icarus (contig browser) is saved to /groups/itay_mayrose/nosnap/liorglic/NGS_course/master/lesson6/assembly_result_sub/QUAST/icarus.html Log is saved to /groups/itay_mayrose/nosnap/liorglic/NGS_course/master/lesson6/assembly_result_sub/QUAST/quast.log
Finished: 2019-12-07 11:28:54 Elapsed time: 0:00:15.122671 NOTICEs: 2; WARNINGs: 0; non-fatal ERRORs: 0
Thank you for using QUAST!
You can find the output report.html attached (just change the extension). report.txt It looks like QUAST completely ignores the --bam inputs. Any idea why?
Hello,
Thank you for reporting this issue! We will include the fix in the upcoming QUAST release. Now you can do the following thing. Please substitute the files <quast_dir>/quast_libs/reads_analyzer.py and <quast_dir>/quast_libs/ra_utils/misc.py with the attached files. Then QUAST should properly work with your BAM files.
Please let me know if you have any issues.
Thanks, Alla reads_analyzer.py.zip misc.py.zip
Thanks Alla. That worked indeed. Is there a scheduled date for the next release?
I really hope that we manage to do it before the New Year :)