Spaces:
Runtime error
Runtime error
File size: 334 Bytes
9d97922 1b28445 9d97922 9628643 9d97922 1b28445 9d97922 |
1 2 3 4 5 6 7 8 9 10 11 12 13 |
import gradio as gr
import shutil
from PIL import Image
from modnet_utils import remove_background
shutil.rmtree('__pycache__', ignore_errors=True)
def process(image: Image.Image) -> Image.Image:
return remove_background_modnet(image)
demo = gr.Interface(fn=process, inputs=gr.Image(type="pil"), outputs="image")
demo.launch()
|