1

I want to run a tenosorboard.dev using the following bash file.

#!/bin/bash
#SBATCH -c 1
#SBATCH -N 1
#SBATCH -t 50:00:00
#SBATCH -p medium
#SBATCH --mem=4G
#SBATCH -o hostname_tensorboard_%j.out
#SBATCH -e hostname_tensorboard_%j.err

module load python/3.7.4 conda2/4.2.13

source activate env_tf

echo y | tensorboard dev upload --logdir="mydir"

I need to authorize it with my google account when I recieve the following massage.

Continue? (yes/NO) Please visit this URL to authorize this application:
 https://accounts.google.com/o/oauth2/auth?response_type=code&client_id=***

How can I do it? Thanks in advance.

  • Did you try to authorize yourself through the URL link? Did it work? Or what problem do you want to solve? – Ladislav Ondris Oct 05 '20 at 23:47
  • I can authorize myself through the link but the problem is that when I use sbatch I cannot enter anything anymore. Everything has to be done through the bash file. – ehsan olyaee Oct 07 '20 at 16:49

1 Answers1

2

Not familiar with sbatch, but when you authorize tensorboard, it creates a file so that you can upload afterwards without re-authorizing. You should be able to manually copy that file into the environment in which you will be uploading in the future.

On my workstation, the credentials file is

~/.config/tensorboard/credentials/uploader-creds.json

BlessedKey
  • 1,615
  • 1
  • 10
  • 16