Add live gamma sweep visualization for safeMPPI vs CFM-MPPI - #1
Add live gamma sweep visualization for safeMPPI vs CFM-MPPI#1DHLeexpress wants to merge 11 commits into
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 46a40d863e
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| @@ -0,0 +1,26 @@ | |||
| #!/usr/bin/env bash | |||
There was a problem hiding this comment.
Make the sweep script executable
This script is documented and invoked as scripts/run_gamma_sweep.sh, but the new file is committed with mode 100644 while the existing runnable scripts in this repo are 100755. On a fresh checkout, both the documented command and the chained call from train_gpc_then_gamma_sweep.sh fail with Permission denied; commit it executable or invoke it via bash.
Useful? React with 👍 / 👎.
| python -m cfm_mppi.training.train_safe_cfm \ | ||
| --epochs "$GPC_EPOCHS" \ | ||
| --batch-size "$GPC_BATCH_SIZE" \ | ||
| --device "$GPC_DEVICE" \ | ||
| $GPC_EXTRA_ARGS 2>&1 | tee logs/train_gpc_overnight.log |
There was a problem hiding this comment.
Do not train a checkpoint the sweep never loads
When SKIP_GPC_TRAIN is unset, this overnight path trains output_dir/safe_contextual_cfm/checkpoint_best.pth, but the subsequent gamma sweep only runs rollout_mizuta and online rollout_safemppi with SafeMPPIAdapter; the --safe-cfm-checkpoint value is not used on that path. This can spend hours training a model whose checkpoint cannot affect the reported comparison, making experiment results misleading unless the sweep actually evaluates the trained policy or the training step is removed.
Useful? React with 👍 / 👎.
Summary
Adds a gamma-sweep visualization workflow comparing Mizuta CFM-MPPI against online safeMPPI across gamma in
[0, 1].What changed
gamma_sweep_records.jsonl.summary.csv,summary.json, andsummary.md.scripts/run_gamma_sweep.sh.scripts/train_gpc_then_gamma_sweep.shto train safe contextual CFM/GPC before running the sweep.docs/GAMMA_SWEEP.mdwith the overnight commands.Verification
python -m py_compile.checks/gamma_grid_check.py.Notes
safeMPPI itself is not trained. Mizuta's pretrained model is expected at
output_dir/cfm_transformer/checkpoint.pth. The GPC/safe contextual CFM training step requires the local canonical dataset files and should be run on the target Ubuntu machine.