Skip to content

feat(minimax-h3): add native Windows RTX path - #1025

Open
yifeif-nv wants to merge 1 commit into
NVIDIA:mainfrom
yifeif-nv:codex/native-windows-h3
Open

feat(minimax-h3): add native Windows RTX path#1025
yifeif-nv wants to merge 1 commit into
NVIDIA:mainfrom
yifeif-nv:codex/native-windows-h3

Conversation

@yifeif-nv

@yifeif-nv yifeif-nv commented Aug 25, 2026

Copy link
Copy Markdown
Collaborator

Background

The native runtime and build flow relied on POSIX shared-library and process behavior, while MiniMax H3 could retain several very large plans at once. This change adds a focused native Windows path for the fixed MiniMax H3 video profile without broadening Windows support to unrelated runtime modes.

Exit Criteria

  • Build the CLI, core runtime, TensorRT-RTX backend, and MiniMax H3 model DLL from explicit local CUDA 12.9 and TensorRT-RTX SDK roots.
  • Build the six H3 plans in isolated processes and stream them into a staged bundle without materializing every plan in host memory.
  • Verify each plan before file-backed deserialization, prebind shared device buffers, and prevent denoiser/VAE residency overlap.
  • Keep the existing standard TensorRT path unchanged and avoid publishing checkpoints, SDK files, generated media, or machine-identifying provenance.

Implementation

  • Adds a small cross-platform shared-library boundary, portable CLI child-process/temp-path handling, model-only CMake selection, and an explicit Windows SDK/output layout.
  • Adds one model-owned staged builder with a 16 GiB tactic-workspace limit, a 32 GiB resident-weight budget, direct-to-file TensorRT serialization, content-bound resume, and sanitized bundle metadata.
  • Streams validated bundle ranges into TensorRT-RTX, applies the weight budget before context creation, prebinds H3 split-plan/VAE buffers, and releases each runtime stage before loading the next.
  • Preserves BF16 attention range instead of narrowing H3 Q/K/V tensors to FP16.
  • Documents the narrow local workflow and its authorization, licensing, output, and validation boundaries; no downloader is included.

Validation

  • ruff check python/tensorrt_model_connect/bundle_writer.py python/tensorrt_model_connect/engine_builder.py python/tensorrt_model_connect/trt_compat.py python/tensorrt_model_connect/families/minimax_h3: passed.
  • python3 -m pytest -q python/tensorrt_model_connect/families/minimax_h3/tests/test_staged_build.py python/tensorrt_model_connect/families/minimax_h3/tests/test_trt_builders.py tests/builder/test_bundle_writer.py tests/builder/test_trt_compat_boundary.py tests/builder/test_max_batch_size_cli.py tests/builder/test_engine_builder_extended.py: 59 passed, 1 skipped.
  • python3 -m pytest -q tests/tools/test_check_doc_file_references.py tests/tools/test_model_plugin_encapsulation_static.py tests/tools/test_test_impact.py tests/tools/test_coverage_map.py: 476 passed.
  • python3 -m tools.community_ci impact --base github/main: passed; the Windows helper selects only minimax-h3-768p, builder units, and the native rebuild lane.
  • python3 -m tools.community_ci source-quality --base github/main: passed, including max CCN 10, changed-file lint/formatting, and 158 architecture-contract tests.
  • python3 -m tools.community_ci unit --scope all: 3,572 passed, 2 skipped.
  • Linux focused CMake configure/build of trtmc_platform_cpp_tests, trtmc_model_minimax_h3, and the H3 external-prebinding test: passed.
  • ctest --test-dir <build> --output-on-failure -L platform: 40/40 passed.
  • ctest --test-dir <build> --output-on-failure -R '^test_minimax_h3_trt_module_bind_external$': 1/1 passed.
  • Forced compilation with the RTX delete/alias/communicator API-age overrides enabled: passed against TensorRT 11 headers.
  • python3 tools/legal_headers.py --check: 5,902 tracked files, 0 findings.
  • PowerShell/MSVC compilation, Windows DLL loading, TensorRT-RTX execution, and real MiniMax H3 build/inference were not run locally because this environment has no Windows toolchain, TensorRT-RTX SDK, or authorized H3 checkpoint.

Notes For Future Readers

  • Review the platform/CMake boundary first, the Python staged builder second, and the RTX/H3 runtime lifetime changes last.
  • This supports one fixed SM 120, BF16, batch-1, single-device, decoded-video profile. It does not add Windows serving, distributed execution, audio output, or general model-family support.
  • Plans and generated bundles are local, environment-bound artifacts. Rebuild with authorized inputs when the checkpoint or SDK/backend cohort changes.

@yifeif-nv
yifeif-nv force-pushed the codex/native-windows-h3 branch from f1930d7 to 8529048 Compare August 25, 2026 03:00
Build MiniMax H3 plans in isolated processes and stream them directly to disk so Windows builds and inference do not co-reside every model stage.

Add portable shared-library loading, explicit Windows SDK inputs, file-backed TensorRT-RTX deserialization with plan integrity checks, staged denoiser/VAE residency, and public-safe documentation. Keep the standard TensorRT path unchanged and omit machine-identifying provenance.
@yifeif-nv
yifeif-nv force-pushed the codex/native-windows-h3 branch from 8529048 to f4f76ee Compare August 25, 2026 03:03
@yifeif-nv
yifeif-nv marked this pull request as ready for review August 25, 2026 03:13
@yifeif-nv yifeif-nv added the run-internal-ci Maintainer-approved dispatch to internal CI label Aug 25, 2026
@github-actions github-actions Bot removed the run-internal-ci Maintainer-approved dispatch to internal CI label Aug 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant