Skip to content

Conversation

rnett
Copy link
Contributor

@rnett rnett commented Dec 5, 2020

Simple PR to add a ones op to match Python TF and numpy APIs. Copies from Zeros and operates in the same way (fill + constant).

rnett added 3 commits December 4, 2020 17:56
Signed-off-by: Ryan Nett <[email protected]>
Signed-off-by: Ryan Nett <[email protected]>
Signed-off-by: Ryan Nett <[email protected]>
* An operator creating a constant initialized with ones of the shape given by `dims`.
*
* <p>For example, the following expression
* <pre>{@code tf.ones(tf.constant(shape), TFloat32.DTYPE)</pre>
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The code block is not closed (same thing below)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is due to a cc generation issue, as this is copied from Zeroes and the same issues are present there.

Signed-off-by: Ryan Nett <[email protected]>
@rnett rnett requested a review from karllessard December 6, 2020 00:25
@karllessard karllessard merged commit 4f51bba into tensorflow:master Dec 7, 2020
@rnett rnett deleted the rn_ones_op branch December 7, 2020 21:20
rnett added a commit to rnett/tensorflow-java that referenced this pull request Dec 28, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants