From 8694fb4187be13dec82b75ccef37fc5509f12e43 Mon Sep 17 00:00:00 2001 From: Felix Bühler Date: Sun, 7 Jan 2024 22:08:32 +0100 Subject: python311Packages.linear-operator: rename from linear_operator (#279258) --- .../development/python-modules/botorch/default.nix | 4 +- .../python-modules/gpytorch/default.nix | 4 +- .../python-modules/linear-operator/default.nix | 56 ++++++++++++++++++++++ .../python-modules/linear_operator/default.nix | 56 ---------------------- pkgs/top-level/python-aliases.nix | 1 + pkgs/top-level/python-packages.nix | 2 +- 6 files changed, 62 insertions(+), 61 deletions(-) create mode 100644 pkgs/development/python-modules/linear-operator/default.nix delete mode 100644 pkgs/development/python-modules/linear_operator/default.nix (limited to 'pkgs') diff --git a/pkgs/development/python-modules/botorch/default.nix b/pkgs/development/python-modules/botorch/default.nix index 746e04df5abe..7d2170d3355e 100644 --- a/pkgs/development/python-modules/botorch/default.nix +++ b/pkgs/development/python-modules/botorch/default.nix @@ -2,7 +2,7 @@ , buildPythonPackage , fetchFromGitHub , gpytorch -, linear_operator +, linear-operator , multipledispatch , pyro-ppl , setuptools @@ -33,7 +33,7 @@ buildPythonPackage rec { propagatedBuildInputs = [ gpytorch - linear_operator + linear-operator multipledispatch pyro-ppl scipy diff --git a/pkgs/development/python-modules/gpytorch/default.nix b/pkgs/development/python-modules/gpytorch/default.nix index 1fea3699d9f5..e4ce55bb2c84 100644 --- a/pkgs/development/python-modules/gpytorch/default.nix +++ b/pkgs/development/python-modules/gpytorch/default.nix @@ -1,7 +1,7 @@ { lib , buildPythonPackage , fetchFromGitHub -, linear_operator +, linear-operator , scikit-learn , setuptools , setuptools-scm @@ -31,7 +31,7 @@ buildPythonPackage rec { ]; propagatedBuildInputs = [ - linear_operator + linear-operator scikit-learn torch ]; diff --git a/pkgs/development/python-modules/linear-operator/default.nix b/pkgs/development/python-modules/linear-operator/default.nix new file mode 100644 index 000000000000..7bd1f6245343 --- /dev/null +++ b/pkgs/development/python-modules/linear-operator/default.nix @@ -0,0 +1,56 @@ +{ lib +, buildPythonPackage +, fetchFromGitHub +, jaxtyping +, pytestCheckHook +, scipy +, setuptools +, setuptools-scm +, torch +, wheel +}: + +buildPythonPackage rec { + pname = "linear-operator"; + version = "0.5.2"; + format = "pyproject"; + + src = fetchFromGitHub { + owner = "cornellius-gp"; + repo = "linear_operator"; + rev = "refs/tags/v${version}"; + hash = "sha256-OuE6jx9Q4IU+b2a+mrglRdBOReN1tt/thetNXxwk1GI="; + }; + + env.SETUPTOOLS_SCM_PRETEND_VERSION = version; + + nativeBuildInputs = [ + setuptools + setuptools-scm + wheel + ]; + + propagatedBuildInputs = [ + jaxtyping + scipy + torch + ]; + + pythonImportsCheck = [ "linear_operator" ]; + + nativeCheckInputs = [ + pytestCheckHook + ]; + + disabledTests = [ + # flaky numerical tests + "test_svd" + ]; + + meta = with lib; { + description = "A LinearOperator implementation to wrap the numerical nuts and bolts of GPyTorch"; + homepage = "https://github.com/cornellius-gp/linear_operator/"; + license = licenses.mit; + maintainers = with maintainers; [ veprbl ]; + }; +} diff --git a/pkgs/development/python-modules/linear_operator/default.nix b/pkgs/development/python-modules/linear_operator/default.nix deleted file mode 100644 index 1bf11865dfc0..000000000000 --- a/pkgs/development/python-modules/linear_operator/default.nix +++ /dev/null @@ -1,56 +0,0 @@ -{ lib -, buildPythonPackage -, fetchFromGitHub -, jaxtyping -, pytestCheckHook -, scipy -, setuptools -, setuptools-scm -, torch -, wheel -}: - -buildPythonPackage rec { - pname = "linear_operator"; - version = "0.5.2"; - format = "pyproject"; - - src = fetchFromGitHub { - owner = "cornellius-gp"; - repo = pname; - rev = "refs/tags/v${version}"; - hash = "sha256-OuE6jx9Q4IU+b2a+mrglRdBOReN1tt/thetNXxwk1GI="; - }; - - env.SETUPTOOLS_SCM_PRETEND_VERSION = version; - - nativeBuildInputs = [ - setuptools - setuptools-scm - wheel - ]; - - propagatedBuildInputs = [ - jaxtyping - scipy - torch - ]; - - pythonImportsCheck = [ "linear_operator" ]; - - nativeCheckInputs = [ - pytestCheckHook - ]; - - disabledTests = [ - # flaky numerical tests - "test_svd" - ]; - - meta = with lib; { - description = "A LinearOperator implementation to wrap the numerical nuts and bolts of GPyTorch"; - homepage = "https://github.com/cornellius-gp/linear_operator/"; - license = licenses.mit; - maintainers = with maintainers; [ veprbl ]; - }; -} diff --git a/pkgs/top-level/python-aliases.nix b/pkgs/top-level/python-aliases.nix index 9f8a6a88eeb5..910531a12614 100644 --- a/pkgs/top-level/python-aliases.nix +++ b/pkgs/top-level/python-aliases.nix @@ -245,6 +245,7 @@ mapAliases ({ ledger_agent = ledger-agent; # Added 2024-01-07 lektor = throw "lektor has been promoted to a top-level attribute"; # added 2023-08-01 line_profiler = line-profiler; # added 2023-11-04 + linear_operator = linear-operator; # added 2024-01-07 livestreamer = throw "'livestreamer' has been removed, as it unmaintained. A currently maintained fork is 'streamlink'."; # added 2023-11-14 livestreamer-curses = throw "'livestreamer-curses' has been removed as it, and livestreamer itself are unmaintained."; # added 2023-11-14 logilab_astng = throw "logilab-astng has not been released since 2013 and is unmaintained"; # added 2022-11-29 diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 8a3855a98c2d..e6d2169c7cc5 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -6493,7 +6493,7 @@ self: super: with self; { limnoria = callPackage ../development/python-modules/limnoria { }; - linear_operator = callPackage ../development/python-modules/linear_operator { }; + linear-operator = callPackage ../development/python-modules/linear-operator { }; linecache2 = callPackage ../development/python-modules/linecache2 { }; -- cgit 1.4.1