nebiyu29 commited on
Commit
609abfc
1 Parent(s): 14aa15f

came back to the before the converiosn of data frame

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -110,11 +110,11 @@ predictions = classify(text_input)
110
  labels_str=",".join(predictions["top_labels"])
111
  probs_ints=",".join(map(str,predictions["top_probabilities"]))
112
 
113
- df=pd.DataFrame({'probabilities: ',probs_ints})
114
- formated_df=df.styled.format("{:.2f}").to_dict('list')
115
 
116
  #for prediction in predictions:
117
  # st.write(f"Segment Text: {prediction['segment_text']}")
118
 
119
  st.write(f"Label: {labels_str}")
120
- st.write(f"Probability: {formated_df["probabilities"][0]}")
 
110
  labels_str=",".join(predictions["top_labels"])
111
  probs_ints=",".join(map(str,predictions["top_probabilities"]))
112
 
113
+ #df=pd.DataFrame({'probabilities: ',probs_ints})
114
+ #formated_df=df.styled.format("{:.2f}").to_dict('list')
115
 
116
  #for prediction in predictions:
117
  # st.write(f"Segment Text: {prediction['segment_text']}")
118
 
119
  st.write(f"Label: {labels_str}")
120
+ st.write(f"Probability: {probs_ints}")