-
Notifications
You must be signed in to change notification settings - Fork 26k
Rename btrifact* to lu
#18435
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
Rename btrifact* to lu
#18435
Conversation
ssnl
left a comment
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.
Nice! I would say that this is a good time to get rid of lu_with_info API, and use a keyword arg (e.g., get_info=False) of lu to dispatch to different method in backend.
|
I removed my earlier comment due to some discrepancy. I think that removing
Are you suggesting overriding the behavior of |
|
Otherwise, we could always return |
|
Test failure: |
|
My bad, fixing it now. |
|
I have a local patch that removes the lu_with_info function and add the get_infos argument in lu. Should I push that or just the fix for the test failures? |
|
@vishwakftw If you like, you can stack the diffs using https://github.com/ezyang/ghstack Otherwise, do what is easiest for you (but with the caveat that the bigger the diff, the harder it is for us to review ;) |
Changelog: - Renames `btrifact` and `btrifact_with_info` to `lu` respectively to remain consistent with other factorization methods (`qr` and `svd`). - Now, we will only have one function and methods named `lu`, which performs `lu` decomposition. This function takes a get_infos kwarg, which when set to True includes a infos tensor in the tuple. - Rename all tests, fix callsites - Create a tentative alias for `lu` under the name `btrifact` and `btrifact_with_info`, and add deprecation warnings to not promote usage. - Add the single batch version for `lu` so that users don't have to unsqueeze and squeeze for a single square matrix (see changes in determinant computation in `LinearAlgebra.cpp`) Test Plan: - All tests should pass to confirm that the patch is correct.
cf4d515 to
9aa2827
Compare
|
@ezyang The patch that I was referring to was rather small, which is why I've amended the commit directly. I'll use ghstack for upcoming PRs (renaming btrisolve and btriunpack). |
|
@pytorchbot rebase this please |
ae1755c to
e4da3d7
Compare
e4da3d7 to
17d9cda
Compare
|
Jenkins tests fail with this error: CircleCI tests pass instead: |
|
@pytorchbot rebase this please |
facebook-github-bot
left a comment
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.
@soumith is landing this pull request. If you are a Facebook employee, you can view this diff on Phabricator.
Summary: Changelog: - Renames `btrifact` and `btrifact_with_info` to `lu`to remain consistent with other factorization methods (`qr` and `svd`). - Now, we will only have one function and methods named `lu`, which performs `lu` decomposition. This function takes a get_infos kwarg, which when set to True includes a infos tensor in the tuple. - Rename all tests, fix callsites - Create a tentative alias for `lu` under the name `btrifact` and `btrifact_with_info`, and add a deprecation warning to not promote usage. - Add the single batch version for `lu` so that users don't have to unsqueeze and squeeze for a single square matrix (see changes in determinant computation in `LinearAlgebra.cpp`) Pull Request resolved: pytorch/pytorch#18435 Differential Revision: D14680352 Pulled By: soumith fbshipit-source-id: af58dfc11fa53d9e8e0318c720beaf5502978cd8
Changelog:
btrifactandbtrifact_with_infotoluto remain consistent with other factorization methods (qrandsvd).lu, which performsludecomposition. This function takes a get_infos kwarg, which when set to True includes a infos tensor in the tuple.luunder the namebtrifactandbtrifact_with_info, and add a deprecation warning to not promote usage.luso that users don't have to unsqueeze and squeeze for a single square matrix (see changes in determinant computation inLinearAlgebra.cpp)Test Plan: