MCPcopy Create free account
hub / github.com/google-deepmind/dm_control / origin

Method origin

dm_control/suite/quadruped.py:214–218  ·  view source on GitHub ↗

Returns origin position in the torso frame.

(self)

Source from the content-addressed store, hash-verified

212 return np.asarray(np.linalg.norm(self.named.data.site_xpos['workspace']))
213
214 def origin(self):
215 """Returns origin position in the torso frame."""
216 torso_frame = self.named.data.xmat['torso'].reshape(3, 3)
217 torso_pos = self.named.data.xpos['torso']
218 return -torso_pos.dot(torso_frame)
219
220 def ball_state(self):
221 """Returns ball position and velocity relative to the torso frame."""

Callers 1

get_observationMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected