-
Notifications
You must be signed in to change notification settings - Fork 113
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
Deprecate native dependency on umfpack
#562
Comments
Jinning,
Thanks! UNFPACK support comes for free with KVXOPT or cvxopt. Once we replace the sparse matrices handling with SciPy, we will automatically switch to using UMFPACK from there.
Get Outlook for iOS<https://aka.ms/o0ukef>
…________________________________
From: Jinning Wang ***@***.***>
Sent: Thursday, August 15, 2024 9:59:25 AM
To: CURENT/andes ***@***.***>
Cc: Hantao Cui ***@***.***>; Assign ***@***.***>
Subject: Re: [CURENT/andes] Deprecate native dependency on ``umfpack`` (Issue #562)
Assigned #562<#562> to @cuihantao<https://github.com/cuihantao>.
—
Reply to this email directly, view it on GitHub<#562 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/ABSNZA3I7LJUYTXCKOSCQBTZRSX33AVCNFSM6AAAAABMSIHBJ2VHI2DSMVQWIX3LMV45UABCJFZXG5LFIV3GK3TUJZXXI2LGNFRWC5DJN5XDWMJTHA4TMMJYGA2TCNY>.
You are receiving this because you were assigned.Message ID: ***@***.***>
|
I'm thinking that, maybe we can benchmark the performance of involved methods? Here is a code to my mind. Feel free to let me know if you have any other comments. scipy.sparse.linalg import spsolve
# assume `A` is a 2D matrix and `b` is a vector
# method1
x1 = spsolve(A, b, use_umfpack=True)
# method2
x2 = spsolve(A, b, use_umfpack=False) |
Sure. This is benchmarking UMFPACK and SuperLU performance. And remember the default solver is KLU, which is probably 30% faster than UMFPACK. And.. using KVXOPT to handle sparse matrices can be 20%-50% faster than using SciPy for systems with, say, 10,000 buses.
… On Aug 15, 2024, at 11:12 AM, Jinning Wang ***@***.***> wrote:
I'm thinking that, maybe we can benchmark the performance of involved methods? Here is a code to my mind.
Feel free to let me know if you have any other comments.
scipy.sparse.linalg import spsolve
# assume `A` is a 2D matrix and `b` is a vector
# method1
x1 = spsolve(A, b, use_umfpack=True)
# method2
x2 = spsolve(A, b, use_umfpack=False)
—
Reply to this email directly, view it on GitHub <#562 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/ABSNZA72HTK7S2KU3GAU5PDZRTANDAVCNFSM6AAAAABMSIHBJ2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEOJRGQ4TKMBVHE>.
You are receiving this because you were mentioned.
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Is your feature request related to a problem? Please describe.
The native dependency on
umfpack
viakvxopt
can introduce license issue. The involved implementation in ANDES is in:andes/andes/linsolvers/suitesparse.py
Lines 7 to 8 in 5ab784b
Further, it can be traced back to
SuiteSparse
viakvxopt
:https://github.com/sanurielf/kvxopt/blob/cc4cd9a4f2f27c2f5cac1363ba0f36574b16b0bd/setup.py#L76-L93
Describe the solution you'd like
For reference, package
SciPy
provides wrappers ofumfpack
(via a BSD licensed packagescikit-umfpack
), but doesn't include it as a dependency.Code:
https://github.com/scipy/scipy/blob/9e9d534b7afac90e8d2fa23be1d0ab1201c1bde1/scipy/sparse/linalg/_dsolve/linsolve.py#L13-L19
Documentation:
https://docs.scipy.org/doc/scipy/reference/generated/scipy.sparse.linalg.use_solver.html
Dependency:
In the dependency, the package
scikit-umfpack
is included in [test] rather than in [build-system].https://github.com/scipy/scipy/blob/9e9d534b7afac90e8d2fa23be1d0ab1201c1bde1/pyproject.toml#L18-L32
Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.
Additional context
The text was updated successfully, but these errors were encountered: