Skip to content

Commit 7351b79

Browse files
authored
Add python 3.14, 3.14t to Linux, Linux aarch64 and MacOS builds (#7022)
Related to pytorch/pytorch#156856
1 parent 11335df commit 7351b79

7 files changed

Lines changed: 628 additions & 16 deletions

.github/actions/setup-binary-builds/action.yml

Lines changed: 23 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -127,25 +127,33 @@ runs:
127127
CONDA_ENV="${RUNNER_TEMP}/conda_environment_${GITHUB_RUN_ID}"
128128
export CONDA_EXTRA_PARAM=""
129129
130-
if [[ "${PYTHON_VERSION:-}" == "3.13t" ]]; then
131-
export PYTHON_VERSION=3.13
132-
export CONDA_EXTRA_PARAM=" python-freethreading -c conda-forge"
133-
134-
# downgrade conda version for python 3.13t install.
135-
# TODO: remove this once python 3.13t is fully supported on conda
130+
if [[ ( "${PYTHON_VERSION:-}" == *t || "${PYTHON_VERSION:-}" == 3.14* ) && "$(uname)" == Darwin ]]; then
131+
# downgrade conda version for python 3.13t/3.14t install.
132+
# TODO: remove this once python 3.13t/3.14t is fully supported on conda
136133
# Please see : https://github.com/conda/conda/issues/14554
137-
if [[ "$(uname)" == Darwin ]]; then
138-
# required to be able to downgrade on MacOS arm64
139-
conda install -y python=3.9
140-
if [[ -n "$(conda list | grep conda-anaconda-telemetry)" ]]; then
141-
conda uninstall -y conda-anaconda-telemetry conda-anaconda-tos
142-
fi
143-
conda install -y conda=24.7.1 conda-libmamba-solver=24.1.0
144-
else
145-
conda install -y conda=24.7.1
134+
conda install -y python=3.9
135+
if [[ -n "$(conda list | grep conda-anaconda-telemetry)" ]]; then
136+
conda uninstall -y conda-anaconda-telemetry conda-anaconda-tos
146137
fi
138+
conda install -y conda=24.7.1 conda-libmamba-solver=24.1.0
147139
fi
148140
141+
# shellcheck disable=SC2153
142+
case $PYTHON_VERSION in
143+
3.14t)
144+
export PYTHON_VERSION=3.14.0rc1
145+
export CONDA_EXTRA_PARAM=" python-freethreading -c conda-forge/label/python_rc -c conda-forge"
146+
;;
147+
3.14)
148+
export PYTHON_VERSION=3.14.0rc1
149+
export CONDA_EXTRA_PARAM=" -c conda-forge/label/python_rc -c conda-forge"
150+
;;
151+
3.13t)
152+
export PYTHON_VERSION=3.13
153+
export CONDA_EXTRA_PARAM=" python-freethreading -c conda-forge"
154+
;;
155+
esac
156+
149157
conda create \
150158
--yes --quiet \
151159
--prefix "${CONDA_ENV}" \

tools/scripts/generate_binary_build_matrix.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323

2424
PYTHON_ARCHES_DICT = {
25-
"nightly": ["3.9", "3.10", "3.11", "3.12", "3.13", "3.13t"],
25+
"nightly": ["3.9", "3.10", "3.11", "3.12", "3.13", "3.13t", "3.14", "3.14t"],
2626
"test": ["3.9", "3.10", "3.11", "3.12", "3.13", "3.13t"],
2727
"release": ["3.9", "3.10", "3.11", "3.12", "3.13", "3.13t"],
2828
}
@@ -471,6 +471,10 @@ def generate_wheels_matrix(
471471
if (gpu_arch_type == "cpu-s390x") and python_version == "3.13t":
472472
continue
473473

474+
# Python 3.14 and 3.14t not yet supported on Windows
475+
if os == WINDOWS and python_version.startswith("3.14"):
476+
continue
477+
474478
desired_cuda = translate_desired_cuda(gpu_arch_type, gpu_arch_version)
475479
entry = {
476480
"python_version": python_version,

tools/tests/assets/build_matrix_linux_wheel_cuda.json

Lines changed: 180 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -539,6 +539,186 @@
539539
"upload_to_base_bucket": "no",
540540
"stable_version": "2.8.0",
541541
"use_split_build": false
542+
},
543+
{
544+
"python_version": "3.14",
545+
"gpu_arch_type": "cpu",
546+
"gpu_arch_version": "",
547+
"desired_cuda": "cpu",
548+
"container_image": "pytorch/manylinux2_28-builder:cpu",
549+
"package_type": "manywheel",
550+
"build_name": "manywheel-py3_14-cpu",
551+
"validation_runner": "linux.2xlarge",
552+
"installation": "pip3 install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cpu",
553+
"channel": "nightly",
554+
"upload_to_base_bucket": "no",
555+
"stable_version": "2.8.0",
556+
"use_split_build": false
557+
},
558+
{
559+
"python_version": "3.14",
560+
"gpu_arch_type": "cuda",
561+
"gpu_arch_version": "12.6",
562+
"desired_cuda": "cu126",
563+
"container_image": "pytorch/manylinux2_28-builder:cuda12.6",
564+
"package_type": "manywheel",
565+
"build_name": "manywheel-py3_14-cuda12_6",
566+
"validation_runner": "linux.g5.4xlarge.nvidia.gpu",
567+
"installation": "pip3 install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cu126",
568+
"channel": "nightly",
569+
"upload_to_base_bucket": "no",
570+
"stable_version": "2.8.0",
571+
"use_split_build": false
572+
},
573+
{
574+
"python_version": "3.14",
575+
"gpu_arch_type": "cuda",
576+
"gpu_arch_version": "12.8",
577+
"desired_cuda": "cu128",
578+
"container_image": "pytorch/manylinux2_28-builder:cuda12.8",
579+
"package_type": "manywheel",
580+
"build_name": "manywheel-py3_14-cuda12_8",
581+
"validation_runner": "linux.g5.4xlarge.nvidia.gpu",
582+
"installation": "pip3 install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cu128",
583+
"channel": "nightly",
584+
"upload_to_base_bucket": "no",
585+
"stable_version": "2.8.0",
586+
"use_split_build": false
587+
},
588+
{
589+
"python_version": "3.14",
590+
"gpu_arch_type": "cuda",
591+
"gpu_arch_version": "12.9",
592+
"desired_cuda": "cu129",
593+
"container_image": "pytorch/manylinux2_28-builder:cuda12.9",
594+
"package_type": "manywheel",
595+
"build_name": "manywheel-py3_14-cuda12_9",
596+
"validation_runner": "linux.g5.4xlarge.nvidia.gpu",
597+
"installation": "pip3 install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cu129",
598+
"channel": "nightly",
599+
"upload_to_base_bucket": "no",
600+
"stable_version": "2.8.0",
601+
"use_split_build": false
602+
},
603+
{
604+
"python_version": "3.14",
605+
"gpu_arch_type": "rocm",
606+
"gpu_arch_version": "6.3",
607+
"desired_cuda": "rocm6.3",
608+
"container_image": "pytorch/manylinux2_28-builder:rocm6.3",
609+
"package_type": "manywheel",
610+
"build_name": "manywheel-py3_14-rocm6_3",
611+
"validation_runner": "linux.2xlarge",
612+
"installation": "pip3 install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/rocm6.3",
613+
"channel": "nightly",
614+
"upload_to_base_bucket": "no",
615+
"stable_version": "2.8.0",
616+
"use_split_build": false
617+
},
618+
{
619+
"python_version": "3.14",
620+
"gpu_arch_type": "rocm",
621+
"gpu_arch_version": "6.4",
622+
"desired_cuda": "rocm6.4",
623+
"container_image": "pytorch/manylinux2_28-builder:rocm6.4",
624+
"package_type": "manywheel",
625+
"build_name": "manywheel-py3_14-rocm6_4",
626+
"validation_runner": "linux.2xlarge",
627+
"installation": "pip3 install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/rocm6.4",
628+
"channel": "nightly",
629+
"upload_to_base_bucket": "no",
630+
"stable_version": "2.8.0",
631+
"use_split_build": false
632+
},
633+
{
634+
"python_version": "3.14t",
635+
"gpu_arch_type": "cpu",
636+
"gpu_arch_version": "",
637+
"desired_cuda": "cpu",
638+
"container_image": "pytorch/manylinux2_28-builder:cpu",
639+
"package_type": "manywheel",
640+
"build_name": "manywheel-py3_14t-cpu",
641+
"validation_runner": "linux.2xlarge",
642+
"installation": "pip3 install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cpu",
643+
"channel": "nightly",
644+
"upload_to_base_bucket": "no",
645+
"stable_version": "2.8.0",
646+
"use_split_build": false
647+
},
648+
{
649+
"python_version": "3.14t",
650+
"gpu_arch_type": "cuda",
651+
"gpu_arch_version": "12.6",
652+
"desired_cuda": "cu126",
653+
"container_image": "pytorch/manylinux2_28-builder:cuda12.6",
654+
"package_type": "manywheel",
655+
"build_name": "manywheel-py3_14t-cuda12_6",
656+
"validation_runner": "linux.g5.4xlarge.nvidia.gpu",
657+
"installation": "pip3 install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cu126",
658+
"channel": "nightly",
659+
"upload_to_base_bucket": "no",
660+
"stable_version": "2.8.0",
661+
"use_split_build": false
662+
},
663+
{
664+
"python_version": "3.14t",
665+
"gpu_arch_type": "cuda",
666+
"gpu_arch_version": "12.8",
667+
"desired_cuda": "cu128",
668+
"container_image": "pytorch/manylinux2_28-builder:cuda12.8",
669+
"package_type": "manywheel",
670+
"build_name": "manywheel-py3_14t-cuda12_8",
671+
"validation_runner": "linux.g5.4xlarge.nvidia.gpu",
672+
"installation": "pip3 install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cu128",
673+
"channel": "nightly",
674+
"upload_to_base_bucket": "no",
675+
"stable_version": "2.8.0",
676+
"use_split_build": false
677+
},
678+
{
679+
"python_version": "3.14t",
680+
"gpu_arch_type": "cuda",
681+
"gpu_arch_version": "12.9",
682+
"desired_cuda": "cu129",
683+
"container_image": "pytorch/manylinux2_28-builder:cuda12.9",
684+
"package_type": "manywheel",
685+
"build_name": "manywheel-py3_14t-cuda12_9",
686+
"validation_runner": "linux.g5.4xlarge.nvidia.gpu",
687+
"installation": "pip3 install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cu129",
688+
"channel": "nightly",
689+
"upload_to_base_bucket": "no",
690+
"stable_version": "2.8.0",
691+
"use_split_build": false
692+
},
693+
{
694+
"python_version": "3.14t",
695+
"gpu_arch_type": "rocm",
696+
"gpu_arch_version": "6.3",
697+
"desired_cuda": "rocm6.3",
698+
"container_image": "pytorch/manylinux2_28-builder:rocm6.3",
699+
"package_type": "manywheel",
700+
"build_name": "manywheel-py3_14t-rocm6_3",
701+
"validation_runner": "linux.2xlarge",
702+
"installation": "pip3 install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/rocm6.3",
703+
"channel": "nightly",
704+
"upload_to_base_bucket": "no",
705+
"stable_version": "2.8.0",
706+
"use_split_build": false
707+
},
708+
{
709+
"python_version": "3.14t",
710+
"gpu_arch_type": "rocm",
711+
"gpu_arch_version": "6.4",
712+
"desired_cuda": "rocm6.4",
713+
"container_image": "pytorch/manylinux2_28-builder:rocm6.4",
714+
"package_type": "manywheel",
715+
"build_name": "manywheel-py3_14t-rocm6_4",
716+
"validation_runner": "linux.2xlarge",
717+
"installation": "pip3 install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/rocm6.4",
718+
"channel": "nightly",
719+
"upload_to_base_bucket": "no",
720+
"stable_version": "2.8.0",
721+
"use_split_build": false
542722
}
543723
]
544724
}

tools/tests/assets/build_matrix_linux_wheel_cuda_norocm.json

Lines changed: 120 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -359,6 +359,126 @@
359359
"upload_to_base_bucket": "no",
360360
"stable_version": "2.8.0",
361361
"use_split_build": false
362+
},
363+
{
364+
"python_version": "3.14",
365+
"gpu_arch_type": "cpu",
366+
"gpu_arch_version": "",
367+
"desired_cuda": "cpu",
368+
"container_image": "pytorch/manylinux2_28-builder:cpu",
369+
"package_type": "manywheel",
370+
"build_name": "manywheel-py3_14-cpu",
371+
"validation_runner": "linux.2xlarge",
372+
"installation": "pip3 install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cpu",
373+
"channel": "nightly",
374+
"upload_to_base_bucket": "no",
375+
"stable_version": "2.8.0",
376+
"use_split_build": false
377+
},
378+
{
379+
"python_version": "3.14",
380+
"gpu_arch_type": "cuda",
381+
"gpu_arch_version": "12.6",
382+
"desired_cuda": "cu126",
383+
"container_image": "pytorch/manylinux2_28-builder:cuda12.6",
384+
"package_type": "manywheel",
385+
"build_name": "manywheel-py3_14-cuda12_6",
386+
"validation_runner": "linux.g5.4xlarge.nvidia.gpu",
387+
"installation": "pip3 install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cu126",
388+
"channel": "nightly",
389+
"upload_to_base_bucket": "no",
390+
"stable_version": "2.8.0",
391+
"use_split_build": false
392+
},
393+
{
394+
"python_version": "3.14",
395+
"gpu_arch_type": "cuda",
396+
"gpu_arch_version": "12.8",
397+
"desired_cuda": "cu128",
398+
"container_image": "pytorch/manylinux2_28-builder:cuda12.8",
399+
"package_type": "manywheel",
400+
"build_name": "manywheel-py3_14-cuda12_8",
401+
"validation_runner": "linux.g5.4xlarge.nvidia.gpu",
402+
"installation": "pip3 install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cu128",
403+
"channel": "nightly",
404+
"upload_to_base_bucket": "no",
405+
"stable_version": "2.8.0",
406+
"use_split_build": false
407+
},
408+
{
409+
"python_version": "3.14",
410+
"gpu_arch_type": "cuda",
411+
"gpu_arch_version": "12.9",
412+
"desired_cuda": "cu129",
413+
"container_image": "pytorch/manylinux2_28-builder:cuda12.9",
414+
"package_type": "manywheel",
415+
"build_name": "manywheel-py3_14-cuda12_9",
416+
"validation_runner": "linux.g5.4xlarge.nvidia.gpu",
417+
"installation": "pip3 install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cu129",
418+
"channel": "nightly",
419+
"upload_to_base_bucket": "no",
420+
"stable_version": "2.8.0",
421+
"use_split_build": false
422+
},
423+
{
424+
"python_version": "3.14t",
425+
"gpu_arch_type": "cpu",
426+
"gpu_arch_version": "",
427+
"desired_cuda": "cpu",
428+
"container_image": "pytorch/manylinux2_28-builder:cpu",
429+
"package_type": "manywheel",
430+
"build_name": "manywheel-py3_14t-cpu",
431+
"validation_runner": "linux.2xlarge",
432+
"installation": "pip3 install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cpu",
433+
"channel": "nightly",
434+
"upload_to_base_bucket": "no",
435+
"stable_version": "2.8.0",
436+
"use_split_build": false
437+
},
438+
{
439+
"python_version": "3.14t",
440+
"gpu_arch_type": "cuda",
441+
"gpu_arch_version": "12.6",
442+
"desired_cuda": "cu126",
443+
"container_image": "pytorch/manylinux2_28-builder:cuda12.6",
444+
"package_type": "manywheel",
445+
"build_name": "manywheel-py3_14t-cuda12_6",
446+
"validation_runner": "linux.g5.4xlarge.nvidia.gpu",
447+
"installation": "pip3 install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cu126",
448+
"channel": "nightly",
449+
"upload_to_base_bucket": "no",
450+
"stable_version": "2.8.0",
451+
"use_split_build": false
452+
},
453+
{
454+
"python_version": "3.14t",
455+
"gpu_arch_type": "cuda",
456+
"gpu_arch_version": "12.8",
457+
"desired_cuda": "cu128",
458+
"container_image": "pytorch/manylinux2_28-builder:cuda12.8",
459+
"package_type": "manywheel",
460+
"build_name": "manywheel-py3_14t-cuda12_8",
461+
"validation_runner": "linux.g5.4xlarge.nvidia.gpu",
462+
"installation": "pip3 install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cu128",
463+
"channel": "nightly",
464+
"upload_to_base_bucket": "no",
465+
"stable_version": "2.8.0",
466+
"use_split_build": false
467+
},
468+
{
469+
"python_version": "3.14t",
470+
"gpu_arch_type": "cuda",
471+
"gpu_arch_version": "12.9",
472+
"desired_cuda": "cu129",
473+
"container_image": "pytorch/manylinux2_28-builder:cuda12.9",
474+
"package_type": "manywheel",
475+
"build_name": "manywheel-py3_14t-cuda12_9",
476+
"validation_runner": "linux.g5.4xlarge.nvidia.gpu",
477+
"installation": "pip3 install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cu129",
478+
"channel": "nightly",
479+
"upload_to_base_bucket": "no",
480+
"stable_version": "2.8.0",
481+
"use_split_build": false
362482
}
363483
]
364484
}

0 commit comments

Comments
 (0)