Closed GoogleCodeExporter closed 9 years ago
I'm not sure where to go with this ... hard to figure out without some more
information. Since it goes away when rewritten (by matlab or by anonymizing)
there must be something different about the way the file is originally stored.
Could you perhaps use pydicom's hex dump or turn on pydicom's debug mode, both
explained on the Troubleshooting wiki page [1], and then capture part of the
text around the start of the private data section, and "anonymize" by simply
replacing values -- both hex bytes and text -- that include confidential
information, with 00's (bytes) or "-" (text). That would show the structure of
how the information is stored without exposing any confidential info. And I
might be able to create from that a file which could reproduce the failure. If
you want you could send directly to me (my full name, no punctuation, at
gmail.com).
Thanks
Darcy
[1] http://code.google.com/p/pydicom/wiki/Troubleshooting
Original comment by darcymason@gmail.com
on 1 Sep 2010 at 12:41
I debugged this issue and found that the calls keep going back and forth
between __getitem__ and __setitem__ for setting the private creator code. The
code goes into infinite recursion once the private_block becomes 0 (line 484
above)
For the tag (0x09,0x10e0) for e.g. code goes to set (0x09,0x10) and in the next
loop goes to (0x09,0x00) and then keeps looping with this tag.
A simple return after a check if private_block == 0 seems to fix this issue.
May be there is a better fix.
I tried modifying existing test files to reproduce the problem but have not
succeeded. I think any data set with private attributes (including creator code
and group lengths for the private group) should help to reproduce the issue.
Original comment by med.diag...@gmail.com
on 7 Sep 2010 at 12:21
After revisiting this I'm thinking it is likely the same problem that was fixed
in revision f54d9aa6b3. When I first checked it I somehow convinced myself it
wasn't, but looking again the fix for the if statement in dataset.py -- "and
tag != private_creator_tag:" does not appear in the error trace (at line 486)
copied above.
Would you be able to update to that revision (or later) and check if that
solves your problem? Alternatively, you could just add the the extra
conditional just quoted and see if that works.
Original comment by darcymason@gmail.com
on 9 Sep 2010 at 1:08
Closing issue as resolved. As in previous comment, I believe the issue was
resolved in revision f54d9aa6b3.
Original comment by darcymason@gmail.com
on 18 Dec 2011 at 4:42
Original issue reported on code.google.com by
bob94...@gmail.com
on 27 Aug 2010 at 7:04