parklab / MosaicForecast

A mosaic detecting software based on phasing and random forest
MIT License
62 stars 21 forks source link

Docker image: /MF/demo missing #2

Closed attilagk closed 5 years ago

attilagk commented 5 years ago

Hi :)

I've just pulled the docker image. I'm in the container now and the demo for Phase.py gives me error because the test.input file is missing from the container. Am I not running docker properly or is test.input really missing from the container?

attila@ada:~/tools/MosaicForecast$ sudo docker run -v $PWD:/MF --rm -it yanmei/mosaicforecast:0.0.1 /bin/bash
root@fca41a77d321:/usr/local/bin# Phase.py /MF/demo/ /MF/demo/phasing hs37d5.fa /MF/demo/test.input 20 k24.umap.wg.bw 4
Traceback (most recent call last):
  File "/usr/local/bin/Phase.py", line 71, in <module>
    file=open(input_pos)
FileNotFoundError: [Errno 2] No such file or directory: '/MF/demo/test.input'
douym commented 5 years ago

Hi Attilagk,

Sorry that I just see your question...

Yes, we did not put all things in the docker image, could you attach your local directory containing the files to the image (through "-v")?

Basically you could run: docker run -v ${your_local_directory}:/MF --rm -it yanmei/mosaicforecast:0.0.1 /bin/bash gunzip hs37d5.fa.gz Phase.py /MF/demo/ /MF/demo/phasing hs37d5.fa /MF/demo/test.input 20 k24.umap.wg.bw 4

The command above would attach your local MF directory containing the demo to your image, and the attached directory in the docker image would be "/MF".

Please tell me if that answers your question.

Best wishes,

Yanmei