Model: MM-ABC | Source: included in MM_ABC/
MM-ABC combines a Qwen3-VL backbone with a dual-stream flow-matching action
expert for mobile manipulation. Both training recipes default to clean-action
prediction (pred_type: x) with velocity-space loss (loss_type: v).
The adapter includes data conversion, training, checkpoint loading, and websocket
inference. Shared argument and deployment conventions are in the
XPolicyLab README.
The supplied embodiment is m92uw, with action_type=joint: two arms, dexterous
hands, waist, leg, wrist/head poses, and base velocities. Its 11 action fields
are defined in MM_ABC/mmabc/embodiments/mobile.py; the full mobile layout extends
the shared arm/gripper dimension schema. Training freezes the layout and
normalization metadata with each checkpoint. Other robots require a matching
embodiment configuration and environment client.
Use a Python environment with CUDA-enabled PyTorch and FlashAttention 2:
cd XPolicyLab/policy/MM_ABC
export MMABC_PYTHON=/path/to/environment/bin/python
bash install.shMMABC_PYTHON selects the interpreter. Otherwise, scripts resolve the supplied
conda environment, environment directory, or executable; none uses Python on
PATH. CONDA_ENVS_PATH can supply additional environment roots.
See MM_ABC/requirements.txt for dependencies.
Prepare these assets locally under pretrained_ckpt/:
Qwen3-VL-4B-Instruct/: backbone weights, tokenizer, and processor.vggt-omega/: teacher source, andVGGT-Omega-1B-256-Text-Alignment/: teacher weights; required by the default future-alignment training recipe.mmabc_pretrain_200k/: compatible exported MM-ABC weights, only forMODE=pretrain. These weights are not distributed with this adapter.
Inference uses the backbone assets and a trained MM-ABC checkpoint; it does not
load the teacher. Asset, dataset, and checkpoint paths resolve against this
adapter directory, overridden by MMABC_HOME. Configuration paths resolve
against the nested source tree, overridden by MMABC_ROOT.
bash process_data.sh <bench_name> <ckpt_name> m92uw joint [expert_data_num]
BENCH_NAME=custom
MOBILE_SRC=/path/to/episodes WORKERS=8 \
bash process_data.sh "$BENCH_NAME" mobile-policy m92uw jointThe source layout is <source>/<task>/data/episode_*.hdf5; EPISODE_SUBDIR
changes the directory between task and episode. Without MOBILE_SRC, input
comes from data/raw/. Episodes contain state/, action/, vision/, and an
instruction. Camera names are cam_head, cam_left_wrist, and
cam_right_wrist. Encoded frames pass through the shared decode_image_bit
helper, and runtime observations are already RGB arrays.
Conversion creates data/mobile_mmabc/<task>/ and its 80-dimensional derivative
data/mobile_mmabc_c80/<task>/. Both use LeRobot v3.0 storage with custom
packed state/action fields and per-camera videos. Their embodiment metadata,
canonical layouts, mixtures, and normalization statistics are generated by the
included converters; generic exports from the official converters need this
policy-specific conversion before training. The 75-dimensional model layout
expands pose rotations to 6D; runtime poses remain position plus quaternion.
The optional episode count caps conversion per task. Reruns skip completed
episodes and refresh metadata. Conversion updates generated configurations
inside MM_ABC/configs/; review those changes before a later source commit.
bash train.sh <bench_name> <ckpt_name> m92uw joint <seed> <gpu_id> [key=value ...]
bash train.sh custom mobile-policy m92uw joint 0 all
MODE=pretrain bash train.sh custom mobile-pretrained m92uw joint 0 0,1| Setting | Default recipe | MODE=pretrain |
|---|---|---|
| Config | configs/train/mobile.yaml |
configs/train/mobile_pretrain.yaml |
| Initialization | Qwen backbone and fresh action expert | Compatible MM-ABC weights |
| Layout | 75-dimensional absolute commands | 80-dimensional canonical layout |
| Flow objective | x-pred / v-loss | x-pred / v-loss |
The mobile recipes predict 32 steps, execute 16, and use 10 Euler integration
steps. TRAIN_CONFIG selects a custom training file. Trailing overrides, such
as max_steps=20 or model_overrides.flow.pred_type=x, are passed to the trainer.
Optional experiment tracking uses WANDB_API_KEY or MMABC_WANDB_ENV.
For multiple nodes, prepare MM_ABC/configs/cluster/hostfile and set
NODES=multi. SUPERVISED=1 enables the included relaunch wrapper. Cluster
scripts require SSH access, shared paths, and suitable network settings; see the
nested guide.
Runs are written to:
checkpoints/<bench_name>-<ckpt_name>-m92uw-joint-<seed>/
├── milestones/step_*/ # Inference weights
├── resume/step_*/ # Training resume state
└── run_meta/ # Model config, layout, statistics, key contract
Keep run_meta/ with the checkpoint directories. Do not commit any generated
weights, datasets, or logs. Policy-local ignore rules cover these artifacts.
bash eval.sh <bench_name> <task_name> <ckpt_name> m92uw joint <seed> \
<policy_gpu_id> <env_gpu_id> <policy_environment> <client_environment>
EVAL_ENV_TYPE=debug MOCK=true \
bash eval.sh custom debug unused m92uw joint 0 0 0 none none
EVAL_ENV_TYPE=debug DEBUG_OBS_ENCODED=1 EVAL_BATCH=true \
bash eval.sh custom debug mobile-policy m92uw joint 0 0 0 none noneThe debug client supports synthetic observations and REPLAY_HDF5 recordings.
MOCK=true returns hold-state actions without loading weights; it checks the
interface, not learned policy quality. Unset MOCK to evaluate a checkpoint.
For replay, REPLAY_START, EVAL_EPISODE_NUM, and EPISODE_STEP_LIMIT control
the run. Encoded debug frames use the shared encode_image_bit helper.
Normal evaluation uses the shared environment client. The client must implement
the mobile state/action contract. Returned chunks contain singular action keys
and pose quaternions ordered [qw, qx, qy, qz], in the base frame.
For separate policy and client machines:
BENCH_NAME=custom TASK_NAME=task \
bash eval_server.sh mobile-policy 0,1 19000 noneThis starts one server per GPU on consecutive ports. PUBLIC_IP controls the
advertised address. eval_server.sh accepts additional deployment key=value
overrides after the environment argument.
deploy.yml key |
Default | Meaning |
|---|---|---|
mock |
false | Use hold-state actions for interface checks |
checkpoint_path |
null | Explicit run or milestone directory |
ckpt_step |
null | Milestone step; otherwise newest completed milestone |
mmabc_root |
null | Override the included source tree |
execute_steps |
null | Use checkpoint execution length |
num_inference_steps |
null | Use checkpoint integration-step count |
device |
cuda | Inference device |
action_key_style |
singular | Singular runtime or plural recorded-data keys |
allow_missing_state_keys |
false | Fill missing state fields with neutral values |
request_timeout_s |
600 | Client RPC timeout |
Checkpoint roots use the shared XPolicyLab resolver. A ckpt_name containing a
path separator is resolved as a path; otherwise the standard run naming applies.
Model configuration saved in run_meta/ controls existing checkpoints, so changing
training defaults does not silently change a saved model's prediction type.