franckew commited on
Commit
2036f09
·
verified ·
1 Parent(s): 0c5866f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -6,7 +6,7 @@ from tensorflow.keras.applications.resnet50 import preprocess_input
6
  from tensorflow.keras.models import load_model
7
 
8
  # Load your trained model
9
- model = load_model('C:\Users\kewin\OneDrive\Desktop\OnePieceCharakter\Datensätze\OnePiece') # Ensure this path is correct
10
 
11
  def predict_pokemon(img):
12
  img = Image.fromarray(img.astype('uint8'), 'RGB') # Ensure the image is in RGB
@@ -23,8 +23,8 @@ def predict_pokemon(img):
23
  interface = gr.Interface(fn=predict_pokemon,
24
  inputs="image", # Simplified input type
25
  outputs="label", # Simplified output type
26
- title="Pokémon Classifier",
27
- description="Upload an image of a Pokémon and the classifier will predict its species.")
28
 
29
  # Launch the interface
30
  interface.launch()
 
6
  from tensorflow.keras.models import load_model
7
 
8
  # Load your trained model
9
+ model = load_model('/home/user/app/franckew.h5') # Ensure this path is correct
10
 
11
  def predict_pokemon(img):
12
  img = Image.fromarray(img.astype('uint8'), 'RGB') # Ensure the image is in RGB
 
23
  interface = gr.Interface(fn=predict_pokemon,
24
  inputs="image", # Simplified input type
25
  outputs="label", # Simplified output type
26
+ title="One Piece Classifier",
27
+ description="Upload an image of a OP Character and the classifier will predict its name.")
28
 
29
  # Launch the interface
30
  interface.launch()