mirror of
https://github.com/opencv/opencv.git
synced 2026-07-29 15:23:05 +04:00
Added exp layer
backport of commit:6111935835partial backport of commit:dd5976162b
This commit is contained in:
committed by
Alexander Alekhin
parent
19f1bac18c
commit
96947c30c0
@@ -621,6 +621,31 @@ INSTANTIATE_TEST_CASE_P(Layer_Test_Halide, Power, Combine(
|
||||
dnnBackendsAndTargetsWithHalide()
|
||||
));
|
||||
|
||||
typedef TestWithParam<tuple<Vec3f, tuple<Backend, Target> > > Exp;
|
||||
TEST_P(Exp, Accuracy)
|
||||
{
|
||||
float base = get<0>(GetParam())[0];
|
||||
float scale = get<0>(GetParam())[1];
|
||||
float shift = get<0>(GetParam())[2];
|
||||
Backend backendId = get<0>(get<1>(GetParam()));
|
||||
Target targetId = get<1>(get<1>(GetParam()));
|
||||
|
||||
LayerParams lp;
|
||||
lp.set("base", base);
|
||||
lp.set("scale", scale);
|
||||
lp.set("shift", shift);
|
||||
lp.type = "Exp";
|
||||
lp.name = "testLayer";
|
||||
testInPlaceActivation(lp, backendId, targetId);
|
||||
}
|
||||
|
||||
INSTANTIATE_TEST_CASE_P(Layer_Test_Halide, Exp, Combine(
|
||||
/*base, scale, shift*/ Values(Vec3f(0.9f, -1.0f, 1.1f), Vec3f(0.9f, 1.1f, -1.0f),
|
||||
Vec3f(-1.0f, 0.9f, 1.1f), Vec3f(-1.0f, 1.1f, 0.9f),
|
||||
Vec3f(1.1f, 0.9f, -1.0f), Vec3f(1.1f, -1.0f, 0.9f)),
|
||||
dnnBackendsAndTargetsWithHalide()
|
||||
));
|
||||
|
||||
TEST_P(Test_Halide_layers, ChannelsPReLU)
|
||||
{
|
||||
LayerParams lp;
|
||||
|
||||
Reference in New Issue
Block a user