0

很长一段时间以来,我一直面临着这个错误。我尝试了互联网上所有可能的解决方案。我正在为我的项目使用 tensorflow 1.14.0 并面临此错误。项目日期到期。请帮忙。我的 PC 规格:i5/8gb 内存/内置显卡

C:\Users\skshr\.virtualenvs\ThesisProject\Scripts\python.exe C:/ThesisProject/estimators/estimator.py
Traceback (most recent call last):
  File "C:\Users\skshr\.virtualenvs\ThesisProject\lib\site-packages\tensorflow\python\pywrap_tensorflow_internal.py", line 18, in swig_import_helper
    fp, pathname, description = imp.find_module('_pywrap_tensorflow_internal', [dirname(__file__)])
  File "C:\Users\skshr\AppData\Local\Programs\Python\Python38\lib\imp.py", line 296, in find_module
    raise ImportError(_ERR_MSG.format(name), name=name)
ImportError: No module named '_pywrap_tensorflow_internal'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:\Users\skshr\.virtualenvs\ThesisProject\lib\site-packages\tensorflow\python\pywrap_tensorflow.py", line 58, in <module>
    from tensorflow.python.pywrap_tensorflow_internal import *
  File "C:\Users\skshr\.virtualenvs\ThesisProject\lib\site-packages\tensorflow\python\pywrap_tensorflow_internal.py", line 28, in <module>
    _pywrap_tensorflow_internal = swig_import_helper()
  File "C:\Users\skshr\.virtualenvs\ThesisProject\lib\site-packages\tensorflow\python\pywrap_tensorflow_internal.py", line 20, in swig_import_helper
    import _pywrap_tensorflow_internal
ModuleNotFoundError: No module named '_pywrap_tensorflow_internal'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:/ThesisProject/estimators/estimator.py", line 5, in <module>
    import tensorflow as tf
  File "C:\Users\skshr\.virtualenvs\ThesisProject\lib\site-packages\tensorflow\__init__.py", line 28, in <module>
    from tensorflow.python import pywrap_tensorflow  # pylint: disable=unused-import
  File "C:\Users\skshr\.virtualenvs\ThesisProject\lib\site-packages\tensorflow\python\__init__.py", line 49, in <module>
    from tensorflow.python import pywrap_tensorflow
  File "C:\Users\skshr\.virtualenvs\ThesisProject\lib\site-packages\tensorflow\python\pywrap_tensorflow.py", line 74, in <module>
    raise ImportError(msg)
ImportError: Traceback (most recent call last):
  File "C:\Users\skshr\.virtualenvs\ThesisProject\lib\site-packages\tensorflow\python\pywrap_tensorflow_internal.py", line 18, in swig_import_helper
    fp, pathname, description = imp.find_module('_pywrap_tensorflow_internal', [dirname(__file__)])
  File "C:\Users\skshr\AppData\Local\Programs\Python\Python38\lib\imp.py", line 296, in find_module
    raise ImportError(_ERR_MSG.format(name), name=name)
ImportError: No module named '_pywrap_tensorflow_internal'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:\Users\skshr\.virtualenvs\ThesisProject\lib\site-packages\tensorflow\python\pywrap_tensorflow.py", line 58, in <module>
    from tensorflow.python.pywrap_tensorflow_internal import *
  File "C:\Users\skshr\.virtualenvs\ThesisProject\lib\site-packages\tensorflow\python\pywrap_tensorflow_internal.py", line 28, in <module>
    _pywrap_tensorflow_internal = swig_import_helper()
  File "C:\Users\skshr\.virtualenvs\ThesisProject\lib\site-packages\tensorflow\python\pywrap_tensorflow_internal.py", line 20, in swig_import_helper
    import _pywrap_tensorflow_internal
ModuleNotFoundError: No module named '_pywrap_tensorflow_internal'


Failed to load the native TensorFlow runtime.

See https://www.tensorflow.org/install/errors
4

1 回答 1

0

您是否尝试过删除 TensorFlow 并更改您的 TF 版本?例如,到 1.15?

于 2020-12-29T15:13:05.377 回答