Spaces:
Running
Running
Update src/vis_utils.py
Browse files- src/vis_utils.py +1 -4
src/vis_utils.py
CHANGED
@@ -230,6 +230,7 @@ def plot_affinity_results(method_names, metric, affinity_path="/tmp/affinity_res
|
|
230 |
|
231 |
# Gather columns related to the specified metric and validate
|
232 |
metric_columns = [col for col in df.columns if col.startswith(f"{metric}_")]
|
|
|
233 |
|
234 |
df = df.fillna(0)
|
235 |
|
@@ -254,10 +255,6 @@ def plot_affinity_results(method_names, metric, affinity_path="/tmp/affinity_res
|
|
254 |
ax.grid(visible=True, which='major', color='gainsboro', linewidth=1.0)
|
255 |
ax.grid(visible=True, which='minor', color='whitesmoke', linewidth=0.5)
|
256 |
|
257 |
-
# Add reference lines
|
258 |
-
ax.plot((best_pipr, best_pipr), (-1, len(df.columns) + 1), color='black', label='Best PIPR')
|
259 |
-
ax.plot((baseline_ac, baseline_ac), (-1, len(df.columns) + 1), color='purple', linestyle='dashed', label='Baseline AC')
|
260 |
-
ax.plot((baseline_ctd, baseline_ctd), (-1, len(df.columns) + 1), color='brown', linestyle='dashed', label='Baseline CTD')
|
261 |
|
262 |
# Apply custom color settings to y-axis labels
|
263 |
for label in ax.get_yticklabels():
|
|
|
230 |
|
231 |
# Gather columns related to the specified metric and validate
|
232 |
metric_columns = [col for col in df.columns if col.startswith(f"{metric}_")]
|
233 |
+
df = df[['Method'] + metric_columns]
|
234 |
|
235 |
df = df.fillna(0)
|
236 |
|
|
|
255 |
ax.grid(visible=True, which='major', color='gainsboro', linewidth=1.0)
|
256 |
ax.grid(visible=True, which='minor', color='whitesmoke', linewidth=0.5)
|
257 |
|
|
|
|
|
|
|
|
|
258 |
|
259 |
# Apply custom color settings to y-axis labels
|
260 |
for label in ax.get_yticklabels():
|