2020-04-24 23:36:52 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
2023-02-02 18:25:31 +00:00
|
|
|
, fetchpatch
|
2022-06-16 17:23:12 +00:00
|
|
|
, keras
|
|
|
|
, numba
|
2020-04-24 23:36:52 +00:00
|
|
|
, numpy
|
2022-06-16 17:23:12 +00:00
|
|
|
, pynndescent
|
|
|
|
, pytestCheckHook
|
|
|
|
, pythonOlder
|
2021-05-20 23:08:51 +00:00
|
|
|
, scikit-learn
|
2020-04-24 23:36:52 +00:00
|
|
|
, scipy
|
2021-02-05 17:12:51 +00:00
|
|
|
, tensorflow
|
2021-12-19 01:06:50 +00:00
|
|
|
, tqdm
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "umap-learn";
|
2024-01-02 11:29:13 +00:00
|
|
|
version = "0.5.5";
|
2022-06-16 17:23:12 +00:00
|
|
|
format = "setuptools";
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.7";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "lmcinnes";
|
|
|
|
repo = "umap";
|
2024-01-02 11:29:13 +00:00
|
|
|
rev = "refs/tags/release-${version}";
|
|
|
|
hash = "sha256-bXAQjq7xBYn34tIZF96Sr5jDUii3s4FGkNx65rGKXkY=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
2022-06-16 17:23:12 +00:00
|
|
|
numba
|
2020-04-24 23:36:52 +00:00
|
|
|
numpy
|
2022-06-16 17:23:12 +00:00
|
|
|
pynndescent
|
2021-05-20 23:08:51 +00:00
|
|
|
scikit-learn
|
2020-04-24 23:36:52 +00:00
|
|
|
scipy
|
2021-12-19 01:06:50 +00:00
|
|
|
tqdm
|
2020-04-24 23:36:52 +00:00
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2021-12-19 01:06:50 +00:00
|
|
|
keras
|
2022-06-16 17:23:12 +00:00
|
|
|
pytestCheckHook
|
|
|
|
tensorflow
|
2021-05-03 20:48:10 +00:00
|
|
|
];
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
preCheck = ''
|
|
|
|
export HOME=$TMPDIR
|
|
|
|
'';
|
|
|
|
|
2020-10-16 20:44:37 +00: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"
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2020-10-16 20:44:37 +00:00
|
|
|
# Flaky test. Fails with AssertionError sometimes.
|
|
|
|
"test_sparse_hellinger"
|
2022-06-16 17:23:12 +00:00
|
|
|
"test_densmap_trustworthiness_on_iris_supervised"
|
2022-01-13 20:06:32 +00:00
|
|
|
|
|
|
|
# tensorflow maybe incompatible? https://github.com/lmcinnes/umap/issues/821
|
|
|
|
"test_save_load"
|
2020-10-16 20:44:37 +00:00
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Uniform Manifold Approximation and Projection";
|
|
|
|
homepage = "https://github.com/lmcinnes/umap";
|
|
|
|
license = licenses.bsd3;
|
2023-08-04 22:07:22 +00:00
|
|
|
maintainers = with maintainers; [ ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|