Skip to content

v0.3.1

Choose a tag to compare

@lassoan lassoan released this 24 Oct 01:43

Clinical test data set download.

New

  • clinical_test_data(revision) downloads a revision of the clinical test data set (15 de-identified 4D flow MRI cases in 3D Slicer native formats, CC BY 4.0, from the TestingData release) and returns the full path of the data set root:

    import slicerheart_4dflow as f4d
    root = f4d.clinical_test_data("rev001")
    case = f4d.load_case(root, f4d.dataset_cases(root)[0])
    • The data sets are kept in ~/.SlicerHeart/slicerheart_4dflow_testingdata (one clinical_<revision>/ folder per revision), shared by every Python environment and 3D Slicer installation of the user; SLICERHEART_4DFLOW_TESTDATA or base_dir selects another folder. cases= downloads only some cases.
    • The manifest of the revision (clinical_manifest_<revision>.json, the manifest.json of the data set) lists the size and sha256 of every file and the zip that contains it; it is verified by the sha256 recorded in the package. Only missing or changed files are downloaded again; the cache is checked by the size and modification time of each file, without reading them.
    • slicerheart_4dflow.testing_data.ClinicalTestingData gives the cases of a revision from its manifest without downloading them, and downloads a case when it is needed (ensure_case).
    • Command line: python -m slicerheart_4dflow.testing_data download [revision], and package to write the release files of a new revision.

Tests

  • The clinical tests (marker clinical) download the data set on first use instead of needing a local copy, and run in CI in a separate job that keeps the data set in the GitHub Actions cache.

Full list of changes: v0.3.0...v0.3.1