abspython commited on
Commit
c6cc5db
·
1 Parent(s): bfc0d66

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -17,13 +17,13 @@ def load_image(image_file):
17
  return img
18
 
19
  def get_img_prediction(imgpath):
20
- img = load_img(imgpath,target_size=(64,64,3))
21
  img = img_to_array(img)
22
  img = img/255
23
 
24
  X_pred_image = np.array(img)
25
 
26
- X_pred_imaged = X_pred_image.reshape(1,64*64*3)
27
  y_pred_pro = loaded_lgbm.predict_proba(X_pred_imaged)
28
  return y_pred_pro[0].tolist()
29
 
 
17
  return img
18
 
19
  def get_img_prediction(imgpath):
20
+ img = load_img(imgpath,target_size=(128,128,3))
21
  img = img_to_array(img)
22
  img = img/255
23
 
24
  X_pred_image = np.array(img)
25
 
26
+ X_pred_imaged = X_pred_image.reshape(1,128*128*3)
27
  y_pred_pro = loaded_lgbm.predict_proba(X_pred_imaged)
28
  return y_pred_pro[0].tolist()
29