The following issues were found
modules/gapi/test/gapi_sample_pipelines.cpp
1 issues
Line: 26
static GMatDesc outMeta(GMatDesc in, Size, double, double, int) { return in; }
};
GAPI_OCV_KERNEL(GOCVInvalidResize, GInvalidResize)
{
static void run(const cv::Mat& in, cv::Size sz, double fx, double fy, int interp, cv::Mat &out)
{
cv::resize(in, out, sz, fx, fy, interp);
}
Reported by Cppcheck.
modules/gapi/test/gapi_scalar_tests.cpp
1 issues
Line: 33
EXPECT_EQ(0, cvtest::norm(out_mat, reference, NORM_INF));
}
TEST(GAPI_Scalar, ReturnValue)
{
const cv::Size sz(2, 2);
cv::Mat in_mat(sz, CV_8U, cv::Scalar(1));
cv::GComputationT<cv::GScalar (cv::GMat)> sum_of_sum([](cv::GMat in)
Reported by Cppcheck.
modules/gapi/test/gapi_smoke_test.cpp
1 issues
Line: 24
EXPECT_NE(m1.data, m2.data);
}
TEST(GAPI, Mat_Recreate)
{
cv::Mat m1 = cv::Mat::zeros(480, 640, CV_8U);
m1.at<uchar>(0, 0) = 128;
cv::Mat m2 = m1;
Reported by Cppcheck.
modules/gapi/test/gapi_transform_tests.cpp
1 issues
Line: 46
using OpaqueT = CustomType;
using WrongOpaqueT = AnotherCustomType;
GAPI_TRANSFORM(gmat_in_gmat_out, <GMat(GMat)>, "gmat_in_gmat_out")
{
static GMat pattern(GMat) { return {}; }
static GMat substitute(GMat) { return {}; }
};
Reported by Cppcheck.
modules/gapi/test/gapi_typed_tests.cpp
1 issues
Line: 23
}
};
GAPI_OCV_KERNEL(GCPUKernelForGArrayGMatOut, custom::GKernelForGArrayGMatOut)
{
static void run(const cv::Mat &src, std::vector<cv::Mat> &out)
{
out[0] = src.clone();
}
Reported by Cppcheck.
modules/gapi/test/gapi_util_tests.cpp
1 issues
Line: 32
"float is not an integral types");
}
TEST(GAPIUtil, AllButLast)
{
using test1 = cv::detail::all_but_last<long, int, float>::type;
static_assert(true == cv::detail::all_satisfy<std::is_integral, test1>::value,
"[long, int] are all integral types (float skipped)");
Reported by Cppcheck.
modules/gapi/test/infer/gapi_infer_ie_test.cpp
1 issues
Line: 144
// TODO: Probably DNN/IE part can be further parametrized with a template
// NOTE: here ".." is used to leave the default "gapi/" search scope
TEST(TestAgeGenderIE, InferBasicTensor)
{
initDLDTDataPath();
cv::gapi::ie::detail::ParamDesc params;
params.model_path = findDataFile(SUBDIR + "age-gender-recognition-retail-0013.xml");
Reported by Cppcheck.
modules/gapi/test/infer/gapi_infer_onnx_test.cpp
1 issues
Line: 565
};
} // anonymous namespace
TEST_F(ONNXClassification, Infer)
{
useModel("classification/squeezenet/model/squeezenet1.0-9");
in_mat = cv::imread(findDataFile("cv/dpm/cat.png", false));
// ONNX_API code
cv::Mat processed_mat;
Reported by Cppcheck.
modules/gapi/test/internal/gapi_int_dynamic_graph.cpp
1 issues
Line: 22
TYPED_TEST_CASE(DynamicGraphProtoArgs, VectorProtoTypes);
TYPED_TEST(DynamicGraphProtoArgs, AddProtoInputArgsSmoke)
{
using T = typename TestFixture::Type;
auto ins = GIn();
T in;
EXPECT_NO_THROW(ins += GIn(in));
Reported by Cppcheck.
modules/gapi/test/internal/gapi_int_garg_test.cpp
1 issues
Line: 59
TYPED_TEST_CASE(GArgKind, GArg_Test_Types);
TYPED_TEST(GArgKind, LocalVar)
{
typename TestFixture::Type val{};
cv::GArg arg(val);
EXPECT_EQ(TestFixture::Kind, arg.kind);
}
Reported by Cppcheck.