@tduncan / Nvidia-Optimization-Stack-VLLM Mirror · read-only / commits / cbd95a2dd1
Fork 0

A high-throughput and memory-efficient inference and serving engine for LLMs

Mirrored from https://github.com/tduncan-lum/Nvidia-Optimization-Stack---VLLM.git

Synced Nov 7, 22:45 UTC

[Benchmark] Use `sns.relplot` for plotting (#35027)

Signed-off-by: DarkLight1337 <tlleungac@connect.ust.hk>

Cyrus Leung committed Feb 22, 2026 at 12:26 UTC cbd95a2dd19a5786e8b6572a8e6599c8375c4abf
1 file changed +25 -23
vllm/benchmarks/sweep/plot.py
+25 -23
@@ -346,27 +346,11 @@ def _plot_fig(
346 else "(All)"
347 )
348
349 - g = sns.FacetGrid(df, row="row_group", col="col_group", height=fig_height)
350 -
351 - if row_by and col_by:
352 - g.set_titles("{row_name}\n{col_name}")
353 - elif row_by:
354 - g.set_titles("{row_name}")
355 - elif col_by:
356 - g.set_titles("{col_name}")
357 - else:
358 - g.set_titles("")
359 -
360 - if scale_x:
361 - g.set(xscale=scale_x)
362 - if scale_y:
363 - g.set(yscale=scale_y)
364 -
349 if len(curve_by) <= 3:
350 hue, style, size, *_ = (*curve_by, None, None, None)
351
368 - g.map_dataframe(
369 - sns.lineplot,
352 + g = sns.relplot(
353 + df,
354 x=var_x,
355 y=var_y,
356 hue=hue,
@@ -374,9 +358,11 @@ def _plot_fig(
358 size=size,
359 markers=True,
360 errorbar="sd" if error_bars else None,
361 + kind="line",
362 + row="row_group",
363 + col="col_group",
364 + height=fig_height,
365 )
378 -
379 - g.add_legend(title=hue)
366 else:
367 df["curve_group"] = (
368 pd.concat(
@@ -387,16 +373,32 @@ def _plot_fig(
373 else "(All)"
374 )
375
390 - g.map_dataframe(
391 - sns.lineplot,
376 + g = sns.relplot(
377 + df,
378 x=var_x,
379 y=var_y,
380 hue="curve_group",
381 markers=True,
382 errorbar="sd" if error_bars else None,
383 + kind="line",
384 + row="row_group",
385 + col="col_group",
386 + height=fig_height,
387 )
388
399 - g.add_legend()
389 + if row_by and col_by:
390 + g.set_titles("{row_name}\n{col_name}")
391 + elif row_by:
392 + g.set_titles("{row_name}")
393 + elif col_by:
394 + g.set_titles("{col_name}")
395 + else:
396 + g.set_titles("")
397 +
398 + if scale_x:
399 + g.set(xscale=scale_x)
400 + if scale_y:
401 + g.set(yscale=scale_y)
402
403 g.savefig(fig_path, dpi=fig_dpi)
404 plt.close(g.figure)