-
Notifications
You must be signed in to change notification settings - Fork 55
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
Refactoring of QR: stabilized Gram-Schmidt for split=1 and TS-QR for split=0 #1329
Refactoring of QR: stabilized Gram-Schmidt for split=1 and TS-QR for split=0 #1329
Conversation
Thank you for the PR! |
1 similar comment
Thank you for the PR! |
To be done:
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #1329 +/- ##
==========================================
- Coverage 92.05% 91.58% -0.48%
==========================================
Files 80 80
Lines 11950 11647 -303
==========================================
- Hits 11001 10667 -334
- Misses 949 980 +31
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
Thank you for the PR! |
Thank you for the PR! |
1 similar comment
Thank you for the PR! |
…QR' of github.com:helmholtz-analytics/heat into features/1237-Try_out_pure_stabilized_Gram-Schmidt_for_QR
Thank you for the PR! |
1 similar comment
Thank you for the PR! |
Thank you for the PR! |
Thank you for the PR! |
Thank you for the PR! |
Thank you for the PR! |
Thank you for the PR! |
Thank you for the PR! |
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.
Thanks for all the work, a few comments:
# handle the case of a single process or split=None: just PyTorch QR | ||
Q, R = torch.linalg.qr(A.larray, mode=mode) | ||
R = DNDarray( |
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.
I disagree, it's not inconsistent to say: we enable all modes for non-distributed DNDarrays, and "reduced" only for distributed DNDarrays.
I have addressed all except for the last comment; the last one I didnt understand because I dont see the inconsistency that is not there (?). |
Thank you for the PR! |
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.
Awesome @mrfh92 thank you so much!
Thank you for the PR! |
1 similar comment
Thank you for the PR! |
Description
Changes in the implementation of QR:
split=1
: column-block-wise stabilized/modified Gram Schmidt; thus any shape allowed.split=0
: TS-QR ("tall skinny QR"); thus input must be tall-skinny in the sense that each local chunk of data has not less rows than columns. Removing this restriction can be considered as future work.mode
; the latter can bereduced
andr
, but we currently do not supportcomplete
orraw
. (complete
is available both in PyTorch and NumPy and should be considered as future work.) The argumentsoverwrite_a
,calc_q
, andtiles_per_proc
are no more used; instead I have introducedprocs_to_merge
which is a hyperparameter related to TS-QR.test_qr.py
and some fromtest_svdtools.py
) on AMD-hardware has been removed since the new PyTorch/ROCm-images supporttorch.linalg.qr
.Possible future work:
mode=complete
is available both in PyTorch and NumPy and therefore might be included in future versions, too.Due Diligence