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

Extracting scan date #5

Closed
marksgraham opened this issue Aug 4, 2022 · 2 comments
Closed

Extracting scan date #5

marksgraham opened this issue Aug 4, 2022 · 2 comments

Comments

@marksgraham
Copy link

Hi,

Thanks for your useful repo! I'm trying to extract scan date from .e2e. I'm struggling with the interpretation of the acquisitionTime here:

bsd.acquisitionTime = mds.acquisitionTime;

does this value contain date as well as time information? I'm struggling to see how the values I extract (e.g. 130129068663440000) can be related to a recognisable date and time.

Another option is to extract the study date from here:

StreamHelper::readFStream(stream, &windowsStudyDate);

but once again I'm struggling to relate the values I extract to a recognisable date.

Thanks in advance for any help.
Mark

@kaygdev
Copy link
Contributor

kaygdev commented Aug 16, 2022

Hi Mark,

thank you for you feedback. The acquisitionTime is encoded in windows ticks (int64). It is converted in
https://github.com/neurodial/LibOctData/blob/6a6f667e8c9c740867c8eaa76b10e31845dccd38/octdata/import/he_e2e/he_e2eread.cpp#L388

The studyDate use the windows time format (double), it is converted in
https://github.com/neurodial/LibOctData/blob/6a6f667e8c9c740867c8eaa76b10e31845dccd38/octdata/import/he_e2e/he_e2eread.cpp#L102

You can find the converting code in https://github.com/neurodial/LibOctData/blob/master/octdata/datastruct/date.cpp

For explaination, the LibE2E is like a frontend for LibOctData. It reads the E2E file and fills a structure that is close to the E2E format. In the LibOctData this structure is then evaluated and converted into a uniform format. The other programs then build on this (convert_oct_data, octdata4matlab, octdata4python, OCT-Marker).

Best
Kay

@marksgraham
Copy link
Author

Thanks for this - really helpful!

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

No branches or pull requests

2 participants