Krishs21 commited on
Commit
e01b157
·
1 Parent(s): 049e8fd

code change

Browse files
Files changed (1) hide show
  1. app.py +4 -0
app.py CHANGED
@@ -7,6 +7,10 @@ from PIL import Image
7
  # Load the trained model (ensure this path is correct in your Space)
8
  model = load_model('human_identifier_model.h5')
9
 
 
 
 
 
10
  # Define the image size for input (based on your model's input size)
11
  IMG_SIZE = (299, 299)
12
 
 
7
  # Load the trained model (ensure this path is correct in your Space)
8
  model = load_model('human_identifier_model.h5')
9
 
10
+ model.compile(optimizer=Adam(), # Choose the same optimizer used during training
11
+ loss='binary_crossentropy', # Use the same loss function as during training
12
+ metrics=['accuracy'])
13
+
14
  # Define the image size for input (based on your model's input size)
15
  IMG_SIZE = (299, 299)
16