QiLinWu / app.py
fengfeng2's picture
'1'
d754844
raw
history blame
662 Bytes
import gradio as gr
from gradio_client import Client, file
# def greet(name, intensity):
# return "Hello, " + name + "!" * int(intensity)
def test(text):
client = Client("stabilityai/stable-fast-3d")
result = client.predict(
image=file('https://raw.githubusercontent.com/gradio-app/gradio/main/test/test_files/bus.png'),
fr=0.85,
api_name="/requires_bg_remove"
)
# print(result)
return result
# demo = gr.Interface(
# fn=greet,
# inputs=["text", "slider"],
# outputs=["text"],
# )
demo = gr.Interface(
fn=test,
inputs=["text"],
outputs=["image"],
)
demo.launch(share=True)