decoding results
Browse files- common.py +2 -1
- decoding_results.json +57 -57
common.py
CHANGED
|
@@ -792,7 +792,8 @@ def launch_parallel(jobs, poll_s=180, tail=3):
|
|
| 792 |
assert len(jobs) <= n_gpu, f"{len(jobs)} jobs but only {n_gpu} GPU(s)"
|
| 793 |
procs = []
|
| 794 |
for gpu, (name, code) in enumerate(jobs):
|
| 795 |
-
env = dict(os.environ, CUDA_VISIBLE_DEVICES=str(gpu), PYTHONUNBUFFERED="1"
|
|
|
|
| 796 |
logf = open(f"{name}.log", "w")
|
| 797 |
procs.append((name, subprocess.Popen([sys.executable, "-u", "-c", code], env=env,
|
| 798 |
stdout=logf, stderr=subprocess.STDOUT), logf))
|
|
|
|
| 792 |
assert len(jobs) <= n_gpu, f"{len(jobs)} jobs but only {n_gpu} GPU(s)"
|
| 793 |
procs = []
|
| 794 |
for gpu, (name, code) in enumerate(jobs):
|
| 795 |
+
env = dict(os.environ, CUDA_VISIBLE_DEVICES=str(gpu), PYTHONUNBUFFERED="1",
|
| 796 |
+
PYTORCH_CUDA_ALLOC_CONF="expandable_segments:True")
|
| 797 |
logf = open(f"{name}.log", "w")
|
| 798 |
procs.append((name, subprocess.Popen([sys.executable, "-u", "-c", code], env=env,
|
| 799 |
stdout=logf, stderr=subprocess.STDOUT), logf))
|
decoding_results.json
CHANGED
|
@@ -27,8 +27,8 @@
|
|
| 27 |
"name": "greedy",
|
| 28 |
"strategy": "greedy"
|
| 29 |
},
|
| 30 |
-
"time_s":
|
| 31 |
-
"ms_per_prompt":
|
| 32 |
"gen_tokens_mean": 69.995,
|
| 33 |
"judge_ppl_median": 3.7136934995651245,
|
| 34 |
"judge_ppl_mean": 3.8431873861551287,
|
|
@@ -55,8 +55,8 @@
|
|
| 55 |
"strategy": "beam",
|
| 56 |
"width": 1
|
| 57 |
},
|
| 58 |
-
"time_s":
|
| 59 |
-
"ms_per_prompt":
|
| 60 |
"gen_tokens_mean": 69.995,
|
| 61 |
"judge_ppl_median": 3.7136934995651245,
|
| 62 |
"judge_ppl_mean": 3.839161422610283,
|
|
@@ -83,8 +83,8 @@
|
|
| 83 |
"strategy": "beam",
|
| 84 |
"width": 2
|
| 85 |
},
|
| 86 |
-
"time_s":
|
| 87 |
-
"ms_per_prompt":
|
| 88 |
"gen_tokens_mean": 69.827,
|
| 89 |
"judge_ppl_median": 4.08447003364563,
|
| 90 |
"judge_ppl_mean": 5.812772500276566,
|
|
@@ -111,12 +111,12 @@
|
|
| 111 |
"strategy": "beam",
|
| 112 |
"width": 4
|
| 113 |
},
|
| 114 |
-
"time_s":
|
| 115 |
-
"ms_per_prompt":
|
| 116 |
"gen_tokens_mean": 69.253,
|
| 117 |
"judge_ppl_median": 3.7220958471298218,
|
| 118 |
"judge_ppl_mean": 549.211596192956,
|
| 119 |
-
"bertscore_p": 0.
|
| 120 |
"bertscore_r": 0.8445523977279663,
|
| 121 |
"bertscore_f1": 0.851769208908081
|
| 122 |
},
|
|
@@ -139,8 +139,8 @@
|
|
| 139 |
"strategy": "top_k",
|
| 140 |
"k": 5
|
| 141 |
},
|
| 142 |
-
"time_s": 28.
|
| 143 |
-
"ms_per_prompt": 28.
|
| 144 |
"gen_tokens_mean": 69.697,
|
| 145 |
"judge_ppl_median": 8.458185195922852,
|
| 146 |
"judge_ppl_mean": 9.329122072458267,
|
|
@@ -167,8 +167,8 @@
|
|
| 167 |
"strategy": "top_k",
|
| 168 |
"k": 20
|
| 169 |
},
|
| 170 |
-
"time_s":
|
| 171 |
-
"ms_per_prompt":
|
| 172 |
"gen_tokens_mean": 69.165,
|
| 173 |
"judge_ppl_median": 14.761709213256836,
|
| 174 |
"judge_ppl_mean": 50.361770061254504
|
|
@@ -192,8 +192,8 @@
|
|
| 192 |
"strategy": "top_k",
|
| 193 |
"k": 50
|
| 194 |
},
|
| 195 |
-
"time_s":
|
| 196 |
-
"ms_per_prompt":
|
| 197 |
"gen_tokens_mean": 68.635,
|
| 198 |
"judge_ppl_median": 20.48440647125244,
|
| 199 |
"judge_ppl_mean": 72.74511349225044
|
|
@@ -218,8 +218,8 @@
|
|
| 218 |
"k": 50,
|
| 219 |
"temperature": 0.7
|
| 220 |
},
|
| 221 |
-
"time_s":
|
| 222 |
-
"ms_per_prompt":
|
| 223 |
"gen_tokens_mean": 69.563,
|
| 224 |
"judge_ppl_median": 10.548301219940186,
|
| 225 |
"judge_ppl_mean": 1104.2365723810196
|
|
@@ -243,8 +243,8 @@
|
|
| 243 |
"strategy": "top_p",
|
| 244 |
"p": 0.5
|
| 245 |
},
|
| 246 |
-
"time_s":
|
| 247 |
-
"ms_per_prompt":
|
| 248 |
"gen_tokens_mean": 69.823,
|
| 249 |
"judge_ppl_median": 9.4617280960083,
|
| 250 |
"judge_ppl_mean": 1095.229723884821
|
|
@@ -268,8 +268,8 @@
|
|
| 268 |
"strategy": "top_p",
|
| 269 |
"p": 0.8
|
| 270 |
},
|
| 271 |
-
"time_s":
|
| 272 |
-
"ms_per_prompt":
|
| 273 |
"gen_tokens_mean": 69.009,
|
| 274 |
"judge_ppl_median": 23.211604118347168,
|
| 275 |
"judge_ppl_mean": 74.37143414640427
|
|
@@ -293,8 +293,8 @@
|
|
| 293 |
"strategy": "top_p",
|
| 294 |
"p": 0.95
|
| 295 |
},
|
| 296 |
-
"time_s":
|
| 297 |
-
"ms_per_prompt":
|
| 298 |
"gen_tokens_mean": 68.636,
|
| 299 |
"judge_ppl_median": 54.274309158325195,
|
| 300 |
"judge_ppl_mean": 297.4285540444851
|
|
@@ -319,8 +319,8 @@
|
|
| 319 |
"p": 0.9,
|
| 320 |
"temperature": 0.7
|
| 321 |
},
|
| 322 |
-
"time_s":
|
| 323 |
-
"ms_per_prompt":
|
| 324 |
"gen_tokens_mean": 69.865,
|
| 325 |
"judge_ppl_median": 9.213471412658691,
|
| 326 |
"judge_ppl_mean": 1094.454825058937
|
|
@@ -330,81 +330,81 @@
|
|
| 330 |
{
|
| 331 |
"mode": "natural",
|
| 332 |
"width": 1,
|
| 333 |
-
"mean_s_per_prompt": 0.
|
| 334 |
-
"std_s": 0.
|
| 335 |
-
"mean_ms_per_token": 11.
|
| 336 |
"mean_output_tokens": 70.0,
|
| 337 |
-
"total_s":
|
| 338 |
"n_prompts": 100
|
| 339 |
},
|
| 340 |
{
|
| 341 |
"mode": "natural",
|
| 342 |
"width": 2,
|
| 343 |
-
"mean_s_per_prompt": 0.
|
| 344 |
-
"std_s": 0.
|
| 345 |
-
"mean_ms_per_token": 11.
|
| 346 |
"mean_output_tokens": 69.86,
|
| 347 |
-
"total_s":
|
| 348 |
"n_prompts": 100
|
| 349 |
},
|
| 350 |
{
|
| 351 |
"mode": "natural",
|
| 352 |
"width": 4,
|
| 353 |
-
"mean_s_per_prompt": 0.
|
| 354 |
-
"std_s": 0.
|
| 355 |
-
"mean_ms_per_token":
|
| 356 |
"mean_output_tokens": 69.59,
|
| 357 |
-
"total_s":
|
| 358 |
"n_prompts": 100
|
| 359 |
},
|
| 360 |
{
|
| 361 |
"mode": "natural",
|
| 362 |
"width": 8,
|
| 363 |
-
"mean_s_per_prompt": 0.
|
| 364 |
-
"std_s": 0.
|
| 365 |
-
"mean_ms_per_token":
|
| 366 |
"mean_output_tokens": 69.34,
|
| 367 |
-
"total_s":
|
| 368 |
"n_prompts": 100
|
| 369 |
},
|
| 370 |
{
|
| 371 |
"mode": "fixed",
|
| 372 |
"width": 1,
|
| 373 |
-
"mean_s_per_prompt": 0.
|
| 374 |
-
"std_s": 0.
|
| 375 |
-
"mean_ms_per_token": 11.
|
| 376 |
"mean_output_tokens": 70.0,
|
| 377 |
-
"total_s":
|
| 378 |
"n_prompts": 100
|
| 379 |
},
|
| 380 |
{
|
| 381 |
"mode": "fixed",
|
| 382 |
"width": 2,
|
| 383 |
-
"mean_s_per_prompt": 0.
|
| 384 |
-
"std_s": 0.
|
| 385 |
-
"mean_ms_per_token": 11.
|
| 386 |
"mean_output_tokens": 70.0,
|
| 387 |
-
"total_s":
|
| 388 |
"n_prompts": 100
|
| 389 |
},
|
| 390 |
{
|
| 391 |
"mode": "fixed",
|
| 392 |
"width": 4,
|
| 393 |
-
"mean_s_per_prompt": 0.
|
| 394 |
-
"std_s": 0.
|
| 395 |
-
"mean_ms_per_token":
|
| 396 |
"mean_output_tokens": 70.0,
|
| 397 |
-
"total_s":
|
| 398 |
"n_prompts": 100
|
| 399 |
},
|
| 400 |
{
|
| 401 |
"mode": "fixed",
|
| 402 |
"width": 8,
|
| 403 |
-
"mean_s_per_prompt": 0.
|
| 404 |
-
"std_s": 0.
|
| 405 |
-
"mean_ms_per_token": 12.
|
| 406 |
"mean_output_tokens": 70.0,
|
| 407 |
-
"total_s":
|
| 408 |
"n_prompts": 100
|
| 409 |
}
|
| 410 |
],
|
|
|
|
| 27 |
"name": "greedy",
|
| 28 |
"strategy": "greedy"
|
| 29 |
},
|
| 30 |
+
"time_s": 27.15269684791565,
|
| 31 |
+
"ms_per_prompt": 27.15269684791565,
|
| 32 |
"gen_tokens_mean": 69.995,
|
| 33 |
"judge_ppl_median": 3.7136934995651245,
|
| 34 |
"judge_ppl_mean": 3.8431873861551287,
|
|
|
|
| 55 |
"strategy": "beam",
|
| 56 |
"width": 1
|
| 57 |
},
|
| 58 |
+
"time_s": 111.54685831069946,
|
| 59 |
+
"ms_per_prompt": 111.54685831069946,
|
| 60 |
"gen_tokens_mean": 69.995,
|
| 61 |
"judge_ppl_median": 3.7136934995651245,
|
| 62 |
"judge_ppl_mean": 3.839161422610283,
|
|
|
|
| 83 |
"strategy": "beam",
|
| 84 |
"width": 2
|
| 85 |
},
|
| 86 |
+
"time_s": 110.16097116470337,
|
| 87 |
+
"ms_per_prompt": 110.16097116470337,
|
| 88 |
"gen_tokens_mean": 69.827,
|
| 89 |
"judge_ppl_median": 4.08447003364563,
|
| 90 |
"judge_ppl_mean": 5.812772500276566,
|
|
|
|
| 111 |
"strategy": "beam",
|
| 112 |
"width": 4
|
| 113 |
},
|
| 114 |
+
"time_s": 121.36622357368469,
|
| 115 |
+
"ms_per_prompt": 121.36622357368469,
|
| 116 |
"gen_tokens_mean": 69.253,
|
| 117 |
"judge_ppl_median": 3.7220958471298218,
|
| 118 |
"judge_ppl_mean": 549.211596192956,
|
| 119 |
+
"bertscore_p": 0.8594745397567749,
|
| 120 |
"bertscore_r": 0.8445523977279663,
|
| 121 |
"bertscore_f1": 0.851769208908081
|
| 122 |
},
|
|
|
|
| 139 |
"strategy": "top_k",
|
| 140 |
"k": 5
|
| 141 |
},
|
| 142 |
+
"time_s": 28.873475074768066,
|
| 143 |
+
"ms_per_prompt": 28.873475074768066,
|
| 144 |
"gen_tokens_mean": 69.697,
|
| 145 |
"judge_ppl_median": 8.458185195922852,
|
| 146 |
"judge_ppl_mean": 9.329122072458267,
|
|
|
|
| 167 |
"strategy": "top_k",
|
| 168 |
"k": 20
|
| 169 |
},
|
| 170 |
+
"time_s": 28.941107749938965,
|
| 171 |
+
"ms_per_prompt": 28.941107749938965,
|
| 172 |
"gen_tokens_mean": 69.165,
|
| 173 |
"judge_ppl_median": 14.761709213256836,
|
| 174 |
"judge_ppl_mean": 50.361770061254504
|
|
|
|
| 192 |
"strategy": "top_k",
|
| 193 |
"k": 50
|
| 194 |
},
|
| 195 |
+
"time_s": 29.148484706878662,
|
| 196 |
+
"ms_per_prompt": 29.148484706878662,
|
| 197 |
"gen_tokens_mean": 68.635,
|
| 198 |
"judge_ppl_median": 20.48440647125244,
|
| 199 |
"judge_ppl_mean": 72.74511349225044
|
|
|
|
| 218 |
"k": 50,
|
| 219 |
"temperature": 0.7
|
| 220 |
},
|
| 221 |
+
"time_s": 29.37712073326111,
|
| 222 |
+
"ms_per_prompt": 29.37712073326111,
|
| 223 |
"gen_tokens_mean": 69.563,
|
| 224 |
"judge_ppl_median": 10.548301219940186,
|
| 225 |
"judge_ppl_mean": 1104.2365723810196
|
|
|
|
| 243 |
"strategy": "top_p",
|
| 244 |
"p": 0.5
|
| 245 |
},
|
| 246 |
+
"time_s": 32.68005704879761,
|
| 247 |
+
"ms_per_prompt": 32.68005704879761,
|
| 248 |
"gen_tokens_mean": 69.823,
|
| 249 |
"judge_ppl_median": 9.4617280960083,
|
| 250 |
"judge_ppl_mean": 1095.229723884821
|
|
|
|
| 268 |
"strategy": "top_p",
|
| 269 |
"p": 0.8
|
| 270 |
},
|
| 271 |
+
"time_s": 32.03048324584961,
|
| 272 |
+
"ms_per_prompt": 32.03048324584961,
|
| 273 |
"gen_tokens_mean": 69.009,
|
| 274 |
"judge_ppl_median": 23.211604118347168,
|
| 275 |
"judge_ppl_mean": 74.37143414640427
|
|
|
|
| 293 |
"strategy": "top_p",
|
| 294 |
"p": 0.95
|
| 295 |
},
|
| 296 |
+
"time_s": 32.22635364532471,
|
| 297 |
+
"ms_per_prompt": 32.22635364532471,
|
| 298 |
"gen_tokens_mean": 68.636,
|
| 299 |
"judge_ppl_median": 54.274309158325195,
|
| 300 |
"judge_ppl_mean": 297.4285540444851
|
|
|
|
| 319 |
"p": 0.9,
|
| 320 |
"temperature": 0.7
|
| 321 |
},
|
| 322 |
+
"time_s": 32.13967037200928,
|
| 323 |
+
"ms_per_prompt": 32.13967037200928,
|
| 324 |
"gen_tokens_mean": 69.865,
|
| 325 |
"judge_ppl_median": 9.213471412658691,
|
| 326 |
"judge_ppl_mean": 1094.454825058937
|
|
|
|
| 330 |
{
|
| 331 |
"mode": "natural",
|
| 332 |
"width": 1,
|
| 333 |
+
"mean_s_per_prompt": 0.7966235804557801,
|
| 334 |
+
"std_s": 0.01989696312825657,
|
| 335 |
+
"mean_ms_per_token": 11.380336863654001,
|
| 336 |
"mean_output_tokens": 70.0,
|
| 337 |
+
"total_s": 79.662358045578,
|
| 338 |
"n_prompts": 100
|
| 339 |
},
|
| 340 |
{
|
| 341 |
"mode": "natural",
|
| 342 |
"width": 2,
|
| 343 |
+
"mean_s_per_prompt": 0.8142524075508117,
|
| 344 |
+
"std_s": 0.024042614408421762,
|
| 345 |
+
"mean_ms_per_token": 11.656413194421047,
|
| 346 |
"mean_output_tokens": 69.86,
|
| 347 |
+
"total_s": 81.42524075508118,
|
| 348 |
"n_prompts": 100
|
| 349 |
},
|
| 350 |
{
|
| 351 |
"mode": "natural",
|
| 352 |
"width": 4,
|
| 353 |
+
"mean_s_per_prompt": 0.8594671440124512,
|
| 354 |
+
"std_s": 0.04051314764123496,
|
| 355 |
+
"mean_ms_per_token": 12.351310080320381,
|
| 356 |
"mean_output_tokens": 69.59,
|
| 357 |
+
"total_s": 85.94671440124512,
|
| 358 |
"n_prompts": 100
|
| 359 |
},
|
| 360 |
{
|
| 361 |
"mode": "natural",
|
| 362 |
"width": 8,
|
| 363 |
+
"mean_s_per_prompt": 0.9159316921234131,
|
| 364 |
+
"std_s": 0.04308222295630671,
|
| 365 |
+
"mean_ms_per_token": 13.236482083315467,
|
| 366 |
"mean_output_tokens": 69.34,
|
| 367 |
+
"total_s": 91.59316921234131,
|
| 368 |
"n_prompts": 100
|
| 369 |
},
|
| 370 |
{
|
| 371 |
"mode": "fixed",
|
| 372 |
"width": 1,
|
| 373 |
+
"mean_s_per_prompt": 0.793733959197998,
|
| 374 |
+
"std_s": 0.01947922482082487,
|
| 375 |
+
"mean_ms_per_token": 11.3390565599714,
|
| 376 |
"mean_output_tokens": 70.0,
|
| 377 |
+
"total_s": 79.3733959197998,
|
| 378 |
"n_prompts": 100
|
| 379 |
},
|
| 380 |
{
|
| 381 |
"mode": "fixed",
|
| 382 |
"width": 2,
|
| 383 |
+
"mean_s_per_prompt": 0.8047142720222473,
|
| 384 |
+
"std_s": 0.01562980802083294,
|
| 385 |
+
"mean_ms_per_token": 11.495918171746387,
|
| 386 |
"mean_output_tokens": 70.0,
|
| 387 |
+
"total_s": 80.47142720222473,
|
| 388 |
"n_prompts": 100
|
| 389 |
},
|
| 390 |
{
|
| 391 |
"mode": "fixed",
|
| 392 |
"width": 4,
|
| 393 |
+
"mean_s_per_prompt": 0.8514944720268249,
|
| 394 |
+
"std_s": 0.014158784290349734,
|
| 395 |
+
"mean_ms_per_token": 12.164206743240355,
|
| 396 |
"mean_output_tokens": 70.0,
|
| 397 |
+
"total_s": 85.1494472026825,
|
| 398 |
"n_prompts": 100
|
| 399 |
},
|
| 400 |
{
|
| 401 |
"mode": "fixed",
|
| 402 |
"width": 8,
|
| 403 |
+
"mean_s_per_prompt": 0.8935490798950195,
|
| 404 |
+
"std_s": 0.015420650987721442,
|
| 405 |
+
"mean_ms_per_token": 12.764986855643139,
|
| 406 |
"mean_output_tokens": 70.0,
|
| 407 |
+
"total_s": 89.35490798950195,
|
| 408 |
"n_prompts": 100
|
| 409 |
}
|
| 410 |
],
|