-
-
Notifications
You must be signed in to change notification settings - Fork 811
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
Support cusolverDn<t>gesvdj and cusolverDn<t>gesvdaStridedBatched #3192
Conversation
@toslunar Could you take a look? |
status = cusolverDnXgesvdjGetResidual(<Handle>handle, <GesvdjInfo>info, | ||
&residual) | ||
check_status(status) | ||
return residual |
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.
Fair to leave it untested because the functionality (to compute residual of the decomposition) does not seem available in NumPy or SciPy.
cuda_version = runtime.runtimeGetVersion() | ||
if version_added is not None and cuda_version < version_added: | ||
return False | ||
if version_removed is not None and cuda_version >= version_removed: |
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.
Agree to have version_removed
to align with cupy/cusparse.py
.
Lines 82 to 93 in 2d10549
_available_cuda_version = { | |
'csrmv': (8000, 11000), | |
'csrmvEx': (8000, None), | |
'csrmm': (8000, 11000), | |
'csrmm2': (8000, 11000), | |
'csrgeam': (8000, 11000), | |
'csrgeam2': (9020, None), | |
'csrgemm': (8000, 11000), | |
'csrgemm2': (8000, None), | |
'spmv': (10010, None), | |
'spmm': (10010, None), | |
} |
Thanks for your review. I fixed typos. |
Jenkins, test this please. |
Successfully created a job for commit f1df4a9: |
Jenkins CI test (for commit f1df4a9, target branch master) succeeded! |
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.
LGTM
This PR makes following two types of cuSolver SVD implementations available in CuPy.
gesvdj
... https://docs.nvidia.com/cuda/cusolver/index.html#cuds-lt-t-gt-gesvdjgesvda
... https://docs.nvidia.com/cuda/cusolver/index.html#cuds-lt-t-gt-gesvdagesvdj
uses Jacobi method and can give better performance compared with standard gesvd using QR factorization when matrix size is not large.gesvda
is approximate SVD solver and better in performance when a tall skinny matrix.This is related to #3174