Java error message when using BBDuk
1
0
Entering edit mode
5.7 years ago
c.e.chong ▴ 60

Hi all,

I am trying to run BBDuk to quality trim and filter my illumina whole genome sequences. I have used this program before and haven't had any problems. However when I run the command:

bbduk.sh -Xmx80g in1=17198wC1_Sample_3_1_trimmed.fastq  in2=17198wC1_Sample_3_2_trimmed.fastq out1=~/comp_genomics/bb_qc_30/bb30_17198wC1_Sample_3_1_trimmed.fastq out2=~/comp_genomics/bb_qc_30/bb30_17198wC1_Sample_3_2_trimmed.fastq qtrim=rl trimq=30 maq= 30 t=16

Or if I run the command in a forloop:

for i in ~/comp_genomics/raw_genomes/scalp_genomereads/*_1_trimmed.fastq; do bbduk.sh -Xmx80g in1=$i in2=${i%%_1_trimmed.fastq}_2_trimmed.fastq out1=~/comp_genomics/bb_qc_30/$i out2=~/comp_genomics/bb_qc_30/${i%%_1_trimmed.fastq}_2_trimmed.fastq qtrim=rl trimq=30 maq= 30 t=16; done

I get the error message:

Version 38.22 Exception in thread "main" java.lang.NullPointerException
    at shared.Parser.parseTrim(Parser.java:317)
    at jgi.BBDukF.<init>(BBDukF.java:163)
    at jgi.BBDukF.main(BBDukF.java:67)

I have run this both in a conda environment and using the downloaded program, however I still get the same error and no output. I have also made sure that the versions I have are updated.

If anyone could help, I would be very grateful!

Thank you!!

genome bbduk QC java bbtools • 3.9k views
ADD COMMENT
1
Entering edit mode

Can you validate your fastq files using validateFiles utility here? Remeber to do chmod a+x validateFiles after you download.

ADD REPLY
0
Entering edit mode

I run validateFiles on my fastq files and the output was "Error count 0"

ADD REPLY
0
Entering edit mode

bbduk.sh should not need 80g of RAM. Can you try running this with a smaller number of threads (t=4 and -Xmx5g). Are you input files already trimmed for adapters and you are now doing quality trim?

ADD REPLY
0
Entering edit mode

Yes, my files are already trimmed for adapters I am now doing a quality trim.

I tried with the lower number of RAM and threads and got this error:

    Exception in thread "main" java.lang.NullPointerException
    at shared.Parser.parseTrim(Parser.java:333)
    at jgi.BBDuk.<init>(BBDuk.java:176)
    at jgi.BBDuk.main(BBDuk.java:76)
java -ea -Xmx5g -Xms5g -cp /pub38/cchong/Software_Downloads/bbmap/current/ jgi.BBDuk -Xmx5g in1=17198wA4_Sample_25_1_trimmed.fastq in2=17198wA4_Sample_25_2_trimmed.fastq out1=/pub38/cchong/comp_genomics/bb_qc_30/17198wA4_Sample_25_1_trimmed.fastq out2=/pub38/cchong/comp_genomics/bb_qc_30/17198wA4_Sample_25_2_trimmed.fastq qtrim=rl trimq=30 maq= 30 t=4
Executing jgi.BBDuk [-Xmx5g, in1=17198wA4_Sample_25_1_trimmed.fastq, in2=17198wA4_Sample_25_2_trimmed.fastq, out1=/pub38/cchong/comp_genomics/bb_qc_30/17198wA4_Sample_25_1_trimmed.fastq, out2=/pub38/cchong/comp_genomics/bb_qc_30/17198wA4_Sample_25_2_trimmed.fastq, qtrim=rl, trimq=30, maq=, 30, t=4]
ADD REPLY
0
Entering edit mode

That worked! Such a simple fix!!

Thank you very much!

ADD REPLY
0
Entering edit mode

Great. You can accept the answer below to provide closure to this thread.

ADD REPLY
1
Entering edit mode
5.7 years ago
GenoMax 147k

It looks like you have a space in one of the command line options after the = sign: maq= 30. Can you remove that and try?

ADD COMMENT
0
Entering edit mode

That worked! Such a simple fix!!

Thank you very much!

ADD REPLY

Login before adding your answer.

Traffic: 1836 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6