LamaRemoverDetailerHookProvider
Erase a detected region instead of detailing it
- DETAILER_HOOK
Most DETAILER_HOOKs in Impact Pack modify how a region gets refined - noise, denoise schedule, preview timing. LamaRemoverDetailerHookProvider does something different: it can make the detailer erase the region instead of enhancing it. Per the README, it "applies Lama Remover to the upscaled image during the detailing stage. If skip_sampling is set to True, Lama Remover can be used alone without the detailing stage, allowing it to simply remove detected regions."
That second sentence is the practical use case worth understanding: detect something with any of Impact Pack's detectors - an object, a watermark, whatever your detector was trained to find - route it through a detailer with this hook attached and skip_sampling on, and instead of refining the detected region, the detailer removes it, filling the hole with LaMa's inpainting rather than running a sampling pass at all.
The dependency this actually needs
This hook is not self-contained. Per the pack's credits section, it requires Layer-norm/comfyui-lama-remover installed as a separate node pack - Impact Pack calls into it, but doesn't bundle it. Without that pack installed, this hook provider won't have anything to actually call.
How it works
mask_threshold and gaussblur_radius control the mask LaMa acts on - the threshold decides how confidently a pixel needs to be flagged before it's treated as "remove this," and the blur radius softens that mask's edge so the removal blends rather than leaving a hard-edged patch. skip_sampling is the mode switch: leave it False and the hook applies LaMa removal as part of a normal detailing pass on the upscaled crop; set it True and sampling is skipped entirely for regions this hook touches, so the detailer becomes a pure removal tool for whatever it detected.
Two real limitations from the README, not something this article is inventing: this hook is not applicable for AnimateDiff detailers - don't expect it to work in that pipeline. And when you combine it with other hooks via DetailerHookCombine, skip_sampling only takes effect if every combined hook has it set to True - one hook with skip_sampling=False in the mix means sampling still happens.
The inputs and output
mask_threshold(INT, default 250, range 0–255) - how confidently a pixel must be flagged before it's included in the removal mask. The high default (250, near the top of the range) means it's tuned conservative out of the box - catching only strongly-flagged pixels rather than anything faintly detected.gaussblur_radius(INT, default 8, range 0–20) - blur applied to the removal mask's edge, softening the transition where the removed region meets the rest of the image.skip_sampling(BOOLEAN, defaulttrue) - whether to skip the detail/sampling pass and use this purely as a removal tool. Defaults to on, which tells you the node's primary intended use is removal-first.
Output is a single DETAILER_HOOK - wire it into a detailer's detailer_hook input, same as any other Impact Pack hook.
How to install it
Via ComfyUI Manager: search ComfyUI Impact Pack, install, restart. Manually:
cd ComfyUI/custom_nodes
git clone https://github.com/ltdrdata/ComfyUI-Impact-Pack comfyui-impact-pack
cd comfyui-impact-pack
python -m pip install -r requirements.txt # ComfyUI's python; python_embeded on portable
then restart. Then also install Layer-norm/comfyui-lama-remover - required, not optional, for this specific hook to function. This is a genuinely niche corner of the pack: reddit search turns up roughly a couple dozen mentions of "lama remover" over the past two years, so don't be surprised if you're one of the few people running it.
Common issues & troubleshooting
The hook does nothing / errors. Almost certainly the missing Lama Remover pack. Install it separately, restart ComfyUI, and try again.
Regions get removed when I only wanted them detailed. Check skip_sampling - it defaults to True, meaning removal-only mode is the out-of-the-box behavior. Set it to False if you actually want LaMa applied alongside a normal sampling pass rather than instead of one.
Combined this with another hook and removal didn't happen. Confirmed by the README: skip_sampling only takes effect through DetailerHookCombine if it's True on every hook in the combination. If one combined hook has it False, sampling proceeds for all of them.
Tried this on an AnimateDiff detailer. Not supported, per the pack's own docs - this hook is documented as inapplicable to AnimateDiff-flavored detailers. Use it only with the standard image detailers.
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| mask_threshold | INT | 2500–255 | — |
| gaussblur_radius | INT | 80–20 | — |
| skip_sampling | BOOLEAN | true | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| DETAILER_HOOK | DETAILER_HOOK | — |