From 8525960b2b853a24c85e2669f8e21a4c926b7f88 Mon Sep 17 00:00:00 2001 From: Junji Hashimoto Date: Wed, 23 Oct 2024 03:09:07 +0900 Subject: [PATCH] libtorch-bin: 2.3.0 -> 2.5.0 --- .../libraries/science/math/libtorch/bin.nix | 2 +- .../science/math/libtorch/binary-hashes.nix | 22 +++++++++---------- .../science/math/libtorch/prefetch.sh | 3 +-- 3 files changed, 13 insertions(+), 14 deletions(-) diff --git a/pkgs/development/libraries/science/math/libtorch/bin.nix b/pkgs/development/libraries/science/math/libtorch/bin.nix index f8e0dcff2bc1..ee24908eb512 100644 --- a/pkgs/development/libraries/science/math/libtorch/bin.nix +++ b/pkgs/development/libraries/science/math/libtorch/bin.nix @@ -19,7 +19,7 @@ let # this derivation. However, we should ensure on version bumps # that the CUDA toolkit for `passthru.tests` is still # up-to-date. - version = "2.3.0"; + version = "2.5.0"; device = if cudaSupport then "cuda" else "cpu"; srcs = import ./binary-hashes.nix version; unavailable = throw "libtorch is not available for this platform"; diff --git a/pkgs/development/libraries/science/math/libtorch/binary-hashes.nix b/pkgs/development/libraries/science/math/libtorch/binary-hashes.nix index dd8104ad5f0d..4f6350d93116 100644 --- a/pkgs/development/libraries/science/math/libtorch/binary-hashes.nix +++ b/pkgs/development/libraries/science/math/libtorch/binary-hashes.nix @@ -1,19 +1,19 @@ version: builtins.getAttr version { - "2.3.0" = { - aarch64-darwin-cpu = { - name = "libtorch-macos-arm64-2.3.0.zip"; - url = "https://download.pytorch.org/libtorch/cpu/libtorch-macos-arm64-2.3.0.zip"; - hash = "sha256-l4qY1jbsECN5qm7dWJ2jSvKuQwQ/HI6G6Vq1Kh2rxkM="; + "2.5.0" = { + aarch64-darwin-cpu = { + name = "libtorch-macos-arm64-2.5.0.zip"; + url = "https://download.pytorch.org/libtorch/cpu/libtorch-macos-arm64-2.5.0.zip"; + hash = "sha256-4d9YKUuvAESBeG/WCUsQfEHwdB2z34grnlwWslj4970="; }; x86_64-linux-cpu = { - name = "libtorch-cxx11-abi-shared-with-deps-2.3.0-cpu.zip"; - url = "https://download.pytorch.org/libtorch/cpu/libtorch-cxx11-abi-shared-with-deps-2.3.0%2Bcpu.zip"; - hash = "sha256-dKAk6UusK2eQIcP0oMXh9cnufMpy5Ph4SGPkIPPV6ds="; + name = "libtorch-cxx11-abi-shared-with-deps-2.5.0-cpu.zip"; + url = "https://download.pytorch.org/libtorch/cpu/libtorch-cxx11-abi-shared-with-deps-2.5.0%2Bcpu.zip"; + hash = "sha256-gUzPhc4Z8rTPhIm89pPoLP0Ww17ono+/xgMW46E/Tro="; }; x86_64-linux-cuda = { - name = "libtorch-cxx11-abi-shared-with-deps-2.3.0-cu121.zip"; - url = "https://download.pytorch.org/libtorch/cu121/libtorch-cxx11-abi-shared-with-deps-2.3.0%2Bcu121.zip"; - hash = "sha256-6B+NF6q78I2WKFudn8bK+eNYDi1zQ7mdgv06fZbm2rE="; + name = "libtorch-cxx11-abi-shared-with-deps-2.5.0-cu124.zip"; + url = "https://download.pytorch.org/libtorch/cu124/libtorch-cxx11-abi-shared-with-deps-2.5.0%2Bcu124.zip"; + hash = "sha256-UaX47GAwyZ6UmzgY85TeAHmy3u52pBHhiyM5NAz7ens="; }; }; } diff --git a/pkgs/development/libraries/science/math/libtorch/prefetch.sh b/pkgs/development/libraries/science/math/libtorch/prefetch.sh index 2682fe677976..d8680d3a60cf 100755 --- a/pkgs/development/libraries/science/math/libtorch/prefetch.sh +++ b/pkgs/development/libraries/science/math/libtorch/prefetch.sh @@ -6,11 +6,10 @@ set -eou pipefail version=$1 bucket="https://download.pytorch.org/libtorch" -CUDA_VERSION=cu121 +CUDA_VERSION=cu124 url_and_key_list=( "aarch64-darwin-cpu $bucket/cpu/libtorch-macos-arm64-${version}.zip libtorch-macos-arm64-${version}.zip" - "x86_64-darwin-cpu $bucket/cpu/libtorch-macos-x86_64-${version}.zip libtorch-macos-x86_64-${version}.zip" "x86_64-linux-cpu $bucket/cpu/libtorch-cxx11-abi-shared-with-deps-${version}%2Bcpu.zip libtorch-cxx11-abi-shared-with-deps-${version}-cpu.zip" "x86_64-linux-cuda $bucket/${CUDA_VERSION}/libtorch-cxx11-abi-shared-with-deps-${version}%2B${CUDA_VERSION}.zip libtorch-cxx11-abi-shared-with-deps-${version}-${CUDA_VERSION}.zip" )