프로그래밍/Python

[Python] libf77blas.so.3: cannot open shared object file

채윤아빠 2022. 10. 23. 14:09
728x90
반응형

문제점 및 증상

파이썬 프로그램을 실행하였더니, 다음과 같은 오류가 발생하였습니다.

pi@raspberrypi:~/work/ $ python3 test_tracking.py
Traceback (most recent call last):
  File "test_tracking.py", line 13, in 
...
  File "/home/pi/.local/lib/python3.7/site-packages/scipy/linalg/misc.py", line 3, in 
    from .blas import get_blas_funcs
  File "/home/pi/.local/lib/python3.7/site-packages/scipy/linalg/blas.py", line 213, in 
    from scipy.linalg import _fblas
ImportError: libf77blas.so.3: cannot open shared object file: No such file or directory

해결 방법

해결 방법은 단순합니다. "libatlas-base-dev" 패키지를 설치하고, 다시 실행하면 됩니다.

pi@raspberrypi:~/work/hunature_TEST $ sudo apt-get install libatlas-base-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
  libatlas3-base
Suggested packages:
  libatlas-doc liblapack-doc
The following NEW packages will be installed:
  libatlas-base-dev libatlas3-base
0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
...
update-alternatives: using /usr/lib/arm-linux-gnueabihf/atlas/liblapack.so to provide /usr/lib/arm-linux-gnueabihf/liblapack.so (liblapack.so-arm-linux-gnueabihf) in auto mode
Processing triggers for libc-bin (2.28-10+rpt2+rpi1+deb10u1) ...

이후, 프로그램을 다시 실행하였더니 정상적으로 잘 실행되었습니다.


참고자료