Nodes/ComfyUI-LogicUtils/Censor Image by Rating
ComfyUI Node

Censor Image by Rating

Auto-blur based on a booru rating classifier

By aria1th·Created 3 years ago·Updated 7 months ago· 116
Censor Image by Rating
  • image
  • IMAGE
rating_threshold
censor_method
model_nameEVA02_Large

This is the interesting one in the pack. Instead of you deciding what to censor, it runs a classifier over the image, reads off a content rating, and blurs, whites-out, or pixelates the whole thing if it lands at or above a threshold you set. It's an automated "is this safe to show" gate you can drop into a batch pipeline so you're not hand-reviewing a thousand outputs.

How it actually works

The rating scale - general, sensitive, questionable, explicit - isn't arbitrary. Those are the four content-rating tags from Danbooru, the anime image board, and the model doing the judging is a WD-style tagger (the "waifu diffusion" tagger family). That lineage is not a coincidence: this pack is by aria1th (AngelBottomless), the trainer behind Illustrious XL, whose day job for years was running taggers over the entire Danbooru set to build training data. This node is basically that machinery, pointed at your ComfyUI output.

So the flow is: the tagger predicts a rating for your image, the node compares it to your rating_threshold, and if the image is at least that spicy it applies your chosen censor_method to the frame. Below the threshold, it passes through untouched.

The inputs that matter

  • rating_threshold - the line in the sand. Pick explicit and it only censors the most extreme stuff; pick sensitive and it clamps down much earlier. This is your one real tuning knob.
  • censor_method - blur, white, or pixelate. Blur keeps the composition legible, white nukes it entirely, pixelate is the classic mosaic.
  • model_name (optional, default EVA02_Large) - which tagger backbone to load. The default EVA02-Large is the accuracy-leading one in the WD tagger series and the sane choice; the list also offers ViT_Large, SwinV2, ConvNext, and lighter variants if you want to trade accuracy for speed or memory.

Output is a single IMAGE - either your original or the censored version - that you wire into your save node.

The catch you need to know

This node downloads a model. The tagger weights aren't shipped with the pack; on first run it pulls them (typically from HuggingFace), which means the first execution stalls while it fetches a few hundred MB, and a machine with no internet access will just fail there. It also needs the inference dependencies (the ONNX/timm stack taggers run on). Most of LogicUtils is zero-dependency pure Python - this node is the exception that isn't.

That matters because the pack's dependency installer is opt-in. If the node errors on a missing import, set the environment variable COMFYUI_LOGICUTILS_AUTO_INSTALL=1 before starting ComfyUI so it can pull what it needs (and COMFYUI_LOGICUTILS_SKIP_INSTALL=1 force-disables that hook if you'd rather manage deps yourself).

Second caveat: it's a classifier, so it's probabilistic. It will miss things and it will over-censor things. Treat it as a bulk first-pass filter, not a compliance guarantee - an anime-trained tagger is also weaker on photoreal content than on the illustrated material it was built for.

Installing ComfyUI-LogicUtils

ComfyUI Manager: Install Custom Nodes → search "ComfyUI-LogicUtils" → install → restart. Or manually:

cd ComfyUI/custom_nodes
git clone https://github.com/aria1th/ComfyUI-LogicUtils

Restart, and remember the auto-install env var above if the tagger import complains. One last honest note: LogicUtils is one person's utility pack, last touched in early 2026, with no real support channel. For a resize helper that's fine. For an automated safety gate you're relying on, test it against your own material before you trust it to run unattended.

Categoryimage

Inputs (4)

NameTypeDefaultDescription
imageIMAGE
rating_thresholdCOMBO4 options: general, sensitive, questionable, explicit
censor_methodCOMBO3 options: blur, white, pixelate
model_nameoptCOMBOEVA02_Large10 options: EVA02_Large, ViT_Large, SwinV2, ConvNext, ConvNextV2, ViT, +4

Outputs (1)

NameTypeDescription
IMAGEIMAGE