2021-12-06 16:07:01 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
|
|
|
, future
|
2023-03-04 12:14:45 +00:00
|
|
|
, joblib
|
2021-12-06 16:07:01 +00:00
|
|
|
, numpy
|
|
|
|
, pytest
|
2023-03-04 12:14:45 +00:00
|
|
|
, pythonOlder
|
|
|
|
, scikit-learn
|
2021-12-06 16:07:01 +00:00
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
2023-03-04 12:14:45 +00:00
|
|
|
pname = "mdp";
|
2020-06-15 15:56:04 +00:00
|
|
|
version = "3.6";
|
2023-03-04 12:14:45 +00:00
|
|
|
format = "setuptools";
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.7";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
2023-03-04 12:14:45 +00:00
|
|
|
pname = "MDP";
|
|
|
|
inherit version;
|
|
|
|
hash = "sha256-rFKmUsy67RhX/xIJhi8Dv5sG0JOxJgb7QQeH2jqmWg4=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-12-06 16:07:01 +00:00
|
|
|
postPatch = ''
|
|
|
|
# https://github.com/mdp-toolkit/mdp-toolkit/issues/92
|
2023-03-04 12:14:45 +00:00
|
|
|
substituteInPlace mdp/utils/routines.py \
|
|
|
|
--replace numx.typeDict numx.sctypeDict
|
|
|
|
substituteInPlace mdp/test/test_NormalizingRecursiveExpansionNode.py \
|
|
|
|
--replace py.test"" "pytest"
|
|
|
|
substituteInPlace mdp/test/test_RecursiveExpansionNode.py \
|
|
|
|
--replace py.test"" "pytest"
|
2021-12-06 16:07:01 +00:00
|
|
|
'';
|
|
|
|
|
2023-03-04 12:14:45 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
future
|
|
|
|
numpy
|
|
|
|
];
|
|
|
|
|
|
|
|
nativeCheckInputs = [
|
|
|
|
joblib
|
|
|
|
pytest
|
|
|
|
scikit-learn
|
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
"mdp"
|
|
|
|
"bimdp"
|
|
|
|
];
|
|
|
|
|
2021-12-06 16:07:01 +00:00
|
|
|
checkPhase = ''
|
|
|
|
runHook preCheck
|
|
|
|
|
|
|
|
pytest --seed 7710873 mdp
|
|
|
|
pytest --seed 7710873 bimdp
|
|
|
|
|
|
|
|
runHook postCheck
|
|
|
|
'';
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Library for building complex data processing software by combining widely used machine learning algorithms";
|
2023-03-04 12:14:45 +00:00
|
|
|
homepage = "https://mdp-toolkit.github.io/";
|
|
|
|
changelog = "https://github.com/mdp-toolkit/mdp-toolkit/blob/MDP-${version}/CHANGES";
|
2020-04-24 23:36:52 +00:00
|
|
|
license = licenses.bsd3;
|
|
|
|
maintainers = with maintainers; [ nico202 ];
|
|
|
|
};
|
|
|
|
}
|