Unify WBT into policy_service_node; retire holosoma_node#132
Merged
tomasz-lewicki merged 2 commits intoJun 24, 2026
Merged
Conversation
Make the Variant B service node (policy_service_node) the single entrypoint for both locomotion and WBT, and remove the separate holosoma_node. - dual_mode._select_policy_class: resolve config.task.policy_type via the holosoma.policies.by_type entry-point group before the robot_type/obs heuristic. Additive and generic -- core reads an optional policy_type via getattr and resolves classes by string, so it never imports or names extension-private policy classes. This lets the service node resolve extension WBT presets identically to the standalone run_policy path. - teleop_with_holosoma_policy.launch.py: drive policy_service_node (was holosoma_node), keep the smplh/dense input_type + conditional retargeter, and expose the velocity/state/interface/domain/node-name knobs. - Delete holosoma_node.py and its console_scripts entry; the dense TargetSource path it provided already exists in ServiceIONode (subscribes CmdDense, serves get_target(), attaches via _attach_target_source). - Tests: resolver resolution-order coverage; service-node attach/iter coverage (ROS-guarded). Docs/diagram updated.
Local ruff (0.15.8) grouped first-party holosoma_* imports with third-party; CI's pinned ruff sorts them into a separate first-party block. Import-order only, no behavior change.
tomasz-lewicki
approved these changes
Jun 24, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Makes the Variant B service node (
policy_service_node) the single entrypoint for both locomotion and WBT, and removes the separateholosoma_node. This is the unified entrypoint we deferred when picking Variant B in #128/#129.Builds on #124 (
dev/tomasz/tracker_service) — base this branch, not main.How it works
Most of the WBT path already worked through Variant B:
WholeBodyTrackingPolicyhonors_target_sourceattribute injection (set post-build, read only at runtime inrl_inference()), andServiceIONodealready subscribesCmdDense+ servesget_target(). The one gap was policy resolution — the node resolved via core_select_policy_class, which didn't honorconfig.task.policy_type/ theholosoma.policies.by_typeentry-point group.Changes
dual_mode._select_policy_class— resolveconfig.task.policy_typeagainst theholosoma.policies.by_typeentry-point group before the existing robot_type/motion_commandheuristic. Additive and generic: core reads an optionalpolicy_typeviagetattrand resolves classes by string through the entry-point group, so it never imports or hardcodes any policy class.teleop_with_holosoma_policy.launch.py— drivepolicy_service_node(washolosoma_node); keep theinput_type:=smplh|denseselector + conditional retargeter; expose thevelocity_input/state_input/interface/domain_id/node_nameknobs.holosoma_node.py+ itsconsole_scriptsentry. Its denseTargetSourcebehavior already lives inServiceIONode(_attach_target_source)._select_policy_class;_attach_target_source/_iter_policiescoverage (ROS-guarded so it skips off-container). Docs/diagram updated.Testing
ruff+ruff-format: clean.pytest src/holosoma_inference/.../test_select_policy_class.py: 6/6 pass (real package). Service-node attach test skips off-ROS (runs in the inference CI container).