-
Notifications
You must be signed in to change notification settings - Fork 16
Open
Description
For some DICOM datasets I would like to order the slices based on multiple tags. For example, in a dataset with a TemporalPositionIdentifier present, I would like to sort by ImagePositionPatient first, and then using the position identifier. The same applies to group_by too.
Preferably, it would be nice to add support for ascending/descending sorts for each tag too:
# single tag
dm.read(path, sort_by="InstanceNumber")
# multiple tags
dm.read(path, sort_by=["ImagePositionPatient", "TemporalPositionIdentifier"])
# multiple tags + order
dm.read(path, sort_by=[{ "tag": "ImagePositionPatient", "asc": True }, { "tag": "TemporalPositionIdentifier", "asc": False }])NB: maybe we should consider to set the default sort_by to ImagePositionPatient.
Metadata
Metadata
Assignees
Labels
No labels