MCPcopy Create free account
hub / github.com/InternRobotics/UniHSI / reset

Method reset

unihsi/env/tasks/vec_task.py:110–117  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

108 return torch.clamp(self.obs_tensor, -self.clip_obs, self.clip_obs), self.rewards_tensor, self.resets_tensor, []
109
110 def reset(self):
111 actions = 0.01 * (1 - 2 * torch.rand([self.task.num_envs, self.task.num_actions], dtype=torch.float32, device=self.rl_device))
112 actions_tensor = gymtorch.unwrap_tensor(actions)
113
114 # step the simulator
115 self.task.step(actions_tensor)
116
117 return torch.clamp(self.obs_tensor, -self.clip_obs, self.clip_obs)
118
119
120# Python CPU/GPU Class

Callers

nothing calls this directly

Calls 1

stepMethod · 0.45

Tested by

no test coverage detected