Skip to content

Commit

Permalink
Merge pull request #1734 from girder/fix-uint8-scale
Browse files Browse the repository at this point in the history
Fix a bug handling pure uint8 data introduced in #1725
  • Loading branch information
manthey authored Dec 3, 2024
2 parents 5872fdd + b1940e5 commit d20a338
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Change Log

## 1.30.4

### Bug Fixes

- Fix a bug handling pure uint8 data introduced in #1725 ([#1734](../../pull/1734))

## 1.30.3

### Improvements
Expand Down
2 changes: 1 addition & 1 deletion large_image/tilesource/tiledict.py
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ def _resample(self, tileData: Union[ImageBytes, PIL.Image.Image, bytes, np.ndarr
if self.resample in (False, None) or not self.requestedScale:
return tileData, pilData
pilResize = True
if (isinstance(tileData, np.ndarray) and tileData.dtype.kind != np.uint8 and
if (isinstance(tileData, np.ndarray) and tileData.dtype != np.uint8 and
TILE_FORMAT_NUMPY in self.format and self.resample in {True, 2, 3}):
try:
import skimage.transform
Expand Down

0 comments on commit d20a338

Please sign in to comment.