Anatomy Guided CSM nnU Net for Pelvic Fragment Instances
About
Summary
Algorithm. The method is a two-stage cascade built on nnU-Net v2 (3D full-resolution). A first anatomical model segments the CT into four bone regions (sacrum, left hipbone, right hipbone, femur). Each region is then masked out of the CT and passed to a second fragment model that predicts a Contact Surface Map (CSM), a three-class representation (background, bone foreground, and inter-fragment contact surface). The CSM is decoded into individual fragment instances with a KD-tree based algorithm that uses the contact surface to separate touching fragments. Instances are then merged into a single label map with per-bone ID offsets (sacrum 1 to 50, left hipbone 51 to 100, right hipbone 101 to 150, femur 151 to 200), clipped to their anatomical region, filtered by a minimum volume, and written as an integer mask geometrically identical to the input.
Development. Models were trained on the PENGWIN CT training set using a patient-grouped 5-fold cross-validation split to prevent leakage between the per-bone cases of a same patient. Two fragment-separation paradigms were benchmarked under a false-positive-aware Panoptic Quality metric, and the CSM approach was selected over an alternative border-core encoding after it scored higher (PQ 0.83 versus 0.77). The fragment model uses the ResEnc-M nnU-Net preset. The full pipeline was validated end to end, checking instance ID ranges, per-region assignment, and voxel-exact output geometry.
Mechanism
Target population. Patients with peripelvic fractures, that is fractures of the pelvic ring and proximal femur, typically resulting from high-energy trauma. These are patients undergoing CT imaging for trauma diagnosis and preoperative planning, where each fractured bone may be broken into several displaced fragments that must be individually identified for classification, reduction planning, and fixation.
Algorithm description. The algorithm is a two-stage cascade based on nnU-Net v2 (3D full resolution). Stage one is an anatomical model that segments the CT into four bone classes (sacrum, left hipbone, right hipbone, femur). Each bone region is then isolated from the CT and processed by a second fragment model that predicts a Contact Surface Map, a three-class representation of background, bone foreground, and the contact surface between adjacent fragments. The contact surface is used by a KD-tree based decoder to split touching fragments into distinct instances. Per-bone instances are merged into one label map using fixed ID offsets per bone, restricted to their anatomical region, and filtered by a minimum volume to suppress spurious fragments. The fragment model uses the residual-encoder ResEnc-M nnU-Net configuration, and models were trained with a patient-grouped cross-validation split to avoid leakage.
Inputs and outputs. The input is a single 3D CT volume. The output is a 3D instance segmentation mask stored as an integer image with the same size, spacing, origin, and orientation as the input. Label encoding is 0 for background, 1 to 50 for sacrum fragments, 51 to 100 for left hipbone fragments, 101 to 150 for right hipbone fragments, and 151 to 200 for femur fragments, allowing up to 50 fragments per bone. Each connected fragment receives a unique label within its bone range.
Interfaces
This algorithm implements all of the following input-output combinations:
Validation and Performance
Method¶
Our pipeline decouples semantic segmentation (solved reliably by a strong backbone) from instance separation (the actual bottleneck of Task 1). It runs in two stages.
A first nnU-Net (3D full-resolution, 5 anatomical classes: sacrum, left/right hipbone, femur) assigns each voxel to a bone. A second nnU-Net (ResEnc-M, 3D full-resolution) predicts a Contact Surface Map (CSM): background, foreground (bone body), and contact (the surface where two fragments touch). Instances are then recovered per bone by masking the CSM to one bone at a time and decoding it with a connected-components plus KD-tree procedure (frac_to_instance, -k 5 -c 100). Per-bone results are fused with an anatomical offset, clipped to the anatomical mask, filtered by a minimum-volume rule, and capped at 50 fragments per bone. Output is a uint8 .mha with labels 1-50 sacrum, 51-100 left hip, 101-150 right hip, 151-200 femur.
All experiments use a patient-grouped 5-fold split (GroupKFold on the patient ID, stripping the per-bone suffix). This prevents the four bones of one patient from straddling the train/validation boundary, a leakage source we identified and corrected early. Reported numbers are per-bone validation on fold 0 (136 cases) unless stated. The panoptic metric is PQ = SQ × RQ, with Hungarian matching at IoU > 0.5.
Instance representation: CSM vs ABBC¶
We evaluated two paradigms for turning the semantic prediction into instances: the CSM used above, and the ABBC representation (border / core / fracture) from the 2024 winners, decoded with a geodesic fast-marching procedure. Under the FP-aware panoptic metric and an equivalent segmentation budget, CSM was clearly ahead, so it was retained.
Table 1. Representation paradigm (FP-aware PQ, equivalent budget, fold 0).
| Representation | Decoder | PQ (FP-aware) |
|---|---|---|
| CSM (3-class) | KD-tree | 0.834 |
| ABBC (4-class) | geodesic FMM | 0.771 |
Loss study: FP-aware Tversky-CE¶
Phantom fragments (false-positive instances) are what the panoptic metric punishes most, so we tried to attack them at the loss level. We trained a compound per-class Tversky plus weighted cross-entropy loss: an FP-emphasis on the foreground channel (Tversky α=0.6, β=0.4) and a recall-emphasis on the thin contact channel (α=0.3, β=0.7, CE weight 3), so that contact surfaces separating glued fragments are not extinguished. A naive global asymmetry collapsed the contact channel to zero Dice; the per-class formulation fixed this (final validation contact Dice 0.61, foreground 0.99).
The loss trained cleanly and did shift the operating point, but it did not beat the stock model. On matched data (same fold, same 136 cases, identical decoding), it converted merge errors into split errors at a roughly 1:1 ratio: relative to stock it recovered 14 true fragments and cut 14 false negatives, but added 17 false positives, leaving recall quality essentially unchanged.
Table 2. Loss configurations (fold 0, 136 cases, decode c=100, no volume filter).
| Model | SQ | RQ | PQ | TP / FP / FN |
|---|---|---|---|---|
| Stock CSM (1000 ep) | 0.9534 | 0.8889 | 0.8475 | 296 / 22 / 52 |
| CSM + Tversky-CE FP-aware (250 ep) | 0.9426 | 0.8895 | 0.8385 | 310 / 39 / 38 |
A fragment-level cross-check confirmed the lower SQ of the loss model is largely a composition artifact: on the 293 fragments both models find, per-fragment IoU is nearly identical (0.9545 vs 0.9521); the aggregate SQ drop comes almost entirely from the 17 harder fragments the loss model additionally recovers (mean IoU 0.78), which pull the mean down. In other words the loss model is scored on more, and harder, fragments.
For reference, the stock CSM reaches 0.849 mean / 0.956 median fragment-IoU per bone, and PQ ≈ 0.825 in 5-fold cross-validation.
Post-processing: minimum-volume filtering¶
We swept the minimum-volume filter on both models. It cleanly removes small false positives, but on the loss model it cannot isolate the gain from the cost: the phantom fragments and the genuinely recovered fragments occupy the same volume band, so the filter removes them together (about 19 FP removed for 14 true TP destroyed). No threshold lets the loss model overtake stock.
Table 3. Volume-filter sweep on the stock model (fold 0, 136 cases).
| min volume (mm³) | TP | FP | FN | SQ | RQ | PQ |
|---|---|---|---|---|---|---|
| 0 | 296 | 22 | 52 | 0.9534 | 0.8889 | 0.8475 |
| 250 | 296 | 21 | 52 | 0.9534 | 0.8902 | 0.8488 |
| 500 | 295 | 19 | 53 | 0.9534 | 0.8912 | 0.8497 |
| 750 | 292 | 13 | 56 | 0.9531 | 0.8943 | 0.8524 |
| 1000 | 283 | 10 | 65 | 0.9565 | 0.8830 | 0.8446 |
The peak PQ (0.8524 at 750 mm³) comes at the cost of 4 real fragments, which hurts instance recall. We therefore keep a recall-preserving setting (250-500 mm³), which improves PQ at zero loss of true fragments.
Summary and ongoing work¶
We established that the limiting factor is not detection (foreground Dice 0.99) nor the loss, but instance separation at the decoding stage: a voxel-level loss can only pick a point on the merge-versus-split trade-off, because the heuristic decoder reintroduces that trade-off downstream. Neither the FP-aware loss nor the volume filter crosses this wall, because the errors are not separable by size.
Current work targets a signal orthogonal to size: guiding fragment merging by the network's own predicted contact probability along shared boundaries (a split unsupported by contact evidence is likely phantom), optionally reinforced by a per-fragment core signal (an over-split leaves one side without a distinct core). This is a decoder-level arbitration applied on top of the existing instances, requiring no retraining.
Uses and Directions
This algorithm was developed for research purposes only. It is not a certified medical device and must not be used for autonomous diagnosis, treatment decisions, or intraoperative guidance. Its output should not be relied upon without review by a trained clinician or annotator. It should not be applied outside its intended scope: non-CT modalities, anatomy other than the pelvis and proximal femur, or clinical populations and imaging protocols that differ substantially from the training data. It is not validated for real-time or safety-critical use.
Warnings
Performance is only established on data resembling the PENGWIN training distribution. Accuracy can degrade on out-of-distribution inputs, including unusual slice thickness or resolution, contrast-enhanced scans, strong metal or motion artifacts, orthopedic hardware, pediatric anatomy, and pathologies such as tumors or prior surgery that were not represented in training. The method is a cascade: errors in the first anatomical segmentation stage propagate to the fragment stage, so a mis-segmented bone can cause missed, merged, or spurious fragments. Typical failure modes include over-segmentation of a single fragment into several instances (split errors), merging of adjacent fragments (merge errors), and small false-positive fragments. Fragment labels are capped at 50 per bone, so cases with extreme comminution may be under-represented. The output geometry matches the input, so any error in input orientation or spacing will carry through. All results must be verified by a qualified professional before any research or clinical interpretation.