
ANR AI Matte Propagator
Paint or roto the matte on one frame, press Start Propagation, and the AI model carries that matte through the rest of the shot.
- Masking
- Masking pack
- Masking models
- 2 inputs
- 19 controls
Overview
AI Matte Propagator takes a matte you made on one frame, the Init Frame, and follows the subject with it through the shot, forward and backward from that frame. The matte can come from anything: a roto, a paint stroke, a key, or a frame of ANR AI Matte Creator.
Nothing runs until you press Start Propagation. The node then reads your mask on the Init Frame and the plate around it, and every frame you play or render gets its own matte. Bake Frames does all of that for you: it starts the propagation by itself and writes the shot to disk.
The result is the raw propagated matte: soft (Raw Soft) or cut to black and white (Raw Hard). To refine hair and soft edges afterwards, follow it with ANR AI Matte Perfector.
Baked frames play back from the Cache Folder, so a comp opened later starts no AI engine and uses no graphics memory.
Inputs
- Sourcerequired
The plate the subject moves in. The AI follows the subject through its pictures.
- Maskrequired
Your matte (its alpha). Only the Init Frame is read, so it only needs to be right on that frame.
Output. The Source with the propagated matte in alpha. Display sets the RGB: the picture tinted with the matte (Matte Overlay, the default), the matte in black and white, the picture premultiplied, or the picture untouched.
Quick start
- Draw your matte on one frame with a Roto (or any matte) and connect it to Mask. Connect the plate to Source.
- Go to that frame and press Set to Current Frame, or type it into Init Frame.
- Press Start Propagation. The Status line confirms the frame it started from.
- Play or render the shot. Check the matte with Display on Matte Overlay.
- For the comp, set Display to Straight (RGB + alpha) or Premultiplied, or take the alpha from the node.
- To keep the result, press Generate Autofill (or set Cache Folder), then Bake Frames. With Limit to Frame Range off it bakes the whole input; on, only Bake From to Bake To.
The panel
The node's panel as Nuke shows it, with the values of a new node. Click any control to see what it does; tabs and sections work as in Nuke.
No control matches.
All controls
ANR AI Matte Propagator19 controls
- StatusStatus
status What the node is doing, or what it needs next: connect the inputs, choose the Init Frame, press Start Propagation or Bake Frames.
- Freeze and Bake to DiskCheckbox
bake Write every frame that renders as a 16-bit RGBA PNG (the matte in rgb and alpha) and play them back from disk. With this on, opening the comp starts no AI engine and uses no graphics memory. Turn it off to edit. Matte Creator asks for confirmation; freezing again refreshes each rendered frame, and Bake Frames replaces the selected range.
- Import Baked FootageButton
importBaked Creates a Read node for the baked sequence right under this node (through Nuke's own Python). If the host cannot do that, the Read goes on the clipboard instead: hover the node graph and press Ctrl+V.
Bake Settings
- Generate AutofillButton
anrCacheAutoFill Create a new node-type/footage_letter_4digits folder on every click, then stop. Previous caches are kept. Enter a folder to choose a custom base.
Makes a new, empty folder for this node each time you click it and puts it in Cache Folder. It goes next to the saved script by default (ANR > Cache Folders > Location in Nuke's menu bar can put it next to the footage); a folder you typed into Cache Folder is used as the base instead. Save the script first.
- Cache FolderFile
bakeDir Each node writes //.####.png. Read the sequence back with an ordinary Read node.
Each node writes into a subfolder named after Name Prefix: with the default prefix,
anr_matte/anr_matte.####.pnginside this folder. Two nodes with the same folder and prefix write over each other, so give each node its own folder (Generate Autofill does) or its own prefix.- Name PrefixText
bakePrefix Prefix for the subfolder and the file names; #### sets the frame padding. Empty uses the node's own id.
- Limit to Frame RangeCheckbox
bakeRange Only bake (and matte) frames inside the range below; the rest pass through. Off: Bake Frames bakes the Source's whole range.
- Bake FromSlider
bakeFrom First frame to bake.
- Bake ToSlider
bakeTo Last frame to bake.
- Bake FramesButton
bakeFrames Bake now, without playing through the shot: every frame from Bake From to Bake To when Limit to Frame Range is on, otherwise the Source's whole range. Each frame is matted again and written as a 16-bit RGBA PNG (the matte in rgb and alpha) into the Cache Folder; Freeze and Bake to Disk turns on, so they play back from disk. Cancel on the progress bar stops it.
- Init FrameSlider
initFrame Frame containing your painted Mask. Propagation begins only after Start Propagation or Bake Frames is pressed.
- Set to Current FrameButton
setInitToCurrent Use the current timeline frame as the seed frame.
- Start PropagationButton
startPropagation Load the propagation model and propagate the connected Mask from Init Frame. Nothing runs before this is pressed.
- Go to Init FrameButton
goToInit Jump the timeline to the init frame.
- OutputMenu
refiner Raw Soft preserves the propagation model's probabilities. Raw Hard thresholds them into a binary matte.
- DisplayMenu
display Matte Overlay: the picture with each object tinted, alpha carries the matte. Matte Only: black and white. Premultiplied: the picture cut out by the matte. Straight: the picture untouched with the matte in alpha.
- Overlay OpacitySlider
overlayMix How strongly each object is tinted in Matte Overlay.
- Processing ResolutionSlider
processingResolution Maximum long edge in pixels used by the propagation model. Preserves aspect ratio and never enlarges the source. 1920 is a practical starting point; 2560 or 3840 retain more detail on larger plates but use more GPU memory and time. After changing it, press Start Propagation again. Init Frame and subsequent frames show the same propagation pipeline.
- Low VRAMCheckbox
lowVram The propagation model remembers 2 past frames instead of 5 (besides the Init Frame) and reads its memory in smaller pieces: about a third less graphics memory and a little faster, the matte almost exactly the same. New nodes start with it on. Processing Resolution saves the most memory of all. After changing it, press Start Propagation again. Off: as before.
Tips
- Choose an Init Frame where the subject is fully in view and clearly separated from the background: the AI starts from exactly what you painted there.
- On large plates, raise Processing Resolution to 2560 or 3840 to keep more edge detail; it uses more graphics memory and time.
- If the graphics card runs out of memory, tick Low VRAM (new nodes start with it on) and lower Processing Resolution.
- Output > Raw Hard gives a clean black-and-white matte for garbage mattes and holdouts; Raw Soft keeps the AI model's soft transitions.
- Connect the result to ANR AI Matte Perfector's Mask input to rebuild hair and motion blur at full resolution.
- While the node's panel is open, its messages show in the Viewer: red when there is no matte and why, amber for notices, with a warning when the object is lost.
- Scrubbing or cancelling keeps the frames already propagated. When the graphics card is too full, the node says so and tries again once there is room.
Good to know
- Start Propagation is saved with the comp: reopening the comp, or reconnecting an input, carries on. After a change of Init Frame, Processing Resolution or Low VRAM the node asks you to press Start Propagation again; setting the value back carries on.
- Start Propagation refuses when the Mask is empty on the Init Frame. Paint the matte first.
- The node needs an NVIDIA graphics card for practical speeds.
- If the Masking models were not installed with ANR Tools, Nuke offers to download them the first time you add the node in a session (Download models or Not now). After the download, press Start Propagation again.
- After about ten minutes without work (sooner when the graphics card is nearly full), the node gives its graphics memory back. The next frame loads the model again, which takes a moment.
- Nothing is baked until Cache Folder is set. With Limit to Frame Range on, frames outside the range pass the Source through untouched.
- Baked frames play back while Freeze and Bake to Disk is on, with no propagation running. Turn it off to edit the matte, then bake again. Start Propagation turns it off by itself, so the new matte shows.
- Import Baked Footage makes a Read node of the baked sequence under this node.
Video tutorials
Something unclear or missing? Write to [email protected].