treewide: stdenv.is -> stdenv.hostPlatform.is (#356363)
[NixPkgs.git] / pkgs / development / python-modules / cleanvision / default.nix
blobff25048ab8869fb99b8798ab838428bd3b3b0fb4
2   lib,
3   stdenv,
4   buildPythonPackage,
5   fetchFromGitHub,
7   # build-system
8   setuptools,
10   # dependencies
11   fsspec,
12   imagehash,
13   matplotlib,
14   numpy,
15   pandas,
16   pillow,
17   tabulate,
18   tqdm,
20   # tests
21   datasets,
22   psutil,
23   pytestCheckHook,
24   torchvision,
27 buildPythonPackage rec {
28   pname = "cleanvision";
29   version = "0.3.6";
30   pyproject = true;
32   src = fetchFromGitHub {
33     owner = "cleanlab";
34     repo = "cleanvision";
35     rev = "refs/tags/v${version}";
36     hash = "sha256-QAydDqLJx/jYKXqxRUElTdM5dOFA6nZag8rNAjPZjRg=";
37   };
39   build-system = [ setuptools ];
41   dependencies = [
42     fsspec
43     imagehash
44     matplotlib
45     numpy
46     pandas
47     pillow
48     tabulate
49     tqdm
50   ];
52   pythonImportsCheck = [ "cleanvision" ];
54   nativeCheckInputs = [
55     datasets
56     psutil
57     pytestCheckHook
58     torchvision
59   ];
61   preCheck = ''
62     export HOME=$(mktemp -d)
63   '';
65   disabledTests = [
66     # Requires accessing s3 (online)
67     "test_s3_dataset"
68   ];
70   meta = {
71     description = "Automatically find issues in image datasets and practice data-centric computer vision";
72     homepage = "https://github.com/cleanlab/cleanvision";
73     changelog = "https://github.com/cleanlab/cleanvision/releases/tag/v${version}";
74     license = lib.licenses.agpl3Only;
75     maintainers = with lib.maintainers; [ GaetanLepage ];
76     # Fatal Python error: Aborted
77     broken = stdenv.hostPlatform.isDarwin;
78   };