Search code examples
tensorflowtensorboard

tensorboard: command not found


I installed TensorFlow on my MacBook Pro 10.12.5 from source code by steps described here. https://www.tensorflow.org/install/install_sources

TensorFlow itself works well but I cannot run TensorBoard. It seems tensorboard is not installed properly.

When I try running tensorboard --logdir=... it says -bash: tensorboard: command not found. And locate tensorboard returns empty.

Do I need any additional step to install tensorboard?


Solution

  • If no other methods work then try this one. It may help you.
    1. check the location of Tensorflow

    pip show tensorflow
    

    It will show output something like this.
    ...
    Name: tensorflow
    Version: 1.4.0
    Location: /home/abc/xy/.local/lib/python2.7/site-packages
    ...
    2. Go to that location you get from the above output.

    cd /home/abc/xy/.local/lib/python2.7/site-packages
    

    There you can see a directory named tensorboard.

    cd tensorboard
    

    3. There must be a file named 'main.py'.
    4. Execute the following command to launch the tensorboard.

    python main.py --logdir=/path/to/log_file/