尝试在 Jupyter Notebook 中打开 TensorBoard 时出错?
Posted
技术标签:
【中文标题】尝试在 Jupyter Notebook 中打开 TensorBoard 时出错?【英文标题】:Having an error while trying to open TensorBoard in Jupyter Notebook? 【发布时间】:2020-10-15 00:03:34 【问题描述】:错误:无法启动 TensorBoard(以 1 退出)。
Contents of stderr:<br />
Traceback (most recent call last):<br />
File "c:\python38\lib\runpy.py", line 193, in _run_module_as_main<br />
return _run_code(code, main_globals, None,<br />
File "c:\python38\lib\runpy.py", line 86, in _run_code<br />
exec(code, run_globals)<br />
File "C:\Python38\Scripts\tensorboard.exe\__main__.py", line 4, in <module><br />
File "c:\python38\lib\site-packages\tensorboard\main.py", line 43, in <module><br />
from tensorboard import default<br />
File "c:\python38\lib\site-packages\tensorboard\default.py", line 39, in <module><br />
from tensorboard.plugins.audio import audio_plugin<br />
File "c:\python38\lib\site-packages\tensorboard\plugins\audio\audio_plugin.py", line 28, in <module><br />
from tensorboard.data import provider<br />
File "c:\python38\lib\site-packages\tensorboard\data\__init__.py", line 20, in <module><br />
from tensorboard.data import experimental<br />
File "c:\python38\lib\site-packages\tensorboard\data\experimental\__init__.py", line 20, in <module><br />
from tensorboard.data.experimental.experiment_from_dev import ExperimentFromDev<br />
File "c:\python38\lib\site-packages\tensorboard\data\experimental\experiment_from_dev.py", line 25, in <module><br />
import grpc<br />
ModuleNotFoundError: No module named 'grpc'<br />
我尝试运行“pip install grpc”,但找不到具有该名称的模块。对于一些背景信息,我没有 Nvidia GPU,以防万一。
编辑:“python -m pip install grpcio”解决了我的问题。但是,我现在遇到了一个新错误。
ERROR: Failed to launch TensorBoard (exited with 1).
Contents of stderr:
2020-06-24 11:42:16.160102: W tensorflow/stream_executor/platform/default/dso_loader.cc:55] Could not load dynamic library 'cudart64_101.dll'; dlerror: cudart64_101.dll not found
2020-06-24 11:42:16.166831: I tensorflow/stream_executor/cuda/cudart_stub.cc:29] Ignore above cudart dlerror if you do not have a GPU set up on your machine.
Traceback (most recent call last):
File "c:\python38\lib\runpy.py", line 193, in _run_module_as_main
return _run_code(code, main_globals, None,
File "c:\python38\lib\runpy.py", line 86, in _run_code
exec(code, run_globals)
File "C:\Python38\Scripts\tensorboard.exe\__main__.py", line 7, in <module>
File "c:\python38\lib\site-packages\tensorboard\main.py", line 75, in run_main
app.run(tensorboard.main, flags_parser=tensorboard.configure)
File "c:\python38\lib\site-packages\absl\app.py", line 299, in run
_run_main(main, args)
File "c:\python38\lib\site-packages\absl\app.py", line 250, in _run_main
sys.exit(main(argv))
File "c:\python38\lib\site-packages\tensorboard\program.py", line 290, in main
return runner(self.flags) or 0
File "c:\python38\lib\site-packages\tensorboard\program.py", line 306, in _run_serve_subcommand
server = self._make_server()
File "c:\python38\lib\site-packages\tensorboard\program.py", line 411, in _make_server
app = application.TensorBoardWSGIApp(
File "c:\python38\lib\site-packages\tensorboard\backend\application.py", line 128, in TensorBoardWSGIApp
return TensorBoardWSGI(
File "c:\python38\lib\site-packages\tensorboard\backend\application.py", line 225, in __init__
raise ValueError(
ValueError: Duplicate plugins for name projector
【问题讨论】:
【参考方案1】:你试过了吗:
python -m pip install grpcio
并且可能
python -m pip install grpcio-tools
website
【讨论】:
以上是关于尝试在 Jupyter Notebook 中打开 TensorBoard 时出错?的主要内容,如果未能解决你的问题,请参考以下文章
Jupyter Notebook 无法在 Ubuntu WSL2 中打开
Jupyter Lab 在错误的路径中打开,与 Jupyter Notebook 不同,两者在“jupyter_notebook_config.py”中具有相同的映射。