Agent Skills › dartsim/dart › dart-python

dart-python

GitHub

DART Python绑定(dartpy)开发技能,涵盖nanobind绑定、Wheels构建、API设计及GUI渲染集成。用于处理Python与C++ DART库的交互、测试及发布流程。

.agents/skills/dart-python/SKILL.md dartsim/dart

Trigger Scenarios

开发或维护dartpy Python绑定 配置nanobind绑定逻辑 构建或修复Python Wheels 集成Filament GUI渲染功能

Install

npx skills add dartsim/dart --skill dart-python -g -y
More Options

Non-standard path

npx skills add https://github.com/dartsim/dart/tree/main/.agents/skills/dart-python -g -y

Use without installing

npx skills use dartsim/dart@dart-python

指定 Agent (Claude Code)

npx skills add dartsim/dart --skill dart-python -a claude-code -g -y

安装 repo 全部 skill

npx skills add dartsim/dart --all -g -y

预览 repo 内 skill

npx skills add dartsim/dart --list

SKILL.md

Frontmatter
{
    "name": "dart-python",
    "description": "DART Python: dartpy bindings, nanobind, wheels, and API patterns"
}

DART Python Bindings (dartpy)

Load this skill when working with Python bindings or dartpy.

When a binding exposes or changes model/scene loading, dynamics, collision/contact/constraints, simulation stepping, GUI/Filament output, or a visual example, also load dart-verify-sim. Pair a focused Python text/behavior oracle with an assessed, claim-tied Filament capture; document a visual exception when capture is unavailable or not applicable.

Quick Start

import dartpy as dart

world = dart.simulation.World()
loader = dart.utils.DartLoader()
skel = loader.parseSkeleton("dart://sample/urdf/KR5/KR5 sixx R650.urdf")
world.addSkeleton(skel)

for _ in range(100):
    world.step()

Full Documentation

For complete Python bindings guide: docs/onboarding/python-bindings.md

For current examples and test patterns: python/examples/ and python/tests/

Quick Commands

pixi run build-py-dev    # Build for development
pixi run test-py         # Run Python tests that need no graphics device
pixi run test-gui        # Run dartpy.gui rendering and integration tests

Wheel Building

This development branch ships Pixi-managed wheel tasks. The core tasks are wheel-build-core, wheel-repair-linux-core, wheel-repair-macos-core, wheel-repair-windows-core, wheel-verify-core, and wheel-test-core; the per-Python environments py310-wheel through py313-wheel expose wheel-build, wheel-repair, wheel-verify, and wheel-test on top of them. CI runs them in .github/workflows/publish_dartpy.yml (for example pixi run -e py313-wheel wheel-build). See docs/onboarding/python-bindings.md for the wheel workflow overview.

Key Patterns

  • nanobind is dartpy's only binder on main, under python/dartpy/. Use the DART 6.20 compatibility notes in the owner guide.
  • Until the PLAN-624 rename lands, follow the current binding names in python/examples and python/tests; bind new DART 7 APIs directly in the DART 7 Python style (snake_case, properties, keyword-only options) from the PLAN-624 design doc.
  • NumPy arrays auto-convert to Eigen types
  • dartpy.gui always exists: dartpy requires DART_BUILD_IO and DART_BUILD_GUI. GUI callers use the Filament-backed dart.gui.Viewer and related neutral classes; import and viewer construction need no display.

Key Files

  • Package config: pyproject.toml
  • Binding dependencies: python/CMakeLists.txt
  • Binding build system: python/dartpy/CMakeLists.txt

Version History

  • f630c91 Current 2026-10-18 20:25

    从pybind11迁移至nanobind作为唯一绑定器;引入ABI3 Wheels支持;更新CI以main为默认开发分支;移除OSG GUI并替换为Filament;优化DART 7.0 API设计模式。

  • deb9869 2026-09-08 21:45

    新增Quick Start代码示例,整合AI指导并改进模型升级审计流程。

  • bcd584e 2026-09-02 23:41

    简化了加载 dart-verify-sim skill 的条件,从覆盖模型/场景加载等广泛领域缩减为仅针对 3D 结构或行为变更的场景。

  • b9fbefc 2026-07-19 11:30

Same Skill Collection

.agents/skills/dart-analyze/SKILL.md
.agents/skills/dart-architecture/SKILL.md
.agents/skills/dart-audit-agent-compliance/SKILL.md
.agents/skills/dart-backport-pr/SKILL.md
.agents/skills/dart-benchmark-packet/SKILL.md
.agents/skills/dart-branch-cleanup/SKILL.md
.agents/skills/dart-build/SKILL.md
.agents/skills/dart-changelog/SKILL.md
.agents/skills/dart-ci/SKILL.md
.agents/skills/dart-close-issue/SKILL.md
.agents/skills/dart-contribute/SKILL.md
.agents/skills/dart-deps/SKILL.md
.agents/skills/dart-docs-update/SKILL.md
.agents/skills/dart-downstream-fix/SKILL.md
.agents/skills/dart-execute-packet/SKILL.md
.agents/skills/dart-fix-issue/SKILL.md
.agents/skills/dart-io/SKILL.md
.agents/skills/dart-manage-pr/SKILL.md
.agents/skills/dart-mechanical-refactor/SKILL.md
.agents/skills/dart-model-upgrade/SKILL.md
.agents/skills/dart-new-task/SKILL.md
.agents/skills/dart-next/SKILL.md
.agents/skills/dart-perf/SKILL.md
.agents/skills/dart-plan-update/SKILL.md
.agents/skills/dart-pr/SKILL.md
.agents/skills/dart-references/SKILL.md
.agents/skills/dart-release-ci-fix/SKILL.md
.agents/skills/dart-release-merge-main/SKILL.md
.agents/skills/dart-release-packaging/SKILL.md
.agents/skills/dart-resume/SKILL.md
.agents/skills/dart-retro/SKILL.md
.agents/skills/dart-review-pr/SKILL.md
.agents/skills/dart-test/SKILL.md
.agents/skills/dart-triage-issue/SKILL.md
.agents/skills/dart-ultrawork/SKILL.md
.agents/skills/dart-verify-sim/SKILL.md
.claude/skills/dart-architecture/SKILL.md
.claude/skills/dart-build/SKILL.md
.claude/skills/dart-ci/SKILL.md
.claude/skills/dart-contribute/SKILL.md
.claude/skills/dart-io/SKILL.md
.claude/skills/dart-perf/SKILL.md
.claude/skills/dart-python/SKILL.md
.claude/skills/dart-references/SKILL.md
.claude/skills/dart-test/SKILL.md
.claude/skills/dart-verify-sim/SKILL.md
.codex/skills/dart-analyze/SKILL.md
.codex/skills/dart-architecture/SKILL.md
.codex/skills/dart-audit-agent-compliance/SKILL.md

Metadata

Files
0
Version
f630c91
Hash
9036265c
Indexed
2026-07-19 11:30

Home - Wiki
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-10-20 01:19
浙ICP备14020137号-1