Terry Zhuo commited on
Commit
5fa61d0
1 Parent(s): 497f0f1

fix code format

Browse files
Files changed (1) hide show
  1. src/tools/plots.py +7 -1
src/tools/plots.py CHANGED
@@ -22,7 +22,13 @@ def plot_solve_rate(df, task, rows=30, cols=38):
22
  values = df["solve_rate"]
23
 
24
  values = np.array(values, dtype=float) # Ensure values are floats
25
-
 
 
 
 
 
 
26
  n = len(values)
27
  pad_width = rows * cols - n
28
 
 
22
  values = df["solve_rate"]
23
 
24
  values = np.array(values, dtype=float) # Ensure values are floats
25
+
26
+ # Extract numerical IDs and sort by them
27
+ ids = [int(key.split('/')[-1]) for key in keys]
28
+ sorted_indices = np.argsort(ids)
29
+ keys = np.array(keys)[sorted_indices]
30
+ values = values[sorted_indices]
31
+
32
  n = len(values)
33
  pad_width = rows * cols - n
34