AttributeError: module ‘setuptools._distutils’ has no attribute ‘version’
pytorch tensorboard error: AttributeError: module ‘setuptools._distutils’ has no attribute ‘version’
from torch.utils.tensorboard import SummaryWriter
writer=SummaryWriter("logs")
# writer.add_image()
#y=x
for i in range(100):
writer.add_scalar("y=x",i,i)
writer.close()
Cause of problem:
Setuptools version too high
Solution:
Install lower version setuptools
Enter:
PIP uninstall setuptools
PIP install setuptools = = 59.5.0// it needs to be lower than your previous version
Read More:
- [Solved] AttributeError: module ‘distutils‘ has no attribute ‘version‘
- [Solved] Pytorch call tensorboard error: AttributeError: module ‘tensorflow’ has no attribute ‘gfile’
- [How to Solve]AttributeError: module ‘scipy’ has no attribute ‘io’
- [Solved] AttributeError: module ‘PIL.Image‘ has no attribute ‘open‘
- AttributeError: module ‘enum‘ has no attribute ‘IntFlag‘ [How to Solve]
- AttributeError: module ‘time‘ has no attribute ‘clock‘ [How to Solve]
- [Solved]AttributeError: module ‘urllib’ has no attribute ‘quote’
- [Solved] AttributeError: partially initialized module ‘xlwings’ has no attribute ‘App’
- [Solved] AttributeError: module ‘time‘ has no attribute ‘clock‘
- [Solved] AttributeError: module ‘logging‘ has no attribute ‘Handler‘
- [Perfectly Solved] attributeerror: module ‘SciPy. Misc’ has no attribute ‘toimage’ error
- [Solved] AttributeError: module ‘tensorflow‘ has no attribute ‘distributions‘
- Python AttributeError: module ‘tensorflow‘ has no attribute ‘InteractiveSession‘
- [Solved] AttributeError: module ‘selenium.webdriver‘ has no attribute ‘Chrome‘
- Python3.7 AttributeError: module ‘time‘ has no attribute ‘clock‘
- [Solved] AttributeError: module ‘dlib‘ has no attribute ‘get_face_chip‘
- [Solved] AttributeError: module ‘pandas‘ has no attribute ‘rolling_count‘
- [Solved] Python Error: AttributeError: partially initialized module ‘keyword‘ has no attribute ‘kwlist‘
- How to Solve Python AttributeError: ‘module’ object has no attribute ‘xxx’
- [Solved] AttributeError: module ‘tensorflow._api.v2.train‘ has no attribute ‘AdampOptimizer‘