ComfyUI_BiRefNet_ll icon indicating copy to clipboard operation
ComfyUI_BiRefNet_ll copied to clipboard

Grey outline on output image (doesn't happen in BiRefNet demo)

Open MrT3chGuy opened this issue 9 months ago • 2 comments

Hi,

Thank you for creating this and for your hard work! I'm relatively new to ComfyUI. When running an image through the demo, it comes out clean with no outlines. But when running it through your node, I get a weird grey outline. I noticed it happens with other BiRefNet nodes, but this one has more outline. Please see the images below:

workflow: Image

BiRefNet_demo output: Image

ComfyUI_BiRefNet_ll output: Image

I'm not sure if it's visible in Github, so here is a screenshot of the grey outline:

Image

Here is the source image if you want to test it:

Image

I'm using:

  • Windows 10
  • GPU: NVIDIA GeForce RTX 2060 (6GB)
  • CPU: AMD Ryzen 9 5950X
  • RAM: 64GB DDR4
  • ComfyUI v0.3.18
  • Python v3.11.9
  • pytorch v2.6.0+cu126
  • ComfyUI_BiRefNet_ll v1.1.1

Thank you for your help!

MrT3chGuy avatar Apr 11 '25 06:04 MrT3chGuy

Image

Hi, you can try JoinImageWithAlpha. I didn't find a best way yet. @MrT3chGuy

lldacing avatar Apr 12 '25 11:04 lldacing

@lldacing thank you for looking into it! Using JoinImageWithAlpha produced much better results. It has a very thin white outline compared to the demo result, but it's much better than the grey outline. Interestingly, the result from JoinImageWithAlpha looks identical to the result of another BiRefNet node from https://github.com/1038lab/ComfyUI-RMBG

workflow:

Image

Using ComfyUI_BiRefNet_ll with JoinImageWithAlpha:

Image

Demo:

Image

It's hard to see the difference without zooming in. But I just wanted to point out the difference

Thanks again!

MrT3chGuy avatar Apr 13 '25 07:04 MrT3chGuy