diff options
13 files changed, 160 insertions, 171 deletions
diff --git a/pkgs/development/python-modules/torch/bin.nix b/pkgs/development/python-modules/torch/bin.nix index 5badb88d3750c..ac83f10157261 100644 --- a/pkgs/development/python-modules/torch/bin.nix +++ b/pkgs/development/python-modules/torch/bin.nix @@ -20,7 +20,7 @@ let pyVerNoDot = builtins.replaceStrings [ "." ] [ "" ] python.pythonVersion; srcs = import ./binary-hashes.nix version; unsupported = throw "Unsupported system"; - version = "1.11.0"; + version = "1.12.1"; in buildPythonPackage { inherit version; @@ -68,7 +68,7 @@ in buildPythonPackage { pythonImportsCheck = [ "torch" ]; meta = with lib; { - description = "Open source, prototype-to-production deep learning platform"; + description = "PyTorch: Tensors and Dynamic neural networks in Python with strong GPU acceleration"; homepage = "https://pytorch.org/"; changelog = "https://github.com/pytorch/pytorch/releases/tag/v${version}"; # Includes CUDA and Intel MKL, but redistributions of the binary are not limited. diff --git a/pkgs/development/python-modules/torch/binary-hashes.nix b/pkgs/development/python-modules/torch/binary-hashes.nix index fccc7ce642e77..2169e1873b0b5 100644 --- a/pkgs/development/python-modules/torch/binary-hashes.nix +++ b/pkgs/development/python-modules/torch/binary-hashes.nix @@ -6,61 +6,61 @@ # To add a new version, run "prefetch.sh 'new-version'" to paste the generated file as follows. version : builtins.getAttr version { - "1.11.0" = { + "1.12.1" = { x86_64-linux-37 = { - name = "torch-1.11.0-cp37-cp37m-linux_x86_64.whl"; - url = "https://download.pytorch.org/whl/cu113/torch-1.11.0%2Bcu113-cp37-cp37m-linux_x86_64.whl"; - hash = "sha256-9WMzRw2uo8lweLN2B+ADXMz3L8XDb9hFRuGkuNmUTys="; + name = "torch-1.12.1-cp37-cp37m-linux_x86_64.whl"; + url = "https://download.pytorch.org/whl/cu116/torch-1.12.1%2Bcu116-cp37-cp37m-linux_x86_64.whl"; + hash = "sha256-/JtHhuxUvmfqqLDHyZmeL0riuJocGOQd4VFaGQRAxpE="; }; x86_64-linux-38 = { - name = "torch-1.11.0-cp38-cp38-linux_x86_64.whl"; - url = "https://download.pytorch.org/whl/cu113/torch-1.11.0%2Bcu113-cp38-cp38-linux_x86_64.whl"; - hash = "sha256-tqeZvbbuPZFOXmK920J21KECSMGvTy0hdzjl+e4nSFs="; + name = "torch-1.12.1-cp38-cp38-linux_x86_64.whl"; + url = "https://download.pytorch.org/whl/cu116/torch-1.12.1%2Bcu116-cp38-cp38-linux_x86_64.whl"; + hash = "sha256-3aMSkBIgiVCHzIPTZlRko9wXHQRGDGHDGvRj77+1SJY="; }; x86_64-linux-39 = { - name = "torch-1.11.0-cp39-cp39-linux_x86_64.whl"; - url = "https://download.pytorch.org/whl/cu113/torch-1.11.0%2Bcu113-cp39-cp39-linux_x86_64.whl"; - hash = "sha256-6RJrCl2VcEvuQKnQ7xy9gtjceGPkY4o3a+9wLf1lk3A="; + name = "torch-1.12.1-cp39-cp39-linux_x86_64.whl"; + url = "https://download.pytorch.org/whl/cu116/torch-1.12.1%2Bcu116-cp39-cp39-linux_x86_64.whl"; + hash = "sha256-dyVCDavr/K9EmE7c4yg+6pH5jw99WHS8aMehZL2BJuM="; }; x86_64-linux-310 = { - name = "torch-1.11.0-cp310-cp310-linux_x86_64.whl"; - url = "https://download.pytorch.org/whl/cu113/torch-1.11.0%2Bcu113-cp310-cp310-linux_x86_64.whl"; - hash = "sha256-powzZXpUYTHrm8ROKpjS+nBKr66GFGCwUbgoE4Usy0Q="; + name = "torch-1.12.1-cp310-cp310-linux_x86_64.whl"; + url = "https://download.pytorch.org/whl/cu116/torch-1.12.1%2Bcu116-cp310-cp310-linux_x86_64.whl"; + hash = "sha256-trwxJEqigYkp+7MMSDwiHfRx6dhW6AXFof9ysTGunns="; }; x86_64-darwin-37 = { - name = "torch-1.11.0-cp37-none-macosx_10_9_x86_64.whl"; - url = "https://download.pytorch.org/whl/cpu/torch-1.11.0-cp37-none-macosx_10_9_x86_64.whl"; - hash = "sha256-aGCx0b8LsLZ6a9R/haDkyCW1GO6hO11hAZmdu8vVvAw="; + name = "torch-1.12.1-cp37-none-macosx_10_9_x86_64.whl"; + url = "https://download.pytorch.org/whl/cpu/torch-1.12.1-cp37-none-macosx_10_9_x86_64.whl"; + hash = "sha256-ijSi+7qgfJIeGyA/WdPW4A7TefKzhERXc70U4yiltsg="; }; x86_64-darwin-38 = { - name = "torch-1.11.0-cp38-none-macosx_10_9_x86_64.whl"; - url = "https://download.pytorch.org/whl/cpu/torch-1.11.0-cp38-none-macosx_10_9_x86_64.whl"; - hash = "sha256-DMyFzQYiej7fgJ4seV/Vdiw9Too4tcn3RMbnz4QTYbs="; + name = "torch-1.12.1-cp38-none-macosx_10_9_x86_64.whl"; + url = "https://download.pytorch.org/whl/cpu/torch-1.12.1-cp38-none-macosx_10_9_x86_64.whl"; + hash = "sha256-qDILqa2H6AylpqAW5GraTRugxUYm4TXZmyEppFQcUJ0="; }; x86_64-darwin-39 = { - name = "torch-1.11.0-cp39-none-macosx_10_9_x86_64.whl"; - url = "https://download.pytorch.org/whl/cpu/torch-1.11.0-cp39-none-macosx_10_9_x86_64.whl"; - hash = "sha256-UP2b+FxXjIccKPHLCs6d/GAkQBx/OZsXT7DzcImfRFQ="; + name = "torch-1.12.1-cp39-none-macosx_10_9_x86_64.whl"; + url = "https://download.pytorch.org/whl/cpu/torch-1.12.1-cp39-none-macosx_10_9_x86_64.whl"; + hash = "sha256-v+woQ9qmVPBP2iO6gjrwPntvdlCoc823JnUtDjcY2to="; }; x86_64-darwin-310 = { - name = "torch-1.11.0-cp310-none-macosx_10_9_x86_64.whl"; - url = "https://download.pytorch.org/whl/cpu/torch-1.11.0-cp39-none-macosx_10_9_x86_64.whl"; - hash = "sha256-UP2b+FxXjIccKPHLCs6d/GAkQBx/OZsXT7DzcImfRFQ="; + name = "torch-1.12.1-cp310-none-macosx_10_9_x86_64.whl"; + url = "https://download.pytorch.org/whl/cpu/torch-1.12.1-cp310-none-macosx_10_9_x86_64.whl"; + hash = "sha256-l2w/mXzqOO6RoN08OkIyJ4VBR0jRdh75JreJ36l8YTQ="; }; aarch64-darwin-38 = { - name = "torch-1.11.0-cp38-none-macosx_11_0_arm64.whl"; - url = "https://download.pytorch.org/whl/cpu/torch-1.11.0-cp38-none-macosx_11_0_arm64.whl"; - hash = "sha256-wVVOSddPGyw+cgLXcFa6LddGVDdYW6xkBitYD3FKROk="; + name = "torch-1.12.1-cp38-none-macosx_11_0_arm64.whl"; + url = "https://download.pytorch.org/whl/cpu/torch-1.12.1-cp38-none-macosx_11_0_arm64.whl"; + hash = "sha256-A+McN3Edss0gHgLeWCbeh1Up5FpVYx0xeq3OLx7UWqg="; }; aarch64-darwin-39 = { - name = "torch-1.11.0-cp39-none-macosx_11_0_arm64.whl"; - url = "https://download.pytorch.org/whl/cpu/torch-1.11.0-cp39-none-macosx_11_0_arm64.whl"; - hash = "sha256-DkivZq11Xw+cXyZkAopBT1fEnWrcN+d+Bv4ABNpO22E="; + name = "torch-1.12.1-cp39-none-macosx_11_0_arm64.whl"; + url = "https://download.pytorch.org/whl/cpu/torch-1.12.1-cp39-none-macosx_11_0_arm64.whl"; + hash = "sha256-af4srnw5zK3WWhI3k9MODbiB8cGSeUVRnFwXMjExQ34="; }; aarch64-darwin-310 = { - name = "torch-1.11.0-cp310-none-macosx_11_0_arm64.whl"; - url = "https://download.pytorch.org/whl/cpu/torch-1.11.0-cp39-none-macosx_11_0_arm64.whl"; - hash = "sha256-DkivZq11Xw+cXyZkAopBT1fEnWrcN+d+Bv4ABNpO22E="; + name = "torch-1.12.1-cp310-none-macosx_11_0_arm64.whl"; + url = "https://download.pytorch.org/whl/cpu/torch-1.12.1-cp310-none-macosx_11_0_arm64.whl"; + hash = "sha256-aBBORxWlXEuymoXGqNV9gg4HV9o2O+G6aA+ozFvhe1I="; }; }; } diff --git a/pkgs/development/python-modules/torch/breakpad-sigstksz.patch b/pkgs/development/python-modules/torch/breakpad-sigstksz.patch deleted file mode 100644 index 33a2304cb9b1a..0000000000000 --- a/pkgs/development/python-modules/torch/breakpad-sigstksz.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/third_party/breakpad/src/client/linux/handler/exception_handler.cc b/third_party/breakpad/src/client/linux/handler/exception_handler.cc -index ca353c4099..499be0a986 100644 ---- a/third_party/breakpad/src/client/linux/handler/exception_handler.cc -+++ b/third_party/breakpad/src/client/linux/handler/exception_handler.cc -@@ -138,7 +138,7 @@ void InstallAlternateStackLocked() { - // SIGSTKSZ may be too small to prevent the signal handlers from overrunning - // the alternative stack. Ensure that the size of the alternative stack is - // large enough. -- static const unsigned kSigStackSize = std::max(16384, SIGSTKSZ); -+ const unsigned kSigStackSize = std::max<unsigned>(16384, SIGSTKSZ); - - // Only set an alternative stack if there isn't already one, or if the current - // one is too small. diff --git a/pkgs/development/python-modules/torch/default.nix b/pkgs/development/python-modules/torch/default.nix index 9d4c64861a3fb..672fcf75d3316 100644 --- a/pkgs/development/python-modules/torch/default.nix +++ b/pkgs/development/python-modules/torch/default.nix @@ -122,31 +122,26 @@ let in buildPythonPackage rec { pname = "torch"; # Don't forget to update torch-bin to the same version. - version = "1.11.0"; + version = "1.12.1"; format = "setuptools"; disabled = pythonOlder "3.7.0"; outputs = [ - "out" # output standard python package - "dev" # output libtorch headers - "lib" # output libtorch libraries + "out" # output standard python package + "dev" # output libtorch headers + "lib" # output libtorch libraries ]; src = fetchFromGitHub { - owner = "pytorch"; - repo = "pytorch"; - rev = "v${version}"; + owner = "pytorch"; + repo = "pytorch"; + rev = "refs/tags/v${version}"; fetchSubmodules = true; - sha256 = "sha256-CEu63tdRBAF8CTchO3Qu8gUNObQylX6U08yDTI4/c/0="; + hash = "sha256-8378BVOBFCRYRG1+yIYFSPKmb1rFOLgR+8pNZKt9NfI="; }; - patches = [ - # Fix for a breakpad incompatibility with glibc>2.33 - # https://github.com/pytorch/pytorch/issues/70297 - # https://github.com/google/breakpad/commit/605c51ed96ad44b34c457bbca320e74e194c317e - ./breakpad-sigstksz.patch - ] ++ lib.optionals (stdenv.isDarwin && stdenv.isx86_64) [ + patches = lib.optionals (stdenv.isDarwin && stdenv.isx86_64) [ # pthreadpool added support for Grand Central Dispatch in April # 2020. However, this relies on functionality (DISPATCH_APPLY_AUTO) # that is available starting with macOS 10.13. However, our current @@ -208,7 +203,7 @@ in buildPythonPackage rec { PYTORCH_BUILD_VERSION = version; PYTORCH_BUILD_NUMBER = 0; - USE_SYSTEM_NCCL=setBool useSystemNccl; # don't build pytorch's third_party NCCL + USE_SYSTEM_NCCL = setBool useSystemNccl; # don't build pytorch's third_party NCCL # Suppress a weird warning in mkl-dnn, part of ideep in pytorch # (upstream seems to have fixed this in the wrong place?) @@ -243,15 +238,17 @@ in buildPythonPackage rec { pillow six future tensorboard protobuf ] ++ lib.optionals MPISupport [ mpi ]; - checkInputs = [ hypothesis ninja psutil ]; - # Tests take a long time and may be flaky, so just sanity-check imports doCheck = false; + pythonImportsCheck = [ "torch" ]; + checkInputs = [ hypothesis ninja psutil ]; + checkPhase = with lib.versions; with lib.strings; concatStringsSep " " [ + "runHook preCheck" cudaStubEnv "${python.interpreter} test/run_test.py" "--exclude" @@ -264,13 +261,15 @@ in buildPythonPackage rec { # tensorboard has acceptable failures for pytorch 1.3.x due to dependencies on tensorboard-plugins (optionalString (majorMinor version == "1.3" ) "tensorboard") ]) + "runHook postCheck" ]; + postInstall = '' find "$out/${python.sitePackages}/torch/include" "$out/${python.sitePackages}/torch/lib" -type f -exec remove-references-to -t ${stdenv.cc} '{}' + mkdir $dev cp -r $out/${python.sitePackages}/torch/include $dev/include - cp -r $out/${python.sitePackages}/torch/share $dev/share + cp -r $out/${python.sitePackages}/torch/share $dev/share # Fix up library paths for split outputs substituteInPlace \ @@ -282,7 +281,7 @@ in buildPythonPackage rec { --replace \''${_IMPORT_PREFIX}/lib "$lib/lib" mkdir $lib - mv $out/${python.sitePackages}/torch/lib $lib/lib + mv $out/${python.sitePackages}/torch/lib $lib/lib ln -s $lib/lib $out/${python.sitePackages}/torch/lib ''; @@ -312,11 +311,12 @@ in buildPythonPackage rec { }; meta = with lib; { - description = "Open source, prototype-to-production deep learning platform"; - homepage = "https://pytorch.org/"; - license = licenses.bsd3; + changelog = "https://github.com/pytorch/pytorch/releases/tag/v${version}"; + # keep PyTorch in the description so the package can be found under that name on search.nixos.org + description = "PyTorch: Tensors and Dynamic neural networks in Python with strong GPU acceleration"; + homepage = "https://pytorch.org/"; + license = licenses.bsd3; maintainers = with maintainers; [ teh thoughtpolice tscholak ]; # tscholak esp. for darwin-related builds - platforms = with platforms; linux ++ lib.optionals (!cudaSupport) darwin; - broken = stdenv.isLinux && stdenv.isAarch64; + platforms = with platforms; linux ++ lib.optionals (!cudaSupport) darwin; }; } diff --git a/pkgs/development/python-modules/torch/prefetch.sh b/pkgs/development/python-modules/torch/prefetch.sh index 31aae438dc56d..78151ae787a52 100755 --- a/pkgs/development/python-modules/torch/prefetch.sh +++ b/pkgs/development/python-modules/torch/prefetch.sh @@ -5,14 +5,15 @@ set -eou pipefail version=$1 -linux_bucket="https://download.pytorch.org/whl/cu113" +linux_cuda_version="cu116" +linux_bucket="https://download.pytorch.org/whl/${linux_cuda_version}" darwin_bucket="https://download.pytorch.org/whl/cpu" url_and_key_list=( - "x86_64-linux-37 $linux_bucket/torch-${version}%2Bcu113-cp37-cp37m-linux_x86_64.whl torch-${version}-cp37-cp37m-linux_x86_64.whl" - "x86_64-linux-38 $linux_bucket/torch-${version}%2Bcu113-cp38-cp38-linux_x86_64.whl torch-${version}-cp38-cp38-linux_x86_64.whl" - "x86_64-linux-39 $linux_bucket/torch-${version}%2Bcu113-cp39-cp39-linux_x86_64.whl torch-${version}-cp39-cp39-linux_x86_64.whl" - "x86_64-linux-310 $linux_bucket/torch-${version}%2Bcu113-cp310-cp310-linux_x86_64.whl torch-${version}-cp310-cp310-linux_x86_64.whl" + "x86_64-linux-37 $linux_bucket/torch-${version}%2B${linux_cuda_version}-cp37-cp37m-linux_x86_64.whl torch-${version}-cp37-cp37m-linux_x86_64.whl" + "x86_64-linux-38 $linux_bucket/torch-${version}%2B${linux_cuda_version}-cp38-cp38-linux_x86_64.whl torch-${version}-cp38-cp38-linux_x86_64.whl" + "x86_64-linux-39 $linux_bucket/torch-${version}%2B${linux_cuda_version}-cp39-cp39-linux_x86_64.whl torch-${version}-cp39-cp39-linux_x86_64.whl" + "x86_64-linux-310 $linux_bucket/torch-${version}%2B${linux_cuda_version}-cp310-cp310-linux_x86_64.whl torch-${version}-cp310-cp310-linux_x86_64.whl" "x86_64-darwin-37 $darwin_bucket/torch-${version}-cp37-none-macosx_10_9_x86_64.whl torch-${version}-cp37-none-macosx_10_9_x86_64.whl" "x86_64-darwin-38 $darwin_bucket/torch-${version}-cp38-none-macosx_10_9_x86_64.whl torch-${version}-cp38-none-macosx_10_9_x86_64.whl" "x86_64-darwin-39 $darwin_bucket/torch-${version}-cp39-none-macosx_10_9_x86_64.whl torch-${version}-cp39-none-macosx_10_9_x86_64.whl" diff --git a/pkgs/development/python-modules/torchaudio/bin.nix b/pkgs/development/python-modules/torchaudio/bin.nix index aabec0a8d4970..7388bbc7d26f9 100644 --- a/pkgs/development/python-modules/torchaudio/bin.nix +++ b/pkgs/development/python-modules/torchaudio/bin.nix @@ -14,7 +14,7 @@ buildPythonPackage rec { pname = "torchaudio"; - version = "0.11.0"; + version = "0.12.1"; format = "wheel"; src = diff --git a/pkgs/development/python-modules/torchaudio/binary-hashes.nix b/pkgs/development/python-modules/torchaudio/binary-hashes.nix index 2cd39f3a9142e..8731c63787cf7 100644 --- a/pkgs/development/python-modules/torchaudio/binary-hashes.nix +++ b/pkgs/development/python-modules/torchaudio/binary-hashes.nix @@ -6,61 +6,61 @@ # To add a new version, run "prefetch.sh 'new-version'" to paste the generated file as follows. version : builtins.getAttr version { - "0.11.0" = { + "0.12.1" = { x86_64-linux-37 = { - name = "torchaudio-0.11.0-cp37-cp37m-linux_x86_64.whl"; - url = "https://download.pytorch.org/whl/cu113/torchaudio-0.11.0%2Bcu113-cp37-cp37m-linux_x86_64.whl"; - hash = "sha256-AdqgntXh2rTD7rBePshFAQ2tVl7b+734wG4r471/Y2U="; + name = "torchaudio-0.12.1-cp37-cp37m-linux_x86_64.whl"; + url = "https://download.pytorch.org/whl/cu116/torchaudio-0.12.1%2Bcu116-cp37-cp37m-linux_x86_64.whl"; + hash = "sha256-8Z72lazhnV2ZBtnvpdm5ZHhiyE/wHwEpQ9UzZoi//mw="; }; x86_64-linux-38 = { - name = "torchaudio-0.11.0-cp38-cp38-linux_x86_64.whl"; - url = "https://download.pytorch.org/whl/cu113/torchaudio-0.11.0%2Bcu113-cp38-cp38-linux_x86_64.whl"; - hash = "sha256-zuCHDpz3bkOUjYWprqX9VXoUbXfR8Vhdf1VFfOUg8z4="; + name = "torchaudio-0.12.1-cp38-cp38-linux_x86_64.whl"; + url = "https://download.pytorch.org/whl/cu116/torchaudio-0.12.1%2Bcu116-cp38-cp38-linux_x86_64.whl"; + hash = "sha256-CCtZ6eUhs/6kaoU0HwDDaK4JTSFKkVJF+OMAu368Zno="; }; x86_64-linux-39 = { - name = "torchaudio-0.11.0-cp39-cp39-linux_x86_64.whl"; - url = "https://download.pytorch.org/whl/cu113/torchaudio-0.11.0%2Bcu113-cp39-cp39-linux_x86_64.whl"; - hash = "sha256-btI9TpsOjeLnIz6J56avNv4poJTpXjjhDbMy6+ZFQvI="; + name = "torchaudio-0.12.1-cp39-cp39-linux_x86_64.whl"; + url = "https://download.pytorch.org/whl/cu116/torchaudio-0.12.1%2Bcu116-cp39-cp39-linux_x86_64.whl"; + hash = "sha256-pNa5fV9vC1cXeDLhHTCscO7RO2lst2Vmm0K7NzINqgw="; }; x86_64-linux-310 = { - name = "torchaudio-0.11.0-cp310-cp310-linux_x86_64.whl"; - url = "https://download.pytorch.org/whl/cu113/torchaudio-0.11.0%2Bcu113-cp310-cp310-linux_x86_64.whl"; - hash = "sha256-Zk+AWytEXfJ+HM69BAPhVsvN6pgQwC6uaW7Xux2row4="; + name = "torchaudio-0.12.1-cp310-cp310-linux_x86_64.whl"; + url = "https://download.pytorch.org/whl/cu116/torchaudio-0.12.1%2Bcu116-cp310-cp310-linux_x86_64.whl"; + hash = "sha256-KdeBVGBQ1lQxXxCQGwX17E1iptMis0Rfex++o4JmVog="; }; x86_64-darwin-37 = { - name = "torchaudio-0.11.0-cp37-cp37m-macosx_10_15_x86_64.whl"; - url = "https://download.pytorch.org/whl/torchaudio-0.11.0-cp37-cp37m-macosx_10_15_x86_64.whl"; - hash = "sha256-uaTT4athEWHAZe0hBoBIM/9LhfZNhAIexZBGg2MWn50="; + name = "torchaudio-0.12.1-cp37-cp37m-macosx_10_9_x86_64.whl"; + url = "https://download.pytorch.org/whl/torchaudio-0.12.1-cp37-cp37m-macosx_10_9_x86_64.whl"; + hash = "sha256-I9vPN68vQdSRwDN8qUUB7H71iK2xdm4esoAz+sVJu9k="; }; x86_64-darwin-38 = { - name = "torchaudio-0.11.0-cp38-cp38-macosx_10_15_x86_64.whl"; - url = "https://download.pytorch.org/whl/torchaudio-0.11.0-cp38-cp38-macosx_10_15_x86_64.whl"; - hash = "sha256-9OndqejTzgu9XnkZJiGfUFS4uFNlx5vi7pAzOs+a2/w="; + name = "torchaudio-0.12.1-cp38-cp38-macosx_10_9_x86_64.whl"; + url = "https://download.pytorch.org/whl/torchaudio-0.12.1-cp38-cp38-macosx_10_9_x86_64.whl"; + hash = "sha256-pMjBWx6BCpO7d7J/pJFZvqIlO1k++UA5lG7Emu9Rdk8="; }; x86_64-darwin-39 = { - name = "torchaudio-0.11.0-cp39-cp39-macosx_10_15_x86_64.whl"; - url = "https://download.pytorch.org/whl/torchaudio-0.11.0-cp39-cp39-macosx_10_15_x86_64.whl"; - hash = "sha256-cNi8B/J3YI0jqaoI2z+68DVmAlS8EtmzYWQMRVZ3dVk="; + name = "torchaudio-0.12.1-cp39-cp39-macosx_10_9_x86_64.whl"; + url = "https://download.pytorch.org/whl/torchaudio-0.12.1-cp39-cp39-macosx_10_9_x86_64.whl"; + hash = "sha256-CPkrxTaC07rYYG3ttwpJ5aD3z5MGyRc/B027qXeFRC4="; }; x86_64-darwin-310 = { - name = "torchaudio-0.11.0-cp310-cp310-macosx_10_15_x86_64.whl"; - url = "https://download.pytorch.org/whl/torchaudio-0.11.0-cp310-cp310-macosx_10_15_x86_64.whl"; - hash = "sha256-g2Pj2wqK9YIP19O/g5agryPcgiHJqdS2Di44mAVJKUQ="; + name = "torchaudio-0.12.1-cp310-cp310-macosx_10_9_x86_64.whl"; + url = "https://download.pytorch.org/whl/torchaudio-0.12.1-cp310-cp310-macosx_10_9_x86_64.whl"; + hash = "sha256-3BOL7gayMFRC/BMhcfKgHV9CUJ6qIb34fD0mpvSgn90="; }; aarch64-darwin-38 = { - name = "torchaudio-0.11.0-cp38-cp38-macosx_11_0_arm64.whl"; - url = "https://download.pytorch.org/whl/torchaudio-0.11.0-cp38-cp38-macosx_11_0_arm64.whl"; - hash = "sha256-MX/Y7Dn92zrx2tkGWTuezcPt9o5/V4DEL43pVlha5IA="; + name = "torchaudio-0.12.1-cp38-cp38-macosx_11_0_arm64.whl"; + url = "https://download.pytorch.org/whl/cpu/torchaudio-0.12.1-cp38-cp38-macosx_11_0_arm64.whl"; + hash = "sha256-g8CLcabcjiPB17AHgKu55MKVKOR6bmRP497nrCJjgh4="; }; aarch64-darwin-39 = { - name = "torchaudio-0.11.0-cp39-cp39-macosx_11_0_arm64.whl"; - url = "https://download.pytorch.org/whl/torchaudio-0.11.0-cp39-cp39-macosx_11_0_arm64.whl"; - hash = "sha256-5eVRP83VeHAGGWW++/B2V4eyX0mcPgC1j02ETkQYMXc="; + name = "torchaudio-0.12.1-cp39-cp39-macosx_11_0_arm64.whl"; + url = "https://download.pytorch.org/whl/cpu/torchaudio-0.12.1-cp39-cp39-macosx_11_0_arm64.whl"; + hash = "sha256-L8WivI6KrUdbxRnzyCuWSeFLXGV0h/+nEs98UUFD6dc="; }; aarch64-darwin-310 = { - name = "torchaudio-0.11.0-cp310-cp310-macosx_11_0_arm64.whl"; - url = "https://download.pytorch.org/whl/torchaudio-0.11.0-cp310-cp310-macosx_11_0_arm64.whl"; - hash = "sha256-06OyzOuV8E7ZNtozvFO9Zm2rBxWnnbM65HGYUiQdwtI="; + name = "torchaudio-0.12.1-cp310-cp310-macosx_11_0_arm64.whl"; + url = "https://download.pytorch.org/whl/cpu/torchaudio-0.12.1-cp310-cp310-macosx_11_0_arm64.whl"; + hash = "sha256-HYH3GDfV1b5lHoXKn6k3fstFE7ASnd+wJVQOHCQG0+Y="; }; }; } diff --git a/pkgs/development/python-modules/torchaudio/prefetch.sh b/pkgs/development/python-modules/torchaudio/prefetch.sh index 294c917e0d17b..72b919c479dd3 100755 --- a/pkgs/development/python-modules/torchaudio/prefetch.sh +++ b/pkgs/development/python-modules/torchaudio/prefetch.sh @@ -5,21 +5,22 @@ set -eou pipefail version=$1 -linux_bucket="https://download.pytorch.org/whl/cu113" +linux_cuda_version="cu116" +linux_bucket="https://download.pytorch.org/whl/${linux_cuda_version}" darwin_bucket="https://download.pytorch.org/whl" url_and_key_list=( - "x86_64-linux-37 $linux_bucket/torchaudio-${version}%2Bcu113-cp37-cp37m-linux_x86_64.whl torchaudio-${version}-cp37-cp37m-linux_x86_64.whl" - "x86_64-linux-38 $linux_bucket/torchaudio-${version}%2Bcu113-cp38-cp38-linux_x86_64.whl torchaudio-${version}-cp38-cp38-linux_x86_64.whl" - "x86_64-linux-39 $linux_bucket/torchaudio-${version}%2Bcu113-cp39-cp39-linux_x86_64.whl torchaudio-${version}-cp39-cp39-linux_x86_64.whl" - "x86_64-linux-310 $linux_bucket/torchaudio-${version}%2Bcu113-cp310-cp310-linux_x86_64.whl torchaudio-${version}-cp310-cp310-linux_x86_64.whl" - "x86_64-darwin-37 $darwin_bucket/torchaudio-${version}-cp37-cp37m-macosx_10_15_x86_64.whl torchaudio-${version}-cp37-cp37m-macosx_10_15_x86_64.whl" - "x86_64-darwin-38 $darwin_bucket/torchaudio-${version}-cp38-cp38-macosx_10_15_x86_64.whl torchaudio-${version}-cp38-cp38-macosx_10_15_x86_64.whl" - "x86_64-darwin-39 $darwin_bucket/torchaudio-${version}-cp39-cp39-macosx_10_15_x86_64.whl torchaudio-${version}-cp39-cp39-macosx_10_15_x86_64.whl" - "x86_64-darwin-310 $darwin_bucket/torchaudio-${version}-cp310-cp310-macosx_10_15_x86_64.whl torchaudio-${version}-cp310-cp310-macosx_10_15_x86_64.whl" - "aarch64-darwin-38 $darwin_bucket/torchaudio-${version}-cp38-cp38-macosx_11_0_arm64.whl torchaudio-${version}-cp38-cp38-macosx_11_0_arm64.whl" - "aarch64-darwin-39 $darwin_bucket/torchaudio-${version}-cp39-cp39-macosx_11_0_arm64.whl torchaudio-${version}-cp39-cp39-macosx_11_0_arm64.whl" - "aarch64-darwin-310 $darwin_bucket/torchaudio-${version}-cp310-cp310-macosx_11_0_arm64.whl torchaudio-${version}-cp310-cp310-macosx_11_0_arm64.whl" + "x86_64-linux-37 $linux_bucket/torchaudio-${version}%2B${linux_cuda_version}-cp37-cp37m-linux_x86_64.whl torchaudio-${version}-cp37-cp37m-linux_x86_64.whl" + "x86_64-linux-38 $linux_bucket/torchaudio-${version}%2B${linux_cuda_version}-cp38-cp38-linux_x86_64.whl torchaudio-${version}-cp38-cp38-linux_x86_64.whl" + "x86_64-linux-39 $linux_bucket/torchaudio-${version}%2B${linux_cuda_version}-cp39-cp39-linux_x86_64.whl torchaudio-${version}-cp39-cp39-linux_x86_64.whl" + "x86_64-linux-310 $linux_bucket/torchaudio-${version}%2B${linux_cuda_version}-cp310-cp310-linux_x86_64.whl torchaudio-${version}-cp310-cp310-linux_x86_64.whl" + "x86_64-darwin-37 $darwin_bucket/torchaudio-${version}-cp37-cp37m-macosx_10_9_x86_64.whl torchaudio-${version}-cp37-cp37m-macosx_10_9_x86_64.whl" + "x86_64-darwin-38 $darwin_bucket/torchaudio-${version}-cp38-cp38-macosx_10_9_x86_64.whl torchaudio-${version}-cp38-cp38-macosx_10_9_x86_64.whl" + "x86_64-darwin-39 $darwin_bucket/torchaudio-${version}-cp39-cp39-macosx_10_9_x86_64.whl torchaudio-${version}-cp39-cp39-macosx_10_9_x86_64.whl" + "x86_64-darwin-310 $darwin_bucket/torchaudio-${version}-cp310-cp310-macosx_10_9_x86_64.whl torchaudio-${version}-cp310-cp310-macosx_10_9_x86_64.whl" + "aarch64-darwin-38 $darwin_bucket/cpu/torchaudio-${version}-cp38-cp38-macosx_11_0_arm64.whl torchaudio-${version}-cp38-cp38-macosx_11_0_arm64.whl" + "aarch64-darwin-39 $darwin_bucket/cpu/torchaudio-${version}-cp39-cp39-macosx_11_0_arm64.whl torchaudio-${version}-cp39-cp39-macosx_11_0_arm64.whl" + "aarch64-darwin-310 $darwin_bucket/cpu/torchaudio-${version}-cp310-cp310-macosx_11_0_arm64.whl torchaudio-${version}-cp310-cp310-macosx_11_0_arm64.whl" ) hashfile=binary-hashes-"$version".nix diff --git a/pkgs/development/python-modules/torchvision/bin.nix b/pkgs/development/python-modules/torchvision/bin.nix index 2abf60009f9e4..e1a0055af2609 100644 --- a/pkgs/development/python-modules/torchvision/bin.nix +++ b/pkgs/development/python-modules/torchvision/bin.nix @@ -16,7 +16,7 @@ let pyVerNoDot = builtins.replaceStrings [ "." ] [ "" ] python.pythonVersion; srcs = import ./binary-hashes.nix version; unsupported = throw "Unsupported system"; - version = "0.12.0"; + version = "0.13.1"; in buildPythonPackage { inherit version; diff --git a/pkgs/development/python-modules/torchvision/binary-hashes.nix b/pkgs/development/python-modules/torchvision/binary-hashes.nix index 4dbeb8d181503..9b6301bab2c3d 100644 --- a/pkgs/development/python-modules/torchvision/binary-hashes.nix +++ b/pkgs/development/python-modules/torchvision/binary-hashes.nix @@ -6,61 +6,61 @@ # To add a new version, run "prefetch.sh 'new-version'" to paste the generated file as follows. version : builtins.getAttr version { - "0.12.0" = { + "0.13.1" = { x86_64-linux-37 = { - name = "torchvision-0.12.0-cp37-cp37m-linux_x86_64.whl"; - url = "https://download.pytorch.org/whl/cu113/torchvision-0.12.0%2Bcu113-cp37-cp37m-linux_x86_64.whl"; - hash = "sha256-i/qktZT+5HQYQjtTHtxOV751DcsP9AHMsSV9/svsGzA="; + name = "torchvision-0.13.1-cp37-cp37m-linux_x86_64.whl"; + url = "https://download.pytorch.org/whl/cu116/torchvision-0.13.1%2Bcu116-cp37-cp37m-linux_x86_64.whl"; + hash = "sha256-3PMvbZmEk+duwho4u7hWt0Ailc96Z/sJzlvefn5yV1Y="; }; x86_64-linux-38 = { - name = "torchvision-0.12.0-cp38-cp38-linux_x86_64.whl"; - url = "https://download.pytorch.org/whl/cu113/torchvision-0.12.0%2Bcu113-cp38-cp38-linux_x86_64.whl"; - hash = "sha256-NxM+jFsOwvAZmeWRFvbQ422a+xx/j1i9DD3ImW+DVBk="; + name = "torchvision-0.13.1-cp38-cp38-linux_x86_64.whl"; + url = "https://download.pytorch.org/whl/cu116/torchvision-0.13.1%2Bcu116-cp38-cp38-linux_x86_64.whl"; + hash = "sha256-w86ys/RW8MmEr3HvVfhjfxeKKdw+E6ZvuwEM7q0okeE="; }; x86_64-linux-39 = { - name = "torchvision-0.12.0-cp39-cp39-linux_x86_64.whl"; - url = "https://download.pytorch.org/whl/cu113/torchvision-0.12.0%2Bcu113-cp39-cp39-linux_x86_64.whl"; - hash = "sha256-bGO5q+KEnv7SexmbbUWaIbsBcIxyDbL8pevZQbLwDbg="; + name = "torchvision-0.13.1-cp39-cp39-linux_x86_64.whl"; + url = "https://download.pytorch.org/whl/cu116/torchvision-0.13.1%2Bcu116-cp39-cp39-linux_x86_64.whl"; + hash = "sha256-dZhqvlchOCWOuXlctM1z9Asr34N0/voa9v9rsNvJcsY="; }; x86_64-linux-310 = { - name = "torchvision-0.12.0-cp310-cp310-linux_x86_64.whl"; - url = "https://download.pytorch.org/whl/cu113/torchvision-0.12.0%2Bcu113-cp310-cp310-linux_x86_64.whl"; - hash = "sha256-ocsGOHa967HcZGV+1omD/xMHufmoi166Yg2Hr+SEhfE="; + name = "torchvision-0.13.1-cp310-cp310-linux_x86_64.whl"; + url = "https://download.pytorch.org/whl/cu116/torchvision-0.13.1%2Bcu116-cp310-cp310-linux_x86_64.whl"; + hash = "sha256-DJorYFrDD89HXWD3m6N4rwBzoi3lhUU/jD3WwUUqubw="; }; x86_64-darwin-37 = { - name = "torchvision-0.12.0-cp37-cp37m-macosx_10_9_x86_64.whl"; - url = "https://download.pytorch.org/whl/torchvision-0.12.0-cp37-cp37m-macosx_10_9_x86_64.whl"; - hash = "sha256-GJM7xZf0VjmTJJcZqWqV28fTN0yQ+7MNPafVGPOv60I="; + name = "torchvision-0.13.1-cp37-cp37m-macosx_10_9_x86_64.whl"; + url = "https://download.pytorch.org/whl/torchvision-0.13.1-cp37-cp37m-macosx_10_9_x86_64.whl"; + hash = "sha256-XmMSQb7jZh3mT4NhZlYiSvLjUS6yWA2nwI4IuMllqKw="; }; x86_64-darwin-38 = { - name = "torchvision-0.12.0-cp38-cp38-macosx_10_9_x86_64.whl"; - url = "https://download.pytorch.org/whl/torchvision-0.12.0-cp38-cp38-macosx_10_9_x86_64.whl"; - hash = "sha256-DWAuCb1Fc2/y55aOjduw7s6Vb/ltcVSLGxtIeP33S9g="; + name = "torchvision-0.13.1-cp38-cp38-macosx_10_9_x86_64.whl"; + url = "https://download.pytorch.org/whl/torchvision-0.13.1-cp38-cp38-macosx_10_9_x86_64.whl"; + hash = "sha256-8jChpA7XDVHkY85D3yQ+xSCQL4cl3iUC5IXvxe6p2GQ="; }; x86_64-darwin-39 = { - name = "torchvision-0.12.0-cp39-cp39-macosx_10_9_x86_64.whl"; - url = "https://download.pytorch.org/whl/torchvision-0.12.0-cp39-cp39-macosx_10_9_x86_64.whl"; - hash = "sha256-RMye+ZLS4qtjsIg/fezrwiRNupO3JUe6EfV6yEUvbq0="; + name = "torchvision-0.13.1-cp39-cp39-macosx_10_9_x86_64.whl"; + url = "https://download.pytorch.org/whl/torchvision-0.13.1-cp39-cp39-macosx_10_9_x86_64.whl"; + hash = "sha256-Api647Caw2GGYIhDQAjYK5nWRY/oiIyN+Qcg70s0fUQ="; }; x86_64-darwin-310 = { - name = "torchvision-0.12.0-cp310-cp310-macosx_10_9_x86_64.whl"; - url = "https://download.pytorch.org/whl/torchvision-0.12.0-cp310-cp310-macosx_10_9_x86_64.whl"; - hash = "sha256-aTZW5nkLarIeSm6H6BwpgrrZ5FW16yThS7ZyOC7GEw8="; + name = "torchvision-0.13.1-cp310-cp310-macosx_10_9_x86_64.whl"; + url = "https://download.pytorch.org/whl/torchvision-0.13.1-cp310-cp310-macosx_10_9_x86_64.whl"; + hash = "sha256-GShqczxp3L1Be4Z5PfgHvSJ9tXhu14fBcpd0GpsND8c="; }; aarch64-darwin-38 = { - name = "torchvision-0.12.0-cp38-cp38-macosx_11_0_arm64.whl"; - url = "https://download.pytorch.org/whl/torchvision-0.12.0-cp38-cp38-macosx_11_0_arm64.whl"; - hash = "sha256-n0JCD38LKc09YXdt8xV4JyV6DPFrLAJ3bcFslquxJW0="; + name = "torchvision-0.13.1-cp38-cp38-macosx_11_0_arm64.whl"; + url = "https://download.pytorch.org/whl/cpu/torchvision-0.13.1-cp38-cp38-macosx_11_0_arm64.whl"; + hash = "sha256-6aVjiU+fpAaS4k0apYw+8EBFABfP7TWY/5Y39ATz/js="; }; aarch64-darwin-39 = { - name = "torchvision-0.12.0-cp39-cp39-macosx_11_0_arm64.whl"; - url = "https://download.pytorch.org/whl/torchvision-0.12.0-cp39-cp39-macosx_11_0_arm64.whl"; - hash = "sha256-adgvR7Z7rW3cu4eDO6WVCmwnG6l7quTAlVYQBxvwNPU="; + name = "torchvision-0.13.1-cp39-cp39-macosx_11_0_arm64.whl"; + url = "https://download.pytorch.org/whl/cpu/torchvision-0.13.1-cp39-cp39-macosx_11_0_arm64.whl"; + hash = "sha256-xe1gnIvIjFdSJkALIjLgMJCUR3yCrziVLgNz7e8AA/0="; }; aarch64-darwin-310 = { - name = "torchvision-0.12.0-cp310-cp310-macosx_11_0_arm64.whl"; - url = "https://download.pytorch.org/whl/torchvision-0.12.0-cp310-cp310-macosx_11_0_arm64.whl"; - hash = "sha256-oL5FAcoLobGVZEySQ/SaHEmiblKn83kkxCOdC/XsvY0="; + name = "torchvision-0.13.1-cp310-cp310-macosx_11_0_arm64.whl"; + url = "https://download.pytorch.org/whl/cpu/torchvision-0.13.1-cp310-cp310-macosx_11_0_arm64.whl"; + hash = "sha256-CPWS6mGDbr7Otcl/TXqBO519xlG7985EAVY8z65qIfw="; }; }; } diff --git a/pkgs/development/python-modules/torchvision/default.nix b/pkgs/development/python-modules/torchvision/default.nix index 594aee03431ee..c44413ba4948d 100644 --- a/pkgs/development/python-modules/torchvision/default.nix +++ b/pkgs/development/python-modules/torchvision/default.nix @@ -24,13 +24,13 @@ let cudaArchStr = lib.optionalString cudaSupport lib.strings.concatStringsSep ";" torch.cudaArchList; in buildPythonPackage rec { pname = "torchvision"; - version = "0.13.0"; + version = "0.13.1"; src = fetchFromGitHub { owner = "pytorch"; repo = "vision"; rev = "refs/tags/v${version}"; - sha256 = "sha256-nIE1HvmAhRh3Hvj3qlF52sN9LGIorLiXlLtN7tzQxqU="; + hash = "sha256-QlUAFAG6zEDCDSXR5n2CznspU3fT0kbqySzofGLPgK4="; }; nativeBuildInputs = [ libpng ninja which ] diff --git a/pkgs/development/python-modules/torchvision/prefetch.sh b/pkgs/development/python-modules/torchvision/prefetch.sh index 5f38bce8d8b30..44a9ba8ece5a2 100755 --- a/pkgs/development/python-modules/torchvision/prefetch.sh +++ b/pkgs/development/python-modules/torchvision/prefetch.sh @@ -5,21 +5,22 @@ set -eou pipefail version=$1 -linux_bucket="https://download.pytorch.org/whl/cu113" +linux_cuda_version="cu116" +linux_bucket="https://download.pytorch.org/whl/${linux_cuda_version}" darwin_bucket="https://download.pytorch.org/whl" url_and_key_list=( - "x86_64-linux-37 $linux_bucket/torchvision-${version}%2Bcu113-cp37-cp37m-linux_x86_64.whl torchvision-${version}-cp37-cp37m-linux_x86_64.whl" - "x86_64-linux-38 $linux_bucket/torchvision-${version}%2Bcu113-cp38-cp38-linux_x86_64.whl torchvision-${version}-cp38-cp38-linux_x86_64.whl" - "x86_64-linux-39 $linux_bucket/torchvision-${version}%2Bcu113-cp39-cp39-linux_x86_64.whl torchvision-${version}-cp39-cp39-linux_x86_64.whl" - "x86_64-linux-310 $linux_bucket/torchvision-${version}%2Bcu113-cp310-cp310-linux_x86_64.whl torchvision-${version}-cp310-cp310-linux_x86_64.whl" + "x86_64-linux-37 $linux_bucket/torchvision-${version}%2B${linux_cuda_version}-cp37-cp37m-linux_x86_64.whl torchvision-${version}-cp37-cp37m-linux_x86_64.whl" + "x86_64-linux-38 $linux_bucket/torchvision-${version}%2B${linux_cuda_version}-cp38-cp38-linux_x86_64.whl torchvision-${version}-cp38-cp38-linux_x86_64.whl" + "x86_64-linux-39 $linux_bucket/torchvision-${version}%2B${linux_cuda_version}-cp39-cp39-linux_x86_64.whl torchvision-${version}-cp39-cp39-linux_x86_64.whl" + "x86_64-linux-310 $linux_bucket/torchvision-${version}%2B${linux_cuda_version}-cp310-cp310-linux_x86_64.whl torchvision-${version}-cp310-cp310-linux_x86_64.whl" "x86_64-darwin-37 $darwin_bucket/torchvision-${version}-cp37-cp37m-macosx_10_9_x86_64.whl torchvision-${version}-cp37-cp37m-macosx_10_9_x86_64.whl" "x86_64-darwin-38 $darwin_bucket/torchvision-${version}-cp38-cp38-macosx_10_9_x86_64.whl torchvision-${version}-cp38-cp38-macosx_10_9_x86_64.whl" "x86_64-darwin-39 $darwin_bucket/torchvision-${version}-cp39-cp39-macosx_10_9_x86_64.whl torchvision-${version}-cp39-cp39-macosx_10_9_x86_64.whl" "x86_64-darwin-310 $darwin_bucket/torchvision-${version}-cp310-cp310-macosx_10_9_x86_64.whl torchvision-${version}-cp310-cp310-macosx_10_9_x86_64.whl" - "aarch64-darwin-38 $darwin_bucket/torchvision-${version}-cp38-cp38-macosx_11_0_arm64.whl torchvision-${version}-cp38-cp38-macosx_11_0_arm64.whl" - "aarch64-darwin-39 $darwin_bucket/torchvision-${version}-cp39-cp39-macosx_11_0_arm64.whl torchvision-${version}-cp39-cp39-macosx_11_0_arm64.whl" - "aarch64-darwin-310 $darwin_bucket/torchvision-${version}-cp310-cp310-macosx_11_0_arm64.whl torchvision-${version}-cp310-cp310-macosx_11_0_arm64.whl" + "aarch64-darwin-38 $darwin_bucket/cpu/torchvision-${version}-cp38-cp38-macosx_11_0_arm64.whl torchvision-${version}-cp38-cp38-macosx_11_0_arm64.whl" + "aarch64-darwin-39 $darwin_bucket/cpu/torchvision-${version}-cp39-cp39-macosx_11_0_arm64.whl torchvision-${version}-cp39-cp39-macosx_11_0_arm64.whl" + "aarch64-darwin-310 $darwin_bucket/cpu/torchvision-${version}-cp310-cp310-macosx_11_0_arm64.whl torchvision-${version}-cp310-cp310-macosx_11_0_arm64.whl" ) hashfile="binary-hashes-$version.nix" diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 5cedebec3232a..8e01b0f152811 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -10929,7 +10929,6 @@ in { torch-bin = callPackage ../development/python-modules/torch/bin.nix { }; - torchWithCuda = self.torch.override { cudaSupport = true; }; |