Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
gaoqiong
MIGraphX
Commits
2a150ccc
Commit
2a150ccc
authored
Nov 26, 2018
by
Shucai Xiao
Browse files
add an onnx tanh test.
parent
abf898da
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
24 additions
and
0 deletions
+24
-0
test/onnx/onnx_test.cpp
test/onnx/onnx_test.cpp
+13
-0
test/onnx/tanh_test.onnx
test/onnx/tanh_test.onnx
+11
-0
No files found.
test/onnx/onnx_test.cpp
View file @
2a150ccc
...
@@ -221,6 +221,18 @@ void cosh_test()
...
@@ -221,6 +221,18 @@ void cosh_test()
EXPECT
(
p
==
prog
);
EXPECT
(
p
==
prog
);
}
}
void
tanh_test
()
{
migraphx
::
program
p
;
auto
input
=
p
.
add_parameter
(
"x"
,
migraphx
::
shape
{
migraphx
::
shape
::
float_type
,
{
1
}});
p
.
add_instruction
(
migraphx
::
op
::
tanh
{},
input
);
auto
prog
=
migraphx
::
parse_onnx
(
"tanh_test.onnx"
);
EXPECT
(
p
==
prog
);
}
void
asin_test
()
void
asin_test
()
{
{
migraphx
::
program
p
;
migraphx
::
program
p
;
...
@@ -271,6 +283,7 @@ int main()
...
@@ -271,6 +283,7 @@ int main()
tan_test
();
tan_test
();
sinh_test
();
sinh_test
();
cosh_test
();
cosh_test
();
tanh_test
();
asin_test
();
asin_test
();
acos_test
();
acos_test
();
atan_test
();
atan_test
();
...
...
test/onnx/tanh_test.onnx
0 → 100644
View file @
2a150ccc
tanh-example:;
xy"Tanh test_tanhZ
x
b
y
B
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment