at master 1.2 kB view raw
1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 matplotlib, 6 numpy, 7 pytestCheckHook, 8 pytest-cov-stub, 9 seaborn, 10 setuptools, 11}: 12 13buildPythonPackage rec { 14 pname = "pycm"; 15 version = "4.4"; 16 pyproject = true; 17 18 src = fetchFromGitHub { 19 owner = "sepandhaghighi"; 20 repo = "pycm"; 21 tag = "v${version}"; 22 hash = "sha256-CKvNnpZBT6CV71887jd+V4plBBdWQhMqAhO38APUg20="; 23 }; 24 25 build-system = [ setuptools ]; 26 27 dependencies = [ 28 matplotlib 29 numpy 30 seaborn 31 ]; 32 33 nativeCheckInputs = [ 34 pytestCheckHook 35 pytest-cov-stub 36 matplotlib 37 ]; 38 39 disabledTests = [ 40 "plot_error_test" # broken doctest (expects matplotlib import exception) 41 ]; 42 43 postPatch = '' 44 # Remove a trivial dependency on the author's `art` Python ASCII art library 45 rm pycm/__main__.py 46 substituteInPlace setup.py \ 47 --replace-fail '=get_requires()' '=[]' 48 ''; 49 50 pythonImportsCheck = [ "pycm" ]; 51 52 meta = { 53 description = "Multiclass confusion matrix library"; 54 homepage = "https://pycm.io"; 55 changelog = "https://github.com/sepandhaghighi/pycm/releases/tag/${src.tag}"; 56 license = lib.licenses.mit; 57 maintainers = with lib.maintainers; [ bcdarwin ]; 58 }; 59}