refactor: 统一 play 管线——训练入口复用 playback session 工厂 - #1250
Merged
TATP-233 merged 1 commit intoAug 21, 2026
Merged
Conversation
- Route play_rsl_rl / play_him_ppo / play_appo / play_offpolicy through the create_*_playback_session factories; scripts keep only CLI assembly, checkpoint diagnostics, ONNX/JIT export, and run_playback_mode wiring. - Promote shared helpers to unilab.visualization.interactive_playback: infer_checkpoint_actor_input_dim, build_play_backend_adapter, available_backends_for_task, PlayInteractiveArgs, build_playback_config, normalize_checkpoint_value. - Extend create_rsl_rl_playback_session with runner_loader / guard_algo_name and expose runner/actor on sessions for entrypoint exports. - Load off-policy actors via load_play_actor so td3 noise_scales buffers no longer break strict state_dict loading. - Replace the local quaternion-to-rotmat helper with utils.rotation.np_matrix_from_quat; play_viser no longer imports underscore-private functions. - Track the materializer consumer move in test_backend_imports and add unit/smoke coverage for the new public API and all four play entries.
TATP-233
changed the base branch from
main
to
dev/issue-1042-manager-based-api
August 21, 2026 14:50
TATP-233
merged commit Aug 21, 2026
f8a19a0
into
dev/issue-1042-manager-based-api
6 of 7 checks passed
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.
Fixes #1242. Part of #1239.
做什么
play_rsl_rl/play_him_ppo/play_appo/play_offpolicy改为复用unilab.visualization.interactive_playback的create_*_playback_session工厂;脚本只保留 CLI 组装、checkpoint 缺失诊断、ONNX/JIT 导出与run_playback_mode/render_play_mode调用。play_interactive.py中被复用的私有函数提升为库层公开 API:infer_checkpoint_actor_input_dim、build_play_backend_adapter、available_backends_for_task、PlayInteractiveArgs、build_playback_config、normalize_checkpoint_value。create_rsl_rl_playback_session新增runner_loader/guard_algo_name注入参数;RslRlPlaybackSession暴露runner/actor供入口导出。utils/rotation.np_matrix_from_quat(保留归一化行为);play_viser.py不再 import 任何下划线函数。顺带修复
load_play_actor:修复 td3 checkpoint 的noise_scalesbuffer 导致 strictload_state_dict失败的问题。test_materializer_consumers_use_backend_facade消费方清单同步(materializer 消费从 play_interactive 移到库层)。不做
manip_loco/play_go2_arm_ik_only.py与train_hora_distill内 play 不在本期。resolve_sim2sim_config,同函数同参数)。Validation
make test-all本地通过(2189 passed, 28 skipped, 1 xfailed;module/script mode 冒烟全过)。runner_loader/guard_algo_name/td3 noise_scales 覆盖、四个入口 play 冒烟(工厂注入参数 + checkpoint 缺失早退 + loop 走 session)。