Update app.py
Browse files
app.py
CHANGED
|
@@ -697,17 +697,17 @@ def page_frauds():
|
|
| 697 |
return
|
| 698 |
|
| 699 |
with st.spinner("Chargement des fraudes..."):
|
| 700 |
-
|
| 701 |
|
| 702 |
# DEBUG : Afficher les types et quelques valeurs brutes
|
| 703 |
-
|
| 704 |
-
|
| 705 |
-
|
| 706 |
-
|
| 707 |
-
|
| 708 |
-
|
| 709 |
-
|
| 710 |
-
|
| 711 |
|
| 712 |
st.markdown(f"""
|
| 713 |
<div style="background-color: {COLOR_FRAUD}; padding: 15px; border-radius: 10px; text-align: center; margin-bottom: 20px;">
|
|
|
|
| 697 |
return
|
| 698 |
|
| 699 |
with st.spinner("Chargement des fraudes..."):
|
| 700 |
+
df = load_last_24h_data()
|
| 701 |
|
| 702 |
# DEBUG : Afficher les types et quelques valeurs brutes
|
| 703 |
+
st.write("### 🔍 DEBUG - Premières lignes brutes:")
|
| 704 |
+
st.write(df.head(10))
|
| 705 |
+
st.write("### 🔍 DEBUG - Types de colonnes:")
|
| 706 |
+
st.write(df.dtypes)
|
| 707 |
+
st.write("### 🔍 DEBUG - Valeurs uniques merchant:")
|
| 708 |
+
st.write(df['merchant'].value_counts().head(20))
|
| 709 |
+
|
| 710 |
+
df_frauds = df[df['pred_is_fraud'] == 1]
|
| 711 |
|
| 712 |
st.markdown(f"""
|
| 713 |
<div style="background-color: {COLOR_FRAUD}; padding: 15px; border-radius: 10px; text-align: center; margin-bottom: 20px;">
|