Python GCP:无法连接到云TPU

Python GCP:无法连接到云TPU,python,tensorflow,google-cloud-platform,tpu,Python,Tensorflow,Google Cloud Platform,Tpu,我使用ctpu-up命令启动了一个TPU实例,并成功运行了MNIST教程。如前所述,当我再次运行MNIST教程时,我从cloud shell中注销,并使用SSH控制台登录到连接到TPU的vm RuntimeError: Cannot find any TPU cores in the system. Please double check Tensorflow master address and TPU worker(s). 当我运行ctpu ls时,我得到 # Flock Na

我使用
ctpu-up
命令启动了一个TPU实例,并成功运行了MNIST教程。如前所述,当我再次运行MNIST教程时,我从cloud shell中注销,并使用SSH控制台登录到连接到TPU的vm

RuntimeError: Cannot find any TPU cores in the system. Please double check Tensorflow master address and TPU worker(s).
当我运行
ctpu ls
时,我得到

#       Flock Name      Status
0:      my-tpu(*)  running
ctpu状态
命令给出

Your cluster is running!
Compute Engine VM:  RUNNING
Cloud TPU:          RUNNING

我是不是错过了一些基本的东西

ctpu
将此名称作为环境变量传递给计算引擎VM(
TPU\u name
),但
gcloud
不会

明确指定您的TPU:使用
--TPU=my TPU
而不是
--TPU=$TPU\u NAME