2021-05-14 18:46:36 +00:00
|
|
|
{ lib, buildPythonPackage, fetchPypi, scikit-learn, pandas, nose, pytest }:
|
2019-07-29 23:59:52 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "imbalanced-learn";
|
2019-11-28 00:49:36 +00:00
|
|
|
version = "0.4.3";
|
2019-07-29 23:59:52 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2019-11-28 00:49:36 +00:00
|
|
|
sha256 = "5bd9e86e40ce4001a57426541d7c79b18143cbd181e3330c1a3e5c5c43287083";
|
2019-07-29 23:59:52 +00:00
|
|
|
};
|
|
|
|
|
2021-05-14 18:46:36 +00:00
|
|
|
propagatedBuildInputs = [ scikit-learn ];
|
2019-07-29 23:59:52 +00:00
|
|
|
checkInputs = [ nose pytest pandas ];
|
|
|
|
checkPhase = ''
|
|
|
|
export HOME=$PWD
|
|
|
|
# skip some tests that fail because of minimal rounding errors
|
|
|
|
# or large dependencies
|
|
|
|
py.test imblearn -k 'not classification \
|
|
|
|
and not _generator \
|
|
|
|
and not _forest \
|
|
|
|
and not wrong_memory'
|
|
|
|
'';
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2019-07-29 23:59:52 +00:00
|
|
|
description = "Library offering a number of re-sampling techniques commonly used in datasets showing strong between-class imbalance";
|
2020-04-01 01:11:51 +00:00
|
|
|
homepage = "https://github.com/scikit-learn-contrib/imbalanced-learn";
|
2019-07-29 23:59:52 +00:00
|
|
|
license = licenses.mit;
|
|
|
|
};
|
|
|
|
}
|