diff --git a/build_m1_domains.sh b/build_m1_domains.sh deleted file mode 100755 index e574cb005..000000000 --- a/build_m1_domains.sh +++ /dev/null @@ -1,45 +0,0 @@ -#!/bin/zsh -# Script used to build domain libraries wheels for M1 -source ~/miniconda3/etc/profile.d/conda.sh -set -ex -TORCH_VERSION=1.11.0 -TORCHVISION_VERSION=0.12.0 -TORCHAUDIO_VERSION=0.11.0 -TORCHTEXT_VERSION=0.12.0 - -for PYTHON_VERSION in 3.8 3.9 3.10; do - PY_VERSION=${PYTHON_VERSION/.} - conda create -yn whl-py${PY_VERSION}-torch-${TORCH_VERSION} python=${PYTHON_VERSION} numpy libpng openjpeg wheel pkg-config - conda activate whl-py${PY_VERSION}-torch-${TORCH_VERSION} - python3 -mpip install torch --extra-index-url=https://download.pytorch.org/whl/test torch==${TORCH_VERSION} - python3 -mpip install delocate - - pushd ~/git/pytorch/vision - git checkout release/${TORCHVISION_VERSION%.*} - rm -rf build - BUILD_VERSION=${TORCHVISION_VERSION} python3 setup.py bdist_wheel - WHL_NAME=torchvision-${TORCHVISION_VERSION}-cp${PY_VERSION}-cp${PY_VERSION}-macosx_11_0_arm64.whl - DYLD_FALLBACK_LIBRARY_PATH="$(dirname $(dirname $(which python)))/lib" delocate-wheel -v --ignore-missing-dependencies dist/${WHL_NAME} - python3 -mpip install dist/${WHL_NAME} - popd - - pushd ~/git/pytorch/audio - git checkout release/${TORCHAUDIO_VERSION%.*} - rm -rf build - BUILD_VERSION=${TORCHAUDIO_VERSION} python3 setup.py bdist_wheel - WHL_NAME=torchaudio-${TORCHAUDIO_VERSION}-cp${PY_VERSION}-cp${PY_VERSION}-macosx_11_0_arm64.whl - python3 -mpip install dist/${WHL_NAME} - popd - - pushd ~/git/pytorch/text - git checkout release/${TORCHTEXT_VERSION%.*} - rm -rf build - BUILD_VERSION=${TORCHTEXT_VERSION} python3 setup.py bdist_wheel - WHL_NAME=torchtext-${TORCHTEXT_VERSION}-cp${PY_VERSION}-cp${PY_VERSION}-macosx_11_0_arm64.whl - python3 -mpip install dist/${WHL_NAME} - popd - - python -c "import torch;import torchvision;print('Is torchvision useable?', all(x is not None for x in [torch.ops.image.decode_png, torch.ops.torchvision.roi_align]))" - python -c "import torch;import torchaudio;torchaudio.set_audio_backend('sox_io')" -done - diff --git a/conda/upload.sh b/conda/upload.sh deleted file mode 100755 index 404ee77e7..000000000 --- a/conda/upload.sh +++ /dev/null @@ -1,28 +0,0 @@ -#!/bin/bash - -set -ex - -# Upload linux conda packages (from inside the docker) -echo "Trying to upload conda packages from $HOST_PACKAGE_DIR" -if [[ -n "$HOST_PACKAGE_DIR" && -d "$HOST_PACKAGE_DIR" ]]; then - ls "$HOST_PACKAGE_DIR" | xargs -I {} anaconda upload "$HOST_PACKAGE_DIR"/{} -u pytorch --label main -else - echo "Couldn't find $HOST_PACKAGE_DIR" -fi - -# Upload linux conda packages (from outside the docker) -# This env variable should only be populated if this was called by cron/upload.sh -echo "Trying to upload conda packages from ${today}/conda_pkgs" -if [[ -n "$today" && -d "${today}/conda_pkgs" ]]; then - ls "${today}/conda_pkgs" | xargs -I {} anaconda upload "${today}/conda_pkgs"/{} -u pytorch --label main -else - echo "Couldn't find ${today}/conda_pkgs" -fi - -# Upload mac conda packages -echo "Trying to upload conda packages from $MAC_CONDA_FINAL_FOLDER" -if [[ -n "$MAC_CONDA_FINAL_FOLDER" && -d "$MAC_CONDA_FINAL_FOLDER" ]]; then - ls "$MAC_CONDA_FINAL_FOLDER" | xargs -I {} anaconda upload "$MAC_CONDA_FINAL_FOLDER"/{} -u pytorch --label main -else - echo "Couldn't find $MAC_CONDA_FINAL_FOLDER" -fi diff --git a/manywheel/upload.sh b/manywheel/upload.sh deleted file mode 100755 index a0c7b5b85..000000000 --- a/manywheel/upload.sh +++ /dev/null @@ -1,44 +0,0 @@ -set -ex - -# PIP_UPLOAD_FOLDER should end in a slash. This is to handle it being empty -# (when uploading to e.g. whl/cpu/) and also to handle nightlies (when -# uploading to e.g. /whl/nightly/cpu) - -if [[ -z "$PACKAGE_ROOT_DIR" ]]; then - PACKAGE_ROOT_DIR="$(pwd)" -fi - -# Upload for all CUDA/cpu versions if not given one to use -if [[ -z "$CUDA_VERSIONS" ]]; then - CUDA_VERSIONS=('cpu' 'cu90' 'cu100' 'cu101') -fi - -# Make sure the user specifically refers to an upload folder -if [[ -z "$PIP_UPLOAD_FOLDER" ]]; then - echo 'The upload folder is not set. We refuse to upload.' - echo 'Please set PIP_UPLOAD_FOLDER' - exit 1 -fi - -for cuda_ver in "${CUDA_VERSIONS[@]}"; do - s3_wheel_dir="s3://pytorch/whl/${PIP_UPLOAD_FOLDER}${cuda_ver}/" - s3_libtorch_dir="s3://pytorch/libtorch/${PIP_UPLOAD_FOLDER}${cuda_ver}/" - if [[ "$cuda_ver" == cpu ]]; then - wheel_dir="${PACKAGE_ROOT_DIR}/wheelhousecpu/" - libtorch_dir="${PACKAGE_ROOT_DIR}/libtorch_housecpu/" - else - wheel_dir="${PACKAGE_ROOT_DIR}/wheelhouse${cuda_ver:2:2}/" - libtorch_dir="${PACKAGE_ROOT_DIR}/libtorch_house${cuda_ver:2:2}/" - fi - - # Upload the wheels to s3 - if [[ -d "$wheel_dir" ]]; then - echo "Uploading all of: $(ls $wheel_dir) to $s3_wheel_dir" - ls "$wheel_dir" | xargs -I {} aws s3 cp "$wheel_dir"/{} "$s3_wheel_dir" --acl public-read - fi - - if [[ -d "$libtorch_dir" ]]; then - echo "Uploading all of: $(ls $libtorch_dir) to $s3_libtorch_dir" - ls "$libtorch_dir" | xargs -I {} aws s3 cp "$libtorch_dir"/{} "$s3_libtorch_dir" --acl public-read - fi -done diff --git a/windows/build_all.bat b/windows/build_all.bat deleted file mode 100755 index f60da8c76..000000000 --- a/windows/build_all.bat +++ /dev/null @@ -1,104 +0,0 @@ -@echo off - -if "%~1"=="" goto arg_error -if "%~2"=="" goto arg_error -if NOT "%~3"=="" goto arg_error -goto arg_end - -:arg_error - -echo Illegal number of parameters. Pass pytorch version, build number -exit /b 1 - -:arg_end - -set PYTORCH_BUILD_VERSION=%~1 -set PYTORCH_BUILD_NUMBER=%~2 - -REM Install Miniconda3 -set "CONDA_HOME=%CD%\conda" -set "tmp_conda=%CONDA_HOME%" -set "miniconda_exe=%CD%\miniconda.exe" -rmdir /s /q conda -del miniconda.exe -curl -k https://repo.continuum.io/miniconda/Miniconda3-latest-Windows-x86_64.exe -o "%miniconda_exe%" -call ..\conda\install_conda.bat - -set "PATH=%CONDA_HOME%;%CONDA_HOME%\scripts;%CONDA_HOME%\Library\bin;%PATH%" -set "ORIG_PATH=%PATH%" - -conda remove -n py36 --all -y || rmdir %CONDA_HOME%\envs\py36 /s -conda remove -n py37 --all -y || rmdir %CONDA_HOME%\envs\py37 /s - -conda create -n py36 -y -q numpy=1.11 mkl=2018 pyyaml boto3 cmake ninja typing_extensions python=3.6 -conda create -n py37 -y -q numpy=1.11 mkl=2018 pyyaml boto3 cmake ninja typing_extensions python=3.7 - -REM Install MKL -rmdir /s /q mkl -del mkl_2018.2.185.7z -curl https://s3.amazonaws.com/ossci-windows/mkl_2018.2.185.7z -k -O -7z x -aoa mkl_2018.2.185.7z -omkl -set CMAKE_INCLUDE_PATH=%cd%\\mkl\\include -set LIB=%cd%\\mkl\\lib;%LIB% - -REM Download MAGMA Files -for %%p in ( - cuda80 - cuda90 - cuda92 - ) do ( - rmdir /s /q magma_%%p_release - del magma_%%p_release.7z - curl -k https://s3.amazonaws.com/ossci-windows/magma_%%p_release_mkl_2018.2.185.7z -o magma_%%p_release.7z - 7z x -aoa magma_%%p_release.7z -omagma_%%p_release - ) - -REM Install sccache -mkdir %CD%\\tmp_bin -curl -k https://s3.amazonaws.com/ossci-windows/sccache.exe --output %CD%\\tmp_bin\\sccache.exe -copy %CD%\\tmp_bin\\sccache.exe %CD%\\tmp_bin\\nvcc.exe - -set CUDA_NVCC_EXECUTABLE=%CD%\\tmp_bin\\nvcc -set "PATH=%CD%\\tmp_bin;%PATH%" - -set PYTORCH_BINARY_BUILD=1 -set TH_BINARY_BUILD=1 - -@setlocal EnableDelayedExpansion -for %%v in ( - py35 - py36 - py37 - ) do ( - REM Activate Python Environment - set "CONDA_LIB_PATH=%CONDA_HOME%\envs\%%v\Library\bin" - set "PATH=%CONDA_HOME%\envs\%%v;%CONDA_HOME%\envs\%%v\scripts;%CONDA_HOME%\envs\%%v\Library\bin;%ORIG_PATH%" - pip install ninja - for %%c in ( - cpu - 80 - 90 - 92 - ) do ( - @setlocal - - REM Set Flags - if NOT "%%c"=="cpu" ( - if NOT "%%c"=="92" ( - set MAGMA_HOME=%cd%\\magma_!CUDA_PREFIX!_release - ) else ( - set MAGMA_HOME=%cd%\\magma_!CUDA_PREFIX!_release\magma_cuda92\magma\install - ) - set CUDA_VERSION=%%c - set CUDA_PREFIX=cuda!CUDA_VERSION! - ) else ( - set CUDA_PREFIX=cpu - ) - call !CUDA_PREFIX!.bat - @endlocal - ) - ) - -@endlocal - -set "PATH=%ORIG_PATH%" diff --git a/windows/build_pytorch.bat b/windows/build_pytorch.bat index 635138735..d4a1249ed 100644 --- a/windows/build_pytorch.bat +++ b/windows/build_pytorch.bat @@ -74,8 +74,6 @@ set LIB=%cd%\mkl\lib;%LIB% :: Download MAGMA Files on CUDA builds set MAGMA_VERSION=2.5.4 -if "%CUDA_VERSION%" == "92" set MAGMA_VERSION=2.5.2 -if "%CUDA_VERSION%" == "100" set MAGMA_VERSION=2.5.2 if "%DEBUG%" == "1" ( set BUILD_TYPE=debug