Merge pull request #110688 from Mic92/umap-learn

This commit is contained in:
Jörg Thalheim 2021-01-27 09:57:31 +00:00 committed by GitHub
commit b1c006f055
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 64 additions and 2 deletions

View File

@ -0,0 +1,52 @@
{ lib
, buildPythonPackage
, fetchPypi
, fetchpatch
, nose
, scikitlearn
, scipy
, numba
, llvmlite
, joblib
}:
buildPythonPackage rec {
pname = "pynndescent";
version = "0.5.1";
src = fetchPypi {
inherit pname version;
sha256 = "74a05a54d13573a38878781d44812ac6df97d8762a56f9bb5dd87a99911820fe";
};
patches = [
# fixes tests, included in 0.5.2
(fetchpatch {
url = "https://github.com/lmcinnes/pynndescent/commit/ef5d8c3c3bfe976063b6621e3e0734c0c22d813b.patch";
sha256 = "sha256-49n3kevs3wpzd4FfZVKmNpF2o1V8pJs4KOx8zCAhR3s=";
})
];
checkInputs = [
nose
];
propagatedBuildInputs = [
scikitlearn
scipy
numba
llvmlite
joblib
];
checkPhase = ''
nosetests
'';
meta = with lib; {
description = "Nearest Neighbor Descent";
homepage = "https://github.com/lmcinnes/pynndescent";
license = licenses.bsd2;
maintainers = [ maintainers.mic92 ];
};
}

View File

@ -6,22 +6,25 @@
, scikitlearn
, scipy
, numba
, pynndescent
, tensorflow
, pytestCheckHook
}:
buildPythonPackage rec {
pname = "umap-learn";
version = "0.4.5";
version = "0.5.0";
src = fetchFromGitHub {
owner = "lmcinnes";
repo = "umap";
rev = version;
sha256 = "080by8h4rxr5ijx8vp8kn952chiqz029j26c04k4js4g9s7201bq";
sha256 = "sha256-2Z5RDi4bz8hh8zMwkcCQY9NrGaVd1DJEBOmrCl2oSvM=";
};
checkInputs = [
nose
tensorflow
pytestCheckHook
];
@ -30,8 +33,13 @@ buildPythonPackage rec {
scikitlearn
scipy
numba
pynndescent
];
preCheck = ''
export HOME=$TMPDIR
'';
disabledTests = [
# Plot functionality requires additional packages.
# These test also fail with 'RuntimeError: cannot cache function' error.

View File

@ -4867,6 +4867,8 @@ in {
pkuseg = callPackage ../development/python-modules/pkuseg { };
pynndescent = callPackage ../development/python-modules/pynndescent { };
pysbd = callPackage ../development/python-modules/pysbd { };
python-codon-tables = callPackage ../development/python-modules/python-codon-tables { };