Closed siarez closed 6 years ago
Something is wrong with the copy of OpenBLAS it's finding since it's missing symbols. Use --no DLIB_USE_BLAS and --clean to recompile without using BLAS. Or install a non-broken BLAS.
I built and installed OpenBlas from source but that didn't help.
I also did python3 setup.py install --clean --no DLIB_USE_BLAS
, but that didn't help either.
Post the build output from that command.
paperspace@***:~/projects/dlib$ python3 setup.py install --clean --no DLIB_USE_BLAS
running install
running bdist_egg
running egg_info
writing dlib.egg-info/PKG-INFO
writing dependency_links to dlib.egg-info/dependency_links.txt
writing top-level names to dlib.egg-info/top_level.txt
package init file 'dlib/__init__.py' not found (or not a regular file)
reading manifest file 'dlib.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'dlib.egg-info/SOURCES.txt'
installing library code to build/bdist.linux-x86_64/egg
running install_lib
running build_py
running build_ext
Removing old directory /home/paperspace/projects/dlib/build/temp.linux-x86_64-3.6
Invoking CMake setup: 'cmake /home/paperspace/projects/dlib/tools/python -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/home/paperspace/projects/dlib/build/lib.linux-x86_64-3.6 -DPYTHON_EXECUTABLE=/home/paperspace/anaconda3/bin/python3 -DDLIB_USE_BLAS=no -DCMAKE_BUILD_TYPE=Release'
-- The C compiler identification is GNU 4.8.4
-- The CXX compiler identification is GNU 4.8.4
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Found PythonInterp: /home/paperspace/anaconda3/bin/python3 (found version "3.6.4")
-- Found PythonLibs: /home/paperspace/anaconda3/lib/libpython3.6m.so
-- Performing Test HAS_CPP14_FLAG
-- Performing Test HAS_CPP14_FLAG - Failed
-- Performing Test HAS_CPP11_FLAG
-- Performing Test HAS_CPP11_FLAG - Success
-- pybind11 v2.2.2
-- Enabling SSE4 instructions
-- Looking for include file pthread.h
-- Looking for include file pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - not found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Looking for XOpenDisplay in /usr/lib/x86_64-linux-gnu/libX11.so;/usr/lib/x86_64-linux-gnu/libXext.so
-- Looking for XOpenDisplay in /usr/lib/x86_64-linux-gnu/libX11.so;/usr/lib/x86_64-linux-gnu/libXext.so - found
-- Looking for gethostbyname
-- Looking for gethostbyname - found
-- Looking for connect
-- Looking for connect - found
-- Looking for remove
-- Looking for remove - found
-- Looking for shmat
-- Looking for shmat - found
-- Looking for IceConnectionNumber in ICE
-- Looking for IceConnectionNumber in ICE - found
-- Found X11: /usr/lib/x86_64-linux-gnu/libX11.so
-- Looking for png_create_read_struct
-- Looking for png_create_read_struct - found
-- Looking for jpeg_read_header
-- Looking for jpeg_read_header - found
-- Searching for BLAS and LAPACK
-- Searching for BLAS and LAPACK
-- Found PkgConfig: /usr/bin/pkg-config (found version "0.26")
-- checking for module 'cblas'
-- package 'cblas' not found
-- checking for module 'lapack'
-- package 'lapack' not found
-- Looking for sys/types.h
-- Looking for sys/types.h - found
-- Looking for stdint.h
-- Looking for stdint.h - found
-- Looking for stddef.h
-- Looking for stddef.h - found
-- Check size of void*
-- Check size of void* - done
-- Found OpenBLAS library
-- Looking for sgetrf_single
-- Looking for sgetrf_single - found
-- Using OpenBLAS's built in LAPACK
-- Looking for cblas_ddot
-- Looking for cblas_ddot - found
-- Looking for sgesv
-- Looking for sgesv - not found
-- Looking for sgesv_
-- Looking for sgesv_ - not found
-- Found CUDA: /usr/local/cuda (found suitable version "8.0", minimum required is "7.5")
-- Looking for cuDNN install...
-- Found cuDNN: /usr/lib/x86_64-linux-gnu/libcudnn.so
-- Building a CUDA test project to see if your compiler is compatible with CUDA...
-- Checking if you have the right version of cuDNN installed.
-- Try OpenMP C flag = [-fopenmp]
-- Performing Test OpenMP_FLAG_DETECTED
-- Performing Test OpenMP_FLAG_DETECTED - Success
-- Try OpenMP CXX flag = [-fopenmp]
-- Performing Test OpenMP_FLAG_DETECTED
-- Performing Test OpenMP_FLAG_DETECTED - Success
-- Found OpenMP: -fopenmp
-- Enabling CUDA support for dlib. DLIB WILL USE CUDA
-- C++11 activated.
-- Found Python with installed numpy package
-- Numpy include path '/home/paperspace/anaconda3/lib/python3.6/site-packages/numpy/core/include'
-- Performing Test HAS_FLTO
-- Performing Test HAS_FLTO - Success
-- LTO enabled
-- Configuring done
-- Generating done
-- Build files have been written to: /home/paperspace/projects/dlib/build/temp.linux-x86_64-3.6
Invoking CMake build: 'cmake --build . --config Release -- -j8'
[ 2%] [ 2%] Building NVCC (Device) object dlib_build/CMakeFiles/dlib.dir/dnn/dlib_generated_cuda_dlib.cu.o
Building NVCC (Device) object dlib_build/CMakeFiles/dlib.dir/dnn/dlib_generated_cusolver_dlibapi.cu.o
Scanning dependencies of target dlib
[ 3%] [ 4%] [ 6%] [ 6%] Building CXX object dlib_build/CMakeFiles/dlib.dir/base64/base64_kernel_1.cpp.o
[ 8%] [ 10%] [ 10%] Building CXX object dlib_build/CMakeFiles/dlib.dir/bigint/bigint_kernel_2.cpp.o
[ 11%] Building CXX object dlib_build/CMakeFiles/dlib.dir/bigint/bigint_kernel_1.cpp.o
Building CXX object dlib_build/CMakeFiles/dlib.dir/bit_stream/bit_stream_kernel_1.cpp.o
Building CXX object dlib_build/CMakeFiles/dlib.dir/entropy_decoder/entropy_decoder_kernel_1.cpp.o
Building CXX object dlib_build/CMakeFiles/dlib.dir/entropy_encoder/entropy_encoder_kernel_1.cpp.o
Building CXX object dlib_build/CMakeFiles/dlib.dir/entropy_decoder/entropy_decoder_kernel_2.cpp.o
Building CXX object dlib_build/CMakeFiles/dlib.dir/entropy_encoder/entropy_encoder_kernel_2.cpp.o
[ 12%] Building CXX object dlib_build/CMakeFiles/dlib.dir/md5/md5_kernel_1.cpp.o
[ 13%] Building CXX object dlib_build/CMakeFiles/dlib.dir/tokenizer/tokenizer_kernel_1.cpp.o
[ 15%] Building CXX object dlib_build/CMakeFiles/dlib.dir/unicode/unicode.cpp.o
[ 16%] [ 17%] Building CXX object dlib_build/CMakeFiles/dlib.dir/data_io/mnist.cpp.o
Building CXX object dlib_build/CMakeFiles/dlib.dir/data_io/image_dataset_metadata.cpp.o
[ 18%] Building CXX object dlib_build/CMakeFiles/dlib.dir/global_optimization/global_function_search.cpp.o
[ 19%] Building CXX object dlib_build/CMakeFiles/dlib.dir/filtering/kalman_filter.cpp.o
[ 20%] Building CXX object dlib_build/CMakeFiles/dlib.dir/test_for_odr_violations.cpp.o
[ 22%] Building CXX object dlib_build/CMakeFiles/dlib.dir/sockets/sockets_kernel_1.cpp.o
[ 23%] Building CXX object dlib_build/CMakeFiles/dlib.dir/bsp/bsp.cpp.o
[ 24%] Building CXX object dlib_build/CMakeFiles/dlib.dir/dir_nav/dir_nav_kernel_1.cpp.o
[ 25%] Building CXX object dlib_build/CMakeFiles/dlib.dir/dir_nav/dir_nav_kernel_2.cpp.o
[ 26%] Building CXX object dlib_build/CMakeFiles/dlib.dir/dir_nav/dir_nav_extensions.cpp.o
[ 27%] Building CXX object dlib_build/CMakeFiles/dlib.dir/linker/linker_kernel_1.cpp.o
[ 29%] Building CXX object dlib_build/CMakeFiles/dlib.dir/logger/extra_logger_headers.cpp.o
[ 30%] Building CXX object dlib_build/CMakeFiles/dlib.dir/logger/logger_kernel_1.cpp.o
[ 31%] Building CXX object dlib_build/CMakeFiles/dlib.dir/logger/logger_config_file.cpp.o
[ 32%] Building CXX object dlib_build/CMakeFiles/dlib.dir/misc_api/misc_api_kernel_1.cpp.o
[ 33%] Building CXX object dlib_build/CMakeFiles/dlib.dir/misc_api/misc_api_kernel_2.cpp.o
[ 34%] Building CXX object dlib_build/CMakeFiles/dlib.dir/sockets/sockets_extensions.cpp.o
[ 36%] Building CXX object dlib_build/CMakeFiles/dlib.dir/sockets/sockets_kernel_2.cpp.o
[ 37%] Building CXX object dlib_build/CMakeFiles/dlib.dir/sockstreambuf/sockstreambuf.cpp.o
[ 38%] Building CXX object dlib_build/CMakeFiles/dlib.dir/sockstreambuf/sockstreambuf_unbuffered.cpp.o
[ 39%] Building CXX object dlib_build/CMakeFiles/dlib.dir/server/server_kernel.cpp.o
[ 40%] Building CXX object dlib_build/CMakeFiles/dlib.dir/server/server_iostream.cpp.o
[ 41%] Building CXX object dlib_build/CMakeFiles/dlib.dir/server/server_http.cpp.o
[ 43%] Building CXX object dlib_build/CMakeFiles/dlib.dir/threads/multithreaded_object_extension.cpp.o
[ 44%] Building CXX object dlib_build/CMakeFiles/dlib.dir/threads/threaded_object_extension.cpp.o
[ 45%] Building CXX object dlib_build/CMakeFiles/dlib.dir/threads/threads_kernel_1.cpp.o
[ 46%] Building CXX object dlib_build/CMakeFiles/dlib.dir/threads/threads_kernel_2.cpp.o
[ 47%] Building CXX object dlib_build/CMakeFiles/dlib.dir/threads/threads_kernel_shared.cpp.o
[ 48%] Building CXX object dlib_build/CMakeFiles/dlib.dir/threads/thread_pool_extension.cpp.o
[ 50%] Building CXX object dlib_build/CMakeFiles/dlib.dir/threads/async.cpp.o
[ 51%] Building CXX object dlib_build/CMakeFiles/dlib.dir/timer/timer.cpp.o
[ 52%] Building CXX object dlib_build/CMakeFiles/dlib.dir/stack_trace.cpp.o
[ 53%] Building CXX object dlib_build/CMakeFiles/dlib.dir/dnn/cpu_dlib.cpp.o
[ 54%] Building CXX object dlib_build/CMakeFiles/dlib.dir/dnn/tensor_tools.cpp.o
[ 55%] Building CXX object dlib_build/CMakeFiles/dlib.dir/gui_widgets/fonts.cpp.o
[ 56%] Building CXX object dlib_build/CMakeFiles/dlib.dir/gui_widgets/widgets.cpp.o
[ 58%] Building CXX object dlib_build/CMakeFiles/dlib.dir/gui_widgets/drawable.cpp.o
[ 59%] Building CXX object dlib_build/CMakeFiles/dlib.dir/gui_widgets/canvas_drawing.cpp.o
[ 60%] Building CXX object dlib_build/CMakeFiles/dlib.dir/gui_widgets/style.cpp.o
[ 61%] Building CXX object dlib_build/CMakeFiles/dlib.dir/gui_widgets/base_widgets.cpp.o
[ 62%] Building CXX object dlib_build/CMakeFiles/dlib.dir/gui_core/gui_core_kernel_1.cpp.o
[ 63%] Building CXX object dlib_build/CMakeFiles/dlib.dir/gui_core/gui_core_kernel_2.cpp.o
[ 65%] Building CXX object dlib_build/CMakeFiles/dlib.dir/image_loader/png_loader.cpp.o
[ 66%] Building CXX object dlib_build/CMakeFiles/dlib.dir/image_saver/save_png.cpp.o
[ 67%] Building CXX object dlib_build/CMakeFiles/dlib.dir/image_loader/jpeg_loader.cpp.o
[ 68%] Building CXX object dlib_build/CMakeFiles/dlib.dir/image_saver/save_jpeg.cpp.o
[ 69%] Building CXX object dlib_build/CMakeFiles/dlib.dir/dnn/cudnn_dlibapi.cpp.o
[ 70%] Building CXX object dlib_build/CMakeFiles/dlib.dir/dnn/cublas_dlibapi.cpp.o
[ 72%] Building CXX object dlib_build/CMakeFiles/dlib.dir/dnn/curand_dlibapi.cpp.o
[ 73%] Building CXX object dlib_build/CMakeFiles/dlib.dir/dnn/cuda_data_ptr.cpp.o
[ 74%] Building CXX object dlib_build/CMakeFiles/dlib.dir/dnn/gpu_data.cpp.o
Linking CXX static library libdlib.a
[ 74%] Built target dlib
Scanning dependencies of target dlib_python
[ 76%] [ 76%] [ 77%] [ 79%] Building CXX object CMakeFiles/dlib_python.dir/src/vector.cpp.o
[ 80%] [ 82%] [ 82%] Building CXX object CMakeFiles/dlib_python.dir/src/svm_c_trainer.cpp.o
Building CXX object CMakeFiles/dlib_python.dir/src/svm_rank_trainer.cpp.o
Building CXX object CMakeFiles/dlib_python.dir/src/other.cpp.o
Building CXX object CMakeFiles/dlib_python.dir/src/basic.cpp.o
Building CXX object CMakeFiles/dlib_python.dir/src/dlib.cpp.o
[ 83%] Building CXX object CMakeFiles/dlib_python.dir/src/matrix.cpp.o
Building CXX object CMakeFiles/dlib_python.dir/src/decision_functions.cpp.o
[ 84%] Building CXX object CMakeFiles/dlib_python.dir/src/cca.cpp.o
[ 86%] Building CXX object CMakeFiles/dlib_python.dir/src/sequence_segmenter.cpp.o
[ 87%] Building CXX object CMakeFiles/dlib_python.dir/src/svm_struct.cpp.o
[ 88%] Building CXX object CMakeFiles/dlib_python.dir/src/image.cpp.o
[ 89%] Building CXX object CMakeFiles/dlib_python.dir/src/rectangles.cpp.o
[ 90%] Building CXX object CMakeFiles/dlib_python.dir/src/object_detection.cpp.o
[ 91%] Building CXX object CMakeFiles/dlib_python.dir/src/shape_predictor.cpp.o
[ 93%] Building CXX object CMakeFiles/dlib_python.dir/src/correlation_tracker.cpp.o
[ 94%] Building CXX object CMakeFiles/dlib_python.dir/src/face_recognition.cpp.o
[ 95%] Building CXX object CMakeFiles/dlib_python.dir/src/cnn_face_detector.cpp.o
[ 96%] Building CXX object CMakeFiles/dlib_python.dir/src/global_optimization.cpp.o
[ 97%] Building CXX object CMakeFiles/dlib_python.dir/src/image_dataset_metadata.cpp.o
[ 98%] Building CXX object CMakeFiles/dlib_python.dir/src/numpy_returns.cpp.o
[100%] Building CXX object CMakeFiles/dlib_python.dir/src/gui.cpp.o
Linking CXX shared module /home/paperspace/projects/dlib/build/lib.linux-x86_64-3.6/dlib.cpython-36m-x86_64-linux-gnu.so
[100%] Built target dlib_python
creating build/bdist.linux-x86_64
creating build/bdist.linux-x86_64/egg
copying build/lib.linux-x86_64-3.6/dlib.cpython-36m-x86_64-linux-gnu.so -> build/bdist.linux-x86_64/egg
creating stub loader for dlib.cpython-36m-x86_64-linux-gnu.so
byte-compiling build/bdist.linux-x86_64/egg/dlib.py to dlib.cpython-36.pyc
creating build/bdist.linux-x86_64/egg/EGG-INFO
copying dlib.egg-info/PKG-INFO -> build/bdist.linux-x86_64/egg/EGG-INFO
copying dlib.egg-info/SOURCES.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
copying dlib.egg-info/dependency_links.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
copying dlib.egg-info/not-zip-safe -> build/bdist.linux-x86_64/egg/EGG-INFO
copying dlib.egg-info/top_level.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
writing build/bdist.linux-x86_64/egg/EGG-INFO/native_libs.txt
creating 'dist/dlib-19.9.99-py3.6-linux-x86_64.egg' and adding 'build/bdist.linux-x86_64/egg' to it
removing 'build/bdist.linux-x86_64/egg' (and everything under it)
Processing dlib-19.9.99-py3.6-linux-x86_64.egg
removing '/home/paperspace/anaconda3/lib/python3.6/site-packages/dlib-19.9.99-py3.6-linux-x86_64.egg' (and everything under it)
creating /home/paperspace/anaconda3/lib/python3.6/site-packages/dlib-19.9.99-py3.6-linux-x86_64.egg
Extracting dlib-19.9.99-py3.6-linux-x86_64.egg to /home/paperspace/anaconda3/lib/python3.6/site-packages
dlib 19.9.99 is already the active version in easy-install.pth
Installed /home/paperspace/anaconda3/lib/python3.6/site-packages/dlib-19.9.99-py3.6-linux-x86_64.egg
Processing dependencies for dlib==19.9.99
Finished processing dependencies for dlib==19.9.99
Add --no DLIB_USE_LAPACK
I did this python3 setup.py install --clean --no DLIB_USE_BLAS --no DLIB_USE_LAPACK
and import works now.
Will I be missing something as a result of this?
Some things will just run slower, but all features are still available.
Thanks this worked for me as well. I am also using paperspace ubuntu 14.
Warning: this issue has been inactive for 92 days and will be automatically closed on 2018-09-07 if there is no further activity.
If you are waiting for a response but haven't received one it's likely your question is somehow inappropriate. E.g. you didn't follow the issue submission instructions, or your question is easily answerable by reading the FAQ, dlib's documentation, or a Google search.
Notice: this issue has been closed because it has been inactive for 96 days. You may reopen this issue if it has been closed in error.
I have tried installing
dlib
on my Ubuntu 14.04 machine in two ways:pip install dlib
python3 setup.py install
In both case it installs fine. But in both cases when I import it get this error:
Here is the installation message when running
python3 setup.py install
:Output of
ldd dlib.cpython-36m-x86_64-linux-gnu.so
: