natethegreate / hent-AI

Automation of censor bar detection
MIT License
1.58k stars 145 forks source link

ImportError: libcublas.so.9.0: cannot open shared object file: No such file or directory #6

Closed Commod0re-github closed 4 years ago

Commod0re-github commented 4 years ago

Hello! I realy proud that our cyber-samuraies fighting with censore! I wish you success! But i have problem:

  1. System: Parrot OS
  2. I installed setup.py successfully
  3. I launched main.py ERROR

┌─[root@parrot]─[/home/user/Desktop/hent-AI] └──╼ #python main.py Traceback (most recent call last): File "main.py", line 14, in from detector import Detector File "/home/user/Desktop/hent-AI/detector.py", line 23, in from mrcnn import model as modellib, utils File "/home/user/Desktop/hent-AI/mrcnn/model.py", line 19, in import tensorflow as tf File "/usr/local/lib/python2.7/dist-packages/tensorflow/init.py", line 22, in from tensorflow.python import pywrap_tensorflow # pylint: disable=unused-import File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/init.py", line 49, in from tensorflow.python import pywrap_tensorflow File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/pywrap_tensorflow.py", line 74, in raise ImportError(msg) ImportError: Traceback (most recent call last): File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/pywrap_tensorflow.py", line 58, in from tensorflow.python.pywrap_tensorflow_internal import * File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/pywrap_tensorflow_internal.py", line 28, in _pywrap_tensorflow_internal = swig_import_helper() File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/pywrap_tensorflow_internal.py", line 24, in swig_import_helper _mod = imp.load_module('_pywrap_tensorflow_internal', fp, pathname, description) ImportError: libcublas.so.9.0: cannot open shared object file: No such file or directory

Failed to load the native TensorFlow runtime.

See https://www.tensorflow.org/install/install_sources#common_installation_problems

for some common reasons and solutions. Include the entire stack trace above this error message when asking for help.

Please Help me.

Commod0re-github commented 4 years ago

After googling problem, installing tensorflow-gpu==1.4, i had the same problem, but with another lib.

┌─[root@parrot]─[/home/user/Desktop/hent-AI] └──╼ #python main.py Traceback (most recent call last): File "main.py", line 14, in from detector import Detector File "/home/user/Desktop/hent-AI/detector.py", line 23, in from mrcnn import model as modellib, utils File "/home/user/Desktop/hent-AI/mrcnn/model.py", line 19, in import tensorflow as tf File "/usr/local/lib/python2.7/dist-packages/tensorflow/init.py", line 24, in from tensorflow.python import File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/init.py", line 49, in from tensorflow.python import pywrap_tensorflow File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/pywrap_tensorflow.py", line 72, in raise ImportError(msg) ImportError: Traceback (most recent call last): File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/pywrap_tensorflow.py", line 58, in from tensorflow.python.pywrap_tensorflow_internal import File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/pywrap_tensorflow_internal.py", line 28, in _pywrap_tensorflow_internal = swig_import_helper() File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/pywrap_tensorflow_internal.py", line 24, in swig_import_helper _mod = imp.load_module('_pywrap_tensorflow_internal', fp, pathname, description) ImportError: libcublas.so.8.0: cannot open shared object file: No such file or directory

Failed to load the native TensorFlow runtime.

See https://www.tensorflow.org/install/install_sources#common_installation_problems

for some common reasons and solutions. Include the entire stack trace above this error message when asking for help.

Commod0re-github commented 4 years ago

heh. After executing pip install tensorflow --ignore-installed:

New type of error:

┌─[root@parrot]─[/home/user/Desktop/hent-AI] └──╼ #python main.py 2020-03-20 22:39:33.537162: W tensorflow/stream_executor/platform/default/dso_loader.cc:55] Could not load dynamic library 'libnvinfer.so.6'; dlerror: libnvinfer.so.6: cannot open shared object file: No such file or directory; LD_LIBRARY_PATH: :/usr/local/cuda-9.0/lib64/:/usr/local/cuda/lib64/:/usr/local/cuda-8.0/lib64/ 2020-03-20 22:39:33.537295: W tensorflow/stream_executor/platform/default/dso_loader.cc:55] Could not load dynamic library 'libnvinfer_plugin.so.6'; dlerror: libnvinfer_plugin.so.6: cannot open shared object file: No such file or directory; LD_LIBRARY_PATH: :/usr/local/cuda-9.0/lib64/:/usr/local/cuda/lib64/:/usr/local/cuda-8.0/lib64/ 2020-03-20 22:39:33.537312: W tensorflow/compiler/tf2tensorrt/utils/py_utils.cc:30] Cannot dlopen some TensorRT libraries. If you would like to use Nvidia GPU with TensorRT, please make sure the missing libraries mentioned above are installed properly. Using TensorFlow backend. Traceback (most recent call last): File "main.py", line 14, in from detector import Detector File "/home/user/Desktop/hent-AI/detector.py", line 23, in from mrcnn import model as modellib, utils File "/home/user/Desktop/hent-AI/mrcnn/model.py", line 20, in import keras File "/usr/local/lib/python2.7/dist-packages/keras/init.py", line 5, in from . import applications File "/usr/local/lib/python2.7/dist-packages/keras/applications/init.py", line 13, in keras_applications.set_keras_submodules( AttributeError: 'module' object has no attribute 'set_keras_submodules'

natethegreate commented 4 years ago

I'm assuming you have some Nvidia, CUDA compatible card. You will need to install cuda 9.0 from Nvidia. After installing that, also uninstall the normal tensorflow and uninstall protobuf.

I would also uninstall, and reinstall tensorflow-gpu 1.9.0 after all this just in case.

This was just solved recently, I will also update the installation and tutorial instructions soon.