Spaces:
Sleeping
Sleeping
AndySAnker
commited on
Commit
•
0942112
1
Parent(s):
f2c8162
Update app.py
Browse files
app.py
CHANGED
@@ -78,16 +78,11 @@ def POMPredicter(POMFinder, Gr, y_onehotenc_cat):
|
|
78 |
y_pred_proba = y_pred_proba[:,1];
|
79 |
res = sorted(range(len(y_pred_proba)), key = lambda sub: y_pred_proba[sub]);
|
80 |
res.reverse();
|
81 |
-
|
82 |
-
|
83 |
-
|
84 |
-
|
85 |
-
|
86 |
-
st.markdown(f'<span style="font-size: 24px; color: green;">The 1st guess from the model is: <b>{str(y_onehotenc_cat.categories_[0][res[0]])[2:-2]+"cale.xyz"}</b> with a probability of {y_pred_proba[res[0]]:.2f}</span> <hr/>',unsafe_allow_html=True)
|
87 |
-
st.markdown(f'<span style="font-size: 24px; color: green;">The 2nd guess from the model is: <b>{str(y_onehotenc_cat.categories_[0][res[1]])[2:-2]+"cale.xyz"}</b> with a probability of {y_pred_proba[res[1]]:.2f}</span> <hr/>',unsafe_allow_html=True)
|
88 |
-
st.markdown(f'<span style="font-size: 24px; color: green;">The 3rd guess from the model is: <b>{str(y_onehotenc_cat.categories_[0][res[2]])[2:-2]+"cale.xyz"}</b> with a probability of {y_pred_proba[res[2]]:.2f}</span> <hr/>',unsafe_allow_html=True)
|
89 |
-
st.markdown(f'<span style="font-size: 24px; color: green;">The 4th guess from the model is: <b>{str(y_onehotenc_cat.categories_[0][res[3]])[2:-2]+"cale.xyz"}</b> with a probability of {y_pred_proba[res[3]]:.2f}</span> <hr/>',unsafe_allow_html=True)
|
90 |
-
st.markdown(f'<span style="font-size: 24px; color: green;">The 5th guess from the model is: <b>{str(y_onehotenc_cat.categories_[0][res[4]])[2:-2]+"cale.xyz"}</b> with a probability of {y_pred_proba[res[4]]:.2f}</span> <hr/>',unsafe_allow_html=True)
|
91 |
|
92 |
return res, y_pred_proba
|
93 |
|
|
|
78 |
y_pred_proba = y_pred_proba[:,1];
|
79 |
res = sorted(range(len(y_pred_proba)), key = lambda sub: y_pred_proba[sub]);
|
80 |
res.reverse();
|
81 |
+
st.markdown(f'<span style="font-size: 24px; color: green;">The 1st guess from the model is: <b>{str(y_onehotenc_cat.categories_[0][res[0]])[2:-2]+"cale.xyz"}</b> with a probability of {y_pred_proba[res[0]]:.2f} %</span> <hr/>',unsafe_allow_html=True)
|
82 |
+
st.markdown(f'<span style="font-size: 24px; color: green;">The 2nd guess from the model is: <b>{str(y_onehotenc_cat.categories_[0][res[1]])[2:-2]+"cale.xyz"}</b> with a probability of {y_pred_proba[res[1]]:.2f} %</span> <hr/>',unsafe_allow_html=True)
|
83 |
+
st.markdown(f'<span style="font-size: 24px; color: green;">The 3rd guess from the model is: <b>{str(y_onehotenc_cat.categories_[0][res[2]])[2:-2]+"cale.xyz"}</b> with a probability of {y_pred_proba[res[2]]:.2f} %</span> <hr/>',unsafe_allow_html=True)
|
84 |
+
st.markdown(f'<span style="font-size: 24px; color: green;">The 4th guess from the model is: <b>{str(y_onehotenc_cat.categories_[0][res[3]])[2:-2]+"cale.xyz"}</b> with a probability of {y_pred_proba[res[3]]:.2f} %</span> <hr/>',unsafe_allow_html=True)
|
85 |
+
st.markdown(f'<span style="font-size: 24px; color: green;">The 5th guess from the model is: <b>{str(y_onehotenc_cat.categories_[0][res[4]])[2:-2]+"cale.xyz"}</b> with a probability of {y_pred_proba[res[4]]:.2f} %</span> <hr/>',unsafe_allow_html=True)
|
|
|
|
|
|
|
|
|
|
|
86 |
|
87 |
return res, y_pred_proba
|
88 |
|