0

I'm new to Docker, and I would like to reproduce a project from a https://github.com/Zhongdao/Towards-Realtime-MOT.

In order to run the project examples, I need to build an image, so I first cloned the repository locally.

The documentation tells me to run the following commands:

docker build -t towards-realtime-mot docker/

docker run --rm --gpus all -v $(pwd)/:/Towards-Realtime-MOT -ti towards-realtime-mot /bin/bash
cd /Towards-Realtime-MOT;
python demo.py --input-video path/to/your/input/video --weights path/to/model/weights
               --output-format video --output-root path/to/output/root

I'm running on macOS (without gpu support), and I've done:

➜ docker build -t towards-realtime-mot docker/
➜ docker run --rm -v -ti towards-realtime-mot /bin/bash
➜ cd /Towards-Realtime-MOT
cd: no such file or directory: /Towards-Realtime-MOT

I've successfully built the docker image, but I'm stuck from the second command onwards. I know that I should create a folder called Towards-Realtime-MOT, but $(pwd) confuses me since it gives me erros (docker: invalid reference format. See 'docker run --help'.). What is the correct way?

Kevin
  • 427
  • 4
  • 12
  • What happened after the `docker run` command? – larsks Sep 13 '20 at 13:06
  • If I run `docker run --rm --gpus all -v $(pwd)/:/Towards-Realtime-MOT -ti towards-realtime-mot /bin/bash` I get `docker: invalid reference format. See 'docker run --help'.` – Kevin Sep 13 '20 at 13:09
  • What is the output of `pwd`? Does that path include any spaces in the same? – larsks Sep 13 '20 at 13:21
  • It outputs the current directory. Yes, it does include space. – Kevin Sep 13 '20 at 13:40
  • The problem is the space, which renders the command line invalid. See https://stackoverflow.com/a/51208726/147356 which discusses how to solve this. – larsks Sep 13 '20 at 13:54

0 Answers0