Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update TPU config in Use TPU notebook #2303

Merged
merged 2 commits into from
Apr 22, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions site/en/guide/tpu.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"id": "Tce3stUlHN0L"
},
"source": [
"##### Copyright 2018 The TensorFlow Authors.\n"
"##### Copyright 2024 The TensorFlow Authors.\n"
]
},
{
Expand Down Expand Up @@ -81,7 +81,7 @@
"id": "ebf7f8489bb7"
},
"source": [
"Before you run this Colab notebook, make sure that your hardware accelerator is a TPU by checking your notebook settings: **Runtime** > **Change runtime type** > **Hardware accelerator** > **TPU**.\n",
"Before you run this Colab notebook, make sure that your hardware accelerator is a TPU by checking your notebook settings: **Runtime** > **Change runtime type** > **Hardware accelerator** > **TPU v2**.\n",
"\n",
"Import some necessary libraries, including TensorFlow Datasets:"
]
Expand Down Expand Up @@ -128,7 +128,7 @@
},
"outputs": [],
"source": [
"resolver = tf.distribute.cluster_resolver.TPUClusterResolver(tpu='')\n",
"resolver = tf.distribute.cluster_resolver.TPUClusterResolver(tpu='local')\n",
"tf.config.experimental_connect_to_cluster(resolver)\n",
"# This is the TPU initialization code that has to be at the beginning.\n",
"tf.tpu.experimental.initialize_tpu_system(resolver)\n",
Expand Down Expand Up @@ -588,7 +588,6 @@
"metadata": {
"accelerator": "TPU",
"colab": {
"collapsed_sections": [],
"name": "tpu.ipynb",
"toc_visible": true
},
Expand Down
Loading