【发布时间】:2019-01-17 00:47:50
【问题描述】:
我正在尝试在 Cloud ML Engine 上使用 TPU,但我不知道应该如何提供 TPUClusterResolver 期望的 tpu 参数。
这是我正在使用的环境:
--python-version 3.5 \
--runtime-version 1.12 \
--region us-central1 \
--scale-tier BASIC_TPU
作业崩溃:
ValueError: Please provide a TPU Name to connect to.
作为一个单独的问题 - ML 引擎似乎将--master grpc://10.129.152.2:8470 自己添加到我的工作中,这也使工作崩溃。作为一种解决方法,我只是在我的代码中添加了一个未使用的主标志。
【问题讨论】:
-
生成了一个
master-replica-0 Running task with arguments: --cluster... --tpu_node={"project": "nd1a3f7fc7f45c50c-ml", "zone": "us-central1-c", "tpu_node_name": "cmle-training-18374866318486238002-tpu"}日志。我猜tpu_node_name需要以某种方式传递给TPUClusterResolver? -
您使用的是哪个样本?请查看此工作示例:github.com/GoogleCloudPlatform/cloudml-samples/tree/master/tpu
-
我使用的是来自github.com/tensorflow/tpu/tree/master/models/experimental/… 的初始样本。我刚刚尝试了来自 github.com/GoogleCloudPlatform/cloudml-samples/tree/master/tpu 的 resnet 示例。这很好用。我能够将其用作模板并更新初始代码以使其正常工作。谢谢指点!
标签: tensorflow google-cloud-ml tpu