2019-07-12 20:36:31 -04:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
2022-05-24 21:44:44 +02:00
|
|
|
, keras
|
|
|
|
, numba
|
2019-07-12 20:36:31 -04:00
|
|
|
, numpy
|
2022-05-24 21:44:44 +02:00
|
|
|
, pynndescent
|
|
|
|
, pytestCheckHook
|
|
|
|
, pythonOlder
|
2021-05-15 01:46:36 +07:00
|
|
|
, scikit-learn
|
2019-07-12 20:36:31 -04:00
|
|
|
, scipy
|
2021-01-24 05:14:28 +01:00
|
|
|
, tensorflow
|
2021-12-10 09:44:47 -05:00
|
|
|
, tqdm
|
2019-07-12 20:36:31 -04:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "umap-learn";
|
2022-04-18 01:36:15 +02:00
|
|
|
version = "0.5.3";
|
2022-05-24 21:44:44 +02:00
|
|
|
format = "setuptools";
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.7";
|
2019-07-12 20:36:31 -04:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "lmcinnes";
|
|
|
|
repo = "umap";
|
|
|
|
rev = version;
|
2022-05-24 21:44:44 +02:00
|
|
|
hash = "sha256-S2+k7Ec4AxsN6d0GUGnU81oLnBgmlZp8OmUFCNaUJYw=";
|
2019-07-12 20:36:31 -04:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
2022-05-24 21:44:44 +02:00
|
|
|
numba
|
2019-07-12 20:36:31 -04:00
|
|
|
numpy
|
2022-05-24 21:44:44 +02:00
|
|
|
pynndescent
|
2021-05-15 01:46:36 +07:00
|
|
|
scikit-learn
|
2019-07-12 20:36:31 -04:00
|
|
|
scipy
|
2021-12-10 09:44:47 -05:00
|
|
|
tqdm
|
2019-07-12 20:36:31 -04:00
|
|
|
];
|
|
|
|
|
2021-04-27 04:29:42 +02:00
|
|
|
checkInputs = [
|
2021-11-25 17:22:42 -05:00
|
|
|
keras
|
2022-05-24 21:44:44 +02:00
|
|
|
pytestCheckHook
|
|
|
|
tensorflow
|
2021-04-27 04:29:42 +02:00
|
|
|
];
|
|
|
|
|
2021-01-24 05:14:28 +01:00
|
|
|
preCheck = ''
|
|
|
|
export HOME=$TMPDIR
|
|
|
|
'';
|
|
|
|
|
2020-10-14 12:55:45 +02:00
|
|
|
disabledTests = [
|
|
|
|
# Plot functionality requires additional packages.
|
|
|
|
# These test also fail with 'RuntimeError: cannot cache function' error.
|
|
|
|
"test_umap_plot_testability"
|
|
|
|
"test_plot_runs_at_all"
|
2019-07-12 20:36:31 -04:00
|
|
|
|
2020-10-14 12:55:45 +02:00
|
|
|
# Flaky test. Fails with AssertionError sometimes.
|
|
|
|
"test_sparse_hellinger"
|
2022-05-24 21:44:44 +02:00
|
|
|
"test_densmap_trustworthiness_on_iris_supervised"
|
2022-01-01 09:30:54 +01:00
|
|
|
|
|
|
|
# tensorflow maybe incompatible? https://github.com/lmcinnes/umap/issues/821
|
|
|
|
"test_save_load"
|
2020-10-14 12:55:45 +02:00
|
|
|
];
|
2019-07-12 20:36:31 -04:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Uniform Manifold Approximation and Projection";
|
2020-03-31 21:11:51 -04:00
|
|
|
homepage = "https://github.com/lmcinnes/umap";
|
2019-07-12 20:36:31 -04:00
|
|
|
license = licenses.bsd3;
|
2022-05-24 21:44:44 +02:00
|
|
|
maintainers = with maintainers; [ costrouc ];
|
2019-07-12 20:36:31 -04:00
|
|
|
};
|
|
|
|
}
|