2020-04-24 23:36:52 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, isPy27
|
2020-05-03 17:38:23 +00:00
|
|
|
, fetchFromGitHub
|
2020-06-18 07:06:33 +00:00
|
|
|
, fetchpatch
|
2020-04-24 23:36:52 +00:00
|
|
|
, pytest
|
|
|
|
, unittest2
|
|
|
|
, future
|
|
|
|
, numpy
|
2020-05-03 17:38:23 +00:00
|
|
|
, pillow
|
2020-04-24 23:36:52 +00:00
|
|
|
, scipy
|
|
|
|
, scikitlearn
|
|
|
|
, scikitimage
|
|
|
|
, threadpoolctl
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "batchgenerators";
|
2020-05-03 17:38:23 +00:00
|
|
|
version = "0.20.0";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
disabled = isPy27;
|
|
|
|
|
2020-05-03 17:38:23 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "MIC-DKFZ";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
|
|
|
sha256 = "0cc3i4wznqb7lk8n6jkprvkpsby6r7khkxqwn75k8f01mxgjfpvf";
|
2020-09-25 04:45:31 +00:00
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2020-06-18 07:06:33 +00:00
|
|
|
patches = [
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/MIC-DKFZ/batchgenerators/pull/59.patch";
|
|
|
|
sha256 = "171b3dm40yn0wi91m9s2nq3j565s1w39jpdf1mvc03rn75i8vdp0";
|
|
|
|
})
|
|
|
|
];
|
|
|
|
|
2020-05-03 17:38:23 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
future numpy pillow scipy scikitlearn scikitimage threadpoolctl
|
|
|
|
];
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
checkInputs = [ pytest unittest2 ];
|
|
|
|
|
|
|
|
checkPhase = "pytest tests";
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "2D and 3D image data augmentation for deep learning";
|
|
|
|
homepage = "https://github.com/MIC-DKFZ/batchgenerators";
|
|
|
|
license = lib.licenses.asl20;
|
|
|
|
maintainers = with lib.maintainers; [ bcdarwin ];
|
|
|
|
};
|
|
|
|
}
|