diff --git a/tpu/create_tpu.py b/tpu/create_tpu.py index da2cdeaaf5bc..1dc72622e682 100644 --- a/tpu/create_tpu.py +++ b/tpu/create_tpu.py @@ -20,8 +20,8 @@ def create_cloud_tpu( project_id: str, zone: str, tpu_name: str, - tpu_type: str = "v2-8", - runtime_version: str = "tpu-vm-tf-2.17.0-pjrt", + tpu_type: str = "v5litepod-4", + runtime_version: str = "v2-tpuv5-litepod", ) -> Node: """Creates a Cloud TPU node. Args: @@ -38,10 +38,10 @@ def create_cloud_tpu( # TODO(developer): Update and un-comment below lines # project_id = "your-project-id" - # zone = "us-central1-b" + # zone = "us-central1-a" # tpu_name = "tpu-name" - # tpu_type = "v2-8" - # runtime_version = "tpu-vm-tf-2.17.0-pjrt" + # tpu_type = "v5litepod-4" + # runtime_version = "v2-tpuv5-litepod" # Create a TPU node node = tpu_v2.Node() @@ -65,7 +65,7 @@ def create_cloud_tpu( print(response) # Example response: # name: "projects/[project_id]/locations/[zone]/nodes/my-tpu" - # accelerator_type: "v2-8" + # accelerator_type: "v5litepod-4" # state: READY # ... @@ -75,5 +75,5 @@ def create_cloud_tpu( if __name__ == "__main__": PROJECT_ID = os.getenv("GOOGLE_CLOUD_PROJECT") - ZONE = "us-central1-b" + ZONE = "us-central1-a" create_cloud_tpu(PROJECT_ID, ZONE, "tpu-name") diff --git a/tpu/create_tpu_spot.py b/tpu/create_tpu_spot.py index 43ef3b0f68da..18cb928fe40a 100644 --- a/tpu/create_tpu_spot.py +++ b/tpu/create_tpu_spot.py @@ -20,8 +20,8 @@ def create_tpu_with_spot( project_id: str, zone: str, tpu_name: str, - tpu_type: str = "v2-8", - runtime_version: str = "tpu-vm-tf-2.17.0-pjrt", + tpu_type: str = "v5litepod-4", + runtime_version: str = "v2-tpuv5-litepod", ) -> Node: """Creates a Cloud TPU node. Args: @@ -40,8 +40,8 @@ def create_tpu_with_spot( # project_id = "your-project-id" # zone = "us-central1-b" # tpu_name = "tpu-name" - # tpu_type = "v2-8" - # runtime_version = "tpu-vm-tf-2.17.0-pjrt" + # tpu_type = "v5litepod-4" + # runtime_version = "v2-tpuv5-litepod" # Create a TPU node node = tpu_v2.Node() @@ -75,5 +75,5 @@ def create_tpu_with_spot( if __name__ == "__main__": PROJECT_ID = os.getenv("GOOGLE_CLOUD_PROJECT") - ZONE = "us-central1-b" + ZONE = "us-central1-a" create_tpu_with_spot(PROJECT_ID, ZONE, "tpu-with-spot") diff --git a/tpu/create_tpu_with_script.py b/tpu/create_tpu_with_script.py index 53a2ada4fb19..f519b0035387 100644 --- a/tpu/create_tpu_with_script.py +++ b/tpu/create_tpu_with_script.py @@ -20,18 +20,18 @@ def create_cloud_tpu_with_script( project_id: str, zone: str, tpu_name: str, - tpu_type: str = "v2-8", - runtime_version: str = "tpu-vm-tf-2.17.0-pjrt", + tpu_type: str = "v5litepod-4", + runtime_version: str = "v2-tpuv5-litepod", ) -> Node: # [START tpu_vm_create_startup_script] from google.cloud import tpu_v2 # TODO(developer): Update and un-comment below lines # project_id = "your-project-id" - # zone = "us-central1-b" + # zone = "us-central1-a" # tpu_name = "tpu-name" - # tpu_type = "v2-8" - # runtime_version = "tpu-vm-tf-2.17.0-pjrt" + # tpu_type = "v5litepod-4" + # runtime_version = "v2-tpuv5-litepod" node = tpu_v2.Node() node.accelerator_type = tpu_type @@ -72,5 +72,5 @@ def create_cloud_tpu_with_script( if __name__ == "__main__": PROJECT_ID = os.getenv("GOOGLE_CLOUD_PROJECT") - ZONE = "us-central1-b" + ZONE = "us-central1-a" create_cloud_tpu_with_script(PROJECT_ID, ZONE, "tpu-name") diff --git a/tpu/delete_tpu.py b/tpu/delete_tpu.py index f927d83c1217..71290129b9b9 100644 --- a/tpu/delete_tpu.py +++ b/tpu/delete_tpu.py @@ -44,5 +44,5 @@ def delete_cloud_tpu(project_id: str, zone: str, tpu_name: str = "tpu-name") -> if __name__ == "__main__": PROJECT_ID = os.getenv("GOOGLE_CLOUD_PROJECT") - ZONE = "us-central1-b" + ZONE = "us-central1-a" delete_cloud_tpu(PROJECT_ID, ZONE, "tpu-name") diff --git a/tpu/get_tpu.py b/tpu/get_tpu.py index 9af19039af59..6515ced7ee58 100644 --- a/tpu/get_tpu.py +++ b/tpu/get_tpu.py @@ -50,5 +50,5 @@ def get_cloud_tpu(project_id: str, zone: str, tpu_name: str = "tpu-name") -> Nod if __name__ == "__main__": PROJECT_ID = os.getenv("GOOGLE_CLOUD_PROJECT") - ZONE = "us-central1-b" + ZONE = "us-central1-a" get_cloud_tpu(PROJECT_ID, ZONE, "tpu-name") diff --git a/tpu/list_tpu.py b/tpu/list_tpu.py index 31a43a5b61ac..02fc8bc0914f 100644 --- a/tpu/list_tpu.py +++ b/tpu/list_tpu.py @@ -50,5 +50,5 @@ def list_cloud_tpu(project_id: str, zone: str) -> ListNodesPager: if __name__ == "__main__": PROJECT_ID = os.getenv("GOOGLE_CLOUD_PROJECT") - ZONE = "us-central1-b" + ZONE = "us-central1-a" list_cloud_tpu(PROJECT_ID, ZONE) diff --git a/tpu/queued_resources_create.py b/tpu/queued_resources_create.py index 91dad552bcfe..d155392db6e9 100644 --- a/tpu/queued_resources_create.py +++ b/tpu/queued_resources_create.py @@ -20,8 +20,8 @@ def create_queued_resource( project_id: str, zone: str, tpu_name: str, - tpu_type: str = "v2-8", - runtime_version: str = "tpu-vm-tf-2.17.0-pjrt", + tpu_type: str = "v5litepod-4", + runtime_version: str = "v2-tpuv5-litepod", queued_resource_name: str = "resource-name", ) -> Node: # [START tpu_queued_resources_create] @@ -29,10 +29,10 @@ def create_queued_resource( # TODO(developer): Update and un-comment below lines # project_id = "your-project-id" - # zone = "us-central1-b" + # zone = "us-central1-a" # tpu_name = "tpu-name" - # tpu_type = "v2-8" - # runtime_version = "tpu-vm-tf-2.17.0-pjrt" + # tpu_type = "v5litepod-4" + # runtime_version = "v2-tpuv5-litepod" # queued_resource_name = "resource-name" node = tpu_v2alpha1.Node() @@ -71,7 +71,7 @@ def create_queued_resource( if __name__ == "__main__": PROJECT_ID = os.getenv("GOOGLE_CLOUD_PROJECT") - ZONE = "us-central1-b" + ZONE = "us-central1-a" create_queued_resource( project_id=PROJECT_ID, zone=ZONE, diff --git a/tpu/queued_resources_create_network.py b/tpu/queued_resources_create_network.py index 5061fbed2bb7..929441fa4cbc 100644 --- a/tpu/queued_resources_create_network.py +++ b/tpu/queued_resources_create_network.py @@ -20,8 +20,8 @@ def create_queued_resource_network( project_id: str, zone: str, tpu_name: str, - tpu_type: str = "v2-8", - runtime_version: str = "tpu-vm-tf-2.17.0-pjrt", + tpu_type: str = "v5litepod-4", + runtime_version: str = "v2-tpuv5-litepod", queued_resource_name: str = "resource-name", network: str = "default", ) -> Node: @@ -30,10 +30,10 @@ def create_queued_resource_network( # TODO(developer): Update and un-comment below lines # project_id = "your-project-id" - # zone = "us-central1-b" + # zone = "us-central1-a" # tpu_name = "tpu-name" - # tpu_type = "v2-8" - # runtime_version = "tpu-vm-tf-2.17.0-pjrt" + # tpu_type = "v5litepod-4" + # runtime_version = "v2-tpuv5-litepod" # queued_resource_name = "resource-name" # network = "default" @@ -81,7 +81,7 @@ def create_queued_resource_network( if __name__ == "__main__": PROJECT_ID = os.getenv("GOOGLE_CLOUD_PROJECT") - ZONE = "us-central1-b" + ZONE = "us-central1-a" create_queued_resource_network( project_id=PROJECT_ID, zone=ZONE, diff --git a/tpu/queued_resources_create_spot.py b/tpu/queued_resources_create_spot.py index 59bacc3b0310..c0dd7e0e7ae7 100644 --- a/tpu/queued_resources_create_spot.py +++ b/tpu/queued_resources_create_spot.py @@ -20,8 +20,8 @@ def create_queued_resource_spot( project_id: str, zone: str, tpu_name: str, - tpu_type: str = "v2-8", - runtime_version: str = "tpu-vm-tf-2.17.0-pjrt", + tpu_type: str = "v5litepod-4", + runtime_version: str = "v2-tpuv5-litepod", queued_resource_name: str = "resource-name", ) -> Node: # [START tpu_queued_resources_create_spot] @@ -29,10 +29,10 @@ def create_queued_resource_spot( # TODO(developer): Update and un-comment below lines # project_id = "your-project-id" - # zone = "us-central1-b" + # zone = "us-central1-a" # tpu_name = "tpu-name" - # tpu_type = "v2-8" - # runtime_version = "tpu-vm-tf-2.17.0-pjrt" + # tpu_type = "v5litepod-4" + # runtime_version = "v2-tpuv5-litepod" # queued_resource_name = "resource-name" node = tpu_v2alpha1.Node() @@ -73,7 +73,7 @@ def create_queued_resource_spot( if __name__ == "__main__": PROJECT_ID = os.getenv("GOOGLE_CLOUD_PROJECT") - ZONE = "us-central1-b" + ZONE = "us-central1-a" create_queued_resource_spot( project_id=PROJECT_ID, zone=ZONE, diff --git a/tpu/queued_resources_create_startup_script.py b/tpu/queued_resources_create_startup_script.py index 44d0ad3fe44f..8b11ddf9501b 100644 --- a/tpu/queued_resources_create_startup_script.py +++ b/tpu/queued_resources_create_startup_script.py @@ -20,8 +20,8 @@ def create_queued_resource_startup_script( project_id: str, zone: str, tpu_name: str, - tpu_type: str = "v2-8", - runtime_version: str = "tpu-vm-tf-2.17.0-pjrt", + tpu_type: str = "v5litepod-4", + runtime_version: str = "v2-tpuv5-litepod", queued_resource_name: str = "resource-name", ) -> Node: # [START tpu_queued_resources_startup_script] @@ -29,10 +29,10 @@ def create_queued_resource_startup_script( # TODO(developer): Update and un-comment below lines # project_id = "your-project-id" - # zone = "us-central1-b" + # zone = "us-central1-a" # tpu_name = "tpu-name" - # tpu_type = "v2-8" - # runtime_version = "tpu-vm-tf-2.17.0-pjrt" + # tpu_type = "v5litepod-4" + # runtime_version = "v2-tpuv5-litepod" # queued_resource_name = "resource-name" node = tpu_v2alpha1.Node() @@ -84,7 +84,7 @@ def create_queued_resource_startup_script( if __name__ == "__main__": PROJECT_ID = os.getenv("GOOGLE_CLOUD_PROJECT") - ZONE = "us-central1-b" + ZONE = "us-central1-a" create_queued_resource_startup_script( project_id=PROJECT_ID, zone=ZONE, diff --git a/tpu/queued_resources_create_time_bound.py b/tpu/queued_resources_create_time_bound.py index 76b352a4de33..65238f9f91fb 100644 --- a/tpu/queued_resources_create_time_bound.py +++ b/tpu/queued_resources_create_time_bound.py @@ -20,8 +20,8 @@ def create_queued_resource_time_bound( project_id: str, zone: str, tpu_name: str, - tpu_type: str = "v2-8", - runtime_version: str = "tpu-vm-tf-2.17.0-pjrt", + tpu_type: str = "v5litepod-4", + runtime_version: str = "v2-tpuv5-litepod", queued_resource_name: str = "resource-name", ) -> Node: # [START tpu_queued_resources_time_bound] @@ -29,10 +29,10 @@ def create_queued_resource_time_bound( # TODO(developer): Update and un-comment below lines # project_id = "your-project-id" - # zone = "us-central1-b" + # zone = "us-central1-a" # tpu_name = "tpu-name" - # tpu_type = "v2-8" - # runtime_version = "tpu-vm-tf-2.17.0-pjrt" + # tpu_type = "v5litepod-4" + # runtime_version = "v2-tpuv5-litepod" # queued_resource_name = "resource-name" node = tpu_v2alpha1.Node() @@ -81,7 +81,7 @@ def create_queued_resource_time_bound( if __name__ == "__main__": PROJECT_ID = os.getenv("GOOGLE_CLOUD_PROJECT") - ZONE = "us-central1-b" + ZONE = "us-central1-a" create_queued_resource_time_bound( project_id=PROJECT_ID, zone=ZONE, diff --git a/tpu/queued_resources_delete.py b/tpu/queued_resources_delete.py index 8586c708c85e..ee993006a853 100644 --- a/tpu/queued_resources_delete.py +++ b/tpu/queued_resources_delete.py @@ -43,5 +43,5 @@ def delete_queued_resource( if __name__ == "__main__": PROJECT_ID = os.environ["GOOGLE_CLOUD_PROJECT"] - ZONE = "us-central1-b" + ZONE = "us-central1-a" delete_queued_resource(PROJECT_ID, ZONE, "resource-name") diff --git a/tpu/queued_resources_delete_force.py b/tpu/queued_resources_delete_force.py index 357a8378a2a4..84560692ccb5 100644 --- a/tpu/queued_resources_delete_force.py +++ b/tpu/queued_resources_delete_force.py @@ -44,5 +44,5 @@ def delete_force_queued_resource( if __name__ == "__main__": PROJECT_ID = os.environ["GOOGLE_CLOUD_PROJECT"] - ZONE = "us-central1-b" + ZONE = "us-central1-a" delete_force_queued_resource(PROJECT_ID, ZONE, "resource-name") diff --git a/tpu/queued_resources_get.py b/tpu/queued_resources_get.py index dc19f64291b8..158c8ee7db2f 100644 --- a/tpu/queued_resources_get.py +++ b/tpu/queued_resources_get.py @@ -44,5 +44,5 @@ def get_queued_resource( if __name__ == "__main__": PROJECT_ID = os.environ["GOOGLE_CLOUD_PROJECT"] - ZONE = "us-central1-b" + ZONE = "us-central1-a" get_queued_resource(PROJECT_ID, ZONE, "resource-name") diff --git a/tpu/queued_resources_list.py b/tpu/queued_resources_list.py index 4ed56a9596fc..52b8086d601b 100644 --- a/tpu/queued_resources_list.py +++ b/tpu/queued_resources_list.py @@ -40,5 +40,5 @@ def list_queued_resources(project_id: str, zone: str) -> ListQueuedResourcesPage if __name__ == "__main__": PROJECT_ID = os.getenv("GOOGLE_CLOUD_PROJECT") - ZONE = "us-central1-b" + ZONE = "us-central1-a" list_queued_resources(PROJECT_ID, ZONE) diff --git a/tpu/start_tpu.py b/tpu/start_tpu.py index 79a6738d1e93..6d6a4cc10ffe 100644 --- a/tpu/start_tpu.py +++ b/tpu/start_tpu.py @@ -31,7 +31,7 @@ def start_cloud_tpu(project_id: str, zone: str, tpu_name: str = "tpu-name") -> N # TODO(developer): Update and un-comment below lines # project_id = "your-project-id" - # zone = "us-central1-b" + # zone = "us-central1-a" # tpu_name = "tpu-name" client = tpu_v2.TpuClient() @@ -57,5 +57,5 @@ def start_cloud_tpu(project_id: str, zone: str, tpu_name: str = "tpu-name") -> N if __name__ == "__main__": PROJECT_ID = os.getenv("GOOGLE_CLOUD_PROJECT") - ZONE = "us-central1-b" + ZONE = "us-central1-a" start_cloud_tpu(PROJECT_ID, ZONE, "tpu-name") diff --git a/tpu/stop_tpu.py b/tpu/stop_tpu.py index afb0100f6ba2..74e545686eeb 100644 --- a/tpu/stop_tpu.py +++ b/tpu/stop_tpu.py @@ -32,7 +32,7 @@ def stop_cloud_tpu(project_id: str, zone: str, tpu_name: str = "tpu-name") -> No # TODO(developer): Update and un-comment below lines # project_id = "your-project-id" - # zone = "us-central1-b" + # zone = "us-central1-a" # tpu_name = "tpu-name" client = tpu_v2.TpuClient() @@ -58,5 +58,5 @@ def stop_cloud_tpu(project_id: str, zone: str, tpu_name: str = "tpu-name") -> No if __name__ == "__main__": PROJECT_ID = os.getenv("GOOGLE_CLOUD_PROJECT") - ZONE = "us-central1-b" + ZONE = "us-central1-a" stop_cloud_tpu(PROJECT_ID, ZONE, "tpu-name")