Hakim571 commited on
Commit
a8ac955
1 Parent(s): dad18b2

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -11,7 +11,7 @@ model=tf.keras.models.load_model('./my_model')
11
 
12
  def import_and_predict(image_data):
13
  x = image_data.reshape((-1, 224, 224, 3))
14
- x = tf.keras.applications.imagenet_utils.preprocess_input(x, data_format=data_format, mode="tf")
15
  prediction = model.predict(x)
16
  labels=class_names
17
  confidences = {labels[i]: float(prediction[0][i]) for i in range(15)}
 
11
 
12
  def import_and_predict(image_data):
13
  x = image_data.reshape((-1, 224, 224, 3))
14
+ x = tf.keras.applications.imagenet_utils.preprocess_input(x, mode="tf")
15
  prediction = model.predict(x)
16
  labels=class_names
17
  confidences = {labels[i]: float(prediction[0][i]) for i in range(15)}