-
Notifications
You must be signed in to change notification settings - Fork 432
Publish CPU docker images for PyTorch 2.13.0 #2099
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -58,17 +58,39 @@ def get_torchaudio_version(torch_version): | |||||
| return "2.0.1" | ||||||
| elif torch_version == "2.0.1": | ||||||
| return "2.0.2" | ||||||
| elif version_ge(torch_version, "2.11"): | ||||||
| # torchaudio only has versions up to 2.11.0 | ||||||
| return "2.11.0" | ||||||
| else: | ||||||
| return torch_version | ||||||
|
Comment on lines
+61
to
65
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. For PyTorch versions else:
return torch_version |
||||||
|
|
||||||
|
|
||||||
| # Latest k2 version per torch version, from https://k2-fsa.github.io/k2/cpu.html | ||||||
| def get_k2_version(torch_version): | ||||||
| # torch 2.13.0 has a newer k2 build | ||||||
| if version_ge(torch_version, "2.13"): | ||||||
| return "1.24.4.dev20260710" | ||||||
| # torch 1.10.0+ through 2.12.x | ||||||
| return "1.24.4.dev20260625" | ||||||
|
|
||||||
|
|
||||||
| # Latest kaldifeat version per torch version, from https://csukuangfj.github.io/kaldifeat/cpu.html | ||||||
| def get_kaldifeat_version(torch_version): | ||||||
| # torch 2.13.0 has a newer kaldifeat build | ||||||
| if version_ge(torch_version, "2.13"): | ||||||
| return "1.25.5.dev20260710" | ||||||
| # torch 1.13.0+ through 2.12.x | ||||||
| if version_ge(torch_version, "1.13"): | ||||||
| return "1.25.5.dev20260626" | ||||||
| # older torch versions | ||||||
| return "1.25.5.dev20241029" | ||||||
|
|
||||||
|
|
||||||
| def get_matrix(min_torch_version, specified_torch_version, specified_python_version): | ||||||
| k2_version = "1.24.4.dev20250630" | ||||||
| kaldifeat_version = "1.25.5.dev20250630" | ||||||
| version = "20250630" | ||||||
| version = "20260712" | ||||||
|
|
||||||
| # torchaudio 2.5.0 does not support python 3.13 | ||||||
| python_version = ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"] | ||||||
| python_version = ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13", "3.14", "3.15"] | ||||||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Python 3.15 is not yet released or supported by PyTorch 2.13.0. Furthermore,
Suggested change
|
||||||
| torch_version = [] | ||||||
| torch_version += ["1.13.0", "1.13.1"] | ||||||
| torch_version += ["2.0.0", "2.0.1"] | ||||||
|
|
@@ -81,6 +103,12 @@ def get_matrix(min_torch_version, specified_torch_version, specified_python_vers | |||||
| torch_version += ["2.5.0"] | ||||||
| torch_version += ["2.5.1"] | ||||||
| torch_version += ["2.6.0", "2.7.0", "2.7.1"] | ||||||
| torch_version += ["2.8.0"] | ||||||
| torch_version += ["2.9.0", "2.9.1"] | ||||||
| torch_version += ["2.10.0"] | ||||||
| torch_version += ["2.11.0"] | ||||||
| torch_version += ["2.12.0", "2.12.1"] | ||||||
| torch_version += ["2.13.0"] | ||||||
|
|
||||||
| if specified_torch_version: | ||||||
| torch_version = [specified_torch_version] | ||||||
|
|
@@ -110,13 +138,22 @@ def get_matrix(min_torch_version, specified_torch_version, specified_python_vers | |||||
| # torch>=2.5 requires python 3.10 | ||||||
| continue | ||||||
|
|
||||||
| k2_version_2 = k2_version | ||||||
| kaldifeat_version_2 = kaldifeat_version | ||||||
| # torch>=2.9 drops python 3.9 | ||||||
| if not version_gt(p, "3.9") and version_ge(t, "2.9"): | ||||||
| continue | ||||||
|
Comment on lines
+141
to
+143
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
||||||
|
|
||||||
| # torch>=2.9 supports python 3.14 | ||||||
| if version_gt(p, "3.13") and not version_ge(t, "2.9"): | ||||||
| continue | ||||||
|
|
||||||
| # only torch>=2.13.0 supports python 3.15 | ||||||
| if version_gt(p, "3.14") and not version_ge(t, "2.13"): | ||||||
| continue | ||||||
|
Comment on lines
+149
to
+151
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
||||||
|
|
||||||
| matrix.append( | ||||||
| { | ||||||
| "k2-version": k2_version_2, | ||||||
| "kaldifeat-version": kaldifeat_version_2, | ||||||
| "k2-version": get_k2_version(t), | ||||||
| "kaldifeat-version": get_kaldifeat_version(t), | ||||||
| "version": version, | ||||||
| "python-version": p, | ||||||
| "torch-version": t, | ||||||
|
|
||||||
| Original file line number | Diff line number | Diff line change | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -77,8 +77,64 @@ def get_v1_3_0_files(): | |||||||||||
| return ans | ||||||||||||
|
|
||||||||||||
|
|
||||||||||||
| def get_v1_4_1_files(): | ||||||||||||
| prefix = ( | ||||||||||||
| "https://github.com/csukuangfj/piper-phonemize/releases/download/v1.4.1/" | ||||||||||||
| ) | ||||||||||||
| files = [ | ||||||||||||
| "piper_phonemize-1.4.1-cp314-cp314-macosx_10_14_x86_64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp314-cp314-macosx_11_0_arm64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp314-cp314-manylinux_2_31_armv7l.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp314-cp314-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp314-cp314-win32.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp313-cp313-macosx_10_14_x86_64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp313-cp313-macosx_11_0_arm64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp313-cp313-manylinux_2_31_armv7l.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp313-cp313-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp313-cp313-win32.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp312-cp312-macosx_10_14_x86_64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp312-cp312-macosx_11_0_arm64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp312-cp312-manylinux_2_31_armv7l.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp312-cp312-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp312-cp312-win32.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp311-cp311-macosx_10_14_x86_64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp311-cp311-macosx_11_0_arm64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp311-cp311-manylinux_2_31_armv7l.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp311-cp311-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp311-cp311-win32.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp310-cp310-macosx_10_14_x86_64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp310-cp310-macosx_11_0_arm64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp310-cp310-manylinux_2_31_armv7l.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp310-cp310-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp310-cp310-win32.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp39-cp39-macosx_10_14_x86_64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp39-cp39-macosx_11_0_arm64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp39-cp39-manylinux_2_31_armv7l.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp39-cp39-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp39-cp39-manylinux2014_x86_64.manylinux_2_17_x86_64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp39-cp39-win32.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp38-cp38-macosx_10_14_x86_64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp38-cp38-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp38-cp38-win32.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp37-cp37m-macosx_10_14_x86_64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp37-cp37m-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", | ||||||||||||
| "piper_phonemize-1.4.1-cp37-cp37m-win32.whl", | ||||||||||||
| ] | ||||||||||||
| ans = [prefix + f for f in files] | ||||||||||||
| return ans | ||||||||||||
|
Comment on lines
+132
to
+133
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. For consistency with
Suggested change
|
||||||||||||
|
|
||||||||||||
|
|
||||||||||||
| def main(): | ||||||||||||
| files = get_v1_3_0_files() + get_v1_2_0_files() | ||||||||||||
| files = get_v1_4_1_files() + get_v1_3_0_files() + get_v1_2_0_files() | ||||||||||||
|
|
||||||||||||
| with open("piper_phonemize.html", "w") as f: | ||||||||||||
| for url in files: | ||||||||||||
|
|
||||||||||||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,5 +1,8 @@ | ||
| name: build-cpu-docker | ||
| on: | ||
| push: | ||
| branches: | ||
| - docker-cpu | ||
| workflow_dispatch: | ||
|
|
||
| concurrency: | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unpinning
onnxandonnxruntimecompletely can lead to non-reproducible Docker builds and potential compatibility issues in the future when new major/minor versions of these packages are released. It is highly recommended to use version ranges (e.g., matching those inrequirements.txt) to ensure build stability.