本文介绍了AttributeError:尝试使用TensorBoard时,模块'tensorboard.util'没有属性'PersistentOpEvaluator'的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我使用张量板制作了一些日志文件,但是我无法访问它们.
I made some log files using tensorboard but I can't access them.
使用
tensorboard
或tensorboard --logdir=logs/
出现以下错误:-
C:\Users\User>tensorboard
Traceback (most recent call last):
File "C:\Users\User\Anaconda3\Scripts\tensorboard-script.py", line 6, in <module>
from tensorboard.main import run_main
File "C:\Users\User\Anaconda3\lib\site-packages\tensorboard\main.py", line 40, in <module>
from tensorboard import default
File "C:\Users\User\Anaconda3\lib\site-packages\tensorboard\default.py", line 38, in <module>
from tensorboard.plugins.beholder import beholder_plugin
File "C:\Users\User\Anaconda3\lib\site-packages\tensorboard\plugins\beholder\__init__.py", line 15, in <module>
from tensorboard.plugins.beholder.beholder import Beholder
File "C:\Users\User\Anaconda3\lib\site-packages\tensorboard\plugins\beholder\beholder.py", line 25, in <module>
from tensorboard.plugins.beholder import im_util
File "C:\Users\User\Anaconda3\lib\site-packages\tensorboard\plugins\beholder\im_util.py", line 89, in <module>
class PNGDecoder(util.PersistentOpEvaluator):
AttributeError: module 'tensorboard.util' has no attribute 'PersistentOpEvaluator'
我尝试了解决方案,但是它没有帮助.
I tried this solution, but it did not help.
推荐答案
我也为此问题付出了很大的努力.最终对我有用的是:
I also had a big fight with this problem. What eventually worked for me was the following:
- pip卸载tensorflow
- pip卸载tensorboard
- conda show或pip show->看一下您安装了哪些其他与tensorflow相关的软件包并将其删除.
- 转到站点软件包并删除tensorflow/tensorboard文件夹(在文件系统中查找与tensorflow/tensorboard安装相关的任何文件夹)
- conda clean --all(不确定是否有必要,但这是其中之一)我的步骤,可能与之相关)
- 重新安装tensorflow和tensorboard.最好使用conda,因为它可通过几个数量级
- pip uninstall tensorflow
- pip uninstall tensorboard
- conda show OR pip show --> have a look at which other tensorflow related packages you have installed and remove them.
- Go to site-packages and remove tensorflow/tensorboard folders (look for any folder in your filesystem related to a tensorflow / tensorboard installation)
- conda clean --all (not sure if this is necessary, but it was one ofmy steps and might be relevant)
- Reinstall tensorflow and tensorboard. Preferably use conda as it is faster by several orders of magnitude
我解决这个问题的主要来源之一是这个github问题线程: https://github.com/tensorflow/tensorboard/issues/1724
One of my main sources in solving this issue was this github issue thread:https://github.com/tensorflow/tensorboard/issues/1724
这篇关于AttributeError:尝试使用TensorBoard时,模块'tensorboard.util'没有属性'PersistentOpEvaluator'的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!