at master 2.0 kB view raw
1{ 2 lib, 3 buildPythonPackage, 4 pythonOlder, 5 fetchFromGitLab, 6 setuptools, 7 dill, 8 h5py, 9 nibabel, 10 numpy, 11 scipy, 12 indexed-gzip, 13 pillow, 14 rtree, 15 trimesh, 16 wxpython, 17 pytestCheckHook, 18 pytest-cov-stub, 19 tomli, 20}: 21 22buildPythonPackage rec { 23 pname = "fslpy"; 24 version = "3.23.0"; 25 pyproject = true; 26 27 disabled = pythonOlder "3.8"; 28 29 src = fetchFromGitLab { 30 domain = "git.fmrib.ox.ac.uk"; 31 owner = "fsl"; 32 repo = "fslpy"; 33 rev = "refs/tags/${version}"; 34 hash = "sha256-lY/7TNOqGK0pRm5Rne1nrqXVQDZPkHwlZV9ITsOwp9Q="; 35 }; 36 37 build-system = [ setuptools ]; 38 39 dependencies = [ 40 dill 41 h5py 42 nibabel 43 numpy 44 scipy 45 ]; 46 47 optional-dependencies = { 48 extra = [ 49 indexed-gzip 50 pillow 51 rtree 52 trimesh 53 wxpython 54 ]; 55 }; 56 57 nativeCheckInputs = [ 58 pytestCheckHook 59 pytest-cov-stub 60 tomli 61 ] 62 ++ optional-dependencies.extra; 63 64 disabledTestPaths = [ 65 # tries to download data: 66 "fsl/tests/test_dicom.py" 67 # tests exit with "SystemExit: Unable to access the X Display, is $DISPLAY set properly?" 68 "fsl/tests/test_idle.py" 69 "fsl/tests/test_platform.py" 70 # require FSL's atlas library (via $FSLDIR), which has an unfree license: 71 "fsl/tests/test_atlases.py" 72 "fsl/tests/test_atlases_query.py" 73 "fsl/tests/test_parse_data.py" 74 "fsl/tests/test_scripts/test_atlasq_list_summary.py" 75 "fsl/tests/test_scripts/test_atlasq_ohi.py" 76 "fsl/tests/test_scripts/test_atlasq_query.py" 77 # requires FSL (unfree and not in Nixpkgs): 78 "fsl/tests/test_fslsub.py" 79 "fsl/tests/test_run.py" 80 "fsl/tests/test_wrappers" 81 ]; 82 83 pythonImportsCheck = [ 84 "fsl" 85 "fsl.data" 86 "fsl.scripts" 87 "fsl.transform" 88 "fsl.utils" 89 "fsl.wrappers" 90 ]; 91 92 meta = { 93 description = "FSL Python library"; 94 homepage = "https://git.fmrib.ox.ac.uk/fsl/fslpy"; 95 changelog = "https://git.fmrib.ox.ac.uk/fsl/fslpy/-/blob/main/CHANGELOG.rst"; 96 license = lib.licenses.asl20; 97 maintainers = with lib.maintainers; [ bcdarwin ]; 98 }; 99}