Auto Adjust (Photoshop-style)
Auto Adjust (Photoshop-style) is the Auto Levels/Tone/Color trio, minus Photoshop
- image
- finish_config
- IMAGE
What it's for
You've got a flat, slightly blue scanned print or a phone photo that's fine except for contrast. The wrong move is an img2img pass - you'll spend a minute of GPU time and hand the seed lottery the job of "make it look like the light was better." This is the cheap, deterministic, millisecond alternative: a real contrast/tone/color correction done as pixel math, the way Photoshop's Auto buttons do it.
AutoAdjustV2 is PortraitUtils' take on that. It shipped with the 2.0 rewrite in October 2026 and, fair warning, the pack has close to zero Reddit footprint so far - you're early. What it does not claim to be: a bit-for-bit clone of Adobe. Adobe's selection heuristics are proprietary, so the node follows documented behaviour instead. For photos straight off a scanner, that's plenty.
How it works
It runs up to three corrections, and the author is explicit that they're normally alternatives, not a stack:
- Auto Levels / Contrast - one black/white-point stretch applied identically to R, G and B. Channel relationships survive, so it can't fix a cast.
- Auto Tone - in
Per-channelmode, computes separate endpoints for each channel. That's the one that can remove or introduce a cast, depending on what your photo's brightest and darkest pixels actually are. - Auto Color - estimates average dark and light colours and can neutralize a genuinely low-chroma midtone. It's deliberately conservative about what counts as neutral; saturated skin and foliage get excluded rather than being treated as gray reference.
adjustment_mode is the switch that matters. Pick one of the three commands and you're done. Leave it on Use Finish Config switches and it reads the auto_levels / auto_tone / auto_color booleans off the finish_config bundle and stacks whatever you enabled in Levels → Tone → Color order - more aggressive than the normal Photoshop workflow, and more clipping. The author says use it only when that's the intent. I'd believe them.
Statistics come from either a 256-bin histogram (Histogram (fast), effectively Photoshop's own approach) or Exact, which sorts every pixel for true percentiles. Histogram is right for real photos, especially after an upscale; Exact is for when you're chasing a number in a comparison.
The inputs you'll actually touch
image and finish_config are both required: the bundle supplies the auto switches and flip_horizontal, so even in direct-command mode you need a Finish & Run Config node wired in. A typed bundle can't come off a plain boolean primitive - see the readers if you want to drive those values from elsewhere.
Then it's taste:
strength(0–1) blends the correction with the original, i.e. adjustment-layer opacity. Start at 1.0, drop to 0.6 if a portrait goes plastic.levels_shadow_clip_pct/levels_highlight_clip_pct- percentage of extreme pixels ignored when finding the endpoints.0.1is Photoshop's traditional default, and0means "use the true min/max."snap_neutral_midtones- on by default; this is the Auto Color behaviour above.tone_mode-Per-channelfor Auto Tone,Monochromaticif you want the contrast of Levels.
One output, IMAGE, straight into your upscaler or saver. Flat or nearly flat channels are left alone rather than stretched into noise, which is the sort of detail that separates this from a weekend gamma node.
Install
Via ComfyUI Manager, search PortraitUtils (publisher heyburns, GPLv3). Manually:
cd ComfyUI/custom_nodes
git clone https://github.com/heyburns/PortraitUtils
/path/to/ComfyUI/venv/bin/python -m pip install -r PortraitUtils/requirements.txt
That pulls numpy, Pillow>=9.1, opencv-python-headless>=4.10.0.84 and tifffile. ComfyUI supplies your PyTorch - don't let anything here reinstall it. And yes, restart the server; a browser refresh does not reload Python node classes.
Where people get burned
If you stack all three switches you get clipping, not a "more thorough" auto. And Auto Color's job is introducing a gray reference - on a photo dominated by intentional warm light it will happily cool the whole thing down, so inspect the result rather than trusting the word "auto."
Inputs (12)
| Name | Type | Default | Description |
|---|---|---|---|
| image | IMAGE | — | |
| finish_config | PORTRAIT_FINISH_CONFIG_V2 | — | |
| precision | COMBO | Histogram (fast) | 256-bin statistics are efficient and close to Photoshop's histogram-based behavior. |
| levels_shadow_clip_pct | FLOAT | 0.100–5 | — |
| levels_highlight_clip_pct | FLOAT | 0.100–5 | — |
| levels_gamma_normalize | BOOLEAN | false | — |
| tone_mode | COMBO | Per-channel | 2 options: Per-channel, Monochromatic |
| tone_shadow_clip_pct | FLOAT | 0.100–5 | — |
| tone_highlight_clip_pct | FLOAT | 0.100–5 | — |
| snap_neutral_midtones | BOOLEAN | true | Used by Auto Color to neutralize genuinely low-chroma midtones. |
| adjustment_mode | COMBO | Use Finish Config switches | Select one Photoshop-style command or use the existing Finish Config booleans. |
| strength | FLOAT | 1.000–1 | Blend the correction with the original image. |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| IMAGE | IMAGE | — |