Skip to content

Commit

Permalink
pre commit
Browse files Browse the repository at this point in the history
  • Loading branch information
ChorntonYoel committed Nov 22, 2024
1 parent 6394d76 commit e73005e
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions lerobot/common/robot_devices/control_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -152,9 +152,12 @@ def on_press(key):
events["stop_recording"] = True
events["exit_early"] = True
elif assign_rewards and key == keyboard.Key.space:
print("Space key pressed. Assigning new rewards to the frames. New reward:", not events["reward"])
print(
"Space key pressed. Assigning new rewards to the frames. New reward:",
not events["reward"],
)
events["reward"] = not events["reward"]

except Exception as e:
print(f"Error handling key press: {e}")

Expand Down

0 comments on commit e73005e

Please sign in to comment.