Merge pull request #14648 from smirnov-alexey:as/gapi_transform

* Introduce GAPI_TRANSFORM initial interface

Comes along with simple tests and kernel package changes

* Fix documentation and adjust combine() function

* Fix stuff after rebasing on master

* Remove redundant functionality

* Refactoring according to review feedback provided

* Fixes according to review feedback

* Reconsider transformations return and fix a warning

* Fixes from code review

* Add a new simple test

* Cleanup, added tests on GScalar, GMatP, GArray
This commit is contained in:
Alexey Smirnov
2019-06-17 16:26:28 +03:00
committed by Alexander Alekhin
parent 66d7956e67
commit 7f9a9f2a09
11 changed files with 391 additions and 53 deletions
+9 -1
View File
@@ -2,7 +2,7 @@
// It is subject to the license terms in the LICENSE file found in the top-level directory
// of this distribution and at http://opencv.org/license.html.
//
// Copyright (C) 2018 Intel Corporation
// Copyright (C) 2018-2019 Intel Corporation
#include "precomp.hpp"
@@ -50,6 +50,11 @@ std::size_t cv::gapi::GKernelPackage::size() const
return m_id_kernels.size();
}
const std::vector<cv::GTransform> &cv::gapi::GKernelPackage::get_transformations() const
{
return m_transformations;
}
cv::gapi::GKernelPackage cv::gapi::combine(const GKernelPackage &lhs,
const GKernelPackage &rhs)
{
@@ -66,6 +71,9 @@ cv::gapi::GKernelPackage cv::gapi::combine(const GKernelPackage &lhs,
result.m_id_kernels.emplace(kernel.first, kernel.second);
}
}
for (const auto &transforms : lhs.m_transformations){
result.m_transformations.push_back(transforms);
}
return result;
}
+1 -1
View File
@@ -35,7 +35,7 @@ namespace
// 1. Get GCompoundKernel implementation
// 2. Create GCompoundContext
// 3. Run GCompoundKernel with GCompoundContext
// 4. Build subgraph from imputs/outputs GCompoundKernel
// 4. Build subgraph from inputs/outputs GCompoundKernel
// 5. Replace compound node to subgraph
void expand(ade::Graph& g, ade::NodeHandle nh, const ImplInfo& impl_info)