summaryrefslogtreecommitdiff
path: root/tests/dnn
diff options
context:
space:
mode:
authorGuo, Yejun <yejun.guo@intel.com>2020-04-11 13:24:36 +0800
committerGuo, Yejun <yejun.guo@intel.com>2020-04-22 13:14:55 +0800
commit265b5bd324496d6a342506ffa6157df5f2a85353 (patch)
tree22980c9d6604987bfae192a02b61ae936f9e2890 /tests/dnn
parentef79408e975057e30d8f4afceaa89702fd5f27da (diff)
dnn-layer-mathbinary-test: add unit test for 'mul'
Signed-off-by: Guo, Yejun <yejun.guo@intel.com>
Diffstat (limited to 'tests/dnn')
-rw-r--r--tests/dnn/dnn-layer-mathbinary-test.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/dnn/dnn-layer-mathbinary-test.c b/tests/dnn/dnn-layer-mathbinary-test.c
index fd8037fca0..3b0f0c5a2e 100644
--- a/tests/dnn/dnn-layer-mathbinary-test.c
+++ b/tests/dnn/dnn-layer-mathbinary-test.c
@@ -34,6 +34,8 @@ static float get_expected(float f1, float f2, DNNMathBinaryOperation op)
return f1 - f2;
case DMBO_ADD:
return f1 + f2;
+ case DMBO_MUL:
+ return f1 * f2;
default:
av_assert0(!"not supported yet");
return 0.f;
@@ -190,5 +192,8 @@ int main(int argc, char **argv)
if (test(DMBO_ADD))
return 1;
+ if (test(DMBO_MUL))
+ return 1;
+
return 0;
}