From 5adf76660af5fd23a32f3a9801c6be2879b908f2 Mon Sep 17 00:00:00 2001 From: TonitaN Date: Fri, 10 Nov 2023 21:52:57 +0300 Subject: [PATCH] =?UTF-8?q?(#268)=20=D0=9F=D1=80=D0=B0=D0=B2=D0=BA=D0=B8?= =?UTF-8?q?=20=D0=BF=D0=BE=20=D1=82=D0=B5=D1=81=D1=82=D0=B0=D0=BC=20=D0=90?= =?UTF-8?q?=D0=BD=D0=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- libs/Logger/src/LogTemplate.cpp | 2 +- libs/Tester/src/Tester.cpp | 2 +- resources/template/Test1.tex | 2 ++ resources/template/Test2.tex | 2 ++ 4 files changed, 6 insertions(+), 2 deletions(-) diff --git a/libs/Logger/src/LogTemplate.cpp b/libs/Logger/src/LogTemplate.cpp index 2842c0d9..f673f48e 100644 --- a/libs/Logger/src/LogTemplate.cpp +++ b/libs/Logger/src/LogTemplate.cpp @@ -224,7 +224,7 @@ string LogTemplate::math_mode(string str) { int step_size(int maxscale, size_t objsize, size_t datasize) { int step = std::ceil((maxscale * (static_cast(objsize) + 3)) / max(static_cast(datasize) - 2, 1)); - return (step > 10 ? std::floor(step / 10) * 10 : step); + return (step > 10 ? std::floor(step / 10) * 10 : max(step, 1)); } string LogTemplate::log_plot(Plot p) { diff --git a/libs/Tester/src/Tester.cpp b/libs/Tester/src/Tester.cpp index 1fb96f9f..0fcbd35b 100644 --- a/libs/Tester/src/Tester.cpp +++ b/libs/Tester/src/Tester.cpp @@ -65,7 +65,7 @@ void Tester::test(const ParseDevice& lang, const Regex& regex, int step, iLogTem plot.data.push_back(make_pair(make_pair(words[i], int(steps[i])), labels[type])); } } - t.columns.push_back("Количество итераций"); + t.columns.push_back("Шаги"); t.columns.push_back("Длина строки"); t.columns.push_back("Время парсинга"); t.columns.push_back("Принадлежность языку"); diff --git a/resources/template/Test1.tex b/resources/template/Test1.tex index 4e12f1a8..69e94f7f 100644 --- a/resources/template/Test1.tex +++ b/resources/template/Test1.tex @@ -11,4 +11,6 @@ \section{Test} %template_table + %template_plot + \end{frame} diff --git a/resources/template/Test2.tex b/resources/template/Test2.tex index 802ca2d9..6cd03b58 100644 --- a/resources/template/Test2.tex +++ b/resources/template/Test2.tex @@ -12,4 +12,6 @@ \section{Test} %template_table + %template_plot + \end{frame}