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

undefined symbol: dnrm2_ #37

Open
vnmabus opened this issue Jan 31, 2024 · 8 comments
Open

undefined symbol: dnrm2_ #37

vnmabus opened this issue Jan 31, 2024 · 8 comments

Comments

@vnmabus
Copy link
Contributor

vnmabus commented Jan 31, 2024

If you install the latest version of this library in an empty environment in Python 3.9, and you then perform import fdasrsf, the following error is raised:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File ".../lib/python3.9/site-packages/fdasrsf/__init__.py", line 43, in <module>
    from .time_warping import (
  File ".../lib/python3.9/site-packages/fdasrsf/time_warping.py", line 9, in <module>
    import fdasrsf.utility_functions as uf
  File ".../python3.9/site-packages/fdasrsf/utility_functions.py", line 24, in <module>
    import crbfgs as cr
ImportError: .../python3.9/site-packages/crbfgs.cpython-39-x86_64-linux-gnu.so: undefined symbol: dnrm2_

I obtained that error in my CI tests.

@jdtuck
Copy link
Owner

jdtuck commented Feb 12, 2024

This is caused by not finding a blas library in the CI. The new optimizer (rbfgs) in Cython requires blas. In conda this is not an issue and on most machines. Easiest fix is to pip install mkl-devel in the CI. I have debated adding this to the requirements, but haven't decided as it pops up in small situations.

@jdtuck
Copy link
Owner

jdtuck commented Feb 12, 2024

Also sorry @vnmabus I totally missed this one.

vnmabus added a commit to GAA-UAM/scikit-fda that referenced this issue Feb 13, 2024
@vnmabus
Copy link
Contributor Author

vnmabus commented Feb 13, 2024

@jdtuck I followed your advice, but it still does not work (it now says ImportError: DLL load failed while importing crbfgs: The specified module could not be found.):
https://github.com/GAA-UAM/scikit-fda/actions/runs/7883161339/job/21509586537

If the issue is due to the rbfgs optimizer (which I do not use) a possible way to sidestep the problem is to import the module only when that particular optimizer is used.

@jdtuck
Copy link
Owner

jdtuck commented Feb 13, 2024

We could do that, but I don't understand this error. It tells me the Windows CI is not compiling properly....

@jdtuck
Copy link
Owner

jdtuck commented Feb 13, 2024

@vnmabus #38 should fix this for you, can you confirm.

@vnmabus
Copy link
Contributor Author

vnmabus commented Feb 14, 2024

If I both install mkl-devel and use #38, then it works for me. However, this is just a workaround, and the cause for the error remains to be identified.

@jdtuck
Copy link
Owner

jdtuck commented Feb 14, 2024

Agreed but it is a work around for now and I think this is a windows specific issue

@jdtuck
Copy link
Owner

jdtuck commented Feb 14, 2024

I will merge and release today for this and keep exploring

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

No branches or pull requests

2 participants