Merge pull request #15312 from smirnov-alexey:gapi_fluid_garray
* Support GArray as input in fluid kernels * Create tests on GArray input in fluid * Some fixes to fully support GArray * Refactor code and change the kernel according to review * Add histogram calculation as a G-API kernel Add assert that input GArgs in fluid contain at least one GMat
This commit is contained in:
committed by
Alexander Alekhin
parent
e98e58c65a
commit
8a7e74673e
@@ -244,6 +244,26 @@ TEST(Fluid, Sum_2_Mats_And_Scalar)
|
||||
EXPECT_EQ(0, cv::countNonZero(out_mat != ref_mat));
|
||||
}
|
||||
|
||||
TEST(Fluid, EqualizeHist)
|
||||
{
|
||||
cv::GMat in, out;
|
||||
cv::GComputation c(cv::GIn(in), cv::GOut(TEqualizeHist::on(in, TCalcHist::on(in))));
|
||||
|
||||
cv::Mat in_mat(320, 480, CV_8UC1),
|
||||
out_mat(320, 480, CV_8UC1),
|
||||
ref_mat(320, 480, CV_8UC1);
|
||||
|
||||
cv::randu(in_mat, 200, 240);
|
||||
|
||||
auto cc = c.compile(cv::descr_of(in_mat), cv::compile_args(fluidTestPackage));
|
||||
|
||||
cc(cv::gin(in_mat), cv::gout(out_mat));
|
||||
|
||||
cv::equalizeHist(in_mat, ref_mat);
|
||||
|
||||
EXPECT_EQ(0, cv::countNonZero(out_mat != ref_mat));
|
||||
}
|
||||
|
||||
TEST(Fluid, Split3)
|
||||
{
|
||||
cv::GMat bgr;
|
||||
|
||||
Reference in New Issue
Block a user