Commit Graph

71 Commits

Author SHA1 Message Date
Dmitry Budnikov
6374b99a1a Merge pull request #13240 from dbudniko:dbudniko/gapi_gpu_to_ocl_renaming
G-API rename GPU backend to OCL backend (#13240)

* renaming draft

* inline namespace instead non-safe define

* more back compatibility

* Updates after review from Dmitry
2018-11-29 16:29:11 +03:00
Dmitry Budnikov
51cc78b2a2 Merge pull request #13251 from dbudniko:dbudniko/gapi_more_fixes_for_tests
More fixes for G-API tests (#13251)

* scalar comparator and more fixes for tests

* add weighted aligned

* white space

* more white space

* Add weighted test accuracy check enabled
2018-11-26 17:44:46 +03:00
Dmitry Budnikov
a518e7063d Merge pull request #13120 from dbudniko:dbudniko/gapi_opencl_kernel_example
* custom OpenCL G-API kernel draft

* clean up and warnings fix

* more warnings

* white space

* new blank line at the EOF removed

* HAVE_OPENCL guard

* remove unnecessary ocl API call

* remove sum test workaround

* check if opencl activated

* fix std::str warning

* CPU fall back for symm7x7

* gpu test kernel draft

* adjust have opencl guard

* more guards

* one more attempt to adjust guards

* empty stub files and kernel source files creation in the test directory

* try to force auto generation

* one more attempt to force build

* remove symm7x7 custom from gapi module

* looks like that this version works properly on Win desktop

* clean up

* more clean up

* address some suggestions from Dmitry's review

* const kernel coefficients

* CV_Error in kernel + try to fix cpu fallback

* CV_Error_ instead CV_Error

* everything in one gapi_gpu_test.cpp

* fix warning

* remove kernel generation, add kernel string

* avoid generated code and ocl internal namespace

* fix misprint

* c_str
2018-11-23 17:51:15 +03:00
Ruslan Garnov
a3df05d93b Merge pull request #13215 from rgarnov:rg/overhead
* Added caching of agents execution sequence

* Merged linesRead() and nextWindow() methods on FluidAgent in one method

* Added caching of input lines for fluid::View

* Added caching of output lines for fluid::Buffer

* Fixed GAPI_Assert to work in standalone mode
2018-11-20 17:25:04 +03:00
Dmitry Matveev
85fad1504a Merge pull request #13030 from dmatveev:tutorial
* G-API: First steps with tutorial

* G-API Tutorial: First iteration

* G-API port of anisotropic image segmentation tutorial;
* Currently works via OpenCV only;
* Some new kernels have been required.

* G-API Tutorial: added chapters on execution code, inspection, and profiling

* G-API Tutorial: make Fluid kernel headers public

For some reason, these headers were not moved to the public
headers subtree during the initial development. Somehow it even
worked for the existing workloads.

* G-API Tutorial: Fix a couple of issues found during the work

* Introduced Phase & Sqrt kernels, OCV & Fluid versions
* Extended GKernelPackage to allow kernel removal & policies on include()

All the above stuff needs to be tested, tests will be added later

* G-API Tutorial: added chapter on running Fluid backend

* G-API Tutorial: fix a number of issues in the text

* G-API Tutorial - some final updates

- Fixed post-merge issues after Sobel kernel renaming;
- Simplified G-API code a little bit;
- Put a conclusion note in text.

* G-API Tutorial - fix build issues in test/perf targets

Public headers were refactored but tests suites were not updated in time

* G-API Tutorial: Added tests & reference docs on new kernels

* Phase
* Sqrt

* G-API Tutorial: added link to the tutorial from the main module doc

* G-API Tutorial: Added tests on new GKernelPackage functionality

* G-API Tutorial: Extended InRange tests to cover 32F

* G-API Tutorial: Misc fixes

* Avoid building examples when gapi module is not there
* Added a volatile API disclaimer to G-API root documentation page

* G-API Tutorial: Fix perf tests build issue

This change came from master where Fluid kernels are still used
incorrectly.

* G-API Tutorial: Fixed channels support in Sqrt/Phase fluid kernels

Extended tests to cover this case

* G-API Tutorial: Fix text problems found on team review
2018-11-15 18:12:36 +03:00
Alexander Alekhin
6189b47648 gapi(test): more reliable checks
avoid `countNonZero()`, use `norm()`
2018-11-14 13:30:53 +03:00
Alexander Alekhin
dd6f5949c2 gapi(test): use relative error check for Norm/Sum tests 2018-11-14 13:30:53 +03:00
Evgeny Latkin
4e40e5bb88 Merge pull request #13070 from elatkin:el/gapi_perf_sobel
GAPI (fluid): optimization of Sobel 3x3 (#13070)

* GAPI: performance test for Sobel

* GAPI: performance test for Sobel w/FP32 input

* GAPI: Sobel speedup: 2.5x (U8) up to 10x (float)

* GAPI: Sobel 3x3 to support U8 into S16

* GAPI (fluid): Sobel 3x3 speedup: 10% (uchar), 1.5x (float)

* GAPI (fluid): Sobel 3x3 speedup: +10x (uchar), but -20% (float)

* GAPI (fluid): Sobel 3x3 speedup: +10% (float)

* GAPI (fluid): Sobel 3x3 speedup: +15% (float), +10% (uchar)

* GAPI (fluid): Sobel 3x3: address GCC warnings

* GAPI (fluid): Sobel 3x3: separate *.cpp file w/SIMD code

* GAPI (fluid): Sobel 3x3: fixed AVX2 code, AVX2 speedup 20-50% (uchar), 10-20% (float)

* GAPI (fluid): Sobel 3x3: fix CV_SIMD code for AVX2

* GAPI (fluid): Sobel 3x3: refactor
2018-11-13 15:04:37 +03:00
Ruslan Garnov
858ba6c798 Fixed uniniitialized mats in tests, added operator<< for compare_f 2018-11-09 12:00:55 +03:00
Dmitry Budnikov
5087ff0814 Merge pull request #13008 from dbudniko:dbudniko/gpu_opencl_backend
G-API GPU-OpenCL backend (#13008)

* gpu/ocl backend core

* accuracy tests added and adjusted + license headers

* GPU perf. tests added; almost all adjusted to pass

* all tests adjusted and passed - ready for pull request

* missing license headers

* fix warning (workaround RGB2Gray)

* fix c++ magic

* precompiled header

* white spaces

* try to fix warning and blur test

* try to fix Blur perf tests

* more alignments with the latest cpu backend

* more gapi tests refactoring + 1 more UB issue fix + more informative tolerance exceed reports

* white space fix

* try workaround for SumTest

* GAPI_EXPORTS instead CV_EXPORTS
2018-11-08 22:14:53 +03:00
Evgeny Latkin
000110e760 Merge pull request #13052 from elatkin:yl/gapi_sobel3x3_f32_v2
* GAPI: Sobel 3x3 with FP32 input

* GAPI: Sobel 3x3 with FP32 input, v2
2018-11-06 23:08:50 +03:00
Ruslan Garnov
443fed796a Merge pull request #12990 from rgarnov:gapi_fluid_reshape_support
G-API: Introduce new `reshape()` API (#12990)

* Moved initFluidUnits, initLineConsumption, calcLatency, calcSkew to separate functions

* Added Fluid::View::allocate method (moved allocation logic from constructor)

* Changed util::zip to util::indexed, utilized collectInputMeta in GFluidExecutable constructor

* Added makeReshape method to FluidExecutable

* Removed m_outputRoi from GFluidExecutable

* Added reshape feature

* Added switch of resize mapper if agent ratio was changed

* Added more TODOs and renamed a function

* G-API reshape(): add missing `override` specifiers

Fix warnings on all platforms
2018-10-30 21:12:36 +03:00
AsyaPronina
08536943ad Merge pull request #12949 from AsyaPronina:missed_multiply_operator_for_GMAT
Made scale parameter optional for mul kernel wrapper (#12949)

* Added missed operator*(GMat, GMat). Made scale parameter optional for mul kernel.

* Fixed perf test for mul(GMat, GMat) kernel

* Removed operator*(GMat, GMat) as not needed
2018-10-30 21:10:47 +03:00
Dmitry Budnikov
220b278575 Merge pull request #12944 from dbudniko:dbudniko/tests_thresholds
* added threshold to g-api imgproc tests

* trailing spaces remove

* try to fix warnings

* fix license header

* fix random numbers issue

* fix Sobel test

* license headers + precompiled headers included
2018-10-29 17:34:20 +03:00
AsyaPronina
e6dd9a78ae Merge pull request #12947 from AsyaPronina:sobel_renaming
* Renamed Sobel operator GAPI kernel to match with OpenCV naming rules

* Fixed perf tests

* Small refactoring to check CI issue

* Refactored alignment for kernel wrappers in imgproc.hpp
2018-10-27 19:54:32 +03:00
Dmitry Matveev
5e9750d1f5 Merge pull request #12870 from dmatveev:gapi_fluid_basic_hetero_support
* G-API Fluid basic heterogeneity support: initial upload

* G-API Fluid heterogeneity: address some coding style issues

* G-API Fluid heterogeneity: fix compiler warnings

* G-API Fluid heterogeneity: fix warnings on Windows & ARMv7

* G-API Fluid heterogeneity: finally fix Windows warnings

* G-API Fluid heterogeneity: fix dangling reference problem
2018-10-19 18:32:48 +03:00
Alexander Alekhin
1188c6fe14 Merge pull request #12838 from dmatveev:gapi_fluid_resize_lpi 2018-10-17 09:22:28 +00:00
Dmitry Matveev
922d5796b9 G-API: Introduce LPI (multiple Lines-Per-Iteration) support for Resize
Several Resize optimizations count on fetching multiple input lines at
once to do interpolation more efficiently.

At the moment, Fluid backend supports only LPI=1 for Resize kernels.

This patch introduces scheduling support for Resizes with LPI>1 and
covers these cases with new tests.

The support is initially written by Ruslan Garnov.
2018-10-15 17:11:55 +03:00
Alexander Alekhin
d5d059690f gapi(test): disable divide tests with zeros 2018-10-14 10:47:50 +00:00
Dmitry Matveev
2c6ab65476 Merge pull request #12674 from dmatveev:gapi_upd270918
* Update G-API code base to 27-Sep-18

Changes mostly improve standalone build support

* G-API code base update 28-09-2018

* Windows/Documentation warnings should be fixed
* Fixed stability issues in Fluid backend
* Fixed precompiled headers issues in G-API source files

* G-API code base update 28-09-18 EOD

* Fixed several static analysis issues
* Fixed issues found when G-API is built in a standalone mode
2018-09-28 18:42:09 +03:00
Dmitry Matveev
29e88e50ff Merge pull request #12608 from dmatveev:gapi
* G-API Initial code upload

* Update G-API code base to Sep-24-2018

* The majority of OpenCV buildbot problems was addressed

* Update G-API code base to 24-Sep-18 EOD

* G-API code base update 25-Sep-2018

* Linux warnings should be resolved
* Documentation build should become green
* Number of Windows warnings should be reduced

* Update G-API code base to 25-Sep-18 EOD

* ARMv7 build issue should be resolved
* ADE is bumped to latest version and should fix Clang builds for macOS/iOS
* Remaining Windows warnings should be resolved
* New Linux32 / ARMv7 warnings should be resolved

* G-API code base update 25-Sep-2018-EOD2

* Final Windows warnings should be resolved now

* G-API code base update 26-Sep-2018

* Fixed issues with precompiled headers in module and its tests
2018-09-26 21:50:39 +03:00