1{
2 lib,
3 buildPythonPackage,
4 pythonOlder,
5 fetchFromGitHub,
6 setuptools,
7 pytestCheckHook,
8 numpy,
9 opencv4,
10 tomli,
11 typing-extensions,
12}:
13
14buildPythonPackage rec {
15 pname = "albucore";
16 version = "0.0.12";
17 pyproject = true;
18
19 disabled = pythonOlder "3.8";
20
21 src = fetchFromGitHub {
22 owner = "albumentations-team";
23 repo = "albucore";
24 rev = "refs/tags/${version}";
25 hash = "sha256-TJTIIshMUcHTGSo0lRA3hVkqMqKsfj0EuiV+SSsP5Q4=";
26 };
27
28 pythonRemoveDeps = [ "opencv-python" ];
29
30 build-system = [ setuptools ];
31
32 dependencies = [
33 numpy
34 opencv4
35 tomli
36 typing-extensions
37 ];
38
39 pythonImportsCheck = [ "albucore" ];
40
41 nativeCheckInputs = [ pytestCheckHook ];
42
43 meta = {
44 description = "High-performance image processing library to optimize and extend Albumentations with specialized functions for image transformations";
45 homepage = "https://github.com/albumentations-team/albucore";
46 changelog = "https://github.com/albumentations-team/albucore/releases/tag/${version}";
47 license = lib.licenses.mit;
48 maintainers = with lib.maintainers; [ bcdarwin ];
49 };
50}