2021-08-19 02:44:10 +01:00
|
|
|
{ lib, buildPythonPackage, fetchFromGitHub, isPy3k, matplotlib, numpy, pytestCheckHook, seaborn }:
|
2020-01-06 22:26:35 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pycm";
|
2021-08-18 22:56:42 +01:00
|
|
|
version = "3.2";
|
2020-01-06 22:26:35 +00:00
|
|
|
|
|
|
|
disabled = !isPy3k;
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "sepandhaghighi";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2021-08-18 22:56:42 +01:00
|
|
|
sha256 = "1p2scgb4aghjlxak4zvm3s9ydkpg42mdxy6vjxlnqw0wpnsskfni";
|
2020-01-06 22:26:35 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
# remove a trivial dependency on the author's `art` Python ASCII art library
|
|
|
|
postPatch = ''
|
|
|
|
rm pycm/__main__.py
|
2021-08-19 02:44:10 +01:00
|
|
|
rm Otherfiles/notebook_check.py # also depends on python3Packages.notebook
|
2020-01-06 22:26:35 +00:00
|
|
|
substituteInPlace setup.py --replace '=get_requires()' '=[]'
|
|
|
|
'';
|
|
|
|
|
2021-08-19 02:44:10 +01:00
|
|
|
checkInputs = [ pytestCheckHook ];
|
|
|
|
disabledTests = [ "pycm.pycm_compare.Compare" ]; # output formatting error
|
2021-05-07 18:36:12 +01:00
|
|
|
propagatedBuildInputs = [ matplotlib numpy seaborn ];
|
2020-01-06 22:26:35 +00:00
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2020-01-06 22:26:35 +00:00
|
|
|
description = "Multiclass confusion matrix library";
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://pycm.ir";
|
2020-01-06 22:26:35 +00:00
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ bcdarwin ];
|
|
|
|
};
|
|
|
|
}
|