Nodes/Monja Image Validator/⚠️ Validar Múltiplo de 8
ComfyUI Node

⚠️ Validar Múltiplo de 8

The node whose whole job is to kill your workflow — and you'll be glad it did

By andremonjardim·Created 2 months ago·Updated 2 months ago· 0
⚠️ Validar Múltiplo de 8
  • image
  • IMAGE

Blocking your run is the feature here. ImageMultipleOfEightValidator sits inline in your graph and refuses to let an image continue if its width or height isn't a multiple of 8 - it raises an error, the queue stops, and you get a red line in the console telling you which dimension lied. That sounds obnoxious until you've had a tiled upscaler lay down a visible grid seam, or a Flux workflow blow up with a VAE/CUDA error because some node handed it a 1330x1020 image instead of a clean one. This is the guard that catches that at the door.

It ships in a tiny single-node pack called Monja Image Validator (andremonjardim/comfyui-image-validator), by Brazilian dev André Monjardim. The README is in Portuguese, the node's display name is "⚠️ Validar Múltiplo de 8", and the repo is brand new (July 2026) with essentially zero community footprint. It's about as simple as a custom node gets - one class, one input, one output - which is exactly what a guard node should be.

How it works

Under the hood it does almost nothing, and that's the point. An IMAGE tensor in ComfyUI has the shape [Batch, Height, Width, Channels], so the node reads shape[1] and shape[2] as height and width and tests width % 8 != 0 or height % 8 != 0. If both pass, it returns the image untouched. If either fails, it prints a red ANSI-escaped line to the console - "DIMENSÃO INVÁLIDA" with the offending dimensions - and raises a ValueError, which ComfyUI treats as a hard stop for the whole queue.

No GPU work, no model, no heavy processing. It's pure tensor-shape arithmetic, so the README's "zero performance impact" claim is actually true rather than marketing.

Why 8, specifically

Every latent-based model you actually run - SD 1.5, SDXL, Flux, the video models - uses a VAE that downsamples the image 8x per side into latent space. The pixel grid has to divide evenly into that latent grid, or encode/decode drifts and tiled upscalers like Ultimate SD Upscale leave seams where the tiles don't line up. Flux workflows usually want multiples of 64 (that's what ComfyUI's Empty Latent snaps to), but 8 is the hard floor every latent pipeline shares, so an 8-check catches all the truly broken cases. Think of this node as the floor check, not a full dimension validator.

The one input and one output

This is the rare node where the entire IO fits in a sentence:

  • Input: image (IMAGE) - feed it whatever image you want to police, from a Load Image, a resize, a ControlNet preprocessor, whatever.
  • Output: image (IMAGE) - the exact same tensor, unchanged, wired into whatever comes next.

It's a pass-through with a tripwire. It is not an output node, so it has to feed something downstream.

Installing it

ComfyUI Manager → search "Monja Image Validator" and install, or clone it manually:

cd ComfyUI/custom_nodes
git clone https://github.com/andremonjardim/comfyui-image-validator

Then restart ComfyUI. The requirements.txt lists torch and torchaudio, but the node only ever imports torch - which ComfyUI already ships - so nothing heavy actually gets pulled in. torchaudio is a leftover, not a burden.

Where people get burned

The main trap: this node fixes nothing. It stops the flow, it doesn't repair the image. When it trips you don't just delete it - you fix the source. Put an ImageScale or a "round to multiple of 8" helper in front of it, or feed it properly-sized images in the first place.

Second: the error kills the entire queue, not just the bad image. Batch-processing a folder of frames and one comes out at an odd size? Everything halts at that frame. That's by design - the author frames it as a workflow-integrity guarantee - but know it going in.

Third: it checks 8, not 64. An image that passes here can still cause Flux-specific trouble. If Flux is your target, you want your dimensions snapped to 64 upstream; this node is the cheap safety net, not the whole system.

Honest take: you could replicate this in five lines of a Python script node, so it's not essential kit. But as a drop-in inline guard it's clean, free, and genuinely invisible until the moment you need it. If you've ever chased a seam in an upscale or cursed at a VAE error from a weird resolution, you'll recognize exactly why it exists.

CategoryActions

Inputs (1)

NameTypeDefaultDescription
imageIMAGE

Outputs (1)

NameTypeDescription
IMAGEIMAGE