-
Notifications
You must be signed in to change notification settings - Fork 16
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
CHOLMOD Wrapper Integration #9
base: main
Are you sure you want to change the base?
Conversation
src/CHOLMODSolver.cpp
Outdated
b = eigen2cholmod(rhs); | ||
x = cholmod_l_solve (CHOLMOD_A, L, &b, cm); | ||
|
||
memcpy(result.data(), x->x, result.size() * sizeof(result[0])); |
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.
might need to resize result before this
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.
Done.
src/CHOLMODSolver.hpp
Outdated
// Base(const Base &) = delete; \ | ||
// Base &operator=(const Base &) = delete; | ||
|
||
//////////////////////////////////////////////////////////////////////////////// |
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.
you can delete these comments
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.
Done.
nice! we need also the ifdefs on top if chlmod is not available |
I have added the initial CHOLMOD wrapper. It might be lacking some additional capabilities like "getinfo".
Currently, the issue is that the code couldn't use GPU. I guess it is because of the version of SuiteSparse being used in polysolve. Could you make the necessary changes in the cmake such that it uses v5.10.1 found here https://github.com/DrTimothyAldenDavis/SuiteSparse/releases
Also, the current code assumes that the input stiffness matrix has inner index type of "long int" instead of "int". This is required because only the long integer version of CHOLMOD can leverage GPU acceleration. Might need to automate it.