diff --git a/pkgs/development/libraries/science/math/libtorch/bin.nix b/pkgs/development/libraries/science/math/libtorch/bin.nix index 5b08cfa7dcf0..8e77ac25dd72 100644 --- a/pkgs/development/libraries/science/math/libtorch/bin.nix +++ b/pkgs/development/libraries/science/math/libtorch/bin.nix @@ -4,12 +4,13 @@ , lib , libcxx , llvmPackages +, config , addOpenGLRunpath , patchelf , fixDarwinDylibNames -, cudaSupport +, cudaSupport ? config.cudaSupport }: let diff --git a/pkgs/development/python-modules/pytorch-metric-learning/default.nix b/pkgs/development/python-modules/pytorch-metric-learning/default.nix index e667590bf1b7..049064754937 100644 --- a/pkgs/development/python-modules/pytorch-metric-learning/default.nix +++ b/pkgs/development/python-modules/pytorch-metric-learning/default.nix @@ -4,6 +4,7 @@ buildPythonPackage, fetchFromGitHub, isPy27, + config, # build-system setuptools, @@ -19,7 +20,7 @@ tensorboard, # tests - cudaSupport, + cudaSupport ? config.cudaSupport, pytestCheckHook, torchvision }: diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 778ef250dd1b..1ac19429d839 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -4249,9 +4249,7 @@ with pkgs; libtensorflow = python3.pkgs.tensorflow.libtensorflow; - libtorch-bin = callPackage ../development/libraries/science/math/libtorch/bin.nix { - inherit (config) cudaSupport; - }; + libtorch-bin = callPackage ../development/libraries/science/math/libtorch/bin.nix { }; tensorflow-lite = callPackage ../development/libraries/science/math/tensorflow-lite { }; diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 0b748b79e260..2fcec9d29e82 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -12814,9 +12814,7 @@ self: super: with self; { pytorch-lightning = callPackage ../development/python-modules/pytorch-lightning { }; - pytorch-metric-learning = callPackage ../development/python-modules/pytorch-metric-learning { - inherit (pkgs.config) cudaSupport; - }; + pytorch-metric-learning = callPackage ../development/python-modules/pytorch-metric-learning { }; pytorch-msssim = callPackage ../development/python-modules/pytorch-msssim { };