Skip to content
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

Use Numpy axis normalizations where possible #419

Merged
merged 3 commits into from
Jun 23, 2022

Conversation

bryevdv
Copy link
Contributor

@bryevdv bryevdv commented Jun 21, 2022

issues: fixes #412

@magnatelee I think this is smaller in scope than you have imagined, but I am not sure much more is advised. Some notes:

  • array.py, sort.py, linalg.py

    I have applied the Numpy normalization functions in places where it seemed to make sense. Most locations were just passing values other functions.

  • fft.py

    Most locations just do computed_axis = (axis,) if axis is not None else None which does not seem worth defining a new function for. One place calls a _sanitize_user_axes but that function does unique conversion that takes shape into account.

  • deferred.py

    A few uses here, but handles comepletely differently, e.g. via result.project

  • ufunc.py, eager.py

    The few uses here just pass on to other functions

  • thunk.py

    no code, just signatures

@bryevdv bryevdv requested a review from magnatelee June 21, 2022 23:46
@bryevdv bryevdv changed the title Bryanv/axes validate Use Numpy axis normalizations where possible Jun 22, 2022
@bryevdv bryevdv merged commit ecb76ee into nv-legate:branch-22.07 Jun 23, 2022
@bryevdv bryevdv deleted the bryanv/axes_validate branch June 23, 2022 22:26
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.

Refactor the axis sanitization
2 participants