Roboparty / P-BFM
git clone https://github.com/Roboparty/P-BFM.git
Perceptive behavioral foundation models for terrain-adaptive humanoid control: motion tracking, goal reaching, reward inference and teleoperation.
+5
stars, 24h · #2,656
+~35
stars, 7 days · #3,300
+84
stars, 30 days · #6,257
91
★ total · +35% this week
9
forks · 0 open issues
Star history (as recorded here)
LanguagePython
License—
Created2026-10-04 (18d ago)
Last push3d ago
Watchers1
OwnerOrganization
GitHub topics
Links
- GitHub: github.com/Roboparty/P-BFM
- Homepage: https://roboparty.github.io/P-BFM/
- Releases · Issues · Hacker News mentions
README excerpt
P-BFM: Perceptive Behavioral Foundation Models for Humanoid Control via Unsupervised Reinforcement Learning English | 中文 P-BFM is a perceptive behavioral foundation model for terrain-adaptive humanoid control. It maps **motion references, target body states, and reward functions** into a shared intent space. A single frozen policy combines these intents with depth perception and explicit heading and velocity instructions to execute whole-body behaviors across terrains. Training uses **40 flat-ground LaFAN motion sequences and online interaction with simulated terrains**, without terrain-specific motion demonstrations. The policy transfers zero-shot to a **Unitree G1 with onboard depth sensing**, supporting motion tracking, goal reaching, reward inference, teleoperation, and terrain-aware recovery. Architecture · Training · Inference / export ## Layout [code] Configuration files are bundled under `pbfm/configs/`, including in the installed package; downloaded motions, weights, replay and videos stay external. ## Model and settings | Component | Hidden width × layers | | --- | --- | | Actor / Forward F | 2048 × 6 | | QD | 1024 × 4 | | QAux | 2048 × 4 | | QH / QV | 1024 × 3 | The four critics are independent; each uses two Q estimates. The training preset is `fb_depth`: BCE/log-odds, D=.01, Aux=.02, QH=QV=.002, dynamic Aux normalization, LaFAN-only, slippage=-4, stumble=-2. Depth is Crop18 (`8×18×32`), CNN stride 1, frame feature 256 and GRU feature 256. The velocity estimator is depth-supervised. ## Install and train Python 3.10, MJLab 1.4, MuJoCo 3.8, PyTorch 2.7. Install from the repository root: [code] Fresh 192M training (eight free GPUs, GPU replay; edit the data/output paths): [code] Add `--use-wandb` after authenticating separately. Add `--smoke` with a different new work directory for a 32768-step short test. These commands do not stop other users' jobs or wait for free GPUs. Use the scratch entry point above for training from step 0: it sets 192020480 total global steps and starts the terrain curriculum at step 0. See Training for schedule and checkpoint requirements. ## Inference and export [code] Tracking selects terrain and camera settings in the same entry point. The policy ONNX includes depth encoding and velocity estimation; the backward encoder is exported separately. Input normalization, context and hardware control requirements are described in the inference guide. ## Tests [code] External-data/hardware checks are explicitly skipped when their inputs are unavailable. CPU and small-model ONNX tests are not full training or real-robot validation. PBFM builds on UFO. Original notices and the upstream CC BY-NC 4.0 license are retained. ## Project and community - Project website and demos: https://roboparty.github.io/P-BFM/ - Paper: https://arxiv.org/abs/2610.15833 - Team: RoboPartyLab - Contact: xuewangusst@gmail.com - To join our discussion group, add **15251239451** on WeChat. ## Repository branches - `main`: PBFM traini