Gazebo | Ignition | Community
Ask Your Question

How to run gazebo with a specific graphic card or no graphic card?

asked 2018-11-22 04:12:36 -0600

chrissunny94 gravatar image

Hey , I am trying to run a tensorflow image classifier along with a Gazebo simulation .

I have a Nvidia GT730 with 2GB graphics .

The problem i am facing is , when i start up gazebo , it eats up most of the GPU memory , this makes my tensorflow node as non run-able .

Is there some parameter i can give with gzclient , so that gazebo runs solely on the CPU or integrated GPU .

edit retag flag offensive close merge delete


This may sound simple, but had you tried starting your image classifier node first and pausing for a few seconds for it to start up, then starting gazebo.

PeteBlackerThe3rd gravatar imagePeteBlackerThe3rd ( 2018-11-22 06:25:35 -0600 )edit

That could be one solution .

chrissunny94 gravatar imagechrissunny94 ( 2018-11-26 05:12:39 -0600 )edit Another solution i found is this one .

chrissunny94 gravatar imagechrissunny94 ( 2018-11-26 05:12:53 -0600 )edit

Not sure, if it is an option for you, but running simulation headless should free some resources on your GPU.

m.bahno gravatar imagem.bahno ( 2021-03-03 07:53:09 -0600 )edit

1 Answer

Sort by ยป oldest newest most voted

answered 2018-11-27 17:44:46 -0600

azeey gravatar image

You can try using a virtual framebuffer like xvfb to run gazebo on the CPU. Once you install xvfb, run xvfb-run -s "-screen 0 1400x900x24" bash. Launching gazebo from that bash shell will run rendering on the CPU. To check if your world is properly loaded, you can run gzclient from another shell (which will use the GPU).

edit flag offensive delete link more


I have Gazebo 11.9.1. Using xvfb did not show any gzclient window, but also no errors. My hunch is that my screen id could be wrong.

leuko gravatar imageleuko ( 2022-02-08 15:29:17 -0600 )edit

Question Tools



Asked: 2018-11-22 04:12:36 -0600

Seen: 5,977 times

Last updated: Nov 27 '18