Google Colab上的Tensorboard返回链接,但不执行任何操作

问题描述 投票:2回答:1

我一直在使用Google Colab进行Tensorflow API进行对象检测,目前,该模型已经过训练。我需要查看Tensorboard进行培训。

这是培训电话:

!python 'Object Detection/models/research/object_detection/legacy/train.py' --logtostderr --train_dir='Object Detection/Model'/ --pipeline_config_path='Object Detection/Faster_RCNN.config'

我尝试了以下命令,这些是它们的结果:

  1. !tensorboard --logdir='Object Detection/Model'

    TensorBoard 1.15.0 at http://cca84e64bb22:6006/ (Press CTRL+C to quit)

  2. %tensorboard --logdir='Object Detection/Model'

    显示Launching Tensorboard...几秒钟并结束

  3. %load_ext tensorboard

    The tensorboard extension is already loaded. To reload it, use: %reload_ext tensorboard

  4. %reload_ext tensorboard

    空白-无输出

  5. 我从'tensorboard_in_notebooks.ipynb'中找到了这个

from tensorboard import notebook
notebook.list()
notebook.display(port=6006, height=1000) 

Known TensorBoard instances: - port 6006: logdir /Object Detection/Model (started 0:07:12 ago; pid 795) Selecting TensorBoard with logdir Object Detection/Model (started 0:07:12 ago; port 6006, pid 795).

  1. LOG_DIR = 'Object Detection/Model'
    get_ipython().system_raw(
        'tensorboard --logdir {} --host 0.0.0.0 --port 6006 &'
        .format(LOG_DIR)
    )
    # Install
    ! npm install -g localtunnel
    
    # Tunnel port 6006 (TensorBoard assumed running)
    get_ipython().system_raw('lt --port 6006 >> url.txt 2>&1 &')
    
    # Get url
    ! cat url.txt
    

/tools/node/bin/lt -> /tools/node/lib/node_modules/localtunnel/bin/lt.js + [email protected] updated 1 package in 1.601s

创建的url.txt文件为空

tensorflow object-detection google-colaboratory tensorboard object-detection-api
1个回答
0
投票

替换

!tensorboard --logdir='Object Detection/Model'

with

%tensorboard --logdir='Object Detection/Model'
© www.soinside.com 2019 - 2024. All rights reserved.