简体   繁体   中英

Tensorboard TypeError: __init__() got an unexpected keyword argument 'file'

I'm starting tensorboard 1.8.0 in cmd using tensorboard --logdir=I:\\logs . The error:

I:\> tensorboard --logdir=I:\logs
Traceback (most recent call last):
  File "c:\python35\lib\runpy.py", line 184, in _run_module_as_main
    "__main__", mod_spec)
  File "c:\python35\lib\runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "C:\Users\Administrator\AppData\Roaming\Python\Python35\Scripts\tensorboard.exe\__main__.py", line 5, in <module>
  File "C:\Users\Administrator\AppData\Roaming\Python\Python35\site-packages\tensorboard\main.py", line 30, in <module>
    from tensorboard import default
  File "C:\Users\Administrator\AppData\Roaming\Python\Python35\site-packages\tensorboard\default.py", line 35, in <module>
    from tensorboard.plugins.audio import audio_plugin
  File "C:\Users\Administrator\AppData\Roaming\Python\Python35\site-packages\tensorboard\plugins\audio\audio_plugin.py", line 30, in <module>
    from tensorboard.plugins.audio import metadata
  File "C:\Users\Administrator\AppData\Roaming\Python\Python35\site-packages\tensorboard\plugins\audio\metadata.py", line 22, in <module>
    from tensorboard.plugins.audio import plugin_data_pb2
  File "C:\Users\Administrator\AppData\Roaming\Python\Python35\site-packages\tensorboard\plugins\audio\plugin_data_pb2.py", line 63, in <module>
    options=None, file=DESCRIPTOR),
TypeError: __init__() got an unexpected keyword argument 'file'

尝试升级protobuf

pip install --upgrade protobuf

I have had the same error. Installing tensorflow==1.8.0 into the same env helps me. Now this works for me on Windows 10. And training on GPU still works.

pip freeze

absl-py==0.2.0                                                                                                                      
astor==0.6.2                                                                                                            
bleach==1.5.0                                                                                                           
certifi==2018.4.16                                                                                                      
gast==0.2.0                                                                                                             
grpcio==1.11.0                                                                                                          
h5py==2.7.1                                                                                                             
html5lib==0.9999999                                                                                                     
Keras==2.1.6                                                                                                            
Markdown==2.6.11                                                                                                        
numpy==1.14.3                                                                                                           
olefile==0.45.1                                                                                                         
Pillow==4.2.1                                                                                                           
protobuf==3.5.2.post1                                                                                                   
PyYAML==3.12                                                                                                            
scipy==1.0.0                                                                                                            
Shapely==1.6.2                                                                                                          
six==1.11.0                                                                                                             
tensorboard==1.8.0                                                                                                      
tensorflow==1.8.0                                                                                                       
tensorflow-gpu==1.8.0                                                                                                   
termcolor==1.1.0                                                                                                        
Werkzeug==0.14.1                                                                                                        
wincertstore==0.2    

Sorry for redundant modules...

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

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