lh3 / seqtk

Toolkit for processing sequences in FASTA/Q formats
MIT License
1.38k stars 308 forks source link

error running seqtk with parallel #177

Open EduanWilkinson opened 3 years ago

EduanWilkinson commented 3 years ago

Hi,

Im trying to run seqtk with parallel. My command looks as follows:

parallel '/Applications/biotools/seqtk/seqtk seq -aQ64 -q20 {}.fastq > {}.fasta' ::: $(ls *_L001_R.fastq | rev | cut -c 14- | rev | uniq)

Which produces the following error:

[E::stk_seq] failed to open the input file/stream. [E::stk_seq] failed to open the input file/stream. [E::stk_seq] failed to open the input file/stream.

When I try running it one by one it works. e.g. /Applications/biotools/seqtk/seqtk seq -aQ64 -q20 313507859_S20_L001_R.fastq > 313507859_S20_L001_R.fasta

Any idea what the problem may be? Much appreciated

yzhernand commented 3 years ago

With parallel it might help to run it using the option --dry-run to see what commands it was trying to run. Eg,

parallel --dry-run '/Applications/biotools/seqtk/seqtk seq -aQ64 -q20 {}.fastq > {}.fasta' ::: $(ls *_L001_R.fastq | rev | cut -c 14- | rev | uniq)

Maybe even add | head at the end there if you have many files to run.