-
Notifications
You must be signed in to change notification settings - Fork 27
Description
I set the floating_base parameter to False because I want to control a full humanoid robot. However, in the rendered images, the initial frame only shows the upper body of the robot and not the legs.
In the subsequent rendered images, I noticed that the agent's legs are gradually rendered, and the robot seems to be initialized in a way that looks like it was ejected or "fired" into place.
This kind of initialization of the robot causes my humanoid robot algorithm to be unable to learn properly. Is this behavior expected?
The code I am using is as follows:
def test_can_step_and_render_rgb_array_mode( self, env_class: type[BiGymEnv], action_mode_class: type[ActionMode] ): env = env_class( action_mode=action_mode_class(floating_base=False), render_mode="rgb_array" ) img = env.render() print(f"img {type(img)}, shape is {img.shape}") obs, _ = env.reset() for i in range(50): obs, rew, term, trunc, info = env.step(env.action_space.sample()) print(f"obs typs{type(obs)}") for k,v in obs.items(): print(f" k is {k} and v shape is {type(v)} shape is {v.shape}") img = env.render() image = Image.fromarray(img) # 保存图像 image.save(f"output_image_{i}.png") self._assert_step_data(env.observation_space, obs, rew, term, trunc, info) assert img.shape[-1] == 3 # RGB image assert img.ndim == 3 # 3 dimensions (h, w, c) env.close()




