EngAbod commited on
Commit
d6354fb
·
1 Parent(s): b669b47

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -35,7 +35,7 @@ drawing_spec = mp_drawing.DrawingSpec(thickness=1, circle_radius=1)
35
 
36
  # Load the model
37
  model = load_model('best_model_HQ_v11.h5')
38
- # model2 = load_model('best_model_HQ_v9.h5')
39
  def u_sliding_factor(image_channel, P):
40
  result = np.zeros(image_channel.shape, np.float32)
41
 
@@ -219,8 +219,8 @@ if picture:
219
  # print(X_array.shape)
220
  X_test_array_reshaped = np.expand_dims(X_array, axis=-1)
221
  prediction = model.predict(X_test_array_reshaped)
222
- # prediction2 = model2.predict(X_test_array_reshaped)
223
- if prediction >= 0.90:
224
  st.text("صورة حقيقية")
225
  st.text(str(prediction[0]))
226
  # st.text(str(prediction2[0]))
 
35
 
36
  # Load the model
37
  model = load_model('best_model_HQ_v11.h5')
38
+ model2 = load_model('best_model_HQ_v9.h5')
39
  def u_sliding_factor(image_channel, P):
40
  result = np.zeros(image_channel.shape, np.float32)
41
 
 
219
  # print(X_array.shape)
220
  X_test_array_reshaped = np.expand_dims(X_array, axis=-1)
221
  prediction = model.predict(X_test_array_reshaped)
222
+ prediction2 = model2.predict(X_test_array_reshaped)
223
+ if prediction >= 0.90 and prediction2 >= 0.0000000000001:
224
  st.text("صورة حقيقية")
225
  st.text(str(prediction[0]))
226
  # st.text(str(prediction2[0]))