python3Packages.wasserstein: init at 1.1.0

This commit is contained in:
Dmitry Kalinkin 2022-09-24 11:31:38 -04:00
parent 2a48d59211
commit ab6dd73dc6
2 changed files with 52 additions and 0 deletions

View File

@ -0,0 +1,50 @@
{ lib
, buildPythonPackage
, fetchFromGitHub
, numpy
, llvmPackages
, wurlitzer
, pytestCheckHook
}:
buildPythonPackage rec {
pname = "Wasserstein";
version = "1.1.0";
src = fetchFromGitHub {
owner = "pkomiske";
repo = pname;
rev = "89c2d6279a7e0aa3b56bcc8fb7b6009420f2563e"; # https://github.com/pkomiske/Wasserstein/issues/1
hash = "sha256-s9en6XwvO/WPsF7/+SEmGePHZQgl7zLgu5sEn4nD9YE=";
};
buildInputs = [
llvmPackages.openmp
];
propagatedBuildInputs = [
numpy
wurlitzer
];
checkInputs = [
pytestCheckHook
];
pytestFlagsArray = [
"wasserstein/tests"
];
disabledTestPaths = [
"wasserstein/tests/test_emd.py" # requires "ot"
# cyclic dependency on energyflow
"wasserstein/tests/test_externalemdhandler.py"
"wasserstein/tests/test_pairwiseemd.py"
];
pythonImportsCheck = [ "wasserstein" ];
meta = with lib; {
description = "Python/C++ library for computing Wasserstein distances efficiently";
homepage = "https://github.com/pkomiske/Wasserstein";
license = licenses.gpl3Only;
maintainers = with maintainers; [ veprbl ];
};
}

View File

@ -11647,6 +11647,8 @@ in {
wasabi = callPackage ../development/python-modules/wasabi { };
wasserstein = callPackage ../development/python-modules/wasserstein { };
wasm = callPackage ../development/python-modules/wasm { };
wasmerPackages = pkgs.recurseIntoAttrs (callPackage ../development/python-modules/wasmer { });