DaehwanKimLab / hisat-genotype

GNU General Public License v3.0
23 stars 15 forks source link

hisat-genotype batch does not process paired reads #1

Closed memumab closed 4 years ago

memumab commented 4 years ago

Hello, I have a question regarding hisat-genotype. I installed it according to the new tutorial/manual at your website. For single processes, it works fine (command: hisatgenotype, -1 and -2 specified). I would like to perform the same typing now to a whole directory using --in-dir (the files end with .1.fq.gz or .2.fq.gz). Unfortunately, after starting with the first file, it stops with an error:

Traceback (most recent call last): File "/home/tcadm/hisat-genotype/hisatgenotype", line 527, in args.verbose) File "/home/tcadm/hisat-genotype/hisatgenotype_modules/hisatgenotype_typing_process.py", line 1694, in extract_reads verbose) File "/home/tcadm/hisat-genotype/hisatgenotype_modules/hisatgenotype_typing_process.py", line 1526, in work stdout=open("%s%s-%s-extracted-1.fq.gz" % (out_dir_slash, fq_fname_base, database), 'w'), IOError: [Errno 2] No such file or directory: '/home/tcadm/hisat-genotype/hla-analysis/hisatgenotype_out/20190917_8_Samples/ERR3240115-hla-extracted-1.fq.gz'

With the option --single-end, it does not produce this error. Can you help me how to do this?

Kind regards and thank you in advance, Matthias

chbe-helix commented 4 years ago

Hi Matthias,

I can certainly help! Would you kindly share the exact command you ran for hisatgenotype and perhaps if possible the names of a pair of files so that I can begin troubleshooting?

Thanks, Chris

memumab commented 4 years ago

Dear Chris, thanks for the fast reply :)

I used the following command in the ~/hisat-genotype/hla-analysis directory: hisatgenotype --base hla --locus-list A --in-dir TESTpair -x genotype_genome

The first two samples in TESTpair have the following names: ERR3240115.1.fq.gz ERR3240115.2.fq.gz

I also tried renaming in ERR3240115_1.fq.gz or ERR3240115.L.fq.gz but it's not taking them with the --in-dir option (tried --read-dir but that's also not working). When I specify the exact same files with -1 and -2, it works perfectly.

Thank you very much in advance, Matthias

chbe-helix commented 4 years ago

Hi Matthias,

Thanks for the information. Let me check how the code is running. The --in-dir option is a little finicky since it is trying to automatically guess all of the file names in the directory and match them. I'll get back to you with a code update by tomorrow.

EDIT: Correction: I have pushed a change to the code that should fix that problem. When you get a chance, try it now and see if it works. With the --in-dir option, please make sure the only files and folders in the directory are the fasta/fastq files you want typed.

Thanks, Chris

memumab commented 4 years ago

Dear Chris, thank you very much for your efforts! Unfortunately, the problem still persists with the same error. I switched to the v1.1.2_beta-devel branch, is this the correct version in which you did the changes?

Greetings, Matthias

chbe-helix commented 4 years ago

Hi Matthias,

My deepest apologies this directory didn't update when I updated the others. Try it now. Sorry about that.

-Chris

memumab commented 4 years ago

Dear Chris, it's working fine, thank you so much for your support :)

Kind regards, Matthias