BenchmarkBot commited on
Commit
bf397e6
β€’
1 Parent(s): 0f1bf97

changed optimizations layout and added them to plot

Browse files
Files changed (2) hide show
  1. app.py +13 -6
  2. src/assets/css_html_js.py +1 -2
app.py CHANGED
@@ -29,14 +29,13 @@ COLUMNS_MAPPING = {
29
  "model": "Model πŸ€—",
30
  "backend.name": "Backend 🏭",
31
  "backend.torch_dtype": "Load Dtype πŸ“₯",
32
- "num_parameters": "#️⃣ Parameters πŸ“",
33
  #
34
  "forward.peak_memory(MB)": "Peak Memory (MB) ⬇️",
35
  "generate.throughput(tokens/s)": "Throughput (tokens/s) ⬆️",
36
  "average": "Average Open LLM Score ⬆️",
37
  #
38
- "backend.bettertransformer": "BetterTransformer πŸ€–",
39
- "backend.load_in_8bit": "LLM.int8 πŸ—œοΈ",
40
  }
41
  COLUMNS_DATATYPES = [
42
  "markdown",
@@ -49,7 +48,6 @@ COLUMNS_DATATYPES = [
49
  "markdown",
50
  #
51
  "str",
52
- "str",
53
  ]
54
  SORTING_COLUMN = ["Throughput (tokens/s) ⬆️"]
55
 
@@ -66,6 +64,13 @@ def get_benchmark_df(benchmark="1xA100-80GB"):
66
  scores_df = pd.read_csv(f"./llm-perf-dataset/reports/additional_data.csv")
67
  bench_df = bench_df.merge(scores_df, on="model", how="left")
68
 
 
 
 
 
 
 
 
69
  return bench_df
70
 
71
 
@@ -100,6 +105,7 @@ def get_benchmark_plot(bench_df):
100
  "model",
101
  "backend.name",
102
  "backend.torch_dtype",
 
103
  "forward.peak_memory(MB)",
104
  "generate.throughput(tokens/s)",
105
  ],
@@ -129,8 +135,9 @@ def get_benchmark_plot(bench_df):
129
  "Model: %{customdata[0]}",
130
  "Backend: %{customdata[1]}",
131
  "Datatype: %{customdata[2]}",
132
- "Peak Memory (MB): %{customdata[3]}",
133
- "Throughput (tokens/s): %{customdata[4]}",
 
134
  "Average Open LLM Score: %{y}",
135
  "Per 1000 Tokens Latency (s): %{x}",
136
  ]
 
29
  "model": "Model πŸ€—",
30
  "backend.name": "Backend 🏭",
31
  "backend.torch_dtype": "Load Dtype πŸ“₯",
32
+ "optimizations": "Optimizations πŸ› οΈ",
33
  #
34
  "forward.peak_memory(MB)": "Peak Memory (MB) ⬇️",
35
  "generate.throughput(tokens/s)": "Throughput (tokens/s) ⬆️",
36
  "average": "Average Open LLM Score ⬆️",
37
  #
38
+ "num_parameters": "#️⃣ Parameters πŸ“",
 
39
  }
40
  COLUMNS_DATATYPES = [
41
  "markdown",
 
48
  "markdown",
49
  #
50
  "str",
 
51
  ]
52
  SORTING_COLUMN = ["Throughput (tokens/s) ⬆️"]
53
 
 
64
  scores_df = pd.read_csv(f"./llm-perf-dataset/reports/additional_data.csv")
65
  bench_df = bench_df.merge(scores_df, on="model", how="left")
66
 
67
+ bench_df["optimizations"] = bench_df[
68
+ ["backend.bettertransformer", "backend.load_in_8bit"]
69
+ ].apply(
70
+ lambda x: "BetterTransformer πŸ€–" if x[0] else "LLM.int8 πŸ—œοΈ" if x[1] else "None",
71
+ axis=1,
72
+ )
73
+
74
  return bench_df
75
 
76
 
 
105
  "model",
106
  "backend.name",
107
  "backend.torch_dtype",
108
+ "optimizations",
109
  "forward.peak_memory(MB)",
110
  "generate.throughput(tokens/s)",
111
  ],
 
135
  "Model: %{customdata[0]}",
136
  "Backend: %{customdata[1]}",
137
  "Datatype: %{customdata[2]}",
138
+ "Optimizations: %{customdata[3]}",
139
+ "Peak Memory (MB): %{customdata[4]}",
140
+ "Throughput (tokens/s): %{customdata[5]}",
141
  "Average Open LLM Score: %{y}",
142
  "Per 1000 Tokens Latency (s): %{x}",
143
  ]
src/assets/css_html_js.py CHANGED
@@ -25,10 +25,9 @@ custom_css = """
25
  border: none;
26
  }
27
 
28
- /* Limit the width of the first AutoEvalColumn so that names don't expand too much */
29
  table td:first-child,
30
  table th:first-child {
31
- max-width: 400px;
32
  overflow: auto;
33
  white-space: nowrap;
34
  }
 
25
  border: none;
26
  }
27
 
 
28
  table td:first-child,
29
  table th:first-child {
30
+ max-width: 300px;
31
  overflow: auto;
32
  white-space: nowrap;
33
  }