Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -9,7 +9,7 @@ from diffusers import DiffusionPipeline
|
|
| 9 |
from huggingface_hub import login
|
| 10 |
import numpy as np
|
| 11 |
|
| 12 |
-
def guessanImage(
|
| 13 |
#model = "microsoft/resnet-50"
|
| 14 |
# st.write("using model:"+model)
|
| 15 |
|
|
@@ -22,7 +22,7 @@ radio = gr.Radio(["microsoft/resnet-50", "google/vit-base-patch16-224", "apple/m
|
|
| 22 |
|
| 23 |
demo = gr.Interface(
|
| 24 |
fn=guessanImage,
|
| 25 |
-
inputs=[gr.Image(type="pil")
|
| 26 |
outputs=["text"],
|
| 27 |
)
|
| 28 |
|
|
|
|
| 9 |
from huggingface_hub import login
|
| 10 |
import numpy as np
|
| 11 |
|
| 12 |
+
def guessanImage(model, image):
|
| 13 |
#model = "microsoft/resnet-50"
|
| 14 |
# st.write("using model:"+model)
|
| 15 |
|
|
|
|
| 22 |
|
| 23 |
demo = gr.Interface(
|
| 24 |
fn=guessanImage,
|
| 25 |
+
inputs=[radio, gr.Image(type="pil")],
|
| 26 |
outputs=["text"],
|
| 27 |
)
|
| 28 |
|