From 53d8f6b785eaa0bd15a36163dd15512d2b0d4973 Mon Sep 17 00:00:00 2001 From: Simon Alibert Date: Sun, 5 May 2024 14:46:29 +0200 Subject: [PATCH] Cleanup eval example --- README.md | 9 +++------ examples/3_train_policy.py | 1 - 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 22e25525..a867e2e1 100644 --- a/README.md +++ b/README.md @@ -133,20 +133,17 @@ Check out [example 2](./examples/2_evaluate_pretrained_policy.py) to see how you Or you can achieve the same result by executing our script from the command line: ```bash -# TODO: Not working right now, update `lerobot/diffusion_policy_pusht_image` to fix python lerobot/scripts/eval.py \ -p lerobot/diffusion_pusht \ - eval_episodes=10 \ - hydra.run.dir=outputs/eval/example_hub + eval.n_episodes=10 \ + eval.batch_size=10 ``` After training your own policy, you can also re-evaluate the checkpoints with: ```bash python lerobot/scripts/eval.py \ - -p PATH/TO/TRAIN/OUTPUT/FOLDER \ - eval_episodes=10 \ - hydra.run.dir=outputs/eval/example_dir + -p PATH/TO/TRAIN/OUTPUT/FOLDER ``` See `python lerobot/scripts/eval.py --help` for more instructions. diff --git a/examples/3_train_policy.py b/examples/3_train_policy.py index 69e3d34c..134271ea 100644 --- a/examples/3_train_policy.py +++ b/examples/3_train_policy.py @@ -33,7 +33,6 @@ dataset = make_dataset(hydra_cfg) # For this example, no arguments need to be passed because the defaults are set up for PushT. # If you're doing something different, you will likely need to change at least some of the defaults. cfg = DiffusionConfig() -# TODO(alexander-soare): Remove LR scheduler from the policy. policy = DiffusionPolicy(cfg, dataset_stats=dataset.stats) policy.train() policy.to(device)