Skip to content

Use oneMKL LAPACK gesv for dpnp.linalg.solve() #2558

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

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

vlad-perevezentsev
Copy link
Collaborator

This PR suggests using oneMKL LAPACK gesv instead of getrf and getrs in dpnp.linalg.solve() since the issues in oneMKL have been resolved. This removes the workaround implemented in #1763

  • Have you provided a meaningful PR description?
  • Have you added a test, reproducer or referred to an issue with a reproducer?
  • Have you tested your changes locally for CPU and GPU devices?
  • Have you made sure that new changes do not introduce compiler warnings?
  • Have you checked performance impact of proposed changes?
  • Have you added documentation for your changes, if necessary?
  • Have you added your changes to the changelog?

Copy link
Contributor

View rendered docs @ https://intelpython.github.io/dpnp/pull/2558/index.html

Copy link
Contributor

Array API standard conformance tests for dpnp=0.19.0dev3=py313h509198e_8 ran successfully.
Passed: 1227
Failed: 0
Skipped: 9


_check_lapack_dev_info(dev_info_h)
Copy link
Collaborator

@vtavana vtavana Aug 14, 2025

Choose a reason for hiding this comment

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

With these changes, lines 733-735 are not covered with any test.

error_msg = error_msg or "Singular matrix"

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Good point!
That is because gesv raises an error internally.
I will update tests for dpnp.linalg.inv() to cover this.
Thank you

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

@vtavana this #2559 will help cover this line

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants