-
Notifications
You must be signed in to change notification settings - Fork 4
RVIZ usage with the docker image #6
Comments
Hello @jabrena, I missed this issue for some reason. Yes you can use RVIZ with this image, and for some initial tests the most simple steps are:
And then, from within the container:
For more advanced tests you can mount some host folders as volumes, set a runtime user instead of using root, use a |
No response. Closing. |
I tried these steps on a new container created from your Dockerfile.
I am on Ubuntu 16.04
|
@subhash I finally found some time to look into this. Do you have an NVidia GPU? |
Yes, i tested with a 1070
…On Tue, Mar 27, 2018, 10:20 PM Diego Ferigo ***@***.***> wrote:
@subhash <https://github.com/subhash> I finally found some time to look
into this. Do you have an NVidia GPU?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#6 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAFWwqo8O1XxDVabJDUk55CabZYUISL2ks5tim3sgaJpZM4N_jyf>
.
|
I had a discussion at robotology/icub-main#501 (comment) just few days ago. Nvidia GPUs need a configured # nvidia-docker hooks
LABEL com.nvidia.volumes.needed="nvidia_driver"
ENV PATH /usr/local/nvidia/bin:${PATH}
ENV LD_LIBRARY_PATH /usr/local/nvidia/lib:/usr/local/nvidia/lib64:${LD_LIBRARY_PATH} I might consider adding them as default to my images in order to provide an out-of-the-box working setup even on Nvidia. From the user side, however, |
I installed ros-kinetic on tensorflow base image on docker. I cannot seem to get rviz working on the docker.
Although I can run other ros gui applications on docker like rqt_image. How can this be fixed? |
Hi, I am trying to run rviz on autoware docker. I get the following error: [ INFO] [1539583851.181537990]: rviz version 1.12.16 I am using Ubuntu 16.04 and have Nvidia 1080. |
+1. Getting the same with Ubuntu 16.04 and Nvidia Geforce GTX 1080 |
I am also having the similar issue on my dockers |
+1, I'm having the same problem. I changed the dockerfile to use cudagl instead of opengl but it didn't solve the problem |
+1, I have the same problem. Cannot get rviz running in a docker environment with autoware. Without docker rviz runs fine. |
one thing I did is:
This seems to work well for me as an alternate way. |
When I see this error:
Usually it means that the GPU access was not configured properly. OpenGL applications have always been tricky with Nvidia, but thanks to their amazing work and their new docker runtime everything should run smooth when coupled with @mpkuse @KetkiChaudhary @hristo-vrigazov @saikishor @hroachewilson @yuqli What's yours system configuration? I suggest you to do tests with minimal images and then add other piece of software on top of it. I have a XPS 15 with a GeForce GTX 1050 Mobile. My OS is Ubuntu 18.04 configured with bumblebee / bbswitch / optirun. This allows me to have the GPU turned off by default and turning it on only for selected processes (or containers). I just updated my ROS image to melodic and added the support of nvidia-docker 2.0, can you please try it out? You can follow the updated README. With and without the Nvidia GPU enabled, on my setup RViz works as expected. Within the same container I tried to execute in background |
@diegoferigo Thanks for the response. My system configuration :
I suspect the problem is I used nvidia-docker instead of a nvidia-docker-2.0, as I seem to see it somewhere about this issue. I have uninstalled everything and will try using nvidia-docker 2.0. On another note, the demo tutorial on autoware homepage seems to instruct install nvidia-docker 1.0. I'll update when I figured out if this is indeed the issue. |
I was wrong. The instructions on autoware homepage let us install NVIDIA Docker: 2.0.3 |
Do the non-opengl GUIs work for you @yuqli? Such as |
Hi @diegoferigo, sorry I later realized this thread is not about autoware. Thanks for the reply! So the root problem seems to be nvidia-docker2 does not have OpenGL installed automatically inside it, and I found this thread to be very helpful regarding running rviz in autoware docker image. Other non-autoware images might have some useful insights from that thread too... Here is a revised Dockerfile authored by someone else. When I figured out what that is doing I'll update here again :) |
Hi, I know nothing about docker internals even though I'm programming inside a container for monthes now. @diegoferigo How could I add your lines to the dockerfile ruling the image please? PS : I do already have installed Regards |
@moucrob You need to get the Dockerfile of your image, append at the bottom those lines, and regenerate the image using Be aware that if you want nvidia support, the base image should not be |
I had to add the --runtime=nvidia to the docker run command and it worked!! I also added the LABEL/ENV stuff and derived the image from cudagl as well, and installed nvidia-docker2 on the host. |
@guru-florida Few things changed (again) in the Docker + Nvidia setup. Docker, starting from 19.03, natively supports nvidia GPUs. You don't need anymore the runtime (even though that method is still working and necessary in few edge cases) being substituted with the container toolkit. Have a look to the upstream installation procedure for more details. |
@diegoferigo Thanks for replying. Yes, I saw that >19 has built-in support. I am on Docker thru apt from Ubuntu 19. I could have upgraded myself, but I wont be the only one using my docker image so wanted to keep compatible with D<19. |
I see 👍 Consider though that I still did not see any image which compatibility has been broken by the latest docker update. |
Hi,
I am thinking to use this Dockerfile to do some tests with ROS and my question is if I run the docker image, it is possible to use some tool to see RVIZ.
Sorry if the question is from a beginner.
Many thanks in advance.
Juan Antonio
The text was updated successfully, but these errors were encountered: