1{ lib 2, buildPythonPackage 3, fetchPypi 4, pythonOlder 5, pytestCheckHook 6, pythonRelaxDepsHook 7, matplotlib 8, nibabel 9, numpy 10, pydicom 11, pymedio 12, scikit-fuzzy 13, scikit-image 14, scikit-learn 15, scipy 16, simpleitk 17, statsmodels 18}: 19 20buildPythonPackage rec { 21 pname = "intensity-normalization"; 22 version = "2.2.4"; 23 format = "setuptools"; 24 25 disabled = pythonOlder "3.6"; 26 27 src = fetchPypi { 28 pname = "intensity_normalization"; 29 inherit version; 30 hash = "sha256-s/trDIRoqLFj3NO+iv3E+AEB4grBAHDlEL6+TCdsgmg="; 31 }; 32 33 postPatch = '' 34 substituteInPlace setup.cfg --replace "!=3.10.*," "" --replace "!=3.11.*" "" 35 substituteInPlace setup.cfg --replace "pytest-runner" "" 36 ''; 37 38 nativeBuildInputs = [ pythonRelaxDepsHook ]; 39 pythonRelaxDeps = [ "nibabel" ]; 40 41 propagatedBuildInputs = [ 42 matplotlib 43 nibabel 44 numpy 45 pydicom 46 pymedio 47 scikit-fuzzy 48 scikit-image 49 scikit-learn 50 scipy 51 simpleitk 52 statsmodels 53 ]; 54 55 nativeCheckInputs = [ 56 pytestCheckHook 57 ]; 58 pytestFlagsArray = [ "tests" ]; 59 60 pythonImportsCheck = [ 61 "intensity_normalization" 62 "intensity_normalization.normalize" 63 "intensity_normalization.plot" 64 "intensity_normalization.util" 65 ]; 66 67 68 meta = with lib; { 69 homepage = "https://github.com/jcreinhold/intensity-normalization"; 70 description = "MRI intensity normalization tools"; 71 maintainers = with maintainers; [ bcdarwin ]; 72 license = licenses.asl20; 73 }; 74}