Change the QR implementation, inspired by LAPACK - #730
Draft
jannschu wants to merge 1 commit into
Draft
Conversation
sebcrozet
force-pushed
the
dev
branch
3 times, most recently
from
April 12, 2021 14:15
700c4dc to
c5c6c13
Compare
|
Why has this never gotten finished and merged? |
Author
|
I rebased this and
The TODOs can now be addressed, was not possible 6 years ago :D, will look into these. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I ported some ideas from LAPACK's QR implementation, more specifically from
?ORG2R.As a result I could increase all epsilons in the test by two order of magnitudes. Also the full computation of the
Qmatrix is now supported, not only the firstmin(n, m)columns. I added a new methodq_columnsfor this. The currentq()method stayed the same.The main difference in the implementation seems to be that LAPACK applies the scaling of the Householder vectors at a different point in the code.
Breaking changes
qr_internal)RandQ.work. This resulted in additional allocator bounds. See discussion below.Things to discuss
q_tr_mulborrows self mutably due to an implementation detail although the struct's state will only be changed temporarily inside the method. Ideas to resolve this:gercandgemvcall (possible performance penalty)workallocations could be done only once by storing a suitable vector in the struct and sharing it. This will result in&mut selfor interior mutability.