ahmetozlu / tensorflow_object_counting_api

🚀 The TensorFlow Object Counting API is an open source framework built on top of TensorFlow and Keras that makes it easy to develop object counting systems!
https://www.youtube.com/watch?v=yT_1eKJTdfk
MIT License
1.32k stars 545 forks source link

ImportError: DLL load failed: The specified module could not be found. #66

Closed SaadAhmed1122 closed 3 years ago

SaadAhmed1122 commented 4 years ago

runfile('C:/Users/Saad/tensorflow_object_counting_api-master/api/object_counting_api.py', wdir='C:/Users/Saad/tensorflow_object_counting_api-master/api') Traceback (most recent call last): File "C:\Users\Saad\tensorflow_object_counting_api-master\venv\lib\site-packages\tensorflow_core\python\pywrap_tensorflow.py", line 58, in from tensorflow.python.pywrap_tensorflow_internal import File "C:\Program Files\JetBrains\PyCharm 2018.3.1\helpers\pydev_pydev_bundle\pydev_import_hook.py", line 21, in do_import module = self._system_import(name, args, kwargs) File "C:\Users\Saad\tensorflow_object_counting_api-master\venv\lib\site-packages\tensorflow_core\python\pywrap_tensorflow_internal.py", line 28, in _pywrap_tensorflow_internal = swig_import_helper() File "C:\Users\Saad\tensorflow_object_counting_api-master\venv\lib\site-packages\tensorflow_core\python\pywrap_tensorflow_internal.py", line 24, in swig_import_helper _mod = imp.load_module('_pywrap_tensorflow_internal', fp, pathname, description) File "C:\Users\Saad\AppData\Local\Programs\Python\Python35\lib\imp.py", line 242, in load_module return load_dynamic(name, filename, file) File "C:\Users\Saad\AppData\Local\Programs\Python\Python35\lib\imp.py", line 342, in load_dynamic return _load(spec) ImportError: DLL load failed: The specified module could not be found. During handling of the above exception, another exception occurred: Traceback (most recent call last): File "", line 1, in File "C:\Program Files\JetBrains\PyCharm 2018.3.1\helpers\pydev_pydev_bundle\pydev_umd.py", line 197, in runfile pydev_imports.execfile(filename, global_vars, local_vars) # execute the script File "C:\Program Files\JetBrains\PyCharm 2018.3.1\helpers\pydev_pydev_imps_pydev_execfile.py", line 18, in execfile exec(compile(contents+"\n", file, 'exec'), glob, loc) File "C:/Users/Saad/tensorflow_object_counting_api-master/api/object_counting_api.py", line 7, in import tensorflow as tf File "C:\Program Files\JetBrains\PyCharm 2018.3.1\helpers\pydev_pydev_bundle\pydev_import_hook.py", line 21, in do_import module = self._system_import(name, *args, kwargs) File "C:\Users\Saad\tensorflow_object_counting_api-master\venv\lib\site-packages\tensorflow__init__.py", line 101, in from tensorflow_core import File "C:\Program Files\JetBrains\PyCharm 2018.3.1\helpers\pydev_pydev_bundle\pydev_import_hook.py", line 21, in do_import module = self._system_import(name, args, kwargs) File "C:\Users\Saad\tensorflow_object_counting_api-master\venv\lib\site-packages\tensorflow_core__init__.py", line 40, in from tensorflow.python.tools import module_util as _module_util File "C:\Program Files\JetBrains\PyCharm 2018.3.1\helpers\pydev_pydev_bundle\pydev_import_hook.py", line 21, in do_import module = self._system_import(name, *args, kwargs) File "C:\Users\Saad\tensorflow_object_counting_api-master\venv\lib\site-packages\tensorflow__init.py", line 50, in getattr module = self._load() File "C:\Users\Saad\tensorflow_object_counting_api-master\venv\lib\site-packages\tensorflow__init__.py", line 44, in _load module = _importlib.import_module(self.name) File "C:\Users\Saad\AppData\Local\Programs\Python\Python35\lib\importlib\init.py", line 126, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "C:\Users\Saad\tensorflow_object_counting_api-master\venv\lib\site-packages\tensorflow_core\python\init__.py", line 49, in from tensorflow.python import pywrap_tensorflow File "C:\Program Files\JetBrains\PyCharm 2018.3.1\helpers\pydev_pydev_bundle\pydev_import_hook.py", line 21, in do_import module = self._system_import(name, *args, *kwargs) File "C:\Program Files\JetBrains\PyCharm 2018.3.1\helpers\pydev_pydev_bundle\pydev_import_hook.py", line 21, in do_import module = self._system_import(name, args, kwargs) File "C:\Users\Saad\tensorflow_object_counting_api-master\venv\lib\site-packages\tensorflow_core\python\pywrap_tensorflow.py", line 74, in raise ImportError(msg) ImportError: Traceback (most recent call last): File "C:\Users\Saad\tensorflow_object_counting_api-master\venv\lib\site-packages\tensorflow_core\python\pywrap_tensorflow.py", line 58, in from tensorflow.python.pywrap_tensorflow_internal import File "C:\Program Files\JetBrains\PyCharm 2018.3.1\helpers\pydev_pydev_bundle\pydev_import_hook.py", line 21, in do_import module = self._system_import(name, args, kwargs) File "C:\Users\Saad\tensorflow_object_counting_api-master\venv\lib\site-packages\tensorflow_core\python\pywrap_tensorflow_internal.py", line 28, in _pywrap_tensorflow_internal = swig_import_helper() File "C:\Users\Saad\tensorflow_object_counting_api-master\venv\lib\site-packages\tensorflow_core\python\pywrap_tensorflow_internal.py", line 24, in swig_import_helper _mod = imp.load_module('_pywrap_tensorflow_internal', fp, pathname, description) File "C:\Users\Saad\AppData\Local\Programs\Python\Python35\lib\imp.py", line 242, in load_module return load_dynamic(name, filename, file) File "C:\Users\Saad\AppData\Local\Programs\Python\Python35\lib\imp.py", line 342, in load_dynamic return _load(spec) ImportError: DLL load failed: The specified module could not be found. Failed to load the native TensorFlow runtime. See https://www.tensorflow.org/install/errors for some common reasons and solutions. Include the entire stack trace above this error message when asking for help.

bidyutchanda commented 4 years ago

This happens due to incorrect installation of tensorflow.

If you are using tensorflow-gpu, then you need exactly compatible versions of CUDA and CuDNN (if your GPU is manufactured by NVIDIA).

SaadAhmed1122 commented 4 years ago

I am using cpu tensorflow 2 anaconda....

On Fri, Mar 6, 2020, 3:46 PM Bidyudipta Chanda notifications@github.com wrote:

This happens due to incorrect installation of tensorflow.

If you are using tensorflow-gpu, then you need exactly compatible versions of CUDA and CuDNN (if your GPU is manufactured by NVIDIA).

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/ahmetozlu/tensorflow_object_counting_api/issues/66?email_source=notifications&email_token=AN5PU5HMRP3LCVKBKFABBDDRGDH73A5CNFSM4KLQ4BDKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEOA5RJY#issuecomment-595712167, or unsubscribe https://github.com/notifications/unsubscribe-auth/AN5PU5DWZ2UQB3M7WQDLPGTRGDH73ANCNFSM4KLQ4BDA .

ahmetozlu commented 3 years ago

Please check this.