Jeeva Bharathi
Jeeva Bharathi

Reputation: 99

How to change the scope of existing VM in GCP?

I created a windows VM where I have the BERT master, SQUAD, and BERT-large model. I tried to run the squad using this:

python run_squad.py \
  --vocab_file=$BERT_LARGE_DIR/vocab.txt \
  --bert_config_file=$BERT_LARGE_DIR/bert_config.json \
  --init_checkpoint=$BERT_LARGE_DIR/bert_model.ckpt \
  --do_train=True \
  --train_file=$SQUAD_DIR/train-v2.0.json \
  --do_predict=True \
  --predict_file=$SQUAD_DIR/dev-v2.0.json \
  --train_batch_size=24 \
  --learning_rate=3e-5 \
  --num_train_epochs=2.0 \
  --max_seq_length=384 \
  --doc_stride=128 \
  --output_dir=gs://some_bucket/squad_large/ \
  --use_tpu=True \
  --tpu_name=$TPU_NAME \
  --version_2_with_negative=True

It threw an error: googleapiclient.errors.HttpError: <HttpError 403 when requesting https://tpu.googleapis.com/v1alpha1/projects/projectname/locations/us-central1-a/nodes/testnode?alt=json returned "Request had insufficient authentication scopes.">

Is there a way to change the scope of existing VM to cloud-platform after VM is created?

Upvotes: 1

Views: 2043

Answers (1)

John Hanley
John Hanley

Reputation: 81464

Is there a way to change the scope of existing VM to cloud-platform after VM is created?

Yes you can. Go to the Google Cloud Console. Select your instance and stop it. Then edit your instance and change the scopes, etc. The restart your instance.

Upvotes: 3

Related Questions