Skip to content

Commit

Permalink
Prefer imagecodecs
Browse files Browse the repository at this point in the history
  • Loading branch information
erikogabrielsson committed Nov 21, 2024
1 parent a0ca84f commit 7581685
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion wsidicom/codec/decoder.py
Original file line number Diff line number Diff line change
Expand Up @@ -198,8 +198,8 @@ def select_decoder(
# Pillow only supports 8 bit color images
return None
decoders: Dict[str, Type[Decoder]] = {
"pillow": PillowDecoder,
"imagecodecs": ImageCodecsDecoder,
"pillow": PillowDecoder,
"pylibjpeg_rle": PylibjpegRleDecoder,
"imagecodecs_rle": ImageCodecsRleDecoder,
"pylibjpeg_ls": PyJpegLsDecoder,
Expand Down
2 changes: 1 addition & 1 deletion wsidicom/wsidicom.py
Original file line number Diff line number Diff line change
Expand Up @@ -538,7 +538,7 @@ def read_thumbnail(
level = self.pyramids.get(pyramid).get_closest_by_size(thumbnail_size)
region = Region(position=Point(0, 0), size=level.size)
image = level.get_region(region, z, path)
image.thumbnail((size), resample=settings.pillow_resampling_filter)
image.thumbnail(size, resample=settings.pillow_resampling_filter)
return image

def read_region(
Expand Down

0 comments on commit 7581685

Please sign in to comment.