Qualimap bamqc v2.2.2 Cannot invoke "org.bioinfo.ngs.qc.qualimap.beans.XYVector.getXVector()" because "this.data" is null

39 views
Skip to first unread message

Vlad Grigorjev

unread,
Dec 9, 2022, 5:09:52 AM12/9/22
to QualiMap
Hi there!

I am having a problem executing the qualimap bamqc -bam ... command which seems to fail during a histogram computation and I could not find anything similar online.


```
Fri Dec 09 10:51:33 CET 2022            WARNING Output folder already exists, the results will be saved there

Starting bam qc....
Loading sam header...
Loading locator...
Loading reference...
Number of windows: 400, effective number of windows: 3765
Chunk of reads size: 1000
Number of threads: 1
Initializing regions from /cluster/work/nexus/nilsson/nilsson_dx-pipeline_2020/reference_data/bedfiles/IAA20691_182_liftoverToHG38.qualimap.bed.....
Found 322 regions
Filling region references...
^[[A^[[A^[[AProcessed 376 out of 3765 windows...
Processed 752 out of 3765 windows...
Processed 1128 out of 3765 windows...
Processed 1504 out of 3765 windows...
Processed 1880 out of 3765 windows...
Processed 2256 out of 3765 windows...
Processed 2632 out of 3765 windows...
Processed 3008 out of 3765 windows...
Processed 3384 out of 3765 windows...
Processed 3760 out of 3765 windows...
Total processed windows:3765
Number of reads: 12413035
Number of valid reads: 12419993
Number of correct strand reads:0

Inside of regions...
Num mapped reads: 12412523
Num mapped first of pair: 6209389
Num mapped second of pair: 6203134
Num singletons: 617

Ouside of regions...
Num mapped reads: 0
Num mapped first of pair: 0
Num mapped second of pair: 0
Num singletons: 0
Time taken to analyze reads: 205
Computing descriptors...
numberOfMappedBases: 1808699994
referenceSize: 3217346917
numberOfSequencedBases: 1808569302
numberOfAs: 527539626
Computing per chromosome statistics...
Computing histograms...

WARNING: number of mapped reads outside of regions equals zero
Overall analysis time: 207
end of bam qc
Computing report...
Failed to run bamqc
java.lang.NullPointerException: Cannot invoke "org.bioinfo.ngs.qc.qualimap.beans.XYVector.getXVector()" because "this.data" is null
        at org.bioinfo.ngs.qc.qualimap.beans.BamQCHistogramChart.render(BamQCHistogramChart.java:143)
        at org.bioinfo.ngs.qc.qualimap.beans.BamQCRegionReporter.computeChartsBuffers(BamQCRegionReporter.java:712)
        at org.bioinfo.ngs.qc.qualimap.main.BamQcTool.execute(BamQcTool.java:277)
        at org.bioinfo.ngs.qc.qualimap.main.NgsSmartTool.run(NgsSmartTool.java:190)
        at org.bioinfo.ngs.qc.qualimap.main.NgsSmartMain.main(NgsSmartMain.java:113)
```

I am not sure what this problem is or how to "bypass" it. 

The version I am running via the command line is QualiMap v.2.2.2-dev
Built on 2019-11-11 14:05

Any suggestion as to what's happening and how to fix it is very appreciated!

Konstantin Okonechnikov

unread,
Dec 9, 2022, 9:25:31 AM12/9/22
to qual...@googlegroups.com
Hi,

it might be connected to the lack of mapped reads outside of annotation regions according to the "Warning" message. What was the full Qualimap command? Is this error happening if annotation regions are not used? If the BAM (or a subsample from if it's repeating the error) could be shared, I can take a detailed look.

Best regards,
  Konstantin 

--
You received this message because you are subscribed to the Google Groups "QualiMap" group.
To unsubscribe from this group and stop receiving emails from it, send an email to qualimap+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/qualimap/451dc095-5512-4251-8d1a-6968f2de44d8n%40googlegroups.com.

Vlad Grigorjev

unread,
Dec 9, 2022, 9:52:01 AM12/9/22
to QualiMap
That solves the problem!

It is a panel data so I thought it would be expected not to have regions outside the given intervals.

Maybe just for completeness, what are the implications of not supplying a --feature-file ? 

Otherwise, the problem is resolved:

```

QualiMap v.2.2.2-dev
Built on 2019-11-11 14:05

Selected tool: bamqc
Available memory (Mb): 32
Max memory (Mb): 4054
Fri Dec 09 15:46:11 CET 2022            WARNING Output folder already exists, the results will be saved there


Starting bam qc....
Loading sam header...
Loading locator...
Loading reference...
Number of windows: 400, effective number of windows: 3765
Chunk of reads size: 1000
Number of threads: 1
Processed 376 out of 3765 windows...
Processed 752 out of 3765 windows...
Processed 1128 out of 3765 windows...
Processed 1504 out of 3765 windows...
Processed 1880 out of 3765 windows...
Processed 2256 out of 3765 windows...
Processed 2632 out of 3765 windows...
Processed 3008 out of 3765 windows...
Processed 3384 out of 3765 windows...
Processed 3760 out of 3765 windows...
Total processed windows:3765
Number of reads: 12413035
Number of valid reads: 12419993
Number of correct strand reads:0

Inside of regions...
Num mapped reads: 12412523
Num mapped first of pair: 6209389
Num mapped second of pair: 6203134
Num singletons: 617
Time taken to analyze reads: 192
Computing descriptors...
numberOfMappedBases: 1836074612
referenceSize: 3217346917
numberOfSequencedBases: 1835943593
numberOfAs: 535499297

Computing per chromosome statistics...
Computing histograms...
Overall analysis time: 194

end of bam qc
Computing report...
Writing PDF report...
PDF file created successfully

Finished
```

Konstantin Okonechnikov

unread,
Dec 9, 2022, 10:33:55 AM12/9/22
to qual...@googlegroups.com
Great! Without feature file argument all read alignments are processed and for statistics/plots computation (e.g coverage  etc) full genome is applied, while in case feature file is provided, the focus is only on target regions. Option "outside regions" activates processing of alignments that do not fall into target regions. More details also in documentation: http://qualimap.conesalab.org/doc_html/analysis.html#bam-qc 

Best regards,
  Konstantin

пт, 9 дек. 2022 г., 15:52 Vlad Grigorjev <Vladislav...@nexus.ethz.ch>:
Reply all
Reply to author
Forward
0 new messages