How to change OpenGL options in Pybullet

Official Python bindings with a focus on reinforcement learning and robotics.
Post Reply
curieuxjy
Posts: 1
Joined: Tue Jun 21, 2022 7:03 am

How to change OpenGL options in Pybullet

Post by curieuxjy »

My computer spec
  • Ubuntu 20.04
  • Pybullet 3.2.1
I got a problem while loading my sdf file.
The error message was
Workaround for some crash in the Intel OpenGL driver on Linux/Ubuntu
and I found one of the solutions below.
Screenshot from 2022-06-21 15-19-17.png
Screenshot from 2022-06-21 15-19-17.png (30.79 KiB) Viewed 38397 times
Followed that solution and selected the Nvidia driver. However, there is no change and it was not solved.

I checked the pybullet GL_OPTIONS:

Code: Select all

GL_VENDOR=Intel
GL_RENDERER=Mesa Intel(R) UHD Graphics (CML GT2)
GL_VERSION=4.6 (Compatibility Profile) Mesa 21.2.6
GL_SHADING_LANGUAGE_VERSION=4.60
and GPU drivers.

Code: Select all

  *-display                 
       description: VGA compatible controller
       product: TU106M [GeForce RTX 2060 Mobile]
       vendor: NVIDIA Corporation
       physical id: 0
       bus info: pci@0000:01:00.0
       version: a1
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress vga_controller bus_master cap_list rom
       configuration: driver=nvidia latency=0
       resources: irq:164 memory:c4000000-c4ffffff memory:b0000000-bfffffff memory:c0000000-c1ffffff ioport:4000(size=128) memory:c5000000-c507ffff
  *-display
       description: VGA compatible controller
       product: CometLake-H GT2 [UHD Graphics]
       vendor: Intel Corporation
       physical id: 2
       bus info: pci@0000:00:02.0
       version: 05
       width: 64 bits
       clock: 33MHz
       capabilities: pciexpress msi pm vga_controller bus_master cap_list rom
       configuration: driver=i915 latency=0
       resources: irq:163 memory:c3000000-c3ffffff memory:a0000000-afffffff ioport:5000(size=64) memory:c0000-dffff

There is my question.

How can I change the GL_OPTIONS to my Nvidia GPU driver?
I couldn't find any instruction for that in Documentations or googling.

If you give me any advice, it will be really helpful for me, a newbie of pybullet.
glanzfreya
Posts: 3
Joined: Thu Jul 07, 2022 6:48 am

Re: How to change OpenGL options in Pybullet

Post by glanzfreya »

Maybe you need to install the latest Nouveau driver for Xorg. Since you are using Ubuntu/Linux, then check Nouveau driver for nVidia graphics card then adjust the Linux kernel module, enable Nouveau related module.
akin
Posts: 1
Joined: Sun Aug 21, 2022 11:15 am

Re: How to change OpenGL options in Pybullet

Post by akin »

I had exactly the same problem and the solution that worked for me is the following:

First, I updated NVIDIA drivers and selected the latest driver (nvidia-driver-515 for me) in the "Additional Drivers" section under "Software & Updates".
After rebooting, I then changed the power mode to "Performance" in the "Power" section under "Settings".
I then selected "NVIDIA (Performance Mode)" in the "PRIME Profiles" section of "NVIDIA Settings" (you can access this by typing nvidia-settings in the terminal).

After a reboot, GL_RENDERER changed to NVIDIA GPU and the problem was fixed.
Post Reply