From abceef74e0a5e7bbd98cf09d87912fec26cc8726 Mon Sep 17 00:00:00 2001 From: Alexander Smorkalov Date: Wed, 22 Jul 2020 10:05:55 +0300 Subject: [PATCH] Added reference to Original Wu's articte about SAUF connected components search method. --- doc/opencv.bib | 13 +++++++++++++ modules/imgproc/include/opencv2/imgproc.hpp | 6 +++--- 2 files changed, 16 insertions(+), 3 deletions(-) diff --git a/doc/opencv.bib b/doc/opencv.bib index 73c4668ff84a..bdfbc8cf1e7d 100644 --- a/doc/opencv.bib +++ b/doc/opencv.bib @@ -1215,3 +1215,16 @@ @article{yang1996structure year = {1996}, publisher = {Elsevier} } +@Article{Wu2009, + author={Wu, Kesheng + and Otoo, Ekow + and Suzuki, Kenji}, + title={Optimizing two-pass connected-component labeling algorithms}, + journal={Pattern Analysis and Applications}, + year={2009}, + month={Jun}, + day={01}, + volume={12}, + number={2}, + pages={117-135}, +} diff --git a/modules/imgproc/include/opencv2/imgproc.hpp b/modules/imgproc/include/opencv2/imgproc.hpp index 91c1ec52fc2c..962501b62deb 100644 --- a/modules/imgproc/include/opencv2/imgproc.hpp +++ b/modules/imgproc/include/opencv2/imgproc.hpp @@ -403,7 +403,7 @@ enum ConnectedComponentsTypes { //! connected components algorithm enum ConnectedComponentsAlgorithmsTypes { - CCL_WU = 0, //!< SAUF algorithm for 8-way connectivity, SAUF algorithm for 4-way connectivity + CCL_WU = 0, //!< SAUF @cite Wu2009 algorithm for 8-way connectivity, SAUF algorithm for 4-way connectivity CCL_DEFAULT = -1, //!< BBDT algorithm for 8-way connectivity, SAUF algorithm for 4-way connectivity CCL_GRANA = 1 //!< BBDT algorithm for 8-way connectivity, SAUF algorithm for 4-way connectivity }; @@ -3842,7 +3842,7 @@ image with 4 or 8 way connectivity - returns N, the total number of labels [0, N represents the background label. ltype specifies the output label image type, an important consideration based on the total number of labels or alternatively the total number of pixels in the source image. ccltype specifies the connected components labeling algorithm to use, currently -Grana (BBDT) and Wu's (SAUF) algorithms are supported, see the #ConnectedComponentsAlgorithmsTypes +Grana (BBDT) and Wu's (SAUF) @cite Wu2009 algorithms are supported, see the #ConnectedComponentsAlgorithmsTypes for details. Note that SAUF algorithm forces a row major ordering of labels while BBDT does not. This function uses parallel version of both Grana and Wu's algorithms if at least one allowed parallel framework is enabled and if the rows of the image are at least twice the number returned by #getNumberOfCPUs. @@ -3874,7 +3874,7 @@ image with 4 or 8 way connectivity - returns N, the total number of labels [0, N represents the background label. ltype specifies the output label image type, an important consideration based on the total number of labels or alternatively the total number of pixels in the source image. ccltype specifies the connected components labeling algorithm to use, currently -Grana's (BBDT) and Wu's (SAUF) algorithms are supported, see the #ConnectedComponentsAlgorithmsTypes +Grana's (BBDT) and Wu's (SAUF) @cite Wu2009 algorithms are supported, see the #ConnectedComponentsAlgorithmsTypes for details. Note that SAUF algorithm forces a row major ordering of labels while BBDT does not. This function uses parallel version of both Grana and Wu's algorithms (statistics included) if at least one allowed parallel framework is enabled and if the rows of the image are at least twice the number returned by #getNumberOfCPUs.