Skip to content

Commit

Permalink
Reverted TiffSource: legacy support providing executer for nested mul…
Browse files Browse the repository at this point in the history
…ti-threading
  • Loading branch information
folterj committed Mar 4, 2024
1 parent 86cb13b commit 8259aeb
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion OmeSliCC/OmeSource.py
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ def render(self, image: np.ndarray, source_dimension_order: str, t: int = 0, z:
tot_alpha = 0
n = len(self.channels)

is_rgb = (self.get_nchannels() == 3 and (n <= 1 or n == 3))
is_rgb = (self.get_nchannels() in (3, 4) and (n <= 1 or n == 3))
do_normalisation = (image.dtype.itemsize == 2)

if not is_rgb:
Expand Down
5 changes: 3 additions & 2 deletions OmeSliCC/TiffSource.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,12 +34,13 @@ def __init__(self,
filename: str,
source_pixel_size: list = None,
target_pixel_size: list = None,
source_info_required: bool = False):
source_info_required: bool = False,
executor: ThreadPoolExecutor = None):

super().__init__()
self.compressed = False
self.decompressed = False
self.executor = None
self.executor = executor
self.data = bytes()
self.arrays = []

Expand Down

0 comments on commit 8259aeb

Please sign in to comment.