BESST_RNA icon indicating copy to clipboard operation
BESST_RNA copied to clipboard

ZeroDivisionError

Open andreaswallberg opened this issue 3 years ago • 1 comments

Dear @ksahlin

When running a test case with 10M reads, that do not cover much of the genome, I seem to get a ZeroDivsionError similar to #3 . The contigs that do have data mapped to them in this case include the longest contigs. Part of the output:

[...]

Total time elapsed: 9.50743699074 USEFUL READS (reads mapping to different contigs): 73057 Reads with too large insert size from "USEFUL READS" (filtered out): 21622 Number of duplicated reads indicated and removed: 18300 Mean coverage before filtering out extreme observations = 2.30129617227 Std dev of coverage before filtering out extreme observations= 17.1396081063 Quantile for repeat detector chosen to: 3.88445706788 Quantile for repeat detector chosen to: 3.88275040907 Quantile for repeat detector chosen to: 3.87954692048 Quantile for repeat detector chosen to: 3.87376768426 Quantile for repeat detector chosen to: 3.86862171346 Quantile for repeat detector chosen to: 3.86362439975 Quantile for repeat detector chosen to: 3.85878824636 Quantile for repeat detector chosen to: 3.85301518805 Quantile for repeat detector chosen to: 3.84766492075 Quantile for repeat detector chosen to: 3.84160413149 Quantile for repeat detector chosen to: 3.83657912303 Quantile for repeat detector chosen to: 3.83052474135 Quantile for repeat detector chosen to: 3.82462333269 Quantile for repeat detector chosen to: 3.82049759129 Quantile for repeat detector chosen to: 3.8153174192 Quantile for repeat detector chosen to: 3.80968449638 Quantile for repeat detector chosen to: 3.80253329065 Quantile for repeat detector chosen to: 3.79551319404 Quantile for repeat detector chosen to: 3.79083467186 Quantile for repeat detector chosen to: 3.78974162661 Traceback (most recent call last): File "Main.py", line 247, in options.mapquality) File "Main.py", line 79, in Main (G, Contigs, Scaffolds, F, param) = CG.PE(Contigs, Scaffolds, F, Information, output_dest, C_dict, param) #Create graph, single out too short contigs/scaffolds and store them in F File "/vaults/vault3/andreasw/devel/besst_rna/BESST_RNA/src/CreateGraph.py", line 234, in PE mean_cov, std_dev_cov = CalculateMeanCoverage(Contigs, param.first_lib, output_dest, param.bamfile) File "/vaults/vault3/andreasw/devel/besst_rna/BESST_RNA/src/CreateGraph.py", line 352, in CalculateMeanCoverage mean_cov = sum(filtered_list) / n ZeroDivisionError: float division by zero

andreaswallberg avatar Jul 09 '20 08:07 andreaswallberg