Nodes/ComfyUI-CustomNodePacks/PAR Desqueeze (anamorphic → square px)
ComfyUI Node

PAR Desqueeze (anamorphic → square px)

Anamorphic footage breaks ComfyUI — desqueeze to square pixels first

By Code2Collapse·Created 7 months ago·Updated about 16 hours ago· 54
PAR Desqueeze (anamorphic → square px)
  • image
  • image
  • par_info
par_presetARRI 4448x3840→2:1 (1.7266)
pixel_aspect1.7266
methodstretch_width
filterbicubic

Ever dropped an anamorphic plate into ComfyUI, run it through a model, and watched everything come back subtly squished? Not a bad seed - a pixel aspect problem. AI models and ComfyUI assume square pixels, and an anamorphic frame doesn't have them. That classic 4448×3840 scan with PAR 1.7266 displays as true 2:1 in Nuke, but ComfyUI reads it as a squarish 1.158:1 image. Generate against that shape and the moment the lens squeeze gets re-applied downstream, circles are ovals and faces are a little wide. PAR Desqueeze (MEC) fixes the front half of that: it converts the plate to square pixels before any AI step, and hands you a par_info string that makes the trip back lossless on geometry.

It's one node in the plate tools of Code2Collapse/ComfyUI-CustomNodePacks, a VFX-flavored suite that otherwise gives you grain matching, plate stabilizers, clean-plate extraction, and the color-science side of the Nuke handoff. This pair is aimed squarely at people who run ComfyUI as an AI node inside a real compositing pipeline - a crowd that barely shows up on the usual model forums, because compositors talk shop in VFX channels.

What it actually does

Desqueezing means resizing so every pixel becomes square. Two ways to get there, selectable via method:

  • stretch_width (recommended) - new width = width × PAR, height untouched. 4448×3840 → 7680×3840. Every scanline survives; you're just adding horizontal resolution.
  • squash_height - height ÷ PAR instead. 4448×3840 → 4448×2224. Fewer pixels, faster downstream, but you've thrown away scanlines.

There's no magic here - it's an interpolated resize with filter control (bicubic default; also bilinear, nearest, area). The clever bit is the second output: par_info, a small JSON string recording the original width/height, the PAR you used, the method and filter. That string is everything PARResqueezeMEC needs to restore the exact original dimensions later. Desqueeze up front, resqueeze at the back, and the round trip puts the frame back to the plate's pixel-for-pixel shape even if the AI between them changed resolution.

The inputs you actually set

  • par_preset - the one that matters. Defaults to ARRI 4448x3840→2:1 (1.7266), which is the case the author built the example around. The rest of the dropdown is your standard anamorphic vocabulary: 2x (2.0), 1.8x, 1.5x, 1.33x, square 1.0, plus NTSC DV (0.9091) and PAL DV (1.0940) if you're wrangling SD video.
  • pixel_aspect - used only when preset is custom. PAR > 1 means pixels wider than tall. Type your exact squeeze (say 1.79 for a particular open-gate mode) and go.
  • method - stretch_width unless you have a reason to lose pixels.
  • filter - leave bicubic; reach for area if you're downscaling and want less aliasing shimmer.

Set par_preset to square 1.0 on square footage and the node is a no-op pass-through - safe to leave parked in a template graph.

Installation and wiring

It ships inside Code2Collapse/ComfyUI-CustomNodePacks, so install the pack once: ComfyUI Manager → search CustomNodePacks, or cd ComfyUI/custom_nodes && git clone https://github.com/Code2Collapse/ComfyUI-CustomNodePacks.git, then restart and look for the MEC load message in the console. This node itself needs nothing special - the resample is plain torch interpolation, no model downloads. It appears under the MEC/Plate group in the node menu.

Where people get burned

The number one failure mode isn't the node - it's running AI on the anamorphic plate at all, then discovering the distortion only after it's back in Nuke with PAR re-applied. Desqueeze before any model, always. Second: the desqueezed frame is bigger (7680 wide), which is heavier than you might expect for a latent model - fine for a crop-based or region workflow, worth knowing before you feed a full-res frame to a model that's going to downscale it anyway. Third: if you deliver square-pixel output on purpose (web, or a normal video), skip the return trip entirely - the desqueezed frame is already correct at PAR 1.0.

The 7680×3840 square frame is what the AI should actually see. Feed that to your graph, then let PAR Resqueeze (MEC) bring the result home.

CategoryMEC/Plate

Inputs (5)

NameTypeDefaultDescription
imageIMAGE
par_presetCOMBOARRI 4448x3840→2:1 (1.7266)9 options: custom, square 1.0, anamorphic 2x (2.0), anamorphic 1.8x (1.8), ARRI 4448x3840→2:1 (1.7266), anamorphic 1.5x (1.5), +3
pixel_aspectFLOAT1.72660.1–4Used when par_preset = custom. PAR>1 = pixels wider than tall.
methodCOMBOstretch_widthstretch_width keeps every scanline (recommended); squash_height keeps the pixel count low.
filterCOMBObicubic4 options: bicubic, bilinear, nearest, area

Outputs (2)

NameTypeDescription
imageIMAGE
par_infoSTRING