Code
Hub
Workspaces
Connect
Indexed graphs
Engine
MCP
copy
hub
/
github.com/nadermx/backgroundremover
/ naive_cutout
Function
naive_cutout
backgroundremover/bg.py:242–245 ·
view source on GitHub ↗
(img, mask)
Source
from the content-addressed store, hash-verified
240
241
242
def
naive_cutout(img, mask):
243
empty = Image.new(
"RGBA"
, (img.size), 0)
244
cutout = Image.composite(img, empty, mask.resize(img.size, Image.LANCZOS))
245
return
cutout
246
247
248
def
get_model(model_name):
Callers
1
remove
Function · 0.85
Calls
no outgoing calls
Tested by
no test coverage detected