Home > Net >  How can I launch chenrocks/uniter with NVIDIA GeForce RTX 3090 GPU?
How can I launch chenrocks/uniter with NVIDIA GeForce RTX 3090 GPU?

Time:10-17

docker run --gpus '"'device=$CUDA_VISIBLE_DEVICES'"' --ipc=host --rm -it \
    --mount src=$(pwd),dst=/src,type=bind \
    --mount src=$OUTPUT,dst=/storage,type=bind \
    --mount src=$PRETRAIN_DIR,dst=/pretrain,type=bind,readonly \
    --mount src=$TXT_DB,dst=/txt,type=bind,readonly \
    --mount src=$IMG_DIR,dst=/img,type=bind,readonly \
    -e NVIDIA_VISIBLE_DEVICES=$CUDA_VISIBLE_DEVICES \
    -w /src chenrocks/uniter

When I run this file, it prints error

NVIDIA Release 19.05 (build 6411784) PyTorch Version 1.1.0a0 828a6a3

...

WARNING: Detected NVIDIA NVIDIA GeForce RTX 3090 GPU, which is not yet supported in this version of the container
ERROR: No supported GPU(s) detected to run this container

it doesn't fit with my NVIDIA GeForce RTX 3090 GPU so I want to change version to 22.05 but when I run this,

docker run --gpus '"'device=$CUDA_VISIBLE_DEVICES'"' --ipc=host --rm
-it nvcr.io/nvidia/pytorch:22.05-py3 \
    --mount src=$(pwd),dst=/src,type=bind \
    --mount src=$OUTPUT,dst=/storage,type=bind \
    --mount src=$PRETRAIN_DIR,dst=/pretrain,type=bind,readonly \
    --mount src=$TXT_DB,dst=/txt,type=bind,readonly \
    --mount src=$IMG_DIR,dst=/img,type=bind,readonly \
    -e NVIDIA_VISIBLE_DEVICES=$CUDA_VISIBLE_DEVICES \
    -w /src chenrocks/uniter

it prints error

/opt/nvidia/nvidia_entrypoint.sh: line 49: exec: --: invalid option
exec: usage: exec [-cl] [-a name] [command [arguments ...]] [redirection ...]

I'd really appreciate it if you could tell me how to change the version.

CodePudding user response:

Your second second docker run command specifies 2 images:

docker run ... nvcr.io/nvidia/pytorch:22.05-py3 chenrocks/uniter

You can only pass one.


Also note the general format of the docker run command:

$ docker run [OPTIONS] IMAGE [COMMAND] [ARG...]

UPDATE

But if the docker image's nvidia/pytorch version doesn't fit my GPU, can I not use that docker image? Or is there something I can do?

You could try editing the Dockerfile of the referenced project to build a custom docker image.

Something like this:

git clone https://github.com/ChenRocks/UNITER.git
cd UNITER
# replace the first line of the Dockerfile with:
# FROM nvcr.io/nvidia/pytorch:22.05-py3
docker build .
# ...
# Successfully built <image_id>

Then simply edit your docker run command to use your custom built image:

docker run ... <image_id>

It looks like that at least one other person had a similar issue. Unfortunately the project is not actively maintained so it's difficult to get any kind of support when trying to make it work with the latest hardware.

  • Related