JdeRobot / RoboticsAcademy

Learn Robotics with JdeRobot
https://jderobot.github.io/RoboticsAcademy
GNU General Public License v3.0
318 stars 226 forks source link

Broken Nvidia GPU acceleration in ROS 2 Superthin Templates #2516

Closed pawanw17 closed 5 months ago

pawanw17 commented 7 months ago

When trying to run an acceleration with nvidia GPU acceleration, it shows a black screen

docker run --rm -it --gpus all --device /dev/dri -e DRI_NAME=card1 -p 7164:7164 -p 6080:6080 -p 1108:1108 -p 7163:7163 jderobot/robotics-academy:4.5.11

image

Syekeon commented 6 months ago

it's strange, I use the same line (with card0 in my case) and it's working good with my Nvidia GPU. image

jmplaza commented 6 months ago

0.95 is definitely a good Gazebo RTF (Real Time Factor) :-) Which version of docker itself are you using? and which Operating System?

Could you please @Syekeon check with htop the % of CPU used by gzserver and gzclient processes?

pawanw17 commented 6 months ago

Hi @Syekeon for me card0 works too, but those are intel integrated graphics, it fails on card1(Nvidia)

Syekeon commented 6 months ago

@pawanw17 in my case, I don't have integrated graphics so my nvidia card is in card0. Maybe is a issue when using multiple gpu cards?

@jmplaza I tested in Windows 11 with 26.0.0 Docker version. I got 0.90 RTF in Follow Line on average. I checked the % of CPU use with htop and I looked that it's consuming a high power of CPU when the exercise is running.

image

pawanw17 commented 6 months ago

@Syekeon Yeah that could be it... The same commands work in a Noetic RADI 3.4.30 though