gpt4 book ai didi

python - Tensorflow 导入使 Python 在 Windows 上没有任何错误地崩溃

转载 作者:可可西里 更新时间:2023-11-01 09:44:15 29 4
gpt4 key购买 nike

昨天我试图解决 Windows 上的 matplotlib 问题,其中包括解决 from matplotlib import ft2font 错误。为此,我添加了 HDF5_DISABLE_VERSION_CHECK=2。但是今天我发现,tensorflow 不再起作用了:

> python                                                                                              
Python 3.5.5 |Anaconda, Inc.| (default, Apr 7 2018, 04:52:34) [MSC v.1900 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import tensorflow as tf

>

它思考 30 秒,然后没有任何错误地退出 Python。

我在哪里可以看到日志或崩溃转储之类的东西?

最佳答案

如果您尝试import h5py,并得到ImportError: DLL load failed,您可能遇到了和我一样的问题。尝试:

  1. Uninstall h5py via anaconda navigator, some relative libs (tensorflow) will be uninstalled as well.

  2. Go VM path in anaconda installation, D:\Anaconda\envs\YOUR_VM\Lib\site-packages, delete h5py and h5py-2.8.0-py3.6.egg-info folders

  3. Reinstall tensorflow or tensorflow-gpu

关于python - Tensorflow 导入使 Python 在 Windows 上没有任何错误地崩溃,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/53062798/

29 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com