summary refs log tree commit diff
path: root/pkgs/development/python-modules/xarray-einstats/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/development/python-modules/xarray-einstats/default.nix')
-rw-r--r--pkgs/development/python-modules/xarray-einstats/default.nix59
1 files changed, 59 insertions, 0 deletions
diff --git a/pkgs/development/python-modules/xarray-einstats/default.nix b/pkgs/development/python-modules/xarray-einstats/default.nix
new file mode 100644
index 00000000000..921bedaae8b
--- /dev/null
+++ b/pkgs/development/python-modules/xarray-einstats/default.nix
@@ -0,0 +1,59 @@
+{ lib
+, buildPythonPackage
+, einops
+, fetchFromGitHub
+, flit-core
+, numba
+, numpy
+, pandas
+, pytestCheckHook
+, pythonOlder
+, scipy
+, xarray
+}:
+
+buildPythonPackage rec {
+  pname = "xarray-einstats";
+  version = "0.2.2";
+  format = "pyproject";
+
+  disabled = pythonOlder "3.7";
+
+  src = fetchFromGitHub {
+    owner = "arviz-devs";
+    repo = pname;
+    rev = "v${version}";
+    hash = "sha256-yc2dWKL9XhSSB7rUKS2uDCa4IyH/ajUf632Of2beY+4=";
+  };
+
+  nativeBuildInputs = [
+    flit-core
+  ];
+
+  propagatedBuildInputs = [
+    numpy
+    scipy
+    xarray
+  ];
+
+  checkInputs = [
+    einops
+    numba
+    pytestCheckHook
+  ];
+
+  pythonImportsCheck = [
+    "xarray_einstats"
+  ];
+
+  pytestFlagsArray = [
+    "src/xarray_einstats/tests/"
+  ];
+
+  meta = with lib; {
+    description = "Stats, linear algebra and einops for xarray";
+    homepage = "https://github.com/arviz-devs/xarray-einstats";
+    license = licenses.asl20;
+    maintainers = with maintainers; [ fab ];
+  };
+}