Update app.py
Browse files
app.py
CHANGED
@@ -19,7 +19,7 @@ labels = ['Abra', 'Cloyster', 'Dodrio']
|
|
19 |
def predict(image):
|
20 |
try:
|
21 |
# Bildvorverarbeitung
|
22 |
-
image = image.resize((
|
23 |
image = np.array(image) / 255.0
|
24 |
image = np.expand_dims(image, axis=0)
|
25 |
|
@@ -41,4 +41,3 @@ iface = gr.Interface(
|
|
41 |
|
42 |
if __name__ == "__main__":
|
43 |
iface.launch()
|
44 |
-
|
|
|
19 |
def predict(image):
|
20 |
try:
|
21 |
# Bildvorverarbeitung
|
22 |
+
image = image.resize((150, 150)) # Bild auf 150x150 skalieren
|
23 |
image = np.array(image) / 255.0
|
24 |
image = np.expand_dims(image, axis=0)
|
25 |
|
|
|
41 |
|
42 |
if __name__ == "__main__":
|
43 |
iface.launch()
|
|