biocore / deblur

Deblur is a greedy deconvolution algorithm based on known read error profiles.
BSD 3-Clause "New" or "Revised" License
91 stars 41 forks source link

FileNotFoundError: [Errno 2] No such file or directory #144

Closed bstamps closed 6 years ago

bstamps commented 7 years ago

I'm receiving this error when running blur as follows:

deblur workflow --seqs-fp seq/SlOut/seqs.fna --output-dir DeblurOut/ -t 210 -w --pos-ref-fp /media/analyses/DB/SILVA_128_QIIME_release/rep_set/rep_set_all/99/99_otus.fasta --log-level 1 -w --neg-ref-fp artifacts.fa --pos-ref-db-fp /media/analyses/DB/SILVA_128_QIIME_release/rep_set/rep_set_all/99/99_otus

Traceback (most recent call last): File "/home/lab/.conda/envs/deblurenv/bin/deblur", line 4, in <module> __import__('pkg_resources').run_script('deblur==1.0.1', 'deblur') File "/home/lab/.conda/envs/deblurenv/lib/python3.6/site-packages/setuptools-27.2.0-py3.6.egg/pkg_resources/__init__.py", line 744, in run_script File "/home/lab/.conda/envs/deblurenv/lib/python3.6/site-packages/setuptools-27.2.0-py3.6.egg/pkg_resources/__init__.py", line 1499, in run_script File "/home/lab/.conda/envs/deblurenv/lib/python3.6/site-packages/deblur-1.0.1-py3.6.egg-info/scripts/deblur", line 678, in <module> deblur_cmds() File "/home/lab/.conda/envs/deblurenv/lib/python3.6/site-packages/click/core.py", line 722, in __call__ return self.main(*args, **kwargs) File "/home/lab/.conda/envs/deblurenv/lib/python3.6/site-packages/click/core.py", line 697, in main rv = self.invoke(ctx) File "/home/lab/.conda/envs/deblurenv/lib/python3.6/site-packages/click/core.py", line 1066, in invoke return _process_result(sub_ctx.command.invoke(sub_ctx)) File "/home/lab/.conda/envs/deblurenv/lib/python3.6/site-packages/click/core.py", line 895, in invoke return ctx.invoke(self.callback, **ctx.params) File "/home/lab/.conda/envs/deblurenv/lib/python3.6/site-packages/click/core.py", line 535, in invoke return callback(*args, **kwargs) File "/home/lab/.conda/envs/deblurenv/lib/python3.6/site-packages/deblur-1.0.1-py3.6.egg-info/scripts/deblur", line 658, in workflow threads=threads_per_sample) File "/home/lab/.conda/envs/deblurenv/lib/python3.6/site-packages/deblur/workflow.py", line 326, in remove_artifacts_from_biom_table good_seqs = {s for _, s in sequence_generator(clean_fp)} File "/home/lab/.conda/envs/deblurenv/lib/python3.6/site-packages/deblur/workflow.py", line 326, in <setcomp> good_seqs = {s for _, s in sequence_generator(clean_fp)} File "/home/lab/.conda/envs/deblurenv/lib/python3.6/site-packages/deblur/workflow.py", line 81, in sequence_generator if sniff_fasta(input_fp)[0]: File "/home/lab/.conda/envs/deblurenv/lib/python3.6/site-packages/skbio/io/registry.py", line 908, in wrapped_sniffer newline=newline, errors=errors, **kwargs) as fh: File "/home/lab/.conda/envs/deblurenv/lib/python3.6/contextlib.py", line 82, in __enter__ return next(self.gen) File "/home/lab/.conda/envs/deblurenv/lib/python3.6/site-packages/skbio/io/util.py", line 246, in open_file with _resolve_file(file, **kwargs) as (file, source, is_binary_file): File "/home/lab/.conda/envs/deblurenv/lib/python3.6/contextlib.py", line 82, in __enter__ return next(self.gen) File "/home/lab/.conda/envs/deblurenv/lib/python3.6/site-packages/skbio/io/util.py", line 203, in _resolve_file file, source, is_binary_file = _resolve(file, **kwargs) File "/home/lab/.conda/envs/deblurenv/lib/python3.6/site-packages/skbio/io/util.py", line 57, in _resolve newfile = source.get_reader() File "/home/lab/.conda/envs/deblurenv/lib/python3.6/site-packages/skbio/io/_iosources.py", line 94, in get_reader return io.open(self.file, mode='rb') FileNotFoundError: [Errno 2] No such file or directory: '/media/analyses/Deblur/DeblurOut/all.seqs.fa.no_artifacts'

Any ideas as to what could be causing the workflow to fail?

amnona commented 7 years ago

Hi, Can you run deblur with the --log-level 1 and --log-file deblurlog.txt and send the output log file deblurlog.txt? Also, is there a reason you are using the 99_otus for the positive ref instead of the default? This only affects the sOTU placement in reference-hit.biom and reference-non-hit.biom (i.e. deciding whether a sequence is 16S or not), but not the all.biom (which contains all sOTUs), and this decision is done with non-stringent parameters for similarity, so i think default positive ref should work well?

Also, for the --pos-ref-db-fp did you pre-index using sortmerna the 99_otus /media/analyses/DB/SILVA_128_QIIME_release/rep_set/rep_set_all/99/99_otus ?

Thanks Amnon

bstamps commented 7 years ago

Problem solved- the pre-generated index was produced with an older version of sortmeRNA. Re-indexing during the workflow has solved the problem. I've got a separate question on the output that I'll throw into a separate issue, but this can be closed out. Thanks!