Vicky000 commited on
Commit
254266e
1 Parent(s): 6a05ca3

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +11 -2
app.py CHANGED
@@ -14,11 +14,20 @@ def predict(img):
14
  # st.write(learn_inf.predict(img))
15
 
16
  f"""
17
- ## This **{'is ' if pred == 'mi' else 'is not'}** an MI (heart attack).
18
- ### Rediction result: {pred}
19
  ### Probability of {pred}: {probs[key].item()*100: .2f}%
20
  """
21
 
 
 
 
 
 
 
 
 
 
22
 
23
  path = "./"
24
  learn_inf = load_learner(path + "demo_model.pkl")
 
14
  # st.write(learn_inf.predict(img))
15
 
16
  f"""
17
+ ## This **{'is cordana' if pred == 'cordana' else 'is pestalotiopsis' if pred == 'pestalotiopsis' else 'is sigatoka' if pred == 'sigatoka' else 'is healthy'}**.
18
+ ### Prediction result: {pred}
19
  ### Probability of {pred}: {probs[key].item()*100: .2f}%
20
  """
21
 
22
+ col1, col2, col3 = st.columns(3)
23
+
24
+ with col1:
25
+ st.image(img1, caption="Image 1", use_column_width=True)
26
+ with col2:
27
+ st.image(img2, caption="Image 2", use_column_width=True)
28
+ with col3:
29
+ st.image(img3, caption="Image 3", use_column_width=True)
30
+
31
 
32
  path = "./"
33
  learn_inf = load_learner(path + "demo_model.pkl")