ki4n-4nt commited on
Commit
ce57502
·
1 Parent(s): df2d5a5

Removed redundant preprocessing

Browse files
Files changed (1) hide show
  1. inference_utils.py +1 -2
inference_utils.py CHANGED
@@ -42,8 +42,7 @@ def preprocess_image(image_path):
42
  image_path, target_size=(IMG_SIZE, IMG_SIZE)
43
  )
44
  img_array = tf.keras.preprocessing.image.img_to_array(img)
45
- # Use EfficientNet preprocessing ([-1, 1] scaling)
46
- img_array = keras.applications.efficientnet.preprocess_input(img_array)
47
  return np.expand_dims(img_array, axis=0)
48
 
49
 
 
42
  image_path, target_size=(IMG_SIZE, IMG_SIZE)
43
  )
44
  img_array = tf.keras.preprocessing.image.img_to_array(img)
45
+ # Preprocessing will be done by the model's input layer
 
46
  return np.expand_dims(img_array, axis=0)
47
 
48