Commit 2e38c636 authored by Guo, Yejun's avatar Guo, Yejun

dnn-layer-mathbinary-test: add unit test for divide

Signed-off-by: 's avatarGuo, Yejun <yejun.guo@intel.com>
parent 8ce9d88f
...@@ -36,6 +36,8 @@ static float get_expected(float f1, float f2, DNNMathBinaryOperation op) ...@@ -36,6 +36,8 @@ static float get_expected(float f1, float f2, DNNMathBinaryOperation op)
return f1 + f2; return f1 + f2;
case DMBO_MUL: case DMBO_MUL:
return f1 * f2; return f1 * f2;
case DMBO_REALDIV:
return f1 / f2;
default: default:
av_assert0(!"not supported yet"); av_assert0(!"not supported yet");
return 0.f; return 0.f;
...@@ -195,5 +197,8 @@ int main(int argc, char **argv) ...@@ -195,5 +197,8 @@ int main(int argc, char **argv)
if (test(DMBO_MUL)) if (test(DMBO_MUL))
return 1; return 1;
if (test(DMBO_REALDIV))
return 1;
return 0; return 0;
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment