question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

cannot import name 'event_pb2'

See original GitHub issue

Describe the bug When install from the source code by running python setup.py install, it shows that cannot import name ‘event_pb2’ when import tensorboardX. Running pip install -e . can solve this.

Minimal runnable code to reproduce the behavior

import tensorboardX
...

Environment protobuf 3.7.1
tensorboard 1.10.0
tensorboardX 1.7+e932310
tensorflow 1.10.0
tensorflow-estimator 1.13.0
tensorflow-tensorboard 1.5.1
torch 1.1.0
torchvision 0.3.0

Ubuntu 18.04 LTS

Issue Analytics

  • State:open
  • Created 4 years ago
  • Comments:12 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
wangj346commented, Mar 1, 2020

i find the way to solve it. cannot use "pip install -e . " to install the environment. if you do so, the file ‘event_pd2’ will be deleted. you can unzip the zip file and find it in /tensorboardX/proto . copy it and solve or just use python setup.py install to install in first time.

1reaction
wqduncommented, Mar 2, 2020

Met the “cannot import name ‘event_pb2’” issue, on jetson TX2 (arm platform); I installed v1.8 and v1.9 from source, problem remained; Using the v1.7 solved it, wish this could help. Command is git clone --recursive --branch=v1.7 https://github.com/wqdun/tensorboardX.git

Read more comments on GitHub >

github_iconTop Results From Across the Web

Why do I see "cannot import name descriptor_pb2" error when ...
I checked in the protobuf\python\google\protobuf directory for descriptor_pb2.py but only found descriptor.py - we're using the latest version, so I assume we ...
Read more >
How to Fix ImportError: Cannot Import Name in Python - Rollbar
The Python ImportError: cannot import name error occurs when an imported class is not accessible or is in a circular dependency.
Read more >
How to fix this Import error problem when training a model in ...
TypeError: Descriptors cannot not be created directly. If this call came from a _pb2.py file, your generated code is out of date and...
Read more >
cannot import name 'Event' in Dash from plotly (python)?
Event was removed in the latest version (0.37 ) of Dash, that's why you cannot import it. See dev comment. If you're bent...
Read more >
1383513 – ImportError: cannot import name Event
Description of problem: Cannot start rtlsdr-scanner app ... in <module> from events import Event ImportError: cannot import name Event.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found