Spaces:
Sleeping
Sleeping
samuel2424
commited on
Commit
·
6608016
1
Parent(s):
41b4ba2
cambiar el número de clases
Browse files
app.py
CHANGED
|
@@ -16,7 +16,7 @@ model, transform = create_effnetb2_model(
|
|
| 16 |
|
| 17 |
model.load_state_dict(
|
| 18 |
torch.load(
|
| 19 |
-
f="
|
| 20 |
map_location=torch.device("cpu")
|
| 21 |
)
|
| 22 |
)
|
|
@@ -44,9 +44,9 @@ def predict(img):
|
|
| 44 |
example_list = [["examples/" + example] for example in os.listdir("examples")]
|
| 45 |
|
| 46 |
# Gradio interface
|
| 47 |
-
title = "
|
| 48 |
-
description = "
|
| 49 |
-
article = "
|
| 50 |
|
| 51 |
demo = gr.Interface(fn=predict,
|
| 52 |
inputs=gr.Image(type="pil"),
|
|
|
|
| 16 |
|
| 17 |
model.load_state_dict(
|
| 18 |
torch.load(
|
| 19 |
+
f="model_v5.pth",
|
| 20 |
map_location=torch.device("cpu")
|
| 21 |
)
|
| 22 |
)
|
|
|
|
| 44 |
example_list = [["examples/" + example] for example in os.listdir("examples")]
|
| 45 |
|
| 46 |
# Gradio interface
|
| 47 |
+
title = "Modelo de Clasificación de Imágenes Finetuneado (Chatbots)"
|
| 48 |
+
description = "Clasifica el tipo de clima de una imagen"
|
| 49 |
+
article = "Código en el que está basado [GitHub](https://github.com/georgescutelnicu/Weather-Image-Classification)."
|
| 50 |
|
| 51 |
demo = gr.Interface(fn=predict,
|
| 52 |
inputs=gr.Image(type="pil"),
|