H3 Per-Frame Denoise:
H3PerFrameDenoise varies face-refinement strength across a MiniMax H3 video clip according to how large the face appears in each frame. A distant face can receive a stronger pass to build visible detail, while a close-up face can receive a gentler pass to preserve detail already present. The node turns those frame-by-frame strengths into a video denoise mask for one sampling pass and smooths changes over time to reduce visible texture shifts. When shot boundaries are available, smoothing stays within each shot. It also adjusts how the H3 model handles masked video regions so the sampler and model work with consistent noise levels, while preserving the audio-side masking used by the audio-lock workflow.
H3 Per-Frame Denoise Input Parameters:
model
The MiniMax H3 MODEL that will be used for sampling. This node returns a patched version that keeps its video mask out of H3’s per-token timestep conditioning and re-noises held video regions to the sampler’s current noise level. Connect the returned model to the guider; continuing with the original model would leave out those changes. This input has no default or numeric range.
av_latent
The MiniMax H3 joint audio/video LATENT to refine. It must contain nested video and audio samples. The node adds or replaces the video portion of its denoise mask; when an existing nested mask is present, it preserves its audio portion. This input has no default or numeric range.
transform
The H3FACEXFORM containing face boxes used to estimate face height in source-image pixels. The node calculates each face height from the box height and crop factor. If the transform provides shot segments, it smooths each shot separately; if it provides a matching frame-by-frame absent-face list, it sets strength to zero at those positions before converting the curve to latent frames. This input has no default or numeric range.
denoise_multiplier_small_face
The multiplier applied at the small-face end of the size range. It scales the denoise value set in BasicScheduler; it is not a standalone denoise setting. A value of 1.0 allows the full scheduled denoise at that end, while 0.8 requests 80% of it. Higher strength gives distant, low-detail faces more opportunity to be rebuilt. Minimum: 0.0; maximum: 1.0; default: 1.0; step: 0.05.
denoise_multiplier_large_face
The multiplier applied at the large-face end of the size range. Lower values give close-up faces a gentler pass, helping preserve existing detail instead of rewriting it. Values between the small-face and large-face ends are interpolated according to face size. Minimum: 0.0; maximum: 1.0; default: 0.35; step: 0.05.
scale_mode
Selects how the node defines “small” and “large” faces. absolute_px uses the source-pixel thresholds set by face_px_small and face_px_large, giving you consistent size references across clips. relative_to_clip uses the smallest and largest measured faces in each clip as its endpoints, so even a clip made entirely of fairly large faces assigns its smallest face the small-face multiplier. Options: absolute_px and relative_to_clip; default: absolute_px.
face_px_small
In absolute_px mode, the source-image face height at or below which the small-face multiplier applies. For example, with the default of 30.0, a face measured at 30 source pixels high or less receives that endpoint strength before smoothing. This setting does not define the endpoints in relative_to_clip mode. Minimum: 4.0; maximum: 400.0; default: 30.0; step: 1.0.
face_px_large
In absolute_px mode, the source-image face height at or above which the large-face multiplier applies. Between the two pixel thresholds, strength changes gradually with face size. This setting does not define the endpoints in relative_to_clip mode. Minimum: 8.0; maximum: 800.0; default: 120.0; step: 1.0.
gamma
Shapes how strength changes between the small-face and large-face endpoints. At 1.0, the size position is used without an added curve; above 1.0, strength stays closer to the small-face setting until the face becomes larger; below 1.0, it moves toward the large-face setting earlier. The effect is most intuitive when the small-face multiplier is higher than the large-face multiplier. Minimum: 0.2; maximum: 4.0; default: 1.0; step: 0.1.
smooth_frames
The requested Gaussian smoothing window for the frame-by-frame strength curve. More smoothing can reduce visible changes in texture as face size varies, but can also make the response to a rapid size change less immediate. Smoothing does not cross supplied shot boundaries, and a shot shorter than the requested window is smoothed using the frames available. Minimum: 1; maximum: 61; default: 9; step: 2.
H3 Per-Frame Denoise Output Parameters:
av_latent
The LATENT passed onward to sampling. It retains the input latent’s other entries and contains a new noise_mask whose video portion varies with the calculated face-refinement strength. If the incoming latent already has a nested audio mask, that audio portion is kept; otherwise, the node creates an audio portion filled with zeros when audio samples are present. This is a sampling mask, not a rendered video or a preview of the final result.
report
A STRING summarizing the measured face-size range, the selected ramp and mode, the highest, lowest, and mean calculated multipliers, the source-frame and latent-frame counts, and the gamma setting. It also describes the model patches or notes when the model lacks a relevant mask-handling method. If denoise_multiplier_small_face is below 1.0, the report adds a reminder that it is a multiplier rather than a denoise value. The reported strengths reflect smoothing and absent-face handling.
model
The patched MODEL to connect to the guider. Its changes make the per-frame video mask operate through the sampler while bringing held video regions to the noise level of the current sampling step. The patch leaves the model’s audio mask conditioning available for an audio-lock workflow. The returned latent alone is not the complete result of this node’s processing; use this model output too.
H3 Per-Frame Denoise Usage Tips:
- Place the node after MiniMaxH3NativeAudioLock when using that workflow, then pass both the returned
av_latentand returnedmodelalong their respective paths to sampling and the guider. This preserves the existing audio-side mask. - Start with
scale_modeset toabsolute_px,denoise_multiplier_small_faceat1.0, anddenoise_multiplier_large_faceat0.35. Inspect the report’s measured face range before adjusting the pixel thresholds to fit your footage. - Use
relative_to_clipwhen deliberately tuning one clip to its own smallest and largest faces. For a batch with different face sizes, preferabsolute_pxwhen you need the same source-pixel thresholds to mean the same thing across clips. - Keep
denoise_multiplier_small_faceat1.0when your smallest faces need the full BasicScheduler denoise. Lower it when you intentionally want a gentler small-face endpoint; remember that smoothing or absent-face handling can change the strengths actually reported. - Increase
gammaabove1.0if mid-sized faces should retain more of the small-face strength; decrease it below1.0if strength should fall toward the large-face setting sooner. Adjust one setting at a time and compare the result with the reported range. - If face detail visibly changes between neighboring frames, try a larger
smooth_framesvalue. If the effect reacts too slowly to a change in face size, try a smaller value. Shot segments, when supplied by the transform, keep smoothing from crossing cuts. - Check the final video rather than expecting a separately adjustable strength for every pixel frame: the calculated curve is converted to the video latent’s temporal resolution, which is coarser than the source frames.
H3 Per-Frame Denoise Common Errors and Solutions:
Expected a MiniMax H3 joint AV latent (NestedTensor).
- Explanation: The
av_latentinput has nosamplesentry, or its samples are not in the nested format this node expects for a MiniMax H3 joint audio/video latent. - Solution: Connect the joint AV latent from the H3 workflow, and make sure an upstream node has not replaced it with an ordinary image or video latent.
transform has no boxes
- Explanation: The transform contains an empty
boxeslist, so the node has no face measurements from which to calculate strength. - Solution: Check the upstream face-transform step and supply a transform containing face boxes for the clip being processed.
Missing boxes in transform (typically KeyError: 'boxes')
- Explanation: The source reads
transform["boxes"]directly. A transform without that key cannot provide the measurements the node requires. - Solution: Connect the expected
H3FACEXFORMoutput rather than an unrelated transform or manually assembled value, and confirm that it contains face boxes.
Audio/video latent has no video member (typically IndexError: list index out of range)
- Explanation: After unpacking the nested samples, the node reads the first member as video. An empty nested latent has no video member to process.
- Solution: Trace the
av_latentconnection upstream and provide a populated joint AV latent.
The report says “this model reads no denoise mask”
- Explanation: This is a report note, not an exception. It means the supplied model does not expose one or both mask-handling methods that the node checks before applying its model patches.
- Solution: Confirm that
modelis the intended MiniMax H3 model and that the returnedmodelis connected to the guider. Do not assume the described H3-specific correction was applied when the report says a method is unavailable.
The report warns that no frame gets the full denoise
- Explanation: This warning appears when
denoise_multiplier_small_faceis below1.0. The setting is a multiplier on BasicScheduler’s denoise, so lowering it makes the small-face endpoint gentler than the full scheduled value. - Solution: Set
denoise_multiplier_small_faceto1.0if you intend to make full scheduled denoise available to the smallest faces; keep the lower value only when a gentler result is deliberate.
Strength appears unchanged across the clip
- Explanation: This may be an expected result rather than an error. The measured face sizes may all fall beyond one
absolute_pxthreshold, the two multipliers may be equal, orrelative_to_clipmay have no face-size range to interpolate across. - Solution: Read the measured face range and ramp in
report, then adjust the thresholds or multipliers to cover the sizes actually present. For a clip with varying face sizes,relative_to_clipcan map its measured extremes to the two endpoints.
