mirror of
https://github.com/NVIDIA/nvbench.git
synced 2026-05-14 10:07:25 +00:00
Addressed both issues raised in review
Malformed values are now represented in result as None. Skipped benchmarks are no longer dropped, i.e., they are present in BenchmarkResult data, but they are not reflected in summary table in line with what NVBench-instrumented benchmarks do.
This commit is contained in:
@@ -143,6 +143,8 @@ def format_percentage(summary: BenchmarkResultSummary) -> str:
|
||||
|
||||
|
||||
def format_summary(summary: BenchmarkResultSummary) -> str:
|
||||
if summary.value is None:
|
||||
return ""
|
||||
if summary.hint == "duration":
|
||||
return format_duration(summary)
|
||||
if summary.hint == "item_rate":
|
||||
@@ -215,6 +217,8 @@ def format_benchmark(result: BenchmarkResult, bench: SubBenchmarkResult) -> str:
|
||||
table = MarkdownTable()
|
||||
row = 0
|
||||
for state in bench.states:
|
||||
if state.is_skipped:
|
||||
continue
|
||||
if device_id is not None and state.device != device_id:
|
||||
continue
|
||||
add_state_row(table, row, state, bench)
|
||||
|
||||
Reference in New Issue
Block a user