Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at release-18.03 86 lines 1.4 kB view raw
1{ stdenv 2, lib 3, pkgs 4, buildPythonPackage 5, fetchPypi 6, pythonOlder 7, pytest 8, cython 9, cymem 10, msgpack-numpy 11, msgpack-python 12, preshed 13, numpy 14, python 15, murmurhash 16, pathlib 17, hypothesis 18, tqdm 19, cytoolz 20, plac 21, six 22, mock 23, termcolor 24, wrapt 25, dill 26}: 27 28buildPythonPackage rec { 29 pname = "thinc"; 30 version = "6.10.2"; 31 name = pname + "-" + version; 32 33 src = fetchPypi { 34 inherit pname version; 35 sha256 = "0xia81wvfrhyriywab184s49g8rpl42vcf5fy3x6xxw50a2yn7cs"; 36 }; 37 38 propagatedBuildInputs = [ 39 cython 40 cymem 41 msgpack-numpy 42 msgpack-python 43 preshed 44 numpy 45 murmurhash 46 pytest 47 hypothesis 48 tqdm 49 cytoolz 50 plac 51 six 52 mock 53 termcolor 54 wrapt 55 dill 56 ] ++ lib.optional (pythonOlder "3.4") pathlib; 57 58 59 checkInputs = [ 60 pytest 61 ]; 62 63 prePatch = '' 64 substituteInPlace setup.py --replace \ 65 "'pathlib>=1.0.0,<2.0.0'," \ 66 "\"pathlib>=1.0.0,<2.0.0; python_version<'3.4'\"," 67 68 substituteInPlace setup.py --replace \ 69 "'cytoolz>=0.8,<0.9'," \ 70 "'cytoolz>=0.8'," 71 ''; 72 73 # Cannot find cython modules. 74 doCheck = false; 75 76 checkPhase = '' 77 pytest thinc/tests 78 ''; 79 80 meta = with stdenv.lib; { 81 description = "Practical Machine Learning for NLP in Python"; 82 homepage = https://github.com/explosion/thinc; 83 license = licenses.mit; 84 maintainers = with maintainers; [ aborsu sdll ]; 85 }; 86}