Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

E2E file read changes #151

Merged
merged 2 commits into from
Feb 18, 2025
Merged

E2E file read changes #151

merged 2 commits into from
Feb 18, 2025

Conversation

sustrev
Copy link
Contributor

@sustrev sustrev commented Feb 13, 2025

I encountered a few new E2E files that were more thoroughly anonymized by Heidelberg's software and made a few changes so that these files could be read through. This includes adding a try/except for e2e_binary.chunk_structure.parse(raw) and better handling of now potentially missing patient metadata.

For context, the errors that were observed were mostly

Error in path (parsing) -> magic3
stream read less than specified amount, expected 12, found 0

with raw being b''(which could be handled more specifically by looking at len(raw) before parsing, if that's preferred)
and a few instances of
'ascii' codec can't decode byte 0xc7 in position 0: ordinal not in range(128) with raw as b'\xc7\xd7\xbe\x00\x00\x00\x003\xc4\x00\x00\x00\x00\xbf\xbd\xad\xc1\x00\x00}\xc4\x00\x00\x00\x00\x00\x00\x9f\xc5\x8d\xc6\xac\xc1\x00\x00%\xc4\xba\xc0\r\xc3\x00\x00\x00\x00\x00\x00\xd7\xc4\x83\xc1\x00\x00\x06\xb1?\xc3)\xc4\x00' (again, might be a more graceful way of handling this, but for now skipping is simpler and from the files I've tested on still output as expected).

(I'd been hoping to get my hands on some of these new-anonymization files!)

Susannah Trevino and others added 2 commits February 13, 2025 13:53
Copy link
Owner

@marksgraham marksgraham left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this!

@marksgraham marksgraham merged commit ee6381f into marksgraham:main Feb 18, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants