简体   繁体   English

无法从 jupyter 启动张量板

[英]Failing to launch tensorboard from jupyter

I get the error below when I try launching tensorboard from my jupyter notebook .当我尝试从jupyter notebook启动tensorboard时,出现以下错误。 I am using a conda environment and using the env-specific kernel since tensorflow is only installed in my environment.我正在使用conda environment并使用特定于 env 的内核,因为tensorflow仅安装在我的环境中。 What am I doing wrong?我究竟做错了什么?

The error:错误:

%tensorboard --logdir logs

ERROR: Failed to launch TensorBoard (exited with -6).
Contents of stderr:
[libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/descriptor_database.cc:393] Invalid file descriptor data passed to EncodedDescriptorDatabase::Add().
[libprotobuf FATAL external/com_google_protobuf/src/google/protobuf/descriptor.cc:1367] CHECK failed: GeneratedDatabase()->Add(encoded_file_descriptor, size): 
libc++abi.dylib: terminating with uncaught exception of type google::protobuf::FatalException: CHECK failed: GeneratedDatabase()->Add(encoded_file_descriptor, size):

EDIT编辑

I have the problem even when I try launching from the terminal (inside my conda env ):即使我尝试从终端启动(在我的conda env ),我也遇到了问题:

tensorboard --logdir = 'logs/'

[libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/descriptor_database.cc:393] Invalid file descriptor data passed to EncodedDescriptorDatabase::Add().
[libprotobuf FATAL external/com_google_protobuf/src/google/protobuf/descriptor.cc:1367] CHECK failed: GeneratedDatabase()->Add(encoded_file_descriptor, size): 
libc++abi.dylib: terminating with uncaught exception of type google::protobuf::FatalException: CHECK failed: GeneratedDatabase()->Add(encoded_file_descriptor, size): 
Abort trap: 6

I found the following solution.我找到了以下解决方案。 Apparently this is a specific issue that occurs when running macOS Catalina , and can be solved by switching to protobuf version 3.8.0 .显然,这是运行macOS Catalina时出现的特定问题,可以通过切换到protobuf version 3.8.0来解决。 So basically uninstalling tensorflow and protobuf and re-installing with protobuf = 3.8.0 .所以基本上卸载tensorflowprotobuf并使用protobuf = 3.8.0重新安装。 I found this answer here , check it out for further info.我在这里找到了这个答案,查看更多信息。

conda update protobuf solved it for me. conda update protobuf为我解决了这个问题。 I assume you can also use pip the upgrade, but I didn't try我假设您也可以使用 pip 升级,但我没有尝试

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM