Balance board
Articulations
Restore balance by placing the missing counterweight.
steel preset (the default), recordedon an NVIDIA RTX PRO 6000 Blackwell, sped up 2× (the readout shows sim time).Run it
cd examples# the default preset (steel), then the othersuv run shelf play balance_board# change solver settings liveuv run shelf tune balance_boardSource: examples/shelf/07_articulations/balance_board/ · ported from steel-webgpu assets/scenes/balance_board (hero_montage export) @ ad03e49
Presets
| Preset | Solver | Status | Checked |
|---|---|---|---|
steeldefault | steel | works | 2026-11-10, newton f6fc82a8b, NVIDIA RTX PRO 6000 Blackwell Server Edition |
Solvers with no row are untested on this example. The full settings are inpresets.toml.
Code
# SPDX-FileCopyrightText: Copyright (c) 2026 Skild AI and the Steel contributors# SPDX-License-Identifier: Apache-2.0# Direct source: steel-webgpu; see presets.toml and THIRD_PARTY.md.# Modified for Steel Shelf: preset-driven execution and shared runner integration.
############################################################################ Example Balance board## A spring-loaded balance beam tips because one counterweight is missing; the arm puts it back and the beam levels out.## Rebuilt from steel-webgpu's exported scene (assets/scenes/balance_board: scene.json# and scene.bin, copied next to this file); see common/exported_scene.py. The# visual meshes draw when a steel-webgpu checkout sits next to the shelf.## Command: python -m shelf run balance_board############################################################################
import numpy as np
import newton.examplesfrom common.exported_scene import ExportedSceneExample
class Example(ExportedSceneExample): file = __file__
def test_post_step(self): pivot = float(self.state_0.joint_q.numpy()[self.model.joint_q_start.numpy()[16]]) # balance.pivot.q self._tip = min(getattr(self, "_tip", 0.0), pivot) self._pivots = (getattr(self, "_pivots", []) + [pivot])[-60:]
def check(self): """The beam tips (about -0.28 rad), the arm places the missing weight and the beam levels out at +0.023 rad (a converged 16 x 32 run) and stays there.""" assert self._tip < -0.2, f"the beam only tipped to {self._tip:.3f} rad" level = self._pivots[-1] assert abs(level - 0.023) < 0.01, f"the beam ends at {level:.4f} rad, converged +0.023" assert np.ptp(self._pivots) < 0.002, f"the beam still moves {np.ptp(self._pivots):.4f} rad in the last second"
if __name__ == "__main__": parser = Example.create_parser() viewer, args = newton.examples.init(parser) newton.examples.run(Example(viewer, args), args)example = "balance_board"source = "steel-webgpu assets/scenes/balance_board (hero_montage export) @ ad03e49"default = "steel"
[check]# Arguments `python -m shelf check` passes in test mode: 720 frames, the whole task and two still seconds (the beam levels out by frame ~600); the example's check() asserts the outcome.args = ["--num-frames", "720"]
[gallery]short = "Restore balance by placing the missing counterweight."title = "Balance board"frame = 420
[xpbd]status = "untested"
[vbd]status = "untested"
[mujoco]status = "untested"
[featherstone]status = "untested"
[semi_implicit]status = "untested"
[feather_pgs]status = "untested"
[steel]status = "works"# 2 substeps x 8 iterations, immediate response, contact warm start (so no sleeping: this Newton's Steel does# not combine them): the fastest setting that matches a converged 16 x 32 run with the palm-on-weight grip under# 2 mm. The beam tips to -0.276 rad, the arm places the missing weight within 1-7 mm of where the converged run# puts it, and the beam settles at +0.024 rad (converged +0.023) by frame 568. With the gripper's finger mimic# (cfeff10) 2 x 4 grips 2.8-3.0 mm deep (1.8 mm without the mimic); 2 x 8: 1.6-1.9 mm, 3 x 8: 0.9 mm at 3.6 ms.# Without warm start 2 x 4 reaches 5.2 mm. Every setting tried does the task. Velocity limits off: every exported# limit is 1e6. Rows: at most 54 used.sim = { fps = 60, substeps = 2 }solver = { solve_mode = "matrix_free", iterations = 8, articulated_contact_response = "immediate", enable_joint_limits = true, joint_limit_activation_gap = 0.1, enable_joint_velocity_limits = false, contact_warmstart = true, articulation_constraint_max = 128, free_body_constraint_max = 128 }checked = "2026-11-10, newton f6fc82a8b, NVIDIA RTX PRO 6000 Blackwell Server Edition"
[kamino]status = "untested"
[implicit_mpm]status = "untested"
[style3d]status = "untested"Steel docs and tutorials are licensed under Apache-2.0. Third-party notices. "Skild", "Skild AI" and the Skild logo are trademarks of Skild AI and are not licensed under Apache-2.0.