Repository navigation
Conversation
|
Hi @bdelwood! Thank you for your pull request and welcome to our community. Action RequiredIn order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you. ProcessIn order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA. Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with If you have received this in error or have any questions, please contact us at cla@meta.com. Thanks! |
|
Thank you for signing our Contributor License Agreement. We can now accept your code for this (and any) Meta Open Source project. Thanks! |
|
Thanks @bdelwood! This looks pretty good to me Could you try rebasing this? We have an auto-import hook for PRs, but it often doesn't run on a first PR before the CLA is signed. I think if you rebase, it should auto-import which will help me merge it faster (otherwise I have to import it and get a second review, which can take a while) |
253166d to
ca4ac5b
Compare
|
This pull request has been imported. If you are a Meta employee, you can view this in D126546793. (Because this pull request was imported automatically, there will not be any future comments.) |
|
Done! |
stroxler
left a comment
There was a problem hiding this comment.
Review automatically exported from Phabricator review in Meta.
Summary: Next after #5290 I found that these stubs did not always agree with jax’s own annotations, causing valid calls to be rejected. This PR makes the ones I ran into issues with consistent. It also adds support for numpy boolean scalars in arithmetic and updates the available exports for jax 0.12. I’m unsure how you prefer to handle jax version compatibility, but these changes address several issues I encountered moving my project to jax 0.12. - [x] I am a human, and I fully understand the code I am submitting. Pull Request resolved: #5291 Test Plan: Added a couple of tests. Reviewed By: stroxler Differential Revision: D126197644 fbshipit-source-id: bde88995b3c84b6007985d4e7b3fd11d5825ad3b
|
This pull request has been merged in 70d31cf. |
Summary
I maintained some out-of-tree jax stubs, but am migrating the project I needed them for to these in-tree stubs. This is the start of a series of PRs to address gaps I found during that migration.
This first change concerns iteration over arrays with an unspecified shape: jax assumes scalar elements, while numpy assumes array elements, which can reject valid code. It removes the empty default from the jax iterator and reversed iterator, and puts numpy's existing gradual iterator overload first.
Test Plan
Added static and runtime tests for unknown-rank inputs and known vectors and matrices.