Views
No views yet
1LDA-robocasa.pt
2config.yaml
3dataset_statistics.jsonLDA-robocasa.pt: PyTorch checkpoint weights.config.yaml: model configuration used to rebuild the LDA framework.dataset_statistics.json: dataset normalization statistics used to un-normalize predicted actions during inference..pt checkpoint to be placed inside a subdirectory, usually named checkpoints, while config.yaml and dataset_statistics.json must stay in the parent run directory.1LDA-robocasa/
2|-- config.yaml
3|-- dataset_statistics.json
4`-- checkpoints/
5 `-- LDA-robocasa.ptLDA-robocasa/checkpoints/LDA-robocasa.ptbaseframework.from_pretrained() loads the checkpoint path and infers the run directory from it:1checkpoint_pt = Path(pretrained_checkpoint)
2run_dir = checkpoint_pt.parents[1]LDA-robocasa/checkpoints/LDA-robocasa.ptLDA-robocasa1LDA-robocasa/config.yaml
2LDA-robocasa/dataset_statistics.jsonLDA-robocasa.pt is placed directly next to config.yaml and dataset_statistics.json, the loader will infer the wrong parent directory and fail to find the required files.huggingface_hub:1from pathlib import Path
2import shutil
3
4from huggingface_hub import snapshot_download
5
6repo_dir = Path(snapshot_download(repo_id="YOUR_ORG_OR_USERNAME/LDA-robocasa"))
7
8ckpt_dir = repo_dir / "checkpoints"
9ckpt_dir.mkdir(exist_ok=True)
10
11src_ckpt = repo_dir / "LDA-robocasa.pt"
12dst_ckpt = ckpt_dir / "LDA-robocasa.pt"
13
14if src_ckpt.exists() and not dst_ckpt.exists():
15 shutil.move(str(src_ckpt), str(dst_ckpt))
16
17print("Checkpoint path:", dst_ckpt)YOUR_ORG_OR_USERNAME/LDA-robocasa with the actual Hugging Face repository ID.1from lda.model.framework.base_framework import baseframework
2
3ckpt_path = "LDA-robocasa/checkpoints/LDA-robocasa.pt"
4
5model = baseframework.from_pretrained(ckpt_path)
6model = model.to("cuda").eval()1python deployment/model_server/server_policy.py \
2 --ckpt_path LDA-robocasa/checkpoints/LDA-robocasa.pt \
3 --port 10093 \
4 --use_bf161export PYTHONPATH=$(pwd):${PYTHONPATH}
2
3python examples/Robocasa_tabletop/eval_files/simulation_env.py \
4 --args.env_name ${env_name} \
5 --args.port 10093 \
6 --args.n_episodes 50 \
7 --args.n_envs 1 \
8 --args.max_episode_steps 720 \
9 --args.n_action_steps 12 \
10 --args.video_out_path ${video_out_path} \
11 --args.pretrained_path LDA-robocasa/checkpoints/LDA-robocasa.ptbash examples/Robocasa_tabletop/eval_files/batch_eval_args.shLDA-robocasa/checkpoints/LDA-robocasa.pt1LDA-robocasa/config.yaml
2LDA-robocasa/dataset_statistics.json
3LDA-robocasa/checkpoints/LDA-robocasa.pt.pt suffixconfig.yaml and dataset_statistics.jsonconfig.yamlMissing `config.yaml`1LDA-robocasa/
2|-- config.yaml
3|-- dataset_statistics.json
4`-- checkpoints/
5 `-- LDA-robocasa.ptLDA-robocasa/checkpoints/LDA-robocasa.ptLDA-robocasa/LDA-robocasa.ptdataset_statistics.jsonMissing `dataset_statistics.json`dataset_statistics.json is in the same directory as config.yaml, not inside the checkpoints directory..pt. Make sure the checkpoint file is named:LDA-robocasa.ptdataset_statistics.json is required for action un-normalization. Removing or replacing it can cause predicted actions to be scaled incorrectly.config.yaml is required because the LDA framework is rebuilt from the saved configuration before loading the checkpoint weights.