Skip to content

Commit 9cfa076

Browse files
authored
[Release/2.0] Use Triton from PYPI (#96010)
* [Release/2.0] Use Triton from PYPI Remove `[dynamo]` extras from setup.py Build torchtriton conda wheels as 2.0.0 * Also, upload triton conda packages to test channel
1 parent 8e05e41 commit 9cfa076

File tree

6 files changed

+10
-15
lines changed

6 files changed

+10
-15
lines changed

.github/scripts/build_triton_wheel.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ def build_triton(commit_hash: str, build_conda: bool = False, py_version : Optio
3838
check_call(["git", "checkout", commit_hash], cwd=triton_basedir)
3939
if build_conda:
4040
with open(triton_basedir / "meta.yaml", "w") as meta:
41-
print(f"package:\n name: torchtriton\n version: 2.0.0+{commit_hash[:10]}\n", file=meta)
41+
print("package:\n name: torchtriton\n version: 2.0.0\n", file=meta)
4242
print("source:\n path: .\n", file=meta)
4343
print("build:\n string: py{{py}}\n number: 1\n script: cd python; "
4444
"python setup.py install --single-version-externally-managed --record=record.txt\n", file=meta)

.github/scripts/generate_binary_build_matrix.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -226,7 +226,8 @@ def generate_wheels_matrix(os: str,
226226
"nvidia-cusolver-cu11==11.4.0.1; platform_system == 'Linux' and platform_machine == 'x86_64' | "
227227
"nvidia-cusparse-cu11==11.7.4.91; platform_system == 'Linux' and platform_machine == 'x86_64' | "
228228
"nvidia-nccl-cu11==2.14.3; platform_system == 'Linux' and platform_machine == 'x86_64' | "
229-
"nvidia-nvtx-cu11==11.7.91; platform_system == 'Linux' and platform_machine == 'x86_64'",
229+
"nvidia-nvtx-cu11==11.7.91; platform_system == 'Linux' and platform_machine == 'x86_64' | "
230+
"triton==2.0.0; platform_system == 'Linux' and platform_machine == 'x86_64'",
230231
"build_name":
231232
f"{package_type}-py{python_version}-{gpu_arch_type}{gpu_arch_version}-with-pypi-cudnn"
232233
.replace(

.github/workflows/build-triton-wheel.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ jobs:
137137
run: |
138138
set -ex
139139
pip install -q awscli
140-
s3_dir="${UPLOAD_BUCKET}/whl/nightly/"
140+
s3_dir="${UPLOAD_BUCKET}/whl/test/"
141141
for pkg in "${PKG_DIR}/"*.whl; do
142142
aws s3 cp --no-progress --acl public-read "${pkg}" "${s3_dir}"
143143
done
@@ -193,7 +193,7 @@ jobs:
193193
if: ${{ github.event_name == 'push' && (github.event.ref == 'refs/heads/master' || github.event.ref == 'refs/heads/main') }}
194194
run: |
195195
container_name=$(docker container ps --format '{{.ID}}')
196-
docker exec -t "${container_name}" sh -c "anaconda upload /artifacts/torch*.tar.bz2 -u pytorch-nightly --label main --no-progress --force"
196+
docker exec -t "${container_name}" sh -c "anaconda upload /artifacts/torch*.tar.bz2 -u pytorch-test --label main --no-progress --force"
197197
198198
- name: Chown artifacts
199199
run: |

.github/workflows/generated-linux-binary-manywheel-master.yml

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.github/workflows/generated-linux-binary-manywheel-nightly.yml

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

setup.py

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1029,12 +1029,6 @@ def main():
10291029
extras_require = {
10301030
'opt-einsum': ['opt-einsum>=3.3']
10311031
}
1032-
if platform.system() == 'Linux':
1033-
triton_pin_file = os.path.join(cwd, ".github", "ci_commit_pins", "triton.txt")
1034-
if os.path.exists(triton_pin_file):
1035-
with open(triton_pin_file) as f:
1036-
triton_pin = f.read().strip()
1037-
extras_require['dynamo'] = ['pytorch-triton==2.0.0+' + triton_pin[:10], 'jinja2']
10381032

10391033
# Parse the command line and check the arguments before we proceed with
10401034
# building deps and setup. We need to set values so `--help` works.

0 commit comments

Comments
 (0)