Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at 20.09 879 B view raw
1{ lib 2, buildPythonPackage 3, fetchPypi 4, pythonOlder 5, cython 6, numpy 7, scipy 8, scikitlearn 9, persim 10, pytest 11}: 12 13buildPythonPackage rec { 14 pname = "ripser"; 15 version = "0.5.4"; 16 disabled = pythonOlder "3.6"; 17 18 src = fetchPypi { 19 inherit pname version; 20 sha256 = "7a54750427e3f1bbb26c625075c831314760a9e5b5bcd3b797df668f020c9eb6"; 21 }; 22 23 checkInputs = [ 24 pytest 25 ]; 26 27 propagatedBuildInputs = [ 28 cython 29 numpy 30 scipy 31 scikitlearn 32 persim 33 ]; 34 35 checkPhase = '' 36 # specifically needed for darwin 37 export HOME=$(mktemp -d) 38 mkdir -p $HOME/.matplotlib 39 echo "backend: ps" > $HOME/.matplotlib/matplotlibrc 40 41 pytest 42 ''; 43 44 meta = with lib; { 45 description = "A Lean Persistent Homology Library for Python"; 46 homepage = "https://ripser.scikit-tda.org"; 47 license = licenses.mit; 48 maintainers = [ maintainers.costrouc ]; 49 }; 50}