Skip to content

Commit

Permalink
[pre-commit.ci lite] apply automatic fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
pre-commit-ci-lite[bot] authored Feb 2, 2024
1 parent 58d5263 commit 330f7a9
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions oct_converter/readers/e2e.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
from __future__ import annotations

import time
import warnings
from collections import defaultdict
Expand All @@ -11,6 +12,7 @@
from oct_converter.image_types import FundusImageWithMetaData, OCTVolumeWithMetaData
from oct_converter.readers.binary_structs import e2e_binary


class E2E(object):
"""Class for extracting data from Heidelberg's .e2e file format.
Expand Down Expand Up @@ -148,7 +150,10 @@ def _make_lut():
windowsTicks = bscan_metadata.acquisitionTime
windowsTicksToUnixFactor = 10000000
secToUnixEpechFromWindowsTicks = 11644473600
unixtime = windowsTicks/windowsTicksToUnixFactor - secToUnixEpechFromWindowsTicks
unixtime = (
windowsTicks / windowsTicksToUnixFactor
- secToUnixEpechFromWindowsTicks
)
utc_time = time.gmtime(unixtime)
utc_time_string = time.strftime("%Y-%m-%d %H:%M:%S", utc_time)
if self.acquisition_date is None:
Expand Down Expand Up @@ -324,7 +329,7 @@ def read_fundus_image(
image_array_dict = {}
laterality_dict = {}
laterality = None

# traverse all chunks and extract slices
for start, pos in chunk_stack:
f.seek(start + self.byte_skip)
Expand Down

0 comments on commit 330f7a9

Please sign in to comment.