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
70fe454f
Commit
70fe454f
authored
Oct 20, 2023
by
Umang Yadav
Browse files
Merge branch 'develop' into resnet50_partition
parents
ea0b8059
f47e0b5b
Changes
44
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
12 additions
and
5 deletions
+12
-5
test/replace_allocate.cpp
test/replace_allocate.cpp
+2
-2
test/rewrite_quantization_test.cpp
test/rewrite_quantization_test.cpp
+8
-1
tools/accuracy/requirements.txt
tools/accuracy/requirements.txt
+1
-1
tools/build_and_test_onnxrt.sh
tools/build_and_test_onnxrt.sh
+1
-1
No files found.
test/replace_allocate.cpp
View file @
70fe454f
...
...
@@ -54,7 +54,7 @@ struct allocate_no_out : migraphx::auto_register_op<allocate_no_out>
const
migraphx
::
shape
&
output_shape
,
const
std
::
vector
<
migraphx
::
argument
>&
)
const
{
return
{
output_shape
};
return
migraphx
::
argument
{
output_shape
};
}
};
...
...
@@ -78,7 +78,7 @@ struct allocate_with_out : migraphx::auto_register_op<allocate_with_out>
const
migraphx
::
shape
&
output_shape
,
const
std
::
vector
<
migraphx
::
argument
>&
)
const
{
return
{
output_shape
};
return
migraphx
::
argument
{
output_shape
};
}
};
...
...
test/rewrite_quantization_test.cpp
View file @
70fe454f
...
...
@@ -31,10 +31,13 @@
#include <migraphx/ranges.hpp>
#include <test.hpp>
#include <migraphx/make_op.hpp>
#include <migraphx/env.hpp>
#include <migraphx/serialize.hpp>
#include <migraphx/pass_manager.hpp>
MIGRAPHX_DECLARE_ENV_VAR
(
MIGRAPHX_ENABLE_CK_WORKAROUNDS
);
bool
is_quantizelinear
(
migraphx
::
instruction
&
ins
)
{
return
ins
.
name
()
==
"quantizelinear"
;
}
bool
is_dequantizelinear
(
migraphx
::
instruction
&
ins
)
{
return
ins
.
name
()
==
"dequantizelinear"
;
}
bool
is_clip_scalar
(
migraphx
::
instruction
&
ins
)
...
...
@@ -82,7 +85,11 @@ TEST_CASE(quantizelinear)
EXPECT
(
any_of
(
*
p1
.
get_main_module
(),
&
is_quantizelinear
));
EXPECT
(
none_of
(
*
p2
.
get_main_module
(),
&
is_quantizelinear
));
// ensure clip literals created in quantized program are scalar
EXPECT
(
any_of
(
*
p2
.
get_main_module
(),
&
is_clip_scalar
));
// unless CK workarounds are enabled
if
(
migraphx
::
enabled
(
MIGRAPHX_ENABLE_CK_WORKAROUNDS
{}))
EXPECT
(
none_of
(
*
p2
.
get_main_module
(),
&
is_clip_scalar
));
else
EXPECT
(
any_of
(
*
p2
.
get_main_module
(),
&
is_clip_scalar
));
}
TEST_CASE
(
dequantizelinear
)
...
...
tools/accuracy/requirements.txt
View file @
70fe454f
...
...
@@ -22,4 +22,4 @@
# THE SOFTWARE.
#####################################################################################
numpy==1.21.6
onnxruntime==1.1
0.0
onnxruntime==1.1
6.1
tools/build_and_test_onnxrt.sh
View file @
70fe454f
...
...
@@ -40,4 +40,4 @@ echo 'InferenceSessionTests.CheckRunProfilerWithSessionOptions' >> ../../../tool
echo
'InferenceSessionTests.CheckRunProfilerWithSessionOptions2'
>>
../../../tools/ci_build/github/pai/migraphx-excluded-tests.txt
echo
'InferenceSessionTests.Test3LayerNestedSubgraph'
>>
../../../tools/ci_build/github/pai/migraphx-excluded-tests.txt
echo
'InferenceSessionTests.Test2LayerNestedSubgraph'
>>
../../../tools/ci_build/github/pai/migraphx-excluded-tests.txt
../../../tools/ci_build/github/pai/
migraphx
_test_launcher.sh
||
(
gdb ./onnxruntime_test_all core
-batch
-ex
bt
&&
exit
1
)
../../../tools/ci_build/github/pai/
pai
_test_launcher.sh
||
(
gdb ./onnxruntime_test_all core
-batch
-ex
bt
&&
exit
1
)
Prev
1
2
3
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