From ed9e64519587d3aef68eecdd41c91be7be8b9f25 Mon Sep 17 00:00:00 2001 From: Fangjun Kuang Date: Sat, 10 Feb 2024 17:12:40 +0800 Subject: [PATCH] support torch 2.2.0 --- .github/workflows/windows-x64-cpu-wheels.yml | 2 +- scripts/github_actions/build-ubuntu-cuda.sh | 10 +++++----- scripts/github_actions/generate_build_matrix.py | 8 +++++++- 3 files changed, 13 insertions(+), 7 deletions(-) diff --git a/.github/workflows/windows-x64-cpu-wheels.yml b/.github/workflows/windows-x64-cpu-wheels.yml index db9a312..d43663d 100644 --- a/.github/workflows/windows-x64-cpu-wheels.yml +++ b/.github/workflows/windows-x64-cpu-wheels.yml @@ -3,7 +3,7 @@ name: build-wheels-cpu-win64 on: push: branches: - - fix-wheel + - fix-wheel-2 tags: - '*' workflow_dispatch: diff --git a/scripts/github_actions/build-ubuntu-cuda.sh b/scripts/github_actions/build-ubuntu-cuda.sh index bb5d586..56347f5 100755 --- a/scripts/github_actions/build-ubuntu-cuda.sh +++ b/scripts/github_actions/build-ubuntu-cuda.sh @@ -26,10 +26,10 @@ fi yum -y install openssl-devel bzip2-devel libffi-devel xz-devel wget redhat-lsb-core -echo "Installing ${PYTHON_VERSION}.3" -curl -O https://www.python.org/ftp/python/${PYTHON_VERSION}.3/Python-${PYTHON_VERSION}.3.tgz -tar xf Python-${PYTHON_VERSION}.3.tgz -pushd Python-${PYTHON_VERSION}.3 +echo "Installing ${PYTHON_VERSION}.2" +curl -O https://www.python.org/ftp/python/${PYTHON_VERSION}.2/Python-${PYTHON_VERSION}.2.tgz +tar xf Python-${PYTHON_VERSION}.2.tgz +pushd Python-${PYTHON_VERSION}.2 PYTHON_INSTALL_DIR=$PWD/py-${PYTHON_VERSION} @@ -44,7 +44,7 @@ make install >/dev/null 2>&1 popd echo "pwd: $PWD" -# rm -rf Python-${PYTHON_VERSION}.3 +# rm -rf Python-${PYTHON_VERSION}.2 export PATH=$PYTHON_INSTALL_DIR/bin:$PATH export LD_LIBRARY_PATH=$PYTHON_INSTALL_DIR/lib:$LD_LIBRARY_PATH diff --git a/scripts/github_actions/generate_build_matrix.py b/scripts/github_actions/generate_build_matrix.py index 72f945c..85f9541 100755 --- a/scripts/github_actions/generate_build_matrix.py +++ b/scripts/github_actions/generate_build_matrix.py @@ -165,10 +165,16 @@ def generate_build_matrix(enable_cuda, for_windows, for_macos, test_only_latest_ if not for_windows else ["11.8.0", "12.1.0"], }, + "2.2.0": { + "python-version": ["3.8", "3.9", "3.10", "3.11", "3.12"], + "cuda": ["11.8", "12.1"] # default 12.1 + if not for_windows + else ["11.8.0", "12.1.0"], + }, # https://github.com/Jimver/cuda-toolkit/blob/master/src/links/windows-links.ts } if test_only_latest_torch: - latest = "2.1.2" + latest = "2.2.0" matrix = {latest: matrix[latest]} if for_windows or for_macos: