Update app.py
Browse files
app.py
CHANGED
@@ -41,7 +41,7 @@ def classify_image(input_image):
|
|
41 |
font = ImageFont.load_default()
|
42 |
text = f'Previsão: {predicted_class_label}'
|
43 |
|
44 |
-
# Obter o tamanho do texto
|
45 |
text_width, text_height = draw.textsize(text, font=font)
|
46 |
|
47 |
x = (width - text_width) // 2
|
@@ -53,6 +53,8 @@ def classify_image(input_image):
|
|
53 |
return result_image
|
54 |
# ...
|
55 |
|
|
|
|
|
56 |
|
57 |
# Criar uma interface Gradio
|
58 |
interface = gr.Interface(
|
|
|
41 |
font = ImageFont.load_default()
|
42 |
text = f'Previsão: {predicted_class_label}'
|
43 |
|
44 |
+
# Obter o tamanho do texto usando getsize
|
45 |
text_width, text_height = draw.textsize(text, font=font)
|
46 |
|
47 |
x = (width - text_width) // 2
|
|
|
53 |
return result_image
|
54 |
# ...
|
55 |
|
56 |
+
# ...
|
57 |
+
|
58 |
|
59 |
# Criar uma interface Gradio
|
60 |
interface = gr.Interface(
|