[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)
* TBB executor for GAPI
- the sole executor
- unit tests for it
- no usage in the GAPI at the momnet
* TBB executor for GAPI
- introduced new overload of execute to explicitly accept tbb::arena
argument
- added more basic tests
- moved arena creation code into tests
-
* TBB executor for GAPI
- fixed compie errors & warnings
* TBB executor for GAPI
- split all-in-one execute() function into logicaly independant parts
* TBB executor for GAPI
- used util::variant in in the tile_node
* TBB executor for GAPI
- moved copy_through_move to separate header
- rearranged details staff in proper namespaces
- moved all implementation into detail namespace
* TBB executor for GAPI
- fixed build error with TBB 4.4.
- fixed build warnings
* TBB executor for GAPI
- aligned strings width
- fixed spaces in expressions
- fixed english grammar
- minor improvements
* TBB executor for GAPI
- added more comments
- minor improvements
* TBB executor for GAPI
- changed ITT_ prefix for macroses to GAPI_ITT
* TBB executor for GAPI
- no more "unused" warning for GAPI_DbgAssert
- changed local assert macro to man onto GAPI_DbgAssert
* TBB executor for GAPI
- file renamings
- changed local assert macro to man onto GAPI_DbgAsse
* TBB executor for GAPI
- test file renamed
- add more comments
* TBB executor for GAPI
- minor clenups and cosmetic changes
* TBB executor for GAPI
- minor clenups and cosmetic changes
* TBB executor for GAPI
- changed spaces and curly braces alignment
* TBB executor for GAPI
- minor cleanups
* TBB executor for GAPI
- minor cleanups
G-API: ONNX. Support tensor input for CNN with dynamic input
* Added support for dynamic input tensor, refactored one input/output tests
* Added multiple input/output fixture, test for mobilenet
* Removed whitespace
* Removed mistake in inferROI
* Small fixes
* One more fix
* Code cleanup
* Code cleanup X2
* bb rstrt
* Fix review comments
* One more fix review comments
* Mistake
[G-API]: findContours() and boundingRect() Standard Kernels Implementation
* Add findContours() standard kernel
- API and documentation provided:
- as OpenCV provides two overloads whether to calculate hierarchy or not, but they differ by only the output in sight of G-API, two different G-API functions and kernels implemented
- G-API Imgproc documentation divided into more parts according to imgproc module parts
- some typos connected with division into parts corrected
- `GArray<GArray<U>>` overload for `get_out` function provided to coonvert correctly into `vector<vector<U>>`
- OCV backend supported
- accuracy tests provided
* Add boundingRect() standard kernel
- API and documentation provided:
- GOpaque<Rect> used as an output
- as OpenCV provides two possibilities whether to take a gray-scale image or a set of 2D points (`Point2i` or `Point2f` supported), three different overloads of a single G-API function and three kernels implemented
- for a gray-scale image the overload via `GMat`
- for a set of `Point2i` - the one via GArray<`Point2i`>
- set of `Point2f` -> GArray<`Point2f`>
- OCV backend supported
- accuracy tests provided
- comparison function for Rects provided
- some typos in `gapi_tests_common` corrected
* Fix precommit windows warnings
* - Addressing comments:
- split tests
- Fix Windows warnings
* Static_cast for warnings
* - Remove randomness
- Fix unnecessary precision losses
* - Forgot reference for RNG
* addressing comments
* equalizeHist -> no group
* `const` addedin new functions
* Address suggestions:
- Hierarchical -> H
- added cv::GMatDesc::isVectorPoins()
- added support of giving a set of points to boundingRect()
* Addressing comments
- IoU comparison function added for Rects
- isPointsVector moved from a GMatDesc method to a separate function in imgproc.hpp
- enums instead of int
- typos corrected
* Addressing comments
- findContours: Point offset -> GOpaque<Point>
- removed "straight" comparison for Rects, IoU available only
- changed vectors initialization -> fix Debug test run
- Some typos
* added comment for later upgrades
* Fix not to corrupt docs by FIXME
* Addressing commens
- overload without offset added (as a temporary workaround)
- checkMetaForFindingContours -> validateFindingContoursMeta
- added ostream overload for enums used in tests
[G-API]: morphologyEx() Standard Kernel Implementation
* cv::gapi::morphologyEx() kernel
- implemented (without separate 3x3 version)
- tests added: check only different operations, not kernels/borders
* Address comments: add `const` where needed
* Replaced fundamental tyeps -> enums where needed
- added operator<< overload for cv::MorphTypes for tests output
* G-API: Introduce ONNX backend for Inference
- Basic operations are implemented (Infer, -ROI, -List, -List2);
- Implemented automatic preprocessing for ONNX models;
- Test suite is extended with `OPENCV_GAPI_ONNX_MODEL_PATH` env for test data
(test data is an ONNX Model Zoo repo snapshot);
- Fixed kernel lookup logic in core G-API:
- Lookup NN kernels not in the default package, but in the associated
backend's aux package. Now two NN backends can work in the same graph.
- Added Infer SSD demo and a combined ONNX/IE demo;
* G-API/ONNX: Fix some of CMake issues
Co-authored-by: Pashchenkov, Maxim <maxim.pashchenkov@intel.com>
Expand ie::Params to support config
* Add config to IE params
* Add test
* Remove comments from tests
* Rename to pluginConfig
* Add one more overloads for pluginConfig
* Add more tests
Set queue size = 1 to Copy island right after the desync.
In this case, Copy won't read more data from a "last_written"
container than required, while feeding the desynchronized path.
Sometimes Copy don't get fused into an island and behaves
on its own -- in this case, it reads more data in advance
so the slow (desync) part actually processes some data in-sync
(more than actually required)
- cv::gapi::serialize bypasses compile arguments which have no S11N specialization with serialize/deserialize callbacks for underlying types
- cv::gapi::deserialize can accept arbitraty number of serialized compile args in a stream but will return only those which are requested by user via template parameter pack if they are presented in the stream. If some or all of them are not presented cv::gapi::deserialize will ignore and return only those which are presented
- cv::gapi::deserialize can accept only types which can be deserialized (have S11N<T> specialization with the user callbacks)
- Added cv::gapi::s11n::detail::has_S11N_spec<T> trait to separate compile arguments which have S11N<T> specialization with the user callbacks
- desync() is a new (and for now, the only one) intrinsic
which splits the graph execution into asynchronous parts
when running in Streaming mode;
- desync() makes no effect when compiling in Traditional mode;
- Added tests on desync() working in various scenarios;
- Extended GStreamingExecutor to support desync(); also extended
GStreamingCompiled() with a new version of pull() returning a
vector of optional values;
- Fixed various issues with storing the type information & proper
construction callbacks for GArray<> and GOpaque;
- Introduced a new infer(Roi,GMat) overload with a sample;
- Introduced an internal API for Islands to control fusion
procedure (to fuse or not to fuse);
- Introduced handleStopStream() callback for island executables;
- Added GCompileArgs to metadata of the graph (required for other
features).
- Changed descr_of(RMat) to use canDescribeHelper to correctly handle planar case
- Added export of createMat
- Added setting of Storage::INPUT and Storage::OUTPUT in deserialization routine of GComputation
GAPI: Addition new Color conversion kernels to CPU backend.
* Add BGR2RGB kernel to CPU backend
* Add BGR2I420 and RGB2I420 kernels to CPU backend
* Add I4202BGR and I4202RGB kernels to CPU backend
[GAPI] RMat integration into the framework
* RMat integration
* Added initialization of input mat in GArray initialization tests
* Fixed klocwork warnings in RMat tests, changed argument order in EXPECT_EQ
[G-API] Export a part of serialization interface
* Initial stub
* Add test on serialization of a custom type
* Namespaces rework
* Fix isSupported in test struct
* Fix clang build and rework namespaces
* Remove redundant header
[G-API]: countNonZero() Standard Kernel Implementation
* Add countNonZero() standard kernel
- API and documentation provided
- OCV backend supported
- accuracy and performance tests provided
- some refactoring of related documentation done
* Fix GOpaque functionality for OCL Backend
- test for OCL Opaque usage providied
* countNonZero for GPU
- OCL Backend implementation for countNonZero() added
- tests provided
* Addressing comments
[G-API] Add support for more types serialization
* Support more types
* Add std::string support
* Fix GOpaque and gin interaction
* Fix tests on kind
* Make map serialization support templates and add tests on kind
Update G-API slides to OpenCV 4.4
* G-API: Updated slides to v4.4 (+ sample)
* Slight formatting changes + Python API page
* Some more updates to slides:
- Added more info on 4.2 and 4.4 versions
- Added explanation on Operations and their functional wrappers