Android: Add Tensor.ones() and Tensor.zeros() factory methods#15388
Android: Add Tensor.ones() and Tensor.zeros() factory methods#15388GregoryComer merged 1 commit into
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/15388
Note: Links to docs will display an error until the docs builds have been completed. ❌ 4 New Failures, 6 PendingAs of commit fac5d2e with merge base 964515c ( NEW FAILURES - The following jobs have failed:
This comment was automatically generated by Dr. CI and updates every 15 minutes. |
|
@pytorchbot label "release notes: misc" |
|
@shubham0204 Thanks for the contribution. Can you fix the java android lint and rebase the PR? If everything looks good, we can merge it shortly. |
|
@GregoryComer I have fixed the Java formatting issues in the modified files. The formatting used is |
|
@GregoryComer @kirklandsign @psiddh Any updates on this PR? |
|
@shubham0204 Apologies for the slow response. Can you take a look at the errors in this CI job: https://github.com/pytorch/executorch/actions/runs/19102814458/job/54604914604?pr=15388? We should be good to merge once that's green. Thanks! |
…e tensors initialized with ones and zeros resp. (#15125)
|
@GregoryComer I have fixed the formatting issue that was causing the job to fail. Could you re-run those workflows? |
|
CI looks green, so I'll go ahead and merge. Thanks for the contribution! |
…h#15388) Fixes pytorch#15125 Release notes: `misc` ### Summary - [x] Add implementation and test for a new factory method `Tensor.ones()` in the `android` extension ### Test plan The following new JUnit tests were added to verify the behavior of `Tensor.ones()` in `extension/android/executorch_android/src/test/java/org/pytorch/executorch/TensorTest.kt` - `testOnes_DTypeIsFloat` cc @kirklandsign @cbilgin
Fixes #15125
Release notes:
miscSummary
Tensor.ones()in theandroidextensionTest plan
The following new JUnit tests were added to verify the behavior of
Tensor.ones()inextension/android/executorch_android/src/test/java/org/pytorch/executorch/TensorTest.kttestOnes_DTypeIsFloatcc @kirklandsign @cbilgin