Bug 212 - Anonymization process transcodes data and loses resource link
Summary: Anonymization process transcodes data and loses resource link
Status: RESOLVED FIXED
Alias: None
Product: Orthanc
Classification: Unclassified
Component: Orthanc Core (show other bugs)
Version: unspecified
Hardware: PC Linux
: --- normal
Assignee: Alain Mazy
URL:
Depends on:
Blocks:
 
Reported: 2022-10-20 10:50 CEST by guillem.vela@xeos.care
Modified: 2023-01-27 12:58 CET (History)
2 users (show)

See Also:


Attachments
Uncompressed DICOM image (Transfer Syntax 1.2.840.10008.1.2.1) (3.34 MB, application/dicom)
2022-10-20 10:50 CEST, guillem.vela@xeos.care
Details

Note You need to log in before you can comment on or make changes to this bug.
Description guillem.vela@xeos.care 2022-10-20 10:50:16 CEST
Created attachment 123 [details]
Uncompressed DICOM image (Transfer Syntax 1.2.840.10008.1.2.1)

Please carefully read the following page before asking support:
https://book.orthanc-server.com/users/support.html

Also, make sure you have read the FAQ, especially the 'Troubleshooting' and 'Troubleshooting DICOM communications' sections:
https://book.orthanc-server.com/faq.html

**What steps will reproduce the problem?**

1. Set "IngestTranscoding" to JPEG Lossless compression ("1.2.840.10008.1.2.4.70") in Orthanc configuration

2. Instantiate Orthanc with a database that contains a non-compressed study

3. Anonymize that study through Orthanc Explorer or the REST API

4. Observe how the anonymized study has its transfer syntax changed to JPEG Lossless compression. Its link to the non-anonymized study is lost (not reported via REST API or Orthanc Explorer)

**What is the expected output? What do you see instead?**

The link to the non-anonymized study is reported through "AnonymizedFrom" in REST API for the anonymized study when /studies is called with option extend=true.

The button "Before Anonymization" is shown in Orthanc Explorer when visualized.

It is instead treated and reported as if it had not been anonymized in this instance of Orthanc.

**What version of the product are you using? On what operating system?**

Ubuntu 22.04, Orthanc 1.11.0

**Please provide sample, possibly anonymized, DICOM files**

Providing an uncompressed DICOM image (Transfer Syntax 1.2.840.10008.1.2.1).
"IngestTranscoding" to be set to "1.2.840.10008.1.2.4.70" in order to reproduce.
Comment 1 Alain Mazy 2023-01-27 12:58:33 CET
This has been fixed in this commit: https://hg.orthanc-server.com/orthanc/rev/19ccae2e0371

Note however that the transcoding of the image using the IngestTranscoding configuration is considered as a feature.  

If you wish to avoid it, you can still force the 'Transcode' option in /modify or /anonymize.  This will work only after this commit: https://hg.orthanc-server.com/orthanc/rev/2df546a76e17