Update app.py
Browse files
app.py
CHANGED
@@ -698,15 +698,16 @@ with gr.Blocks(theme=theme, title="Analyse de lésions", css=css) as demo:
|
|
698 |
'Probabilités (%)': [0] * len(CLASS_NAMES)
|
699 |
})
|
700 |
|
|
|
701 |
output_plot = gr.BarPlot(
|
702 |
-
|
703 |
-
|
704 |
-
|
705 |
-
|
706 |
-
|
707 |
-
|
708 |
-
|
709 |
-
|
710 |
|
711 |
output_gradcam = gr.Image(label="🔍 Visualisation Grad-CAM")
|
712 |
output_status = gr.Textbox(label="Statut", interactive=False)
|
|
|
698 |
'Probabilités (%)': [0] * len(CLASS_NAMES)
|
699 |
})
|
700 |
|
701 |
+
# Configuration correcte du BarPlot
|
702 |
output_plot = gr.BarPlot(
|
703 |
+
value=initial_df, # DataFrame initial
|
704 |
+
x="Classes", # Nom de la colonne x
|
705 |
+
y="Probabilités (%)", # Nom de la colonne y
|
706 |
+
title="Probabilités par classe",
|
707 |
+
y_lim=[0, 100],
|
708 |
+
height=450,
|
709 |
+
show_label=True # Afficher les valeurs sur les barres
|
710 |
+
)
|
711 |
|
712 |
output_gradcam = gr.Image(label="🔍 Visualisation Grad-CAM")
|
713 |
output_status = gr.Textbox(label="Statut", interactive=False)
|