Hi Team,
I'm trying to encapsulate zip, txt, or json file, etc into DICOM file via private attribute, for example. No similar topics have been found in this channel yet.
Any suggestion?
Thanks,
Jingkun
Encapsulate ZIP file in DICOM file
Moderator: Moderator Team
-
- DCMTK Developer
- Posts: 2055
- Joined: Fri, 2004-11-05, 13:47
- Location: Oldenburg, Germany
- Contact:
Re: Encapsulate ZIP file in DICOM file
Hi Jingkun,
some general info how to insert private data can be found in our Howtos: https://support.dcmtk.org/redmine/proje ... rivateData
Best regards,
Michael
some general info how to insert private data can be found in our Howtos: https://support.dcmtk.org/redmine/proje ... rivateData
Best regards,
Michael
-
- Posts: 7
- Joined: Wed, 2023-02-08, 18:18
Re: Encapsulate ZIP file in DICOM file
Hi Michael,
Adding private attribute won't be able to encapsulate files into DICOM object as far as I know.
I should make my question more specific. There are three IODs of Encapsulating documents defined in DICOM standard. DCMTK also implemented DcmEncapsulatedDocument which allows encapsulating PDF file in DICOM. Is it possible to encapsulate ZIP TXT or JSON using DcmEncapsulatedDocument? Any other suggestions?
Thanks,
Jingkun
Adding private attribute won't be able to encapsulate files into DICOM object as far as I know.
I should make my question more specific. There are three IODs of Encapsulating documents defined in DICOM standard. DCMTK also implemented DcmEncapsulatedDocument which allows encapsulating PDF file in DICOM. Is it possible to encapsulate ZIP TXT or JSON using DcmEncapsulatedDocument? Any other suggestions?
Thanks,
Jingkun
-
- DCMTK Developer
- Posts: 2517
- Joined: Tue, 2011-05-03, 14:38
- Location: Oldenburg, Germany
- Contact:
Re: Encapsulate ZIP file in DICOM file
No, the DcmEncapsulatedDocument does not support this, as the DICOM standard does not support this. Encapsulating ZIP, TXT or JSON files, would be a private extension and should be encoded appropriately, e.g. by using private attributes in a standard Storage SOP Class or by using a private SOP Class.
However, I personally would not recommend to encapsulate these types of data. Text files could be converted to PDF or encoded as DICOM SR (Structured Report). JSON files will probably also contain structured data, so they should be encoded as DICOM SR. Regarding ZIP files, I don't know what their contents is.
Bottom line: we don't know your use case, but storing private data in a standardized encapsulation format only makes sense in very rare cases. It always means that probably only the creator can actually read (and interpret) the stored data, which contradicts the purpose of a vendor-independent standard like DICOM.
However, I personally would not recommend to encapsulate these types of data. Text files could be converted to PDF or encoded as DICOM SR (Structured Report). JSON files will probably also contain structured data, so they should be encoded as DICOM SR. Regarding ZIP files, I don't know what their contents is.
Bottom line: we don't know your use case, but storing private data in a standardized encapsulation format only makes sense in very rare cases. It always means that probably only the creator can actually read (and interpret) the stored data, which contradicts the purpose of a vendor-independent standard like DICOM.
Last edited by J. Riesmeier on Tue, 2023-05-09, 09:16, edited 2 times in total.
-
- DCMTK Developer
- Posts: 2055
- Joined: Fri, 2004-11-05, 13:47
- Location: Oldenburg, Germany
- Contact:
Re: Encapsulate ZIP file in DICOM file
Hi,
no, there is no specific IOD for this task. In DICOM there is so far: Encapsulated PDF, Enc. CDA, Enc. STL, Enc. OBJ and Enc. MTL. The only way to encapsulate a ZIP file would be private data, and/or using the Raw Data IOD.
Best regards,
Michael
no, there is no specific IOD for this task. In DICOM there is so far: Encapsulated PDF, Enc. CDA, Enc. STL, Enc. OBJ and Enc. MTL. The only way to encapsulate a ZIP file would be private data, and/or using the Raw Data IOD.
Best regards,
Michael
-
- Posts: 7
- Joined: Wed, 2023-02-08, 18:18
Re: Encapsulate ZIP file in DICOM file
Hi Michael and Riesmeier,
Thank you very much for your responses. Using DICOM SR IOD might be a reasonable approach to embed Json files.
Regard,
Jingkun
Thank you very much for your responses. Using DICOM SR IOD might be a reasonable approach to embed Json files.
Regard,
Jingkun
Who is online
Users browsing this forum: Google [Bot] and 1 guest