无法从Jupyter启动Tensorboard

时间:2020-02-02 17:52:18

标签: python tensorflow jupyter-notebook tensorboard

当我尝试从tensorboard启动jupyter notebook时,出现以下错误。由于conda environment仅安装在我的环境中,因此我正在使用tensorflow并使用特定于环境的内核。我在做什么错了?

错误:

%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):

编辑

即使我尝试从终端(在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

2 个答案:

答案 0 :(得分:4)

我找到了以下解决方案。显然,这是在运行macOS Catalina时发生的特定问题,可以通过切换到protobuf version 3.8.0来解决。因此,基本上卸载tensorflowprotobuf并用protobuf = 3.8.0重新安装。我找到了这个答案here,请查看该答案以获取更多信息。

答案 1 :(得分:1)

conda update protobuf为我解决了该问题。我认为您也可以使用pip升级,但是我没有尝试