{
  "schema_version": 1,
  "method": "Native MLX Radiomics voxel extraction with mlxradiomics.medmlx.run, one run per selected BTCV organ label",
  "job": {
    "script": "docs/hero/compute_radiomics_organs.py",
    "script_sha256": "45e3f3b67dba39ebedaa348054397f0aa7bd62246972d317bade9420adf0fc26",
    "entry_point": "mlxradiomics.medmlx.run(image_path, mask_path, output_dir, params, voxel=True)",
    "started_at": "2026-10-31T21:42:39+00:00",
    "finished_at": "2026-10-31T21:42:40+00:00"
  },
  "runtime": {
    "package": "mlxradiomics",
    "version": "0.1.0.dev8",
    "medmlx_core_version": "0.2.5",
    "mlx_version": "0.32.4",
    "simpleitk_version": "2.5.6",
    "nibabel_version": "5.4.2",
    "numpy_version": "2.5.4",
    "python_version": "3.13.18",
    "device": "Apple M5 Max GPU",
    "precision": "float32"
  },
  "source": {
    "source_file": "paper/inputs/figure1.npz",
    "source_sha256": "809be09f21e54691861026c9b43dcb50a2e4f2eeb13b5d9f0b4cff33909a6198",
    "image_key": "swinunetr/image",
    "labels_key": "swinunetr/labels",
    "source_case": "AMOS22 amos_0008",
    "axial_slice": 80,
    "spacing_mm_row_col": [
      0.6158854365348816,
      0.6158854365348816
    ],
    "input_shape": [
      768,
      768
    ],
    "derivation": "Same as radiomics-run.json: the retained raw HU axial slice and native SwinUNETR prediction are written as one-slice NIfTI with SimpleITK in local display coordinates. Display orientation and in-plane spacing are preserved; the 1 mm through-plane spacing is a storage convention that force2D excludes from neighborhoods. No resampling or input smoothing. Each ROI is a 0/1 mask extracted as label 1.",
    "parameters": {
      "setting": {
        "binWidth": 10,
        "kernelRadius": 5,
        "maskedKernel": true,
        "force2D": true,
        "force2Ddimension": 0
      },
      "featureClass": {
        "firstorder": [
          "Entropy"
        ],
        "glcm": [
          "Contrast",
          "Idmn"
        ]
      }
    },
    "ct_nifti_sha256": "f4d18d7a6eac69d620bc48b65a9ade83349aca088f6e080e87dd0226a3df3bba",
    "ct_nifti_matches_liver_run": true
  },
  "label_map": {
    "source": "swin-unetr-mlx v0.2.5, src/swin_unetr_mlx/specification.json, inference.labels (BTCV)",
    "names": {
      "0": "background",
      "1": "spleen",
      "2": "right kidney",
      "3": "left kidney",
      "4": "gallbladder",
      "5": "esophagus",
      "6": "liver",
      "7": "stomach",
      "8": "aorta",
      "9": "inferior vena cava",
      "10": "portal and splenic veins",
      "11": "pancreas",
      "12": "right adrenal gland",
      "13": "left adrenal gland"
    }
  },
  "organ_selection": {
    "rule": "Parenchymal organs (vessels excluded) whose largest predicted 4-connected component has at least 1000 pixels on this plane and at most 25% of its pixels below -200 HU (gas lumen). Smaller ROIs leave most 11 x 11 kernels partly empty; gas-filled ROIs map air-wall edges rather than tissue texture.",
    "labels_on_plane": {
      "1": {
        "name": "spleen",
        "predicted_pixels": 533,
        "components": 1,
        "largest_component_pixels": 533,
        "largest_component_area_cm2": 2.02,
        "largest_component_fraction_below_-200_hu": 0.0,
        "shown": false,
        "excluded_because": [
          "largest component below 1000 pixels"
        ]
      },
      "2": {
        "name": "right kidney",
        "predicted_pixels": 3282,
        "components": 1,
        "largest_component_pixels": 3282,
        "largest_component_area_cm2": 12.45,
        "largest_component_fraction_below_-200_hu": 0.0,
        "shown": true,
        "excluded_because": []
      },
      "3": {
        "name": "left kidney",
        "predicted_pixels": 3811,
        "components": 1,
        "largest_component_pixels": 3811,
        "largest_component_area_cm2": 14.46,
        "largest_component_fraction_below_-200_hu": 0.0,
        "shown": true,
        "excluded_because": []
      },
      "4": {
        "name": "gallbladder",
        "predicted_pixels": 940,
        "components": 1,
        "largest_component_pixels": 940,
        "largest_component_area_cm2": 3.57,
        "largest_component_fraction_below_-200_hu": 0.033,
        "shown": false,
        "excluded_because": [
          "largest component below 1000 pixels"
        ]
      },
      "6": {
        "name": "liver",
        "predicted_pixels": 14940,
        "components": 3,
        "largest_component_pixels": 14435,
        "largest_component_area_cm2": 54.75,
        "largest_component_fraction_below_-200_hu": 0.0,
        "shown": true,
        "excluded_because": []
      },
      "7": {
        "name": "stomach",
        "predicted_pixels": 5153,
        "components": 12,
        "largest_component_pixels": 2706,
        "largest_component_area_cm2": 10.26,
        "largest_component_fraction_below_-200_hu": 0.576,
        "shown": false,
        "excluded_because": [
          "58% of pixels below -200 HU"
        ]
      },
      "8": {
        "name": "aorta",
        "predicted_pixels": 1478,
        "components": 1,
        "largest_component_pixels": 1478,
        "largest_component_area_cm2": 5.61,
        "largest_component_fraction_below_-200_hu": 0.0,
        "shown": false,
        "excluded_because": [
          "vessel"
        ]
      },
      "9": {
        "name": "inferior vena cava",
        "predicted_pixels": 827,
        "components": 1,
        "largest_component_pixels": 827,
        "largest_component_area_cm2": 3.14,
        "largest_component_fraction_below_-200_hu": 0.0,
        "shown": false,
        "excluded_because": [
          "vessel",
          "largest component below 1000 pixels"
        ]
      },
      "10": {
        "name": "portal and splenic veins",
        "predicted_pixels": 84,
        "components": 1,
        "largest_component_pixels": 84,
        "largest_component_area_cm2": 0.32,
        "largest_component_fraction_below_-200_hu": 0.0,
        "shown": false,
        "excluded_because": [
          "vessel",
          "largest component below 1000 pixels"
        ]
      },
      "11": {
        "name": "pancreas",
        "predicted_pixels": 1419,
        "components": 3,
        "largest_component_pixels": 1357,
        "largest_component_area_cm2": 5.15,
        "largest_component_fraction_below_-200_hu": 0.0,
        "shown": true,
        "excluded_because": []
      },
      "12": {
        "name": "right adrenal gland",
        "predicted_pixels": 283,
        "components": 1,
        "largest_component_pixels": 283,
        "largest_component_area_cm2": 1.07,
        "largest_component_fraction_below_-200_hu": 0.0,
        "shown": false,
        "excluded_because": [
          "largest component below 1000 pixels"
        ]
      },
      "13": {
        "name": "left adrenal gland",
        "predicted_pixels": 265,
        "components": 1,
        "largest_component_pixels": 265,
        "largest_component_area_cm2": 1.01,
        "largest_component_fraction_below_-200_hu": 0.0,
        "shown": false,
        "excluded_because": [
          "largest component below 1000 pixels"
        ]
      }
    }
  },
  "execution": {
    "settings": {
      "gldm_alpha": 0,
      "bin_width": 10.0,
      "bin_count": null,
      "normalize": false,
      "normalize_scale": 1.0,
      "remove_outliers": null,
      "resegment_range": null,
      "resegment_mode": "absolute",
      "resegment_shape": false,
      "label": 1,
      "distances": [
        1
      ],
      "symmetrical_glcm": true,
      "force2d_axis": 0,
      "masked_kernel": true,
      "kernel_radius": 5,
      "voxel_array_shift": 0.0,
      "scratch_mib": 64,
      "max_gray_levels": 256,
      "features": [
        "firstorder_Entropy",
        "glcm_Contrast",
        "glcm_Idmn"
      ]
    },
    "device": "gpu",
    "precision": "float32",
    "voxel": true,
    "spacing": [
      1.0,
      0.6158854365348816,
      0.6158854365348816
    ],
    "histogram_method": "mlx",
    "preprocessing": "Host float64 normalization, resegmentation and binning; native Metal features"
  },
  "organs": {
    "right-kidney": {
      "label": 2,
      "name": "right kidney",
      "roi_selection": {
        "rule": "largest 4-connected component of the original predicted right kidney mask, computed before radiomics extraction",
        "original_roi_pixels": 3282,
        "selected_roi_pixels": 3282,
        "excluded_roi_pixels": 0,
        "original_component_count": 1,
        "component_pixels": [
          3282
        ],
        "manual_mask_edits": false
      },
      "roi_nifti_sha256": "c6eb3689896d428d727ea3cf6147630aba6b944f424b1445a891ce17395332c7",
      "roi_main_nifti_sha256": "c6eb3689896d428d727ea3cf6147630aba6b944f424b1445a891ce17395332c7",
      "execution": {
        "batch_size": 2025,
        "gray_levels": 11,
        "scratch_estimate_bytes": 67103760
      },
      "wall_seconds": 1.05,
      "roi_local_artifact": "dist/radiomics-organs-demo/right-kidney-roi-main.nii.gz",
      "entropy_map": {
        "sha256": "6d754969d264231792bc0edf51dd3153d5c8e138352d0c78806ebaf58b93d220",
        "finite_roi_voxels": 3282,
        "outside_roi_zero": true,
        "range": [
          1.726324439048767,
          2.988022804260254
        ],
        "local_artifact": "dist/radiomics-organs-demo/computed/right-kidney/maps/original_firstorder_Entropy.nii.gz",
        "percentiles_2_50_98_bits": [
          1.8785721516609193,
          2.2501273155212402,
          2.8213612031936646
        ]
      },
      "other_maps_sha256": {
        "original_glcm_Contrast": "e1f30a3c75611f947fffa5c077d690287db2366164edcbfa7a89c276b05b05db",
        "original_glcm_Idmn": "9d84f7fb530841fbd82b0dae205a563432fa834d4b51fb6de995a9b43352f26c"
      }
    },
    "left-kidney": {
      "label": 3,
      "name": "left kidney",
      "roi_selection": {
        "rule": "largest 4-connected component of the original predicted left kidney mask, computed before radiomics extraction",
        "original_roi_pixels": 3811,
        "selected_roi_pixels": 3811,
        "excluded_roi_pixels": 0,
        "original_component_count": 1,
        "component_pixels": [
          3811
        ],
        "manual_mask_edits": false
      },
      "roi_nifti_sha256": "3588ceaebc4a8f4f873ff9f65d0b95d7061af6836ca8978775d8a64defbd703d",
      "roi_main_nifti_sha256": "3588ceaebc4a8f4f873ff9f65d0b95d7061af6836ca8978775d8a64defbd703d",
      "execution": {
        "batch_size": 1859,
        "gray_levels": 12,
        "scratch_estimate_bytes": 67076080
      },
      "wall_seconds": 0.24,
      "roi_local_artifact": "dist/radiomics-organs-demo/left-kidney-roi-main.nii.gz",
      "entropy_map": {
        "sha256": "56773f87444236611c7b3afa1496846ec6f0e2e709c803df60ea92c5ca7ecf51",
        "finite_roi_voxels": 3811,
        "outside_roi_zero": true,
        "range": [
          1.3890089988708496,
          3.1654586791992188
        ],
        "local_artifact": "dist/radiomics-organs-demo/computed/left-kidney/maps/original_firstorder_Entropy.nii.gz",
        "percentiles_2_50_98_bits": [
          1.629258942604065,
          2.1198906898498535,
          2.9625503540039055
        ]
      },
      "other_maps_sha256": {
        "original_glcm_Contrast": "9f7732e08790e88f2e49f1c40cae02f7ad9d5934874d3eabaac64b8f0eb7fb0c",
        "original_glcm_Idmn": "0b5774295dbacc40d1e040e1e552238e51674d3a256bc1dfab11749ef04f6b45"
      }
    },
    "liver": {
      "label": 6,
      "name": "liver",
      "roi_selection": {
        "rule": "largest 4-connected component of the original predicted liver mask, computed before radiomics extraction",
        "original_roi_pixels": 14940,
        "selected_roi_pixels": 14435,
        "excluded_roi_pixels": 505,
        "original_component_count": 3,
        "component_pixels": [
          14435,
          468,
          37
        ],
        "manual_mask_edits": false
      },
      "roi_nifti_sha256": "bcd2ce26e73500ec93b13142003360cd36fc5c23c357ae1855353fbcf884d091",
      "roi_main_nifti_sha256": "c5239e3354e6b388d2fa402c3ac24c87767567b928e9c4dbd39e27327024716a",
      "execution": {
        "batch_size": 687,
        "gray_levels": 25,
        "scratch_estimate_bytes": 67087536
      },
      "wall_seconds": 0.29,
      "roi_local_artifact": "dist/radiomics-organs-demo/liver-roi-main.nii.gz",
      "entropy_map": {
        "sha256": "b1f5021b41cdde937a4e334feef6ad63c874e2c16fac0e13f849a6002a94ab43",
        "finite_roi_voxels": 14435,
        "outside_roi_zero": true,
        "range": [
          0.6815892457962036,
          3.194377899169922
        ],
        "local_artifact": "dist/radiomics-organs-demo/computed/liver/maps/original_firstorder_Entropy.nii.gz",
        "percentiles_2_50_98_bits": [
          1.4660650730133056,
          1.9705654382705688,
          2.936603088378906
        ]
      },
      "other_maps_sha256": {
        "original_glcm_Contrast": "afca448197d5d5ad0a34c676c9de1fc183dd3b3bdef0a5d2dfbabad499c4751a",
        "original_glcm_Idmn": "f90942caa4814f34352e8365a6f47d7c5bac1c552034827e2829fb23bd6f9d75"
      }
    },
    "pancreas": {
      "label": 11,
      "name": "pancreas",
      "roi_selection": {
        "rule": "largest 4-connected component of the original predicted pancreas mask, computed before radiomics extraction",
        "original_roi_pixels": 1419,
        "selected_roi_pixels": 1357,
        "excluded_roi_pixels": 62,
        "original_component_count": 3,
        "component_pixels": [
          1357,
          46,
          16
        ],
        "manual_mask_edits": false
      },
      "roi_nifti_sha256": "566f885ae19cd89c624f992e4e0527aee9ea95f2a1c7aa824c2cd2452b205e5c",
      "roi_main_nifti_sha256": "4f3b29e77fff7b87555b7b57bab4c0906e316f41c0a91dec0fd03fc21cc15edd",
      "execution": {
        "batch_size": 2203,
        "gray_levels": 10,
        "scratch_estimate_bytes": 67080304
      },
      "wall_seconds": 0.226,
      "roi_local_artifact": "dist/radiomics-organs-demo/pancreas-roi-main.nii.gz",
      "entropy_map": {
        "sha256": "b5797939c2f415b7713bdab44f07e993b9cd78aeb38c05b9b312ef49758b2e71",
        "finite_roi_voxels": 1357,
        "outside_roi_zero": true,
        "range": [
          1.5287095308303833,
          2.8415069580078125
        ],
        "local_artifact": "dist/radiomics-organs-demo/computed/pancreas/maps/original_firstorder_Entropy.nii.gz",
        "percentiles_2_50_98_bits": [
          1.867669277191162,
          2.215189218521118,
          2.74032130241394
        ]
      },
      "other_maps_sha256": {
        "original_glcm_Contrast": "9c20bdf183c60f33eb526b874159e33e308aa607eb366f3fad911be7e6034c73",
        "original_glcm_Idmn": "4cf079a0c964c65cf06a61240cb6c2ac4b59b01ef1fc1f766f33e4da5ecb8926"
      }
    }
  },
  "reference_check": {
    "reference": "radiomics-run.json maps, mlxradiomics 0.1.0.dev5, same CT, ROI and parameters",
    "liver_roi_main_matches": true,
    "maps": {
      "original_firstorder_Entropy": {
        "previous_sha256": "b1f5021b41cdde937a4e334feef6ad63c874e2c16fac0e13f849a6002a94ab43",
        "current_sha256": "b1f5021b41cdde937a4e334feef6ad63c874e2c16fac0e13f849a6002a94ab43",
        "identical": true
      },
      "original_glcm_Contrast": {
        "previous_sha256": "afca448197d5d5ad0a34c676c9de1fc183dd3b3bdef0a5d2dfbabad499c4751a",
        "current_sha256": "afca448197d5d5ad0a34c676c9de1fc183dd3b3bdef0a5d2dfbabad499c4751a",
        "identical": true
      },
      "original_glcm_Idmn": {
        "previous_sha256": "f90942caa4814f34352e8365a6f47d7c5bac1c552034827e2829fb23bd6f9d75",
        "current_sha256": "f90942caa4814f34352e8365a6f47d7c5bac1c552034827e2829fb23bd6f9d75",
        "identical": true
      }
    }
  },
  "display": {
    "renderer": "docs/hero/render_radiomics_organs.py",
    "renderer_sha256": "a1776a2a5312b6175268ba6dd3f7ac1122c1302d454939c0866f1cc626a1fd7a",
    "feature": "original_firstorder_Entropy",
    "units": "bits",
    "ct_window_hu": [
      -160,
      240
    ],
    "color_range_rule": "2nd-98th percentile of the union of every displayed ROI value (liver, right-kidney, left-kidney, pancreas), lower bound floored at 0; one range for every frame",
    "color_range_percentiles": [
      2,
      98
    ],
    "color_range_bits": [
      1.5410347270965576,
      2.9084545898437497
    ],
    "union_roi_pixels": 22885,
    "union_feature_range_bits": [
      0.6815892457962036,
      3.194377899169922
    ],
    "union_pixels_clipped": {
      "below": 458,
      "above": 458
    },
    "color_palette_rgb": [
      [
        48,
        9,
        20
      ],
      [
        120,
        24,
        43
      ],
      [
        195,
        58,
        77
      ],
      [
        239,
        137,
        143
      ],
      [
        255,
        233,
        226
      ]
    ],
    "overlay_opacity": 0.78,
    "body_mask": "largest CT > -300 HU component, holes filled; contains every analysis ROI; pixels outside it set to black",
    "source_crop_xyxy": [
      118,
      164,
      639,
      576
    ],
    "source_crop_matches_liver_asset": true,
    "panel_xywh_px": [
      20,
      54,
      521,
      412
    ],
    "display_resampling": "none; the cropped panel is placed at 1:1 source pixels",
    "numerical_smoothing": false,
    "frame_size_px": [
      800,
      520
    ],
    "background": "black",
    "legend": {
      "font": "Inter SemiBold 40 px (organ), Inter Regular 30 px (labels)",
      "font_source": "Inter, SIL Open Font License",
      "text": [
        "frame title",
        "Local entropy",
        "2.9 bits",
        "1.5 bits"
      ],
      "ramp_px": [
        22,
        180
      ]
    }
  },
  "animation": {
    "fps": 24,
    "hold_frames": 48,
    "dissolve_frames": 12,
    "hold_seconds": 2.0,
    "dissolve_seconds": 0.5,
    "dissolve": "smoothstep cross-dissolve of the rendered RGB frames, alpha = s((k+1)/13) for k = 0..11; feature values are never blended or interpolated",
    "title": "the outgoing organ name fades out over the first half of each dissolve and the incoming name fades in over the second half; the ramp and its labels are identical in every frame",
    "order": [
      {
        "title": "Liver",
        "organs": [
          "liver"
        ],
        "start_frame": 0,
        "start_seconds": 0.0
      },
      {
        "title": "Kidneys",
        "organs": [
          "right-kidney",
          "left-kidney"
        ],
        "start_frame": 60,
        "start_seconds": 2.5
      },
      {
        "title": "Pancreas",
        "organs": [
          "pancreas"
        ],
        "start_frame": 120,
        "start_seconds": 5.0
      }
    ],
    "loop_frames": 180,
    "loop_seconds": 7.5,
    "loop": "the last dissolve leads into frame 0, which is the poster"
  },
  "encode": {
    "video": {
      "codec": "H.264 (libx264)",
      "preset": "veryslow",
      "crf": 24,
      "pix_fmt": "yuv420p",
      "color": "BT.709, limited range",
      "fps": 24,
      "frames": 180,
      "size_px": [
        800,
        520
      ],
      "audio": false,
      "movflags": "+faststart",
      "ffmpeg": "ffmpeg version 7.1",
      "imageio_ffmpeg": "0.7.0",
      "sha256": "6028c317e275c9d38b7a12c08e120f603b096e9fbf6c3ebbd30a32c38da2f33f",
      "bytes": 67710
    },
    "poster": {
      "format": "WebP",
      "quality": 85,
      "method": 6,
      "frame": 0,
      "size_px": [
        800,
        520
      ],
      "sha256": "c65ed7fcd8958bce3985bd69e3a05c5d9e9847f1f348ffb5d627b9ec7b3bb512",
      "bytes": 29444
    }
  },
  "outputs": {
    "video": "site/assets/hero/radiomics-organs.mp4",
    "poster": "site/assets/hero/radiomics-organs-poster.webp"
  },
  "interpretation": "One axial plane for a software visualization. Not a clinical finding, comparison, or performance validation. Each map is computed from its own selected ROI neighborhoods; the shared color scale only keeps colors consistent between frames."
}
