Skip to content

Commit

Permalink
Fix small bug in testspeed.
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 627773755
Change-Id: Iebbcaa41cfdde126312e388d368843a4754abfb8
  • Loading branch information
btaba authored and copybara-github committed Apr 24, 2024
1 parent 1c8ff66 commit 0a60d55
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions mjx/mujoco/mjx/testspeed.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,9 @@

def _main(argv: Sequence[str]):
"""Runs testpeed function."""
base_path = _BASE_PATH.value or epath.resource_path('mujoco.mjx')
f = base_path / 'test_data' / _MJCF.value
path = epath.resource_path('mujoco.mjx') / 'test_data'
path = _BASE_PATH.value or path
f = epath.Path(path) / _MJCF.value
m = mujoco.MjModel.from_xml_path(f.as_posix())

print(f'Rolling out {_NSTEP.value} steps at dt = {m.opt.timestep:.3f}...')
Expand Down

0 comments on commit 0a60d55

Please sign in to comment.