From 696b75ba238a189acec089d375fa946fd0b929f2 Mon Sep 17 00:00:00 2001 From: Joachim Date: Fri, 3 Apr 2020 13:58:03 +0200 Subject: [PATCH] Small modifs on the tests - Reduced blurring kernels - Small errors in the report --- README.rst | 30 +++++++++---------- .../benchmark/bm_build-debug.rst | 28 ++++++++--------- .../benchmark/bm_build-release.rst | 19 ++++++------ .../esp_opencv_tests/benchmark/bm_concat.rst | 28 ++++++++--------- esp32/examples/esp_opencv_tests/main/main.cpp | 19 ++++++------ .../examples/esp_opencv_tests/main/report.cpp | 4 +-- 6 files changed, 60 insertions(+), 68 deletions(-) diff --git a/README.rst b/README.rst index 73e1fa2..5bc2912 100644 --- a/README.rst +++ b/README.rst @@ -26,7 +26,7 @@ Benchmark Below is a summary of the OpenCV features tested on the ESP32 and the time they took (adding the heap/stack used could also be useful). -All measures are in milliseconds. +All measures are in **milliseconds**. +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | Function name and arguments | BUILD_TYPE=Debug | BUILD_TYPE=Release | @@ -37,9 +37,9 @@ All measures are in milliseconds. +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | **Threshold** | | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| binaryThreshold | 4.5 | 18 | 69 | 175 | 2.6 | 11 | 42 | 107 | +| binaryThreshold | 4.5 | 18 | 69 | 175 | 2.5 | 11 | 42 | 107 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| triangleThreshold | 8.1 | 32 | 124 | 315 | 3.9 | 17 | 66 | 168 | +| triangleThreshold | 8.0 | 32 | 124 | 315 | 3.9 | 17 | 66 | 168 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | OTSUThreshold | 11 | 35 | 127 | 318 | 6.5 | 20 | 69 | 171 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ @@ -49,29 +49,29 @@ All measures are in milliseconds. +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | **Blurring** | | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| GaussianBlur 9x9 kernel | 223 | 875 | 3473 | 9042 | 34 | 128 | 504 | 1458 | +| GaussianBlur 3x3 kernel | 16 | 54 | 206 | 521 | 5.6 | 20 | 76 | 192 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| medianBlur 9x9 kernel | 141 | 608 | 2754 | 7505 | 56 | 273 | 1425 | 4091 | +| medianBlur 3x3 kernel | 180 | 721 | 2883 | 7390 | 22 | 90 | 360 | 926 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| bilateralFilter diameter=9 | 413 | 1628 | 6487 | 16386 | 138 | 535 | 2119 | 5293 | +| bilateralFilter diameter=5 | 132 | 509 | 2014 | 5079 | 51 | 190 | 743 | 1854 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | | | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | **Morphological tranforms** | | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| erode 5x5 kernel | 41 | 151 | 587 | 1493 | 6.2 | 22 | 84 | 214 | +| erode 5x5 kernel | 41 | 151 | 587 | 1494 | 6.2 | 22 | 84 | 214 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| dilate 5x5 kernel | 41 | 151 | 587 | 1494 | 6.2 | 22 | 84 | 214 | +| dilate 5x5 kernel | 41 | 151 | 588 | 1495 | 6.2 | 22 | 84 | 214 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| open 5x5 kernel | 81 | 299 | 1163 | 2959 | 11 | 41 | 158 | 400 | +| open 5x5 kernel | 82 | 299 | 1164 | 2961 | 11 | 41 | 158 | 400 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | | | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | **Resize image** | | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| resize linear interpolation | 10 | 39 | 150 | 378 | 3.8 | 16 | 59 | 147 | +| resize linear interpolation | 10 | 40 | 150 | 378 | 3.8 | 16 | 59 | 147 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| resize cubic interpolation | 21 | 75 | 291 | 733 | 6.5 | 27 | 108 | 277 | +| resize cubic interpolation | 21 | 75 | 287 | 728 | 6.5 | 27 | 108 | 275 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | | | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ @@ -79,18 +79,18 @@ All measures are in milliseconds. +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | Sobel | 34 | 116 | 438 | 1129 | 14 | 50 | 187 | 497 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| Canny | 81 | 260 | 894 | ERR | 32 | 108 | 375 | ERR | +| Canny | 80 | 256 | 886 | ERR | 32 | 108 | 375 | ERR | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | | | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | **Hough tranformations** | | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| HoughLines | 392 | 897 | ERR | ERR | 313 | 681 | 2121 | ERR | +| HoughLines | 392 | 897 | ERR | ERR | 314 | 686 | 2121 | ERR | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| HoughLines probabilistic | 699 | 1652 | ERR | ERR | 608 | 1358 | 3766 | ERR | +| HoughLines probabilistic | 699 | 1652 | ERR | ERR | 603 | 1352 | 3765 | ERR | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -The ``ERR`` fields means that the test hasn't pass (most of time due to OutOfMemory error. +The ``ERR`` fields means that the test hasn't pass (most of time due to OutOfMemory error). The benchmark code can be found in `esp32/examples/esp_opencv_tests/`_. diff --git a/esp32/examples/esp_opencv_tests/benchmark/bm_build-debug.rst b/esp32/examples/esp_opencv_tests/benchmark/bm_build-debug.rst index 90286d7..c2135da 100644 --- a/esp32/examples/esp_opencv_tests/benchmark/bm_build-debug.rst +++ b/esp32/examples/esp_opencv_tests/benchmark/bm_build-debug.rst @@ -2,8 +2,6 @@ | Function name and arguments | BUILD_TYPE=Debug | +------------------------------------------------+-------------+-------------+-------------+-------------+ | | 160x120 | 320x240 | 640x480 | 1024x768 | -+------------------------------------------------+-------------+-------------+-------------+-------------+ -| All measures are in [ms] | +================================================+=============+=============+=============+=============+ | | +------------------------------------------------+-------------+-------------+-------------+-------------+ @@ -11,7 +9,7 @@ +------------------------------------------------+-------------+-------------+-------------+-------------+ | binaryThreshold | 4.5 | 18 | 69 | 175 | +------------------------------------------------+-------------+-------------+-------------+-------------+ -| triangleThreshold | 8.1 | 32 | 124 | 315 | +| triangleThreshold | 8.0 | 32 | 124 | 315 | +------------------------------------------------+-------------+-------------+-------------+-------------+ | OTSUThreshold | 11 | 35 | 127 | 318 | +------------------------------------------------+-------------+-------------+-------------+-------------+ @@ -21,29 +19,29 @@ +------------------------------------------------+-------------+-------------+-------------+-------------+ | **Blurring** | +------------------------------------------------+-------------+-------------+-------------+-------------+ -| GaussianBlur 9x9 kernel | 223 | 875 | 3473 | 9042 | +| GaussianBlur 3x3 kernel | 16 | 54 | 206 | 521 | +------------------------------------------------+-------------+-------------+-------------+-------------+ -| medianBlur 9x9 kernel | 141 | 608 | 2754 | 7505 | +| medianBlur 3x3 kernel | 180 | 721 | 2883 | 7390 | +------------------------------------------------+-------------+-------------+-------------+-------------+ -| bilateralFilter diameter=9 | 413 | 1628 | 6487 | 16386 | +| bilateralFilter diameter=5 | 132 | 509 | 2014 | 5079 | +------------------------------------------------+-------------+-------------+-------------+-------------+ | | +------------------------------------------------+-------------+-------------+-------------+-------------+ | **Morphological tranforms** | +------------------------------------------------+-------------+-------------+-------------+-------------+ -| erode 5x5 kernel | 41 | 151 | 587 | 1493 | +| erode 5x5 kernel | 41 | 151 | 587 | 1494 | +------------------------------------------------+-------------+-------------+-------------+-------------+ -| dilate 5x5 kernel | 41 | 151 | 587 | 1494 | +| dilate 5x5 kernel | 41 | 151 | 588 | 1495 | +------------------------------------------------+-------------+-------------+-------------+-------------+ -| open 5x5 kernel | 81 | 299 | 1163 | 2959 | +| open 5x5 kernel | 82 | 299 | 1164 | 2961 | +------------------------------------------------+-------------+-------------+-------------+-------------+ | | +------------------------------------------------+-------------+-------------+-------------+-------------+ | **Resize image** | +------------------------------------------------+-------------+-------------+-------------+-------------+ -| resize linear interpolation | 10 | 39 | 150 | 378 | +| resize linear interpolation | 10 | 40 | 150 | 378 | +------------------------------------------------+-------------+-------------+-------------+-------------+ -| resize cubic interpolation | 21 | 75 | 291 | 733 | +| resize cubic interpolation | 21 | 75 | 287 | 728 | +------------------------------------------------+-------------+-------------+-------------+-------------+ | | +------------------------------------------------+-------------+-------------+-------------+-------------+ @@ -51,13 +49,13 @@ +------------------------------------------------+-------------+-------------+-------------+-------------+ | Sobel | 34 | 116 | 438 | 1129 | +------------------------------------------------+-------------+-------------+-------------+-------------+ -| Canny | 81 | 260 | 894 | - | +| Canny | 80 | 256 | 886 | ERR | +------------------------------------------------+-------------+-------------+-------------+-------------+ | | +------------------------------------------------+-------------+-------------+-------------+-------------+ | **Hough tranformations** | +------------------------------------------------+-------------+-------------+-------------+-------------+ -| HoughLines | 392 | 897 | - | - | +| HoughLines | 392 | 897 | ERR | ERR | ++------------------------------------------------+-------------+-------------+-------------+-------------+ +| HoughLines probabilistic | 699 | 1652 | ERR | ERR | +------------------------------------------------+-------------+-------------+-------------+-------------+ -| HoughLines probabilistic | 699 | 1652 | - | - | -+------------------------------------------------+-------------+-------------+-------------+-------------+ \ No newline at end of file diff --git a/esp32/examples/esp_opencv_tests/benchmark/bm_build-release.rst b/esp32/examples/esp_opencv_tests/benchmark/bm_build-release.rst index 17d9cf7..ec1c1bc 100644 --- a/esp32/examples/esp_opencv_tests/benchmark/bm_build-release.rst +++ b/esp32/examples/esp_opencv_tests/benchmark/bm_build-release.rst @@ -2,14 +2,12 @@ | Function name and arguments | BUILD_TYPE=Release | +------------------------------------------------+-------------+-------------+-------------+-------------+ | | 160x120 | 320x240 | 640x480 | 1024x768 | -+------------------------------------------------+-------------+-------------+-------------+-------------+ -| All measures are in [ms] | +================================================+=============+=============+=============+=============+ | | +------------------------------------------------+-------------+-------------+-------------+-------------+ | **Threshold** | +------------------------------------------------+-------------+-------------+-------------+-------------+ -| binaryThreshold | 2.6 | 11 | 42 | 107 | +| binaryThreshold | 2.5 | 11 | 42 | 107 | +------------------------------------------------+-------------+-------------+-------------+-------------+ | triangleThreshold | 3.9 | 17 | 66 | 168 | +------------------------------------------------+-------------+-------------+-------------+-------------+ @@ -21,11 +19,11 @@ +------------------------------------------------+-------------+-------------+-------------+-------------+ | **Blurring** | +------------------------------------------------+-------------+-------------+-------------+-------------+ -| GaussianBlur 9x9 kernel | 34 | 128 | 504 | 1458 | +| GaussianBlur 3x3 kernel | 5.6 | 20 | 76 | 192 | +------------------------------------------------+-------------+-------------+-------------+-------------+ -| medianBlur 9x9 kernel | 56 | 273 | 1425 | 4091 | +| medianBlur 3x3 kernel | 22 | 90 | 360 | 926 | +------------------------------------------------+-------------+-------------+-------------+-------------+ -| bilateralFilter diameter=9 | 138 | 535 | 2119 | 5293 | +| bilateralFilter diameter=5 | 51 | 190 | 743 | 1854 | +------------------------------------------------+-------------+-------------+-------------+-------------+ | | +------------------------------------------------+-------------+-------------+-------------+-------------+ @@ -43,7 +41,7 @@ +------------------------------------------------+-------------+-------------+-------------+-------------+ | resize linear interpolation | 3.8 | 16 | 59 | 147 | +------------------------------------------------+-------------+-------------+-------------+-------------+ -| resize cubic interpolation | 6.5 | 27 | 108 | 277 | +| resize cubic interpolation | 6.5 | 27 | 108 | 275 | +------------------------------------------------+-------------+-------------+-------------+-------------+ | | +------------------------------------------------+-------------+-------------+-------------+-------------+ @@ -51,13 +49,14 @@ +------------------------------------------------+-------------+-------------+-------------+-------------+ | Sobel | 14 | 50 | 187 | 497 | +------------------------------------------------+-------------+-------------+-------------+-------------+ -| Canny | 32 | 108 | 375 | - | +| Canny | 32 | 108 | 375 | ERR | +------------------------------------------------+-------------+-------------+-------------+-------------+ | | +------------------------------------------------+-------------+-------------+-------------+-------------+ | **Hough tranformations** | +------------------------------------------------+-------------+-------------+-------------+-------------+ -| HoughLines | 313 | 681 | 2121 | - | +| HoughLines | 314 | 686 | 2121 | ERR | +------------------------------------------------+-------------+-------------+-------------+-------------+ -| HoughLines probabilistic | 608 | 1358 | 3766 | - | +| HoughLines probabilistic | 603 | 1352 | 3765 | ERR | +------------------------------------------------+-------------+-------------+-------------+-------------+ + diff --git a/esp32/examples/esp_opencv_tests/benchmark/bm_concat.rst b/esp32/examples/esp_opencv_tests/benchmark/bm_concat.rst index bebea4f..c3ff649 100644 --- a/esp32/examples/esp_opencv_tests/benchmark/bm_concat.rst +++ b/esp32/examples/esp_opencv_tests/benchmark/bm_concat.rst @@ -2,16 +2,14 @@ | Function name and arguments | BUILD_TYPE=Debug | BUILD_TYPE=Release | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | | 160x120 | 320x240 | 640x480 | 1024x768 | 160x120 | 320x240 | 640x480 | 1024x768 | -+------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| All measures are in [ms] | | +================================================+=============+=============+=============+=============+=============+=============+=============+=============+ | | | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | **Threshold** | | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| binaryThreshold | 4.5 | 18 | 69 | 175 | 2.6 | 11 | 42 | 107 | +| binaryThreshold | 4.5 | 18 | 69 | 175 | 2.5 | 11 | 42 | 107 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| triangleThreshold | 8.1 | 32 | 124 | 315 | 3.9 | 17 | 66 | 168 | +| triangleThreshold | 8.0 | 32 | 124 | 315 | 3.9 | 17 | 66 | 168 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | OTSUThreshold | 11 | 35 | 127 | 318 | 6.5 | 20 | 69 | 171 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ @@ -21,29 +19,29 @@ +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | **Blurring** | | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| GaussianBlur 9x9 kernel | 223 | 875 | 3473 | 9042 | 34 | 128 | 504 | 1458 | +| GaussianBlur 3x3 kernel | 16 | 54 | 206 | 521 | 5.6 | 20 | 76 | 192 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| medianBlur 9x9 kernel | 141 | 608 | 2754 | 7505 | 56 | 273 | 1425 | 4091 | +| medianBlur 3x3 kernel | 180 | 721 | 2883 | 7390 | 22 | 90 | 360 | 926 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| bilateralFilter diameter=9 | 413 | 1628 | 6487 | 16386 | 138 | 535 | 2119 | 5293 | +| bilateralFilter diameter=5 | 132 | 509 | 2014 | 5079 | 51 | 190 | 743 | 1854 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | | | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | **Morphological tranforms** | | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| erode 5x5 kernel | 41 | 151 | 587 | 1493 | 6.2 | 22 | 84 | 214 | +| erode 5x5 kernel | 41 | 151 | 587 | 1494 | 6.2 | 22 | 84 | 214 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| dilate 5x5 kernel | 41 | 151 | 587 | 1494 | 6.2 | 22 | 84 | 214 | +| dilate 5x5 kernel | 41 | 151 | 588 | 1495 | 6.2 | 22 | 84 | 214 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| open 5x5 kernel | 81 | 299 | 1163 | 2959 | 11 | 41 | 158 | 400 | +| open 5x5 kernel | 82 | 299 | 1164 | 2961 | 11 | 41 | 158 | 400 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | | | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | **Resize image** | | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| resize linear interpolation | 10 | 39 | 150 | 378 | 3.8 | 16 | 59 | 147 | +| resize linear interpolation | 10 | 40 | 150 | 378 | 3.8 | 16 | 59 | 147 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| resize cubic interpolation | 21 | 75 | 291 | 733 | 6.5 | 27 | 108 | 277 | +| resize cubic interpolation | 21 | 75 | 287 | 728 | 6.5 | 27 | 108 | 275 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | | | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ @@ -51,13 +49,13 @@ +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | Sobel | 34 | 116 | 438 | 1129 | 14 | 50 | 187 | 497 | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| Canny | 81 | 260 | 894 | - | 32 | 108 | 375 | - | +| Canny | 80 | 256 | 886 | ERR | 32 | 108 | 375 | ERR | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | | | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ | **Hough tranformations** | | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| HoughLines | 392 | 897 | - | - | 313 | 681 | 2121 | - | +| HoughLines | 392 | 897 | ERR | ERR | 314 | 686 | 2121 | ERR | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ -| HoughLines probabilistic | 699 | 1652 | - | - | 608 | 1358 | 3766 | - | +| HoughLines probabilistic | 699 | 1652 | ERR | ERR | 603 | 1352 | 3765 | ERR | +------------------------------------------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+-------------+ diff --git a/esp32/examples/esp_opencv_tests/main/main.cpp b/esp32/examples/esp_opencv_tests/main/main.cpp index f6cef0e..3d317db 100644 --- a/esp32/examples/esp_opencv_tests/main/main.cpp +++ b/esp32/examples/esp_opencv_tests/main/main.cpp @@ -62,19 +62,19 @@ int64_t BM_toZeroThresh(const Mat& src) { return BENCHMARK(threshold, src, dst, 128, 255, THRESH_TOZERO); } -int64_t BM_GaussianBlur9x9(const Mat& src) { +int64_t BM_GaussianBlur3x3(const Mat& src) { Mat dst; - return BENCHMARK(GaussianBlur, src, dst, Size(9, 9), 0, 0, BORDER_DEFAULT); + return BENCHMARK(GaussianBlur, src, dst, Size(3, 3), 0, 0, BORDER_DEFAULT); } -int64_t BM_medianBlur9x9(const Mat& src) { +int64_t BM_medianBlur3x3(const Mat& src) { Mat dst; - return BENCHMARK(medianBlur, src, dst, 9); + return BENCHMARK(medianBlur, src, dst, 3); } int64_t BM_bilateralFilter(const Mat& src) { Mat dst; - return BENCHMARK(bilateralFilter, src, dst, 9, 18, 5, BORDER_DEFAULT); + return BENCHMARK(bilateralFilter, src, dst, 5, 18, 5, BORDER_DEFAULT); } int64_t BM_erode(const Mat& src) { @@ -134,10 +134,9 @@ int64_t BM_HoughLinesP(const Mat& src) { void app_main(void) { + // Needed for opencv linkage with pthread to work pthread_cond_t cond_test = PTHREAD_COND_INITIALIZER; pthread_cond_init(&cond_test, nullptr); - unsigned ncpus = std::thread::hardware_concurrency(); - ESP_LOGI(TAG, "Number of CPU with std::thread::hardware_concurrency() = %d", ncpus); ESP_LOGI(TAG, "Starting main"); disp_mem_infos(); @@ -161,9 +160,9 @@ void app_main(void) thresholds.addTestCase(TestCase("toZeroThreshold", BM_toZeroThresh)); TestGroup &blurrings = report.addGroup("Blurring"); - blurrings.addTestCase(TestCase("GaussianBlur 9x9 kernel", BM_GaussianBlur9x9)); - blurrings.addTestCase(TestCase("medianBlur 9x9 kernel", BM_medianBlur9x9)); - blurrings.addTestCase(TestCase("bilateralFilter diameter=9", BM_bilateralFilter)); + blurrings.addTestCase(TestCase("GaussianBlur 3x3 kernel", BM_GaussianBlur3x3)); + blurrings.addTestCase(TestCase("medianBlur 3x3 kernel", BM_medianBlur3x3)); + blurrings.addTestCase(TestCase("bilateralFilter diameter=5", BM_bilateralFilter)); TestGroup &morph = report.addGroup("Morphological tranforms"); morph.addTestCase(TestCase("erode 5x5 kernel", BM_erode)); diff --git a/esp32/examples/esp_opencv_tests/main/report.cpp b/esp32/examples/esp_opencv_tests/main/report.cpp index bb11a58..d03f9ec 100644 --- a/esp32/examples/esp_opencv_tests/main/report.cpp +++ b/esp32/examples/esp_opencv_tests/main/report.cpp @@ -165,8 +165,6 @@ string Summary::summaryHeader(const string &reportName) { summaryHeaderLines += lineText({"Function name and arguments", reportName}); summaryHeaderLines += lineSeparator('-'); summaryHeaderLines += lineText(imagesNames); - summaryHeaderLines += lineSeparator('-'); - summaryHeaderLines += lineText({"Measures are in [ms]"}); summaryHeaderLines += lineSeparator('='); return summaryHeaderLines; } @@ -191,7 +189,7 @@ string Summary::summaryTest(const TestCase &test) { for(auto res : test.resultTime) { string value; if(res == -1) { - value = " - "; + value = "ERR"; } else { stringstream ss;