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
ed0625e7
Commit
ed0625e7
authored
Feb 09, 2019
by
Paul
Browse files
Formatting
parent
754dbbd4
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
4 deletions
+5
-4
src/py/migraphx_py.cpp
src/py/migraphx_py.cpp
+5
-4
No files found.
src/py/migraphx_py.cpp
View file @
ed0625e7
...
@@ -103,10 +103,11 @@ PYBIND11_MODULE(migraphx, m)
...
@@ -103,10 +103,11 @@ PYBIND11_MODULE(migraphx, m)
py
::
class_
<
migraphx
::
argument
>
(
m
,
"argument"
,
py
::
buffer_protocol
())
py
::
class_
<
migraphx
::
argument
>
(
m
,
"argument"
,
py
::
buffer_protocol
())
.
def_buffer
([](
migraphx
::
argument
&
x
)
->
py
::
buffer_info
{
return
to_buffer_info
(
x
);
})
.
def_buffer
([](
migraphx
::
argument
&
x
)
->
py
::
buffer_info
{
return
to_buffer_info
(
x
);
})
.
def
(
"__init__"
,
[](
migraphx
::
argument
&
x
,
py
::
buffer
b
)
{
.
def
(
"__init__"
,
py
::
buffer_info
info
=
b
.
request
();
[](
migraphx
::
argument
&
x
,
py
::
buffer
b
)
{
new
(
&
x
)
migraphx
::
argument
(
to_shape
(
info
),
info
.
ptr
);
py
::
buffer_info
info
=
b
.
request
();
})
new
(
&
x
)
migraphx
::
argument
(
to_shape
(
info
),
info
.
ptr
);
})
.
def
(
"__eq__"
,
std
::
equal_to
<
migraphx
::
argument
>
{})
.
def
(
"__eq__"
,
std
::
equal_to
<
migraphx
::
argument
>
{})
.
def
(
"__ne__"
,
std
::
not_equal_to
<
migraphx
::
argument
>
{})
.
def
(
"__ne__"
,
std
::
not_equal_to
<
migraphx
::
argument
>
{})
.
def
(
"__repr__"
,
[](
const
migraphx
::
argument
&
x
)
{
return
migraphx
::
to_string
(
x
);
});
.
def
(
"__repr__"
,
[](
const
migraphx
::
argument
&
x
)
{
return
migraphx
::
to_string
(
x
);
});
...
...
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