Nodes/comfyui_cv/CV Array Size
ComfyUI Node

CV Array Size

Reads width/height of an ndarray image. The 'size' output is the whole (width, height) as ONE composite value - wire it straight into a low-level cv2 node's dsize / ksize / imageSize input; 'dsize' is the same pair as a '(w, h)' literal string, for the composite params that are still free-text. A LATENT input reports its size in latent CELLS (pixels / 8) - the units every cv2 node sees when operating on a latent.

By bmad4ever·Created 3 months ago·Updated 2 days ago· 0
CV Array Size
  • nparray
  • width
  • height
  • dsize
  • size
Categoryimage/CV/features

Inputs (1)

NameTypeDefaultDescription
nparrayNPARRAY,IMAGE,MASK,LATENTImage whose width/height to read (only the shape is used). LATENT sizes count latent cells, not pixels. Accepts a ComfyUI IMAGE/MASK directly (frame 0 of a batch) or an NPARRAY. Arithmetic ops (add, multiply, etc.) process the full IMAGE batch when both inputs have the same batch size.

Outputs (4)

NameTypeDescription
widthINT
heightINT
dsizeSTRING'(width, height)' literal - for the composite cv2 params that are still free-text.
sizeCV_TUPLE(width, height) as ONE composite value - wire it straight into a cv2 node's dsize / ksize / imageSize input, in one link instead of two.