Open song-hl opened 1 year ago
What's more. Is there some methods I can get a images obs from the env. And is it possible for isaacgymenv to train a RL agent with a image input
I've found the solution for your first question. graphics_device_id
need to be passed to isaacgymenvs.make
, otherwise it will be set to -1 by default and cause the error. I use the following code and it works well.
envs = isaacgymenvs.make(
seed=0,
task="Ant",
num_envs=2000,
sim_device="cuda:0",
rl_device="cuda:0",
graphics_device_id=0,
headless=False
)
I've found the solution for your first question.
graphics_device_id
need to be passed toisaacgymenvs.make
, otherwise it will be set to -1 by default and cause the error. I use the following code and it works well.envs = isaacgymenvs.make( seed=0, task="Ant", num_envs=2000, sim_device="cuda:0", rl_device="cuda:0", graphics_device_id=0, headless=False )
Thank you, ashuai.
I've found the solution for your first question.
graphics_device_id
need to be passed toisaacgymenvs.make
, otherwise it will be set to -1 by default and cause the error. I use the following code and it works well.envs = isaacgymenvs.make( seed=0, task="Ant", num_envs=2000, sim_device="cuda:0", rl_device="cuda:0", graphics_device_id=0, headless=False )
Thanks, it works fine for me. Or set headless as True to close the render window, but it seems not a good idea.
I've found the solution for your first question.
graphics_device_id
need to be passed toisaacgymenvs.make
, otherwise it will be set to -1 by default and cause the error. I use the following code and it works well.envs = isaacgymenvs.make( seed=0, task="Ant", num_envs=2000, sim_device="cuda:0", rl_device="cuda:0", graphics_device_id=0, headless=False )
Thanks, it works fine for me. Or set headless as True to close the render window, but it seems not a good idea.
Thank you! Setting either to graphics_device_id=0
or headless=True
solves my problem.
How can I get image obs from isaacgym in a headless device? even if when I use a HEADED device , and set
headless = False, virtual_screen_capture =True
, I tried following code.GOT OUTPUT WITH ERROR:
[Error] [carb.gym.plugin] Error creating viewer: Sim->Graphics is nullptr
It seems that the error raised by 235 line in vec_task.pyself.viewer = self.gym.create_viewer( self.sim, gymapi.CameraProperties())
I can't find a solution to it , please help me.