2度もはまったのでメモ.
結論
- 解決策:
cd /usr/lib64/atlas && ln -s libtatlas.so libcblas.so
状況
CentOSにscikit-learnをpipで入れようとしても以下のように怒られる
g++ -pthread -shared -Wl,-z,relro build/temp.linux-x86_64-2.7/sklearn/svm/liblinear.o build/temp.linux-x86_64-2.7/sklearn/svm/src/liblinear/tron.o build/temp.linux-x86_64-2.7/sklearn/svm/src/liblinear/linear.o -L/usr/lib64/atlas -L/usr/lib64 -Lbuild/temp.linux-x86_64-2.7 -lcblas -lm -lpython2.7 -o build/lib.linux-x86_64-2.7/sklearn/svm/liblinear.so
/usr/bin/ld: -lcblas が見つかりません
collect2: エラー: ld はステータス 1 で終了しました
/usr/bin/ld: -lcblas が見つかりません
collect2: エラー: ld はステータス 1 で終了しました
error: Command "g++ -pthread -shared -Wl,-z,relro build/temp.linux-x86_64-2.7/sklearn/svm/liblinear.o build/temp.linux-x86_64-2.7/sklearn/svm/src/liblinear/tron.o build/temp.linux-x86_64-2.7/sklearn/svm/src/liblinear/linear.o -L/usr/lib64/atlas -L/usr/lib64 -Lbuild/temp.linux-x86_64-2.7 -lcblas -lm -lpython2.7 -o build/lib.linux-x86_64-2.7/sklearn/svm/liblinear.so" failed with exit status 1
atlasを入れればいいらしいのだが,入っている模様:
$ yum list | grep atlas
atlas.x86_64 3.10.1-10.el7 @base
atlas-devel.x86_64 3.10.1-10.el7 @base
atlas.i686 3.10.1-10.el7 base
atlas-devel.i686 3.10.1-10.el7 base
atlas-sse2.i686 3.10.1-10.el7 base
atlas-sse3.i686 3.10.1-10.el7 base
atlas-static.i686 3.10.1-10.el7 base
atlas-static.x86_64 3.10.1-10.el7 base