This repository has been archived by the owner on Nov 17, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 6.8k
[Numpy] ffi invocation: expand_dims, tril, diff, broadcast_to #17738
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Alicia1529
changed the title
ffi invocation: expand_dims, tril, diff, broadcast_to
[Numpy] ffi invocation: expand_dims, tril, diff, broadcast_to
Mar 2, 2020
Alicia1529
force-pushed
the
np_op_ffi_invocation_diff
branch
from
March 2, 2020 17:30
02331f4
to
be46128
Compare
haojin2
reviewed
Mar 2, 2020
hzfan
reviewed
Mar 3, 2020
hzfan
reviewed
Mar 3, 2020
Alicia1529
force-pushed
the
np_op_ffi_invocation_diff
branch
from
March 6, 2020 03:12
be46128
to
c7a6659
Compare
Alicia1529
force-pushed
the
np_op_ffi_invocation_diff
branch
from
March 6, 2020 03:43
c7a6659
to
68593a1
Compare
hzfan
reviewed
Mar 7, 2020
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
|
||
int num_outputs = 0; | ||
NDArray* inputs[] = {args[0].operator mxnet::NDArray*()}; | ||
auto ndoutputs = Invoke(op, &attrs, 1, inputs, &num_outputs, nullptr); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The 1
seems like a magic number. Better to use int num_inputs = 1
and call Invoke
with num_inputs
. Same for 3 other operators.
MoisesHer
pushed a commit
to MoisesHer/incubator-mxnet
that referenced
this pull request
Apr 10, 2020
anirudh2290
pushed a commit
to anirudh2290/mxnet
that referenced
this pull request
May 29, 2020
sxjscience
pushed a commit
to sxjscience/mxnet
that referenced
this pull request
Jul 1, 2020
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
as title