Skip to content

Commit 58f70b6

Browse files
fix(scripts): better prints teleop (#2538)
1 parent b07160e commit 58f70b6

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/lerobot/scripts/lerobot_teleoperate.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -170,12 +170,13 @@ def teleop_loop(
170170
# Display the final robot action that was sent
171171
for motor, value in robot_action_to_send.items():
172172
print(f"{motor:<{display_len}} | {value:>7.2f}")
173-
move_cursor_up(len(robot_action_to_send) + 5)
173+
move_cursor_up(len(robot_action_to_send) + 3)
174174

175175
dt_s = time.perf_counter() - loop_start
176176
precise_sleep(1 / fps - dt_s)
177177
loop_s = time.perf_counter() - loop_start
178-
print(f"\ntime: {loop_s * 1e3:.2f}ms ({1 / loop_s:.0f} Hz)")
178+
print(f"Teleop loop time: {loop_s * 1e3:.2f}ms ({1 / loop_s:.0f} Hz)")
179+
move_cursor_up(1)
179180

180181
if duration is not None and time.perf_counter() - start >= duration:
181182
return

0 commit comments

Comments
 (0)