From e0546f44a96794592bf7aceb53a4d0e8735435bc Mon Sep 17 00:00:00 2001 From: Iztok Fister Jr Date: Thu, 3 Nov 2022 00:10:49 +0100 Subject: [PATCH] python310Packages.niaaml: init at 1.1.11 (#196752) Co-authored-by: Sandro --- .../python-modules/niaaml/default.nix | 59 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 + 2 files changed, 61 insertions(+) create mode 100644 pkgs/development/python-modules/niaaml/default.nix diff --git a/pkgs/development/python-modules/niaaml/default.nix b/pkgs/development/python-modules/niaaml/default.nix new file mode 100644 index 000000000000..39a4c485205b --- /dev/null +++ b/pkgs/development/python-modules/niaaml/default.nix @@ -0,0 +1,59 @@ +{ lib +, buildPythonPackage +, fetchFromGitHub +, niapy +, numpy +, pandas +, poetry-core +, scikit-learn +, toml-adapt +, pytestCheckHook +, pythonOlder +}: + +buildPythonPackage rec { + pname = "niaaml"; + version = "1.1.11"; + format = "pyproject"; + + disabled = pythonOlder "3.7"; + + src = fetchFromGitHub { + owner = "lukapecnik"; + repo = "NiaAML"; + rev = version; + sha256 = "sha256-B87pI1EpZj1xECrgTmzN5S35Cy1nPowBRyu1IDb5zCE="; + }; + + nativeBuildInputs = [ + poetry-core + toml-adapt + ]; + + propagatedBuildInputs = [ + niapy + numpy + pandas + scikit-learn + ]; + + # create scikit-learn dep version consistent + preBuild = '' + toml-adapt -path pyproject.toml -a change -dep scikit-learn -ver X + ''; + + checkInputs = [ + pytestCheckHook + ]; + + pythonImportsCheck = [ + "niaaml" + ]; + + meta = with lib; { + description = "Python automated machine learning framework"; + homepage = "https://github.com/lukapecnik/NiaAML"; + license = licenses.mit; + maintainers = with maintainers; [ firefly-cpp ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 8043050ade6f..5248321ec871 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -6111,6 +6111,8 @@ self: super: with self; { enablePython = true; # ... and its Python bindings })).python; + niaaml = callPackage ../development/python-modules/niaaml { }; + niaarm = callPackage ../development/python-modules/niaarm { }; niapy = callPackage ../development/python-modules/niapy { };