Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at 19.09 36 lines 1.1 kB view raw
1{ stdenv, buildPythonPackage, fetchFromGitHub, fetchpatch, numpy, scipy, deap, scikitlearn, python }: 2 3buildPythonPackage rec { 4 pname = "sklearn-deap"; 5 version = "0.2.3"; 6 7 # No tests in Pypi 8 src = fetchFromGitHub { 9 owner = "rsteca"; 10 repo = pname; 11 rev = version; 12 sha256 = "1yqnmy8h08i2y6bb2s0a5nx9cwvyg45293whqh420c195gpzg1x3"; 13 }; 14 15 patches = [ 16 # Fix for newer versions of scikit-learn. See: https://github.com/rsteca/sklearn-deap/pull/62 17 (fetchpatch { 18 url = "https://github.com/rsteca/sklearn-deap/commit/3ae62990fc87f36b59382e7c4db3c74cf99ec3bf.patch"; 19 sha256 = "1na6wf4v0dcmyz3pz8aiqkmv76d1iz3hi4iyfq9kfnycgzpv1kxk"; 20 }) 21 ]; 22 23 propagatedBuildInputs = [ numpy scipy deap scikitlearn ]; 24 25 checkPhase = '' 26 ${python.interpreter} test.py 27 ''; 28 29 meta = with stdenv.lib; { 30 description = "Use evolutionary algorithms instead of gridsearch in scikit-learn"; 31 homepage = https://github.com/rsteca/sklearn-deap; 32 license = licenses.lgpl3; 33 maintainers = with maintainers; [ psyanticy ]; 34 }; 35} 36