Skip to content
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

Revert openblas linking changes from #451 #1386

Merged
merged 3 commits into from
Dec 19, 2024
Merged

Conversation

dime10
Copy link
Contributor

@dime10 dime10 commented Dec 17, 2024

PR #451 introduced linking against both OpenBLAS and LAPACKE+Accelerate on arm macOS, which breaks re-compilation of certain user programs (like Shor's). The cause of the shared library conflict is unknown.

For now, we revert these linking changes, which were originally introduced due to Lightning not finding its OpenBLAS dependency when invoked through Catalyst:

FAILED frontend/test/pytest/test_measurements_shots_results.py::TestExpval::test_hermitian[lightning.qubit]

RuntimeError: [pennylane_lightning/core/src/utils/SharedLibLoader.hpp][Line:60][Method:SharedLibLoader]: Error in PennyLane Lightning: dlopen(libscipy_openblas.dylib, 0x0001): tried: 'libscipy_openblas.dylib' (no such file), '$ORIGIN/../scipy_openblas32/lib/libscipy_openblas.dylib' (no such file)

The above test will fail as a result of this, which we plan to fix with a PR on the lightning side.

[sc-80803]

@dime10 dime10 added the bug Something isn't working label Dec 17, 2024
Copy link
Contributor

Hello. You may have forgotten to update the changelog!
Please edit doc/releases/changelog-dev.md on your branch with:

  • A one-to-two sentence description of the change. You may include a small working example for new features.
  • A link back to this PR.
  • Your name (or GitHub username) in the contributors section.

@PennyLaneAI PennyLaneAI deleted a comment from github-actions bot Dec 17, 2024
Copy link
Member

@multiphaseCFD multiphaseCFD left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Thanks @dime10

Copy link

codecov bot commented Dec 17, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 95.82%. Comparing base (94b0bd6) to head (91ca827).
Report is 8 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1386      +/-   ##
==========================================
- Coverage   96.72%   95.82%   -0.91%     
==========================================
  Files          78       78              
  Lines        8439     8437       -2     
  Branches      873      873              
==========================================
- Hits         8163     8085      -78     
- Misses        222      299      +77     
+ Partials       54       53       -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@erick-xanadu
Copy link
Contributor

@dime10 there were some documentation changes to reflect support for finite shot measurements of hermitian observables. If this comes into effect, we should also revert those documentation changes.

@dime10
Copy link
Contributor Author

dime10 commented Dec 18, 2024

@dime10 there were some documentation changes to reflect support for finite shot measurements of hermitian observables. If this comes into effect, we should also revert those documentation changes.

Well in theory they are supported simply by upgrading the version of lightning (which will be forced by next release anyway) 🤔 The original PR had no functional changes on the catalyst side besides the erroneous linking.

We could consider it a known issue on macos that the lapack libs may clash, and try to resolve it in a follow up?

@dime10
Copy link
Contributor Author

dime10 commented Dec 18, 2024

We could consider it a known issue on macos that the lapack libs may clash, and try to resolve it in a follow up?

Having said that it might not be possible to merge this if the failure is reproducible in the CI.

@dime10
Copy link
Contributor Author

dime10 commented Dec 18, 2024

Just waiting on the lightning wheels to become available and we should be able to merge this!

@dime10 dime10 merged commit 6ebfd70 into main Dec 19, 2024
41 checks passed
@dime10 dime10 deleted the fix-lightning-conflict-macos branch December 19, 2024 15:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants