opencv/modules/gapi
Orest Chura 986ad4ff06
Merge pull request #18857 from OrestChura:oc/kmeans
[G-API]: kmeans() Standard Kernel Implementation

* cv::gapi::kmeans kernel implementation
 - 4 overloads:
    - standard GMat - for any dimensionality
    - GMat without bestLabels initialization
    - GArray<Point2f> - for 2D
    - GArray<Point3f> - for 3D
 - Accuracy tests:
   - for every input - 2 tests
   1) without initializing. In this case, no comparison with cv::kmeans is done as kmeans uses random auto-initialization
   2) with initialization
   - in both cases, only 1 attempt is done as after first attempt kmeans initializes bestLabels randomly

* Addressing comments
 - bestLabels is returned to its original place among parameters
 - checkVector and isPointsVector functions are merged into one, shared between core.hpp & imgproc.hpp by placing it into gmat.hpp (and implementation - to gmat.cpp)
 - typos corrected

* addressing comments
 - unified names in tests
 - const added
 - typos

* Addressing comments
 - fixed the doc note
 - ddepth -> expectedDepth, `< 0 ` -> `== -1`

* Fix unsupported cases of input Mat
 - supported: multiple channels, reversed width
 - added test cases for those
 - added notes in docs
 - refactored checkVector to return dimentionality along with quantity

* Addressing comments
 - makes chackVector smaller and (maybe) clearer

* Addressing comments

* Addressing comments
 - cv::checkVector -> cv::gapi::detail

* Addressing comments
 - Changed checkVector: returns bool, quantity & dimensionality as references

* Addressing comments
 - Polishing checkVector
 - FIXME added

* Addressing discussion
 - checkVector: added overload, separate two different functionalities
 - depth assert - out of the function

* Addressing comments
 - quantity -> amount, dimensionality -> dim
 - Fix typos

* Addressing comments
 - fix docs
 - use 2 variable's definitions instead of one (for all non-trivial variables)
2020-11-30 13:18:43 +00:00
..
cmake Added rmat.cpp and media.cpp to files being built in standalone 2020-11-06 01:59:09 +03:00
doc Merge pull request #18387 from dmatveev:dm/slides_upd_44 2020-09-26 20:59:26 +00:00
include/opencv2 Merge pull request #18857 from OrestChura:oc/kmeans 2020-11-30 13:18:43 +00:00
misc/python Merge pull request #18762 from TolyaTalamanov:at/support-garray 2020-11-27 17:39:46 +00:00
perf G-API: Introduced a Text Detection sample 2020-10-21 17:25:56 +03:00
samples Merge pull request #18716 from dmatveev:dm/upstream_onnx 2020-11-03 18:39:16 +00:00
scripts Added a script to measure & report privacy masking camera performance in different configurations 2020-07-08 19:19:37 +03:00
src Merge pull request #18857 from OrestChura:oc/kmeans 2020-11-30 13:18:43 +00:00
test Merge pull request #18857 from OrestChura:oc/kmeans 2020-11-30 13:18:43 +00:00
CMakeLists.txt Merge pull request #17851 from anton-potapov:sole_tbb_executor 2020-11-30 13:15:13 +00:00