[2/N] Add a minimal temporal chunk callback for MiniMax-H3 (#7017)

Signed-off-by: specture724 <specture724@gmail.com>
Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
Anjie HouandClaude Sonnet 5 authored and GitHub committed 2026-09-09 16:40:32 +08:00
1 parent ffa991b24f
commit ecdd762ff5
6 files changed
+641 -27

No files matched your search

+8
View File
@@ -58,8 +58,16 @@ class SupportsChunkedVAEDecode(Protocol):
Implementations must drain decoding before surfacing callback errors. In a
distributed VAE, every rank invokes the method so collectives stay in
lockstep, while ``on_chunk`` is called only on the rank that owns output.
``chunk_value_range`` is the closed interval the delivered floats occupy,
which differs per checkpoint: a Wan VAE emits ``(-1.0, 1.0)`` while a
MiniMax-H3 VAE reverts through its processor to ``(0.0, 1.0)``. A consumer
cannot quantize chunks to pixels without it, so it is part of the
capability rather than knowledge each consumer hard-codes per model.
"""
chunk_value_range: ClassVar[tuple[float, float]]
def decode_with_chunks(
self,
z: torch.Tensor,