InsightSoftwareConsortium / InsightSoftwareConsortium/ITK
GDCMSeriesFileNames: support gantry-tilt CT ordering by default (follow-up to #6468)
- Dominant language
- C++
- Stars
- 1.7k
- Forks
- 748
- Avg merge
- 1d 1h
- Merged PRs (30d)
- 64
Description
Follow-up to #6468 (now closed): the `GDCMSeriesFileNames` migration onto `gdcm::IPPSorter` landed (`50dfb136658`, `7cb3bbec23d`), but @dzenanz's specific request from that discussion is not yet fully satisfied and deserves its own tracking issue.
> Gantry-tilt CTs should continue to be supported. I encountered this with pediatric patients - technicians were trying hard to avoid the eyes while scanning.
## Current state on `main`
`gdcm::IPPSorter` treats gantry tilt as an error, so with the default `m_FailOnAmbiguousOrdering = true` (`itkGDCMSeriesFileNames.h:258`) a gantry-tilt series now **throws** instead of ordering. Gantry-tilt CT is only handled by setting `FailOnAmbiguousOrdering` to false, which routes to the ported SerieHelper fallback — and the code comment for that path (`itkGDCMSeriesFileNames.cxx:234`) calls it "an untrustworthy, non-standard hack whose output should not be trusted."
So the acquisition @dzenanz named — real, clinically-motivated pediatric head CT — is supported only via an opt-in path the code itself disavows, and not at all by default.
## The ask
Decide and implement first-class gantry-tilt handling for `GDCMSeriesFileNames`. Options to weigh:
1. Detect gantry tilt explicitly (non-orthogonal slice-normal vs. orientation) and order it correctly via IPP-projected-on-normal, *without* routing through the disavowed legacy fallback — i.e. make the tilt case trustworthy rather than merely tolerated.
2. Keep the strict default but promote gantry tilt out of the "ambiguous → throw" bucket into a supported, documented, correctly-sorted case.
3. Confirm whether `IPPSorter`'s own `SetComputeZSpacing` / tilt handling can be leaned on before falling back to ported logic.
Whatever the choice, the acceptance test is a gantry-tilt CT series that sorts correctly under the **default** settings, with a regression test fixture.
## Related
- #6468 — the discussion this splits from (closed; concrete migration deliverable landed)
- #6467 — the migration PR
- #2735, #6464, #6466 — DCMTK IPP-on-normal ordering parity
Contributor guide
Research direction
Read itkGDCMSeriesFileNames.h around m_FailOnAmbiguousOrdering and itkGDCMSeriesFileNames.cxx around the SerieHelper fallback, then inspect gdcm::IPPSorter and the ordering discussion in #6468. Determine how gantry tilt should be handled without the disavowed fallback. Done means a gantry-tilt CT fixture sorts correctly with default settings and a regression test covers it.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- computer-vision
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100