Skip to content

Running a model trained earlier leads to stats error #1078

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
2 tasks done
Himhawkins opened this issue May 6, 2025 · 1 comment
Open
2 tasks done

Running a model trained earlier leads to stats error #1078

Himhawkins opened this issue May 6, 2025 · 1 comment
Labels
bug Something isn’t working correctly policies Items related to robot policies

Comments

@Himhawkins
Copy link

Himhawkins commented May 6, 2025

System Info

Error: File "/home/pranav/Repo/lerobot/lerobot/common/policies/normalize.py", line 169, in forward
    assert not torch.isinf(mean).any(), _no_stats_error_str("mean")
AssertionError: `mean` is infinity. You should either initialize with `stats` as an argument, or use a pretrained model.
 Can someone help with resolving this? I am getting this while running evaluate on an ACT model i trained. Model: ps5387/SHAKE29k

Information

  • One of the scripts in the examples/ folder of LeRobot
  • My own task or dataset (give details below)

Reproduction

Download the ps5387/SHAKE29k and running python lerobot/scripts/control_robot.py
--robot.type=so100
--control.type=record
--control.fps=30
--control.single_task="Grab and Shake hand when you see it"
--control.repo_id=ps5387/eval_act_so100_shake2_1
--control.tags='["so100","shake"]'
--control.warmup_time_s=5
--control.episode_time_s=25
--control.reset_time_s=10
--control.num_episodes=10
--control.push_to_hub=true
--control.policy.path=shake20k/pretrained_model

Expected behavior

Getting error File "/home/pranav/Repo/lerobot/lerobot/common/policies/normalize.py", line 169, in forward
assert not torch.isinf(mean).any(), _no_stats_error_str("mean")
AssertionError: mean is infinity. You should either initialize with stats as an argument, or use a pretrained model.

@CarolinePascal CarolinePascal added bug Something isn’t working correctly policies Items related to robot policies labels May 14, 2025
@CarolinePascal
Copy link
Collaborator

HI @Himhawkins !

Could you check if the naming issue reported in #1095 solves your issue as well ?

Best,

Caroline.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn’t working correctly policies Items related to robot policies
Projects
None yet
Development

No branches or pull requests

2 participants