Recently I encountered a problem when reading DICOM files using DCMTK 3.6.4. The following is the detailed log information.
W: Found element (2001,105f) with VR UN and undefined length, reading a sequence with transfer syntax LittleEndianImplicit (CP-246)
W: DcmItem: Length of element (2001,0010) is odd
W: DcmItem: Element PrivateCreator (2001,0010) larger (20053) than remaining bytes (468) of surrounding item
Could anyone solve this problem?
Thanks in advance.
Error: length of element larger than explicit length of surrounding item
Moderator: Moderator Team
-
- DCMTK Developer
- Posts: 2051
- Joined: Fri, 2004-11-05, 13:47
- Location: Oldenburg, Germany
- Contact:
Re: Error when reading DICOM files
Hi,
the file seems to be broken. You can try to see whether a common workaround can be applied.
Also, to force the parser to continue, sometimes it is able to recover. Additionally, option -d could provide more information (but I don't expect it here to help).
Best regards,
Michael
the file seems to be broken. You can try
Code: Select all
dcmdump --disable-cp246 <file>
Also,
Code: Select all
dcmdump +E +Ep <file>
Best regards,
Michael
Re: Error: length of element larger than explicit length of surrounding item
Thanks for your reply. It seems that the code you provided is used in the command line, but how can I fix this problem in C++ code?
Best regards,
Jisu Hu
Best regards,
Jisu Hu
-
- DCMTK Developer
- Posts: 2051
- Joined: Fri, 2004-11-05, 13:47
- Location: Oldenburg, Germany
- Contact:
Re: Error: length of element larger than explicit length of surrounding item
Try helping yourself: Look into dcmdump.cc how these command line options are provided to the parser when loading a file for dumping
I would do the same.
BR Michael
I would do the same.
BR Michael
Who is online
Users browsing this forum: Ahrefs [Bot], Google [Bot] and 1 guest