MCPcopy
hub / github.com/abi/screenshot-to-code / remove_background

Function remove_background

backend/image_generation/replicate.py:145–157  ·  view source on GitHub ↗
(image_url: str, api_token: str)

Source from the content-addressed store, hash-verified

143
144
145async def remove_background(image_url: str, api_token: str) -> str:
146 result = await call_replicate_version(
147 REMOVE_BACKGROUND_VERSION,
148 {
149 "image": image_url,
150 "format": "png",
151 "reverse": False,
152 "threshold": 0,
153 "background_type": "rgba",
154 },
155 api_token,
156 )
157 return _extract_output_url(result, "background remover")
158
159
160async def edit_image(

Callers 1

_remove_backgroundMethod · 0.90

Calls 2

call_replicate_versionFunction · 0.85
_extract_output_urlFunction · 0.85

Tested by

no test coverage detected