2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchFromGitHub,
|
|
|
|
setuptools,
|
|
|
|
deepdiff,
|
|
|
|
numpy,
|
|
|
|
opencv4,
|
|
|
|
pyyaml,
|
|
|
|
scikit-image,
|
|
|
|
scikit-learn,
|
|
|
|
scipy,
|
|
|
|
pydantic,
|
|
|
|
pytestCheckHook,
|
|
|
|
pythonOlder,
|
|
|
|
pythonRelaxDepsHook,
|
|
|
|
torch,
|
|
|
|
torchvision,
|
|
|
|
typing-extensions,
|
2023-08-04 22:07:22 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "albumentations";
|
2024-05-15 15:35:15 +00:00
|
|
|
version = "1.4.4";
|
2024-04-21 15:54:59 +00:00
|
|
|
pyproject = true;
|
2023-08-04 22:07:22 +00:00
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
disabled = pythonOlder "3.8";
|
2023-08-04 22:07:22 +00:00
|
|
|
|
2024-05-15 15:35:15 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "albumentations-team";
|
|
|
|
repo = "albumentations";
|
|
|
|
rev = "refs/tags/${version}";
|
|
|
|
hash = "sha256-7t1+22zzFtkZaAyOo6xjk+MXT9N44PmQ/NRRfvLeRVk=";
|
2023-08-04 22:07:22 +00:00
|
|
|
};
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
nativeBuildInputs = [ pythonRelaxDepsHook ];
|
2023-08-04 22:07:22 +00:00
|
|
|
|
|
|
|
pythonRemoveDeps = [
|
|
|
|
"opencv-python"
|
2024-05-15 15:35:15 +00:00
|
|
|
"pydantic"
|
2023-08-04 22:07:22 +00:00
|
|
|
];
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
build-system = [ setuptools ];
|
2024-04-21 15:54:59 +00:00
|
|
|
|
|
|
|
dependencies = [
|
2023-08-04 22:07:22 +00:00
|
|
|
numpy
|
|
|
|
opencv4
|
2024-05-15 15:35:15 +00:00
|
|
|
pydantic
|
2023-08-04 22:07:22 +00:00
|
|
|
pyyaml
|
|
|
|
scikit-image
|
2024-05-15 15:35:15 +00:00
|
|
|
scikit-learn
|
2023-08-04 22:07:22 +00:00
|
|
|
scipy
|
2024-05-15 15:35:15 +00:00
|
|
|
typing-extensions
|
2023-08-04 22:07:22 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
nativeCheckInputs = [
|
2024-04-21 15:54:59 +00:00
|
|
|
deepdiff
|
2023-08-04 22:07:22 +00:00
|
|
|
pytestCheckHook
|
2024-04-21 15:54:59 +00:00
|
|
|
torch
|
|
|
|
torchvision
|
2023-08-04 22:07:22 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
disabledTests = [
|
|
|
|
# this test hangs up
|
|
|
|
"test_transforms"
|
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "albumentations" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Fast image augmentation library and easy to use wrapper around other libraries";
|
|
|
|
homepage = "https://github.com/albumentations-team/albumentations";
|
|
|
|
changelog = "https://github.com/albumentations-team/albumentations/releases/tag/${version}";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ natsukium ];
|
|
|
|
};
|
|
|
|
}
|