Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Accessing Tensorboard on AWS

I'm trying to access Tensorboard on AWS. Here is my setting :

  • Tensorboard : tensorboard --host 0.0.0.0 --logdir=train :

Starting TensorBoard b'39' on port 6006 (You can navigate to http://172.31.18.170:6006)

  • AWS Security groups (in):
    • HTTPS TCP 443 0.0.0.0/0
    • Custom_TCP TCP 6006 0.0.0.0/0

However connecting to ec2-blabla.us-west-1.compute.amazonaws.com:6006 I can't see anything, I basically can't connect.

Do you have any idea?

like image 597
ted Avatar asked Feb 16 '17 14:02

ted


People also ask

Can I use TensorFlow on AWS?

AWS provides broad support for TensorFlow, enabling customers to develop and serve their own models across computer vision, natural language processing, speech translation, and more.

What is the use of TensorBoard?

TensorBoard is a tool for providing the measurements and visualizations needed during the machine learning workflow. It enables tracking experiment metrics like loss and accuracy, visualizing the model graph, projecting embeddings to a lower dimensional space, and much more.


2 Answers

You can use ssh tunneling technique.

In your terminal you can write:

ssh -i /path/to/your/AWS/key/file -NL 6006:localhost:6006 user@host

where user and host are your aws ec2 user and instance specific.

After that you can browse to http://localhost:6006/

like image 198
alexopoulos7 Avatar answered Nov 02 '22 05:11

alexopoulos7


  1. Run tensorboard in your ec2 terminal (you can custom logdir and port)

    tensorboard --logdir=data/model --port=8080
    
  2. Find your workstations public ip (a.b.c.d) address by visiting http://ip4.me/

  3. Access the security group configuration assigned to your EC2 and add a custom TCP rule to your inbound traffic.

    Security group inbound traffic configuration

  4. Outbound should be set to allow traffic from tensorboard port. (In this case 8080). Or you just allow all outgoing traffic from your EC2 instance

    Protocol       Port Range      Destination      Description   
    All traffic    All             All               0.0.0.0/0
    
  5. Use your public DNS to access tensorboard from your workstation

    http://ec2-xx-xxx-xx-xx.compute-1.amazonaws.com:8080/

like image 20
Anthony Awuley Avatar answered Nov 02 '22 05:11

Anthony Awuley