This post is in response to this question that I received from an IDC user recently:
“where I can find an example of FRACTIONAL Segmentation in DICOM-SEG?”
TL;DR: IDC contains 17,238 fractional segmentation series across multiple radiology and slide microscopy collections.
What are Fractional Segmentations?
DICOM Segmentation objects support three encoding types, defined by the Segmentation Type attribute (0062,0001):
| Type | Values | Overlap Allowed | Description |
|---|---|---|---|
| BINARY | 0 or 1 | Yes | Each voxel is fully inside (1) or outside (0) the segment |
| FRACTIONAL | 0 to MaxFractionalValue | Yes | Continuous values representing probability or occupancy |
| LABELMAP | Integer segment labels | No | Each voxel belongs to exactly one segment (mutually exclusive) |
Fractional Sub-types
FRACTIONAL segmentations are further classified by Segmentation Fractional Type (0062,0010):
- PROBABILITY: Value represents the probability that the segment occupies the voxel
- OCCUPANCY: Value represents the proportion of voxel volume occupied by the segment
Values are stored as unsigned 8-bit integers with the maximum value defined by Maximum Fractional Value attribute (0062,000E) (up to 255).
Why Use Fractional Segmentations?
Fractional segmentations are useful for representing:
- Probability maps from AI/ML model predictions
- Partial volume effects where a voxel contains multiple tissue types
- Uncertainty quantification in automated segmentations
- Continuous measurements like enhancement ratios in functional imaging
Note: as of data release v23, IDC contains only BINARY and FRACTIONAL segmentations; no LABELMAP examples are available.
See DICOM PS3.3 Section C.8.20.2.3 for the normative definition.
Major Collections with Fractional Segmentations
| collection_id | Source Modality | Algorithm | Type | Count |
|---|---|---|---|---|
| ispy2 | MR | Background Threshold, PE threshold | SEMIAUTOMATIC | 2,688 |
| ispy1 | MR | Background Threshold variants | SEMIAUTOMATIC | 2,568 |
| acrin_6698 | MR | Background Threshold / Manual | SEMI/MANUAL | 2,213 |
| tcga_brca | SM | Stony Brook TIL Segmentation | AUTOMATIC | 1,061 |
| breast_mri_nact_pilot | MR | Background Threshold, VOI limits | SEMIAUTOMATIC | 756 |
| tcga_kirc | SM | Stony Brook TIL Segmentation | AUTOMATIC | 514 |
| tcga_ucec | SM | Stony Brook TIL Segmentation | AUTOMATIC | 504 |
| tcga_luad | SM | Stony Brook TIL Segmentation | AUTOMATIC | 479 |
Two Main Types of Fractional SEGs
- Breast MRI (MR) functional tumor mapping (ISPY1, ISPY2, ACRIN-6698) - Probability maps from DCE-MRI enhancement thresholds.
- Slide Microscopy (SM) TIL segmentations (TCGA collections) - Deep learning-based predictions on pathology slides
Ready-to-View Examples
Example 1: Breast MRI (Source Modality: MR)
- collection_id: breast_mri_nact_pilot (part of the I-SPY 1 trial imaging data)
- Patient: UCSF-BR-26
- Algorithm: Background Threshold, PEthresh and MinConn filter, VOI limits
- Source Modality: MR (Breast)
- License: CC BY 3.0
- View DICOM study
Note: OHIF v3 currently cannot display fractional DICOM SEG, see handle fractional SEG objects · Issue #1346 · OHIF/Viewers · GitHub.
Example 2: Pathology Slide (Source Modality: SM)
- collection_id: tcga_kirc
- Patient: TCGA-CJ-4875
- Algorithm: Stony Brook TIL Segmentation Inception-V4 2022
- Source Modality: SM (Slide Microscopy)
- License: CC BY 4.0
- View DICOM study
Tip: Generate viewer URLs programmatically with
client.get_viewer_URL(seriesInstanceUID="...")which auto-selects OHIF for radiology or SLIM for pathology.
Download an Example
from idc_index import IDCClient
client = IDCClient()
# Download a fractional SEG from breast MRI (Source Modality: MR)
# Collection: breast_mri_nact_pilot, Patient: UCSF-BR-26
client.download_from_selection(
seriesInstanceUID="1.3.6.1.4.1.14519.5.2.1.7695.2311.249901144986078351313294733363",
downloadDir="./fractional_seg_example_MR"
)
# Download a fractional SEG from pathology slide (Source Modality: SM)
# Collection: tcga_kirc, Patient: TCGA-CJ-4875
client.download_from_selection(
seriesInstanceUID="1.2.826.0.1.3680043.10.511.3.43729124912062621812911227783921569",
downloadDir="./fractional_seg_example_SM"
)
Query for All Fractional Segmentations
from idc_index import IDCClient
client = IDCClient()
client.fetch_index("seg_index")
# Find all fractional segmentations with collection info and source modality
results = client.sql_query("""
SELECT
i.collection_id,
src.Modality as source_modality,
s.SeriesInstanceUID,
s.AlgorithmName,
s.AlgorithmType,
s.total_segments,
s.segmented_SeriesInstanceUID as source_series
FROM seg_index s
JOIN index i ON s.SeriesInstanceUID = i.SeriesInstanceUID
JOIN index src ON s.segmented_SeriesInstanceUID = src.SeriesInstanceUID
WHERE s.SegmentationType = 'FRACTIONAL'
""")
print(f"Found {len(results)} fractional segmentation series")
print(results[['collection_id', 'source_modality', 'AlgorithmName']].head(10))
Verify the Data
Run this to confirm the statistics are current:
from idc_index import IDCClient
client = IDCClient()
client.fetch_index("seg_index")
# Total fractional segmentations
total = client.sql_query("SELECT COUNT(*) FROM seg_index WHERE SegmentationType = 'FRACTIONAL'")
print(f"Total fractional SEGs: {total.iloc[0,0]}")
# IDC version
print(f"IDC version: {client.get_idc_version()}")
If you made it all the way to this point - you get a bonus: this blog post was generated using the imaging-data-commons Claude skill that we recently added here: GitHub - K-Dense-AI/claude-scientific-skills: A set of ready to use scientific skills for Claude (with several follow up prompts, not from the first try yet), followed by some relatively minor manual edits. I will follow up with a separate post on that skill, but you are welcome to give it a try right away and share your feedback with me!