1{ lib
2, buildPythonPackage
3, fetchFromGitHub
4, isPy27
5, gdcm
6, nose
7, nibabel
8, numpy
9, pydicom
10, scipy
11, setuptools
12}:
13
14buildPythonPackage rec {
15 pname = "dicom2nifti";
16 version = "2.3.0";
17 disabled = isPy27;
18
19 # no tests in PyPI dist
20 src = fetchFromGitHub {
21 owner = "icometrix";
22 repo = pname;
23 rev = version;
24 sha256 = "sha256-QSu9CGXFjDpI25Cy6QSbrwiQ2bwsVezCUxSovRLs6AI=";
25 };
26
27 propagatedBuildInputs = [ nibabel numpy pydicom scipy setuptools ];
28
29 checkInputs = [ nose gdcm ];
30 checkPhase = "nosetests tests";
31
32 meta = with lib; {
33 homepage = "https://github.com/icometrix/dicom2nifti";
34 description = "Library for converting dicom files to nifti";
35 license = licenses.mit;
36 maintainers = with maintainers; [ bcdarwin ];
37 };
38}