-
Notifications
You must be signed in to change notification settings - Fork 49
Add dynamic lapack/openblas lib loading at runtime #653
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
Conversation
Co-authored-by: Amintor Dusko <[email protected]>
…LaneAI/pennylane-lightning into lightning-qubit2-add-shots
…eAI/pennylane-lightning into lightning-qubit-new-api
…eAI/pennylane-lightning into lightning-qubit-new-api
…y-table and remove std::sort from the logic by re-ordering lookups
maliasadi
left a comment
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 @multiphaseCFD!
Thanks @maliasadi ! According to previous tests, removing the dummy file |
maliasadi
left a comment
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.
🥳
dime10
left a comment
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.
Great work! :)
Before submitting
Please complete the following checklist when submitting a PR:
All new features must include a unit test.
If you've fixed a bug or added code that should be tested, add a test to the
testsdirectory!All new functions and code must be clearly commented and documented.
If you do make documentation changes, make sure that the docs build and
render correctly by running
make docs.Ensure that the test suite passes, by running
make test.Add a new entry to the
.github/CHANGELOG.mdfile, summarizing thechange, and including a link back to the PR.
Ensure that code is properly formatted by running
make format.When all the above are checked, delete everything above the dashed
line and fill in the pull request template.
Context:
Switch static LAPACK linking to dynamic loading to LAPACK/OpenBLAS.
Description of the Change:
Deprecated static linking against lapack-dev. Now we load
openblaslibs deployed byscipyfor Hermitian decomposition at runtime.There are two different approaches for
scipy.libssearch depending on how users use/installlightningSCIPY_LIBS_PATHmacro variable, which is configured at the compile time with the help ofCMAKEand its built-in variable${Python_SITELIB}.pip -e .install: ifSCIPY_LIBS_PATHdoesn't work, we try to usedladdrto get thepath\ to\ lightning_qubit_ops.soand we can get\path\to\scipy.libswithpath\ to\ lightning_qubit_ops.so\..\..\scipy.libs, given that bothscipyandlightningare installed in the samesite-packages(which should be always true if the env is set up correctly).Benefits:
The licence issue of linking against
lapack-devcan be avoided.Possible Drawbacks:
Related GitHub Issues: