Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
gaoqiong
MIGraphX
Commits
7bacd3ba
Commit
7bacd3ba
authored
Jul 02, 2019
by
Khalique
Browse files
Merge branch 'develop' of
https://github.com/ROCmSoftwarePlatform/AMDMIGraphX
into expand_dims_op
parents
bbb5f61a
5af04e80
Changes
23
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
55 additions
and
0 deletions
+55
-0
test/gpu/miopen.cpp
test/gpu/miopen.cpp
+36
-0
test/tf/tanh_test.pb
test/tf/tanh_test.pb
+8
-0
test/tf/tf_test.cpp
test/tf/tf_test.cpp
+11
-0
No files found.
test/gpu/miopen.cpp
View file @
7bacd3ba
...
...
@@ -3445,4 +3445,40 @@ struct test_fp32_fp16_sub : verify_program<test_fp32_fp16_sub>
};
};
struct
test_reduce_sum
:
verify_program
<
test_reduce_sum
>
{
migraphx
::
program
create_program
()
const
{
migraphx
::
program
p
;
migraphx
::
shape
s
{
migraphx
::
shape
::
float_type
,
{
3
,
1026
,
4
,
3
}};
auto
x
=
p
.
add_parameter
(
"x"
,
s
);
p
.
add_instruction
(
migraphx
::
op
::
reduce_sum
{{
1
}},
x
);
return
p
;
};
};
struct
test_reduce_sum_int
:
verify_program
<
test_reduce_sum_int
>
{
migraphx
::
program
create_program
()
const
{
migraphx
::
program
p
;
migraphx
::
shape
s
{
migraphx
::
shape
::
int32_type
,
{
3
,
4
,
8
,
8
}};
auto
x
=
p
.
add_parameter
(
"x"
,
s
);
p
.
add_instruction
(
migraphx
::
op
::
reduce_sum
{{
1
}},
x
);
return
p
;
};
};
struct
test_reduce_sum_half
:
verify_program
<
test_reduce_sum_half
>
{
migraphx
::
program
create_program
()
const
{
migraphx
::
program
p
;
migraphx
::
shape
s
{
migraphx
::
shape
::
half_type
,
{
3
,
4
,
8
,
8
}};
auto
x
=
p
.
add_parameter
(
"x"
,
s
);
p
.
add_instruction
(
migraphx
::
op
::
reduce_sum
{{
1
}},
x
);
return
p
;
};
};
int
main
(
int
argc
,
const
char
*
argv
[])
{
test
::
run
(
argc
,
argv
);
}
test/tf/tanh_test.pb
0 → 100644
View file @
7bacd3ba
:
0Placeholder*
dtype0*
shape:
tanhTanh0*
T0"
\ No newline at end of file
test/tf/tf_test.cpp
View file @
7bacd3ba
...
...
@@ -384,4 +384,15 @@ TEST_CASE(sub_test)
EXPECT
(
p
==
prog
);
}
TEST_CASE
(
tanh_test
)
{
migraphx
::
program
p
;
auto
l0
=
p
.
add_parameter
(
"0"
,
migraphx
::
shape
{
migraphx
::
shape
::
float_type
,
{
1
,
2
,
2
,
3
}});
auto
l1
=
p
.
add_parameter
(
"1"
,
migraphx
::
shape
{
migraphx
::
shape
::
float_type
,
{
1
,
2
,
2
,
3
}});
p
.
add_instruction
(
migraphx
::
op
::
sub
{},
l0
,
l1
);
auto
prog
=
migraphx
::
parse_tf
(
"sub_test.pb"
,
false
);
EXPECT
(
p
==
prog
);
}
int
main
(
int
argc
,
const
char
*
argv
[])
{
test
::
run
(
argc
,
argv
);
}
Prev
1
2
Next
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