Closed ahmedbaigkpd closed 1 year ago
Hello Ahmed,
The problem might be due to the virtual machine so that the docker cannot see the GPU. We need to remove the GPU flags from the /docker/ros1_run.sh file.
Could you delete "--gpus all" flag the from line:
docker-run --gpus all --volume $(dirname "$DIR"):/home/rosuser/ws --image rwthika/acdc:ros1 --workdir="/home/rosuser/ws/catkin_workspace" --name acdc
and try again?
Such at the end file will be:
#!/bin/bash
# in order to be able to use this script install:
# pip install docker-run-cli
DIR="$(cd -P "$(dirname "$0")" && pwd)"
if docker ps --format '{{.Names}}' | grep -q "acdc"; then
docker-run --name acdc
else
docker-run --volume $(dirname "$DIR"):/home/rosuser/ws --image rwthika/acdc:ros1 --workdir="/home/rosuser/ws/catkin_workspace" --name acdc
fi
Let us know if the error persists.
Thanks for the quick response.
I did as suggested however still same result.
Hi,
please try to use the flag --no-gpu
#!/bin/bash
# in order to be able to use this script install:
# pip install docker-run-cli
DIR="$(cd -P "$(dirname "$0")" && pwd)"
if docker ps --format '{{.Names}}' | grep -q "acdc"; then
docker-run --name acdc
else
docker-run --no-gpu --volume $(dirname "$DIR"):/home/rosuser/ws --image rwthika/acdc:ros1 --workdir="/home/rosuser/ws/catkin_workspace" --name acdc
fi
Please let me know if that works.
Bests, Till
Thanks Till. Its working.
VMware player 17 virtual machine
Does not apply
lsb_release -a
in a terminal)No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 20.04.6 LTS Release: 20.04 Codename: focal
ls -la
and paste the content here.abaig@abaig-virtual-machine:~/Documents/acdc$ ls -la total 56 drwxrwxr-x 9 abaig abaig 4096 Oct 17 16:19 . drwxr-xr-x 3 abaig abaig 4096 Oct 17 16:18 .. drwxrwxr-x 2 abaig abaig 4096 Oct 17 16:19 assets drwxrwxr-x 2 abaig abaig 4096 Oct 17 16:19 bag drwxrwxr-x 3 abaig abaig 4096 Oct 17 16:19 catkin_workspace drwxrwxr-x 3 abaig abaig 4096 Oct 17 16:19 colcon_workspace drwxrwxr-x 2 abaig abaig 4096 Oct 17 16:19 docker drwxrwxr-x 9 abaig abaig 4096 Oct 17 16:19 .git drwxrwxr-x 4 abaig abaig 4096 Oct 17 16:19 .github -rwxrwxr-x 1 abaig abaig 2761 Oct 17 16:19 .gitignore -rwxrwxr-x 1 abaig abaig 2001 Oct 17 16:19 .gitlab-ci.yml -rwxrwxr-x 1 abaig abaig 833 Oct 17 16:19 .gitmodules -rwxrwxr-x 1 abaig abaig 1104 Oct 17 16:19 LICENSE -rwxrwxr-x 1 abaig abaig 2816 Oct 17 16:19 README.md
catkin_workspace
folder in the acdc repository and executels -la
and paste the content here.abaig@abaig-virtual-machine:~/Documents/acdc/catkin_workspace$ ls -la total 16 drwxrwxr-x 3 abaig abaig 4096 Oct 17 16:19 . drwxrwxr-x 9 abaig abaig 4096 Oct 17 16:19 .. -rw-rw-r-- 1 abaig abaig 98 Oct 17 16:19 .catkin_workspace -rw-rw-r-- 1 abaig abaig 0 Oct 17 16:19 .gitkeep drwxrwxr-x 4 abaig abaig 4096 Oct 17 16:19 src
docker images
and paste the content here.abaig@abaig-virtual-machine:~/Documents$ docker images REPOSITORY TAG IMAGE ID CREATED SIZE rwthika/acdc ros1 b4c4c4abd17a 8 days ago 23.8GB hello-world latest 9c7a54a9a43c 5 months ago 13.3kB rwthika/acdc latest 82e604df3cde 12 months ago 23.7GB
Terminal 1: abaig@abaig-virtual-machine:~/Documents/acdc/docker$ ./ros1_run.sh Starting new container 'acdc' ...
docker: Error response from daemon: could not select device driver "" with capabilities: [[gpu]].
Terminal 2: abaig@abaig-virtual-machine:~/Documents/acdc/docker$ ./ros1_run.sh Starting new container 'acdc' ...
docker: Error response from daemon: could not select device driver "" with capabilities: [[gpu]]. ERRO[0001] error waiting for container:
Screenshot: INSERT HERE