sanger-pathogens/seroba

gzip: No such file or directory

Closed this issue · 3 comments

Hey everybody,

because I couldn't fix the problem executing seroba installed from source, I tried to run it using the provided docker image.
Unfortunatly I am still not able to get it to work. I get the following error message. Can maybe someone help me with that?

sudo docker run --rm -it -v /home/user/Test:/data sangerpathogens/seroba seroba runSerotyping seroba/database '/home/user/RKI4410_S1_L001_R1.fastq.gz' '/home/user/RKI4410_S1_L001_R2.fastq.gz' '/home/user/Test/output_test' gzip: /home/user/RKI4410_S1_L001_R1.fastq.gz: No such file or directory Traceback (most recent call last): File "/usr/local/bin/seroba", line 4, in <module> __import__('pkg_resources').run_script('seroba==1.0.2', 'seroba') File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 666, in run_script self.require(requires)[0].run_script(script_name, ns) File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 1469, in run_script exec(script_code, namespace, namespace) File "/usr/local/lib/python3.7/dist-packages/seroba-1.0.2-py3.7.egg/EGG-INFO/scripts/seroba", line 86, in <module> File "/usr/local/lib/python3.7/dist-packages/seroba-1.0.2-py3.7.egg/seroba/tasks/sero_run.py", line 19, in run File "/usr/local/lib/python3.7/dist-packages/seroba-1.0.2-py3.7.egg/seroba/serotyping.py", line 468, in run File "/usr/local/lib/python3.7/dist-packages/seroba-1.0.2-py3.7.egg/seroba/serotyping.py", line 60, in _run_kmc File "/usr/local/lib/python3.7/dist-packages/seroba-1.0.2-py3.7.egg/seroba/kmc.py", line 10, in run_kmc File "/usr/local/lib/python3.7/dist-packages/seroba-1.0.2-py3.7.egg/seroba/common.py", line 42, in detect_sequence_format File "/usr/lib/python3/dist-packages/pyfastaq/utils.py", line 15, in open_file_read raise Error("Error opening for reading gzipped file '" + filename + "'") pyfastaq.utils.Error: Error opening for reading gzipped file '/home/user/RKI4410_S1_L001_R1.fastq.gz'

Thank you very much in advance!

Karsten

Hi Karsten,

with the -v flag you mounted your reads into the "data" directory of the docker container. To run SeroBA you have to to set the correct internal path. It will probably look like this:

sudo docker run --rm -it -v /home/user/Test:/data sangerpathogens/seroba seroba runSerotyping seroba/database /data/RKI4410_S1_L001_R1.fastq.gz /data/RKI4410_S1_L001_R2.fastq.gz /data/output_test

Instead of installing SeroBA from source it might be easier to install it via conda within a separate environment:

conda install -c bioconda seroba

Best,
Lennard

Hey Lennard,

again thank you for the quick response.

But how does seroba know in which directory the reads are? I thought -v only mounts my physical folder /home/user/Test to /data in the seroba Container. For the command I just dragged the files to the console for the Path to the reads.

I am sorry to bother you with that, but I am really struggling with that.

I tried conda but it failed multiple times solving the environment.

Best,

Karsten

Hi Karsten,

I think it is rather a general problem of using a docker container than something seroba specific. If you like, you can contact me on my e-mail an we will figure it out : eppingl[at]rki.de

for conda I would recommend to create a new environment:

conda create -n seroba
source activate seroba
conda install seroba