diff --git a/packages/dicom/gdcm/image-sets-normalization.cxx b/packages/dicom/gdcm/image-sets-normalization.cxx index ee7847176..c48d5d362 100644 --- a/packages/dicom/gdcm/image-sets-normalization.cxx +++ b/packages/dicom/gdcm/image-sets-normalization.cxx @@ -30,6 +30,8 @@ const std::string STUDY_INSTANCE_UID = "0020|000D"; const std::string SERIES_INSTANCE_UID = "0020|000e"; +const std::string FRAME_OF_REFERENCE_UID = "0020|0052"; +const std::string IMAGE_ORIENTATION_PATIENT = "0020|0037"; using File = std::string; @@ -124,8 +126,7 @@ bool compareTags(const TagMap &tags1, const TagMap &tags2, const TagKeys &tagKey bool isSameVolume(const TagMap &tags1, const TagMap &tags2) { - // TODO check cosines - return compareTags(tags1, tags2, {SERIES_INSTANCE_UID}); + return compareTags(tags1, tags2, {SERIES_INSTANCE_UID, FRAME_OF_REFERENCE_UID, IMAGE_ORIENTATION_PATIENT}); } Volumes groupByVolume(const DicomFiles &dicomFiles) @@ -135,8 +136,7 @@ Volumes groupByVolume(const DicomFiles &dicomFiles) { const auto tags = dicomFile.second; auto matchingVolume = std::find_if(volumes.begin(), volumes.end(), [&tags](const Volume &volume) - { - return isSameVolume(volume.begin()->second, tags); }); + { return isSameVolume(volume.begin()->second, tags); }); if (matchingVolume != volumes.end()) { diff --git a/packages/dicom/python/itkwasm-dicom-wasi/itkwasm_dicom_wasi/wasm_modules/image-sets-normalization.wasi.wasm b/packages/dicom/python/itkwasm-dicom-wasi/itkwasm_dicom_wasi/wasm_modules/image-sets-normalization.wasi.wasm index c52816111..c5e210089 100755 Binary files a/packages/dicom/python/itkwasm-dicom-wasi/itkwasm_dicom_wasi/wasm_modules/image-sets-normalization.wasi.wasm and b/packages/dicom/python/itkwasm-dicom-wasi/itkwasm_dicom_wasi/wasm_modules/image-sets-normalization.wasi.wasm differ