Skip to content

Commit 5b24d8d

Browse files
nitins17Google-ML-Automation
authored andcommitted
Add 3.13 and 3.13t to tpu matrix strategy and run only a single build for oldest supported libtpu
The following builds are run for TPU in the nightly/release workflow: * v4-8: Python 3.10 * v5e-8: Python 3.13, Python 3.13t * v6e-8: Python 3.11, Python 3.12 The following builds are run for TPU in the continuous workflow: * v4-8: Python 3.10, libtpu=nightly * v5e-8: Python 3.10, libtpu=nightly, oldest_supported_libtpu * v6e-8: Python 3.10, libtpu=nightly PiperOrigin-RevId: 752686662
1 parent ede6bfe commit 5b24d8d

File tree

4 files changed

+37
-11
lines changed

4 files changed

+37
-11
lines changed

.github/workflows/wheel_tests_continuous.yml

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -174,14 +174,24 @@ jobs:
174174
tpu-specs: [
175175
# {type: "v3-8", cores: "4"}, # Enable when we have the v3 type available
176176
{type: "v4-8", cores: "4", runner: "linux-x86-ct4p-240-4tpu"},
177-
{type: "v5e-8", cores: "8", runner: "linux-x86-ct5lp-224-8tpu"}
177+
{type: "v5e-8", cores: "8", runner: "linux-x86-ct5lp-224-8tpu"},
178+
{type: "v6e-8", cores: "8", runner: "linux-x86-ct6e-180-8tpu"}
178179
]
180+
libtpu-version-type: ["nightly", "oldest_supported_libtpu"]
181+
exclude:
182+
# Run a single config for oldest_supported_libtpu
183+
- libtpu-version-type: "oldest_supported_libtpu"
184+
tpu-specs:
185+
type: "v4-8"
186+
- libtpu-version-type: "oldest_supported_libtpu"
187+
tpu-specs:
188+
type: "v6e-8"
179189
name: "Pytest TPU (JAX artifacts version = ${{ format('{0}', 'head') }})"
180190
with:
181191
runner: ${{ matrix.tpu-specs.runner }}
182192
cores: ${{ matrix.tpu-specs.cores }}
183193
tpu-type: ${{ matrix.tpu-specs.type }}
184194
python: ${{ matrix.python }}
185195
run-full-tpu-test-suite: "1"
186-
libtpu-version-type: "nightly"
196+
libtpu-version-type: ${{ matrix.libtpu-version-type }}
187197
gcs_download_uri: ${{ needs.build-jaxlib-artifact.outputs.gcs_upload_uri }}

.github/workflows/wheel_tests_nightly_release.yml

Lines changed: 20 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -83,37 +83,50 @@ jobs:
8383
strategy:
8484
fail-fast: false # don't cancel all jobs on failure
8585
matrix:
86-
# Skip Python 3.13 as it fails due to missing TensorFlow wheels (used for
87-
# profiler_test.py, build/collect-profile-requirements.txt) for that version (b/402590302)
88-
python: ["3.10", "3.11", "3.12"]
86+
python: ["3.10", "3.11", "3.12", "3.13", "3.13-nogil"]
8987
tpu-specs: [
9088
# {type: "v3-8", cores: "4"}, # Enable when we have the v3 type available
9189
{type: "v4-8", cores: "4", runner: "linux-x86-ct4p-240-4tpu"},
9290
{type: "v5e-8", cores: "8", runner: "linux-x86-ct5lp-224-8tpu"},
9391
{type: "v6e-8", cores: "8", runner: "linux-x86-ct6e-180-8tpu"}
9492
]
95-
libtpu-version-type: ["pypi_latest", "nightly", "oldest_supported_libtpu"]
93+
libtpu-version-type: ["pypi_latest", "nightly"]
9694
exclude:
95+
# Exclude nightly for releases
9796
- libtpu-version-type: ${{ startsWith(github.ref_name, 'release/') && 'nightly' }}
98-
- libtpu-version-type: ${{ startsWith(github.ref_name, 'release/') && 'oldest_supported_libtpu' }}
97+
# Exclude pypi_latest for nightly releases
9998
- libtpu-version-type: ${{ !startsWith(github.ref_name, 'release/') && 'pypi_latest' }}
100-
# Run a single Python version for v4-8 and v6e-8
99+
# Run a single Python version for v4-8
101100
- tpu-specs:
102101
type: "v4-8"
103102
python: "3.10"
104103
- tpu-specs:
105104
type: "v4-8"
106105
python: "3.11"
106+
- tpu-specs:
107+
type: "v4-8"
108+
python: "3.12"
109+
- tpu-specs:
110+
type: "v4-8"
111+
python: "3.13-nogil"
112+
# Run Python versions in between min and max for v6e-8
107113
- tpu-specs:
108114
type: "v6e-8"
109115
python: "3.10"
110116
- tpu-specs:
111117
type: "v6e-8"
112-
python: "3.11"
118+
python: "3.13"
119+
- tpu-specs:
120+
type: "v6e-8"
121+
python: "3.13-nogil"
113122
# Run min and max Python versions for v5e-8
114123
- tpu-specs:
115124
type: "v5e-8"
116125
python: "3.11"
126+
- tpu-specs:
127+
type: "v5e-8"
128+
python: "3.12"
129+
117130
name: "Pytest TPU (JAX artifacts version = ${{ startsWith(github.ref_name, 'release/') && 'latest release' || 'nightly' }})"
118131
with:
119132
runner: ${{ matrix.tpu-specs.runner }}
Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
tensorflow
1+
# TF hasn't released 3.13 wheels yet (b/402590302)
2+
tensorflow; python_version<"3.13"
23
tensorboard-plugin-profile<=2.19.0
34
# Needed for the profile plugin to work without error
45
protobuf

ci/run_pytest_tpu.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,9 @@ echo "Installed packages:"
4141
"$JAXCI_PYTHON" -c 'import sys; print("python version:", sys.version)'
4242
"$JAXCI_PYTHON" -c 'import jax; print("jax version:", jax.__version__)'
4343
"$JAXCI_PYTHON" -c 'import jaxlib; print("jaxlib version:", jaxlib.__version__)'
44-
strings /usr/local/lib/"$JAXCI_PYTHON"/dist-packages/libtpu/libtpu.so | grep 'Built on'
44+
# Free-threaded builds use "-nogil" as the suffix for the binary and "t" for its
45+
# dist-packages path
46+
strings /usr/local/lib/"${JAXCI_PYTHON//-nogil/t}"/dist-packages/libtpu/libtpu.so | grep 'Built on'
4547
"$JAXCI_PYTHON" -c 'import jax; print("libtpu version:",jax.lib.xla_bridge.get_backend().platform_version)'
4648

4749
# Set up all common test environment variables

0 commit comments

Comments
 (0)