From 28174cb167e5861710387c2cb6a21016bca48037 Mon Sep 17 00:00:00 2001 From: Andrzej Kopytko Date: Thu, 19 Dec 2024 13:41:02 +0100 Subject: [PATCH] [DOCS] Port for Graph refactoring to master (#28147) Port for https://github.com/openvinotoolkit/openvino/pull/28146 --- .../benchmarks_files/data/graph-data-ov.json | 16 ++++++++-------- .../_static/benchmarks_files/graph-config.json | 1 + docs/sphinx_setup/_static/js/graphs.js | 14 ++++++++------ 3 files changed, 17 insertions(+), 14 deletions(-) diff --git a/docs/sphinx_setup/_static/benchmarks_files/data/graph-data-ov.json b/docs/sphinx_setup/_static/benchmarks_files/data/graph-data-ov.json index c5cfca9df3f095..7a2a9d68a3fefe 100644 --- a/docs/sphinx_setup/_static/benchmarks_files/data/graph-data-ov.json +++ b/docs/sphinx_setup/_static/benchmarks_files/data/graph-data-ov.json @@ -16046,7 +16046,7 @@ "bf16": "" } ], - "Unit": "Tokens per Sec", + "Unit": "Tokens per sec", "UnitDesc": "higher is better" }, "latency": { @@ -16081,7 +16081,7 @@ "bf16": "" } ], - "Unit": "Tokens per Sec", + "Unit": "Tokens per sec", "UnitDesc": "higher is better" }, "latency": { @@ -16116,7 +16116,7 @@ "bf16": "" } ], - "Unit": "Tokens per Sec", + "Unit": "Tokens per sec", "UnitDesc": "higher is better" }, "latency": { @@ -16151,7 +16151,7 @@ "bf16": "" } ], - "Unit": "Tokens per Sec", + "Unit": "Tokens per sec", "UnitDesc": "higher is better" }, "latency": { @@ -16186,7 +16186,7 @@ "bf16": "" } ], - "Unit": "Tokens per Sec", + "Unit": "Tokens per sec", "UnitDesc": "higher is better" }, "latency": { @@ -16256,7 +16256,7 @@ "bf16": "" } ], - "Unit": "Tokens per Sec", + "Unit": "Tokens per sec", "UnitDesc": "higher is better" }, "latency": { @@ -16326,7 +16326,7 @@ "bf16": "" } ], - "Unit": "Tokens per Sec", + "Unit": "Tokens per sec", "UnitDesc": "higher is better" }, "latency": { @@ -16361,7 +16361,7 @@ "bf16": "" } ], - "Unit": "Tokens per Sec", + "Unit": "Tokens per sec", "UnitDesc": "higher is better" }, "latency": { diff --git a/docs/sphinx_setup/_static/benchmarks_files/graph-config.json b/docs/sphinx_setup/_static/benchmarks_files/graph-config.json index e090e5abe97474..78b24d446300ec 100644 --- a/docs/sphinx_setup/_static/benchmarks_files/graph-config.json +++ b/docs/sphinx_setup/_static/benchmarks_files/graph-config.json @@ -25,6 +25,7 @@ "msec/token": "(lower is better)", "Generating time, sec.": "(lower is better)", "msec/token/TDP": "(lower is better)", + "Tokens per sec": "(higher is better)", "FPS": "(higher is better)", "FPS/$": "(higher is better)", "FPS/TDP": "(higher is better)", diff --git a/docs/sphinx_setup/_static/js/graphs.js b/docs/sphinx_setup/_static/js/graphs.js index 04e34d6c2fefe5..f860cffb6b88fd 100644 --- a/docs/sphinx_setup/_static/js/graphs.js +++ b/docs/sphinx_setup/_static/js/graphs.js @@ -661,15 +661,18 @@ $(document).ready(function () { var filteredNetworkModels = Filter.FilterByNetworkModel(graph, [networkModel]); var filteredIeTypes = Filter.ByIeTypes(filteredNetworkModels, ieTypes); var filteredGraphData = Filter.BySortPlatforms(filteredIeTypes, platforms); + var filterdPlatforms = platforms.filter(platform => + filteredGraphData.some(filteredGraph => platform === filteredGraph.Platform) + ); $('.chart-placeholder').append(chartContainer); if (filteredGraphData.length > 0) { if (isLLM === true) { - var graphConfigs = setGraphConfigsByEngines(filteredGraphData, appConfig, kpis, precisions) - createChartWithNewDataByEngines(platforms, graphConfigs, chartContainer, display); + var graphConfigs = setGraphConfigsByEngines(filteredGraphData, appConfig, kpis, precisions); + createChartWithNewDataByEngines(filterdPlatforms, graphConfigs, chartContainer, display); } else { - var graphConfigs = setGraphConfigs(filteredGraphData, appConfig, kpis, precisions) - createChartWithNewData(platforms, graphConfigs, appConfig, chartContainer, display); + var graphConfigs = setGraphConfigs(filteredGraphData, appConfig, kpis, precisions); + createChartWithNewData(filterdPlatforms, graphConfigs, appConfig, chartContainer, display); } } else { @@ -759,8 +762,7 @@ $(document).ready(function () { columnHeaderContainer.append(columnIcon); var columnHeader = $('
'); columnHeader.append($('
' + graphConfig.chartTitle + '
')); - columnHeader.append($('
' + graphConfig.unit + '
')); - columnHeader.append($('
' + appConfig.UnitDescription[graphConfig.unit] + '
')); + columnHeader.append($('
' + graphConfig.unit + ' ' + appConfig.UnitDescription[graphConfig.unit] +'
')); columnHeaderContainer.append(columnHeader); chartGraphsContainer.append(graphItem); var graphClass = $('
');