-
Notifications
You must be signed in to change notification settings - Fork 157
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[luci/service] Support Range op Shape Inference for Non-const Param #14010
Conversation
This commit support Range op shape inference for non-const param. ONE-DCO-1.0-Signed-off-by: bokyeong lee <[email protected]>
243ee61
to
d8f8877
Compare
shape.dim(r) = node->dim(r).known() ? node->dim(r).value() : 1; | ||
} | ||
return shape; | ||
return output_shape; |
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.
above
output_shape.rank(1);
now output rank is 1. how is this valid?
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.
In the Range operation, the output is a sequence of numbers.
so output_shape.rank()
is 1
both const and non-const params.
However, when params are non constant, dim(0).value()
is determine in runtime.
+)
According to TensorFlow, Return is 'An 1-D Tensor of type dtype.' https://www.tensorflow.org/api_docs/python/tf/range#returns
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 thank you!
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
This commit Range op support shape inference for non-const param.
ONE-DCO-1.0-Signed-off-by: bokyeong lee [email protected]