large-image-source-pil 1.30.6__tar.gz → 1.30.6.dev2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (15) hide show
  1. {large_image_source_pil-1.30.6 → large_image_source_pil-1.30.6.dev2}/PKG-INFO +4 -4
  2. {large_image_source_pil-1.30.6 → large_image_source_pil-1.30.6.dev2}/large_image_source_pil/__init__.py +2 -9
  3. {large_image_source_pil-1.30.6 → large_image_source_pil-1.30.6.dev2}/large_image_source_pil.egg-info/PKG-INFO +4 -4
  4. large_image_source_pil-1.30.6.dev2/large_image_source_pil.egg-info/requires.txt +12 -0
  5. {large_image_source_pil-1.30.6 → large_image_source_pil-1.30.6.dev2}/setup.py +3 -2
  6. large_image_source_pil-1.30.6/large_image_source_pil.egg-info/requires.txt +0 -10
  7. {large_image_source_pil-1.30.6 → large_image_source_pil-1.30.6.dev2}/LICENSE +0 -0
  8. {large_image_source_pil-1.30.6 → large_image_source_pil-1.30.6.dev2}/README.rst +0 -0
  9. {large_image_source_pil-1.30.6 → large_image_source_pil-1.30.6.dev2}/large_image_source_pil/girder_source.py +0 -0
  10. {large_image_source_pil-1.30.6 → large_image_source_pil-1.30.6.dev2}/large_image_source_pil.egg-info/SOURCES.txt +0 -0
  11. {large_image_source_pil-1.30.6 → large_image_source_pil-1.30.6.dev2}/large_image_source_pil.egg-info/dependency_links.txt +0 -0
  12. {large_image_source_pil-1.30.6 → large_image_source_pil-1.30.6.dev2}/large_image_source_pil.egg-info/entry_points.txt +0 -0
  13. {large_image_source_pil-1.30.6 → large_image_source_pil-1.30.6.dev2}/large_image_source_pil.egg-info/top_level.txt +0 -0
  14. {large_image_source_pil-1.30.6 → large_image_source_pil-1.30.6.dev2}/pyproject.toml +0 -0
  15. {large_image_source_pil-1.30.6 → large_image_source_pil-1.30.6.dev2}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: large-image-source-pil
3
- Version: 1.30.6
3
+ Version: 1.30.6.dev2
4
4
  Summary: A Pillow tilesource for large_image.
5
5
  Home-page: https://github.com/girder/large_image
6
6
  Author: Kitware, Inc.
@@ -19,14 +19,14 @@ Classifier: Programming Language :: Python :: 3.13
19
19
  Requires-Python: >=3.8
20
20
  Description-Content-Type: text/x-rst
21
21
  License-File: LICENSE
22
- Requires-Dist: large-image>=1.30.6
22
+ Requires-Dist: large-image>=1.30.6.dev2
23
23
  Provides-Extra: all
24
- Requires-Dist: rawpy; extra == "all"
24
+ Requires-Dist: rawpy; python_version < "3.13" and extra == "all"
25
25
  Requires-Dist: pillow-heif; extra == "all"
26
26
  Requires-Dist: pillow-jxl-plugin; extra == "all"
27
27
  Requires-Dist: pillow-jpls; extra == "all"
28
28
  Provides-Extra: girder
29
- Requires-Dist: girder-large-image>=1.30.6; extra == "girder"
29
+ Requires-Dist: girder-large-image>=1.30.6.dev2; extra == "girder"
30
30
 
31
31
  A Pillow tilesource for large_image.
32
32
 
@@ -19,7 +19,6 @@ import json
19
19
  import math
20
20
  import os
21
21
  import threading
22
- import warnings
23
22
 
24
23
  import numpy as np
25
24
  import PIL.Image
@@ -57,8 +56,6 @@ except PackageNotFoundError:
57
56
  # package is not installed
58
57
  pass
59
58
 
60
- warnings.filterwarnings('ignore', category=UserWarning, module='.*PIL.*')
61
-
62
59
  # Default to ignoring files with some specific extensions.
63
60
  config.ConfigValues['source_pil_ignored_names'] = \
64
61
  r'(\.mrxs|\.vsi)$'
@@ -141,7 +138,7 @@ class PILFileTileSource(FileTileSource, metaclass=LruCacheMetaclass):
141
138
  if self._pilImage is None:
142
139
  try:
143
140
  self._pilImage = PIL.Image.open(largeImagePath)
144
- except (OSError, ValueError, NotImplementedError):
141
+ except OSError:
145
142
  if not os.path.isfile(largeImagePath):
146
143
  raise TileSourceFileNotFoundError(largeImagePath) from None
147
144
  msg = 'File cannot be opened via PIL.'
@@ -178,11 +175,7 @@ class PILFileTileSource(FileTileSource, metaclass=LruCacheMetaclass):
178
175
  except Exception:
179
176
  msg = 'PIL cannot find loader for this file.'
180
177
  raise TileSourceError(msg)
181
- try:
182
- maxval = 256 ** math.ceil(math.log(float(np.max(imgdata)) + 1, 256)) - 1
183
- except Exception:
184
- msg = 'PIL cannot load this file.'
185
- raise TileSourceError(msg)
178
+ maxval = 256 ** math.ceil(math.log(float(np.max(imgdata)) + 1, 256)) - 1
186
179
  self._factor = 255.0 / max(maxval, 1)
187
180
  self._pilImage = PIL.Image.fromarray(np.uint8(np.multiply(
188
181
  imgdata, self._factor)))
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: large-image-source-pil
3
- Version: 1.30.6
3
+ Version: 1.30.6.dev2
4
4
  Summary: A Pillow tilesource for large_image.
5
5
  Home-page: https://github.com/girder/large_image
6
6
  Author: Kitware, Inc.
@@ -19,14 +19,14 @@ Classifier: Programming Language :: Python :: 3.13
19
19
  Requires-Python: >=3.8
20
20
  Description-Content-Type: text/x-rst
21
21
  License-File: LICENSE
22
- Requires-Dist: large-image>=1.30.6
22
+ Requires-Dist: large-image>=1.30.6.dev2
23
23
  Provides-Extra: all
24
- Requires-Dist: rawpy; extra == "all"
24
+ Requires-Dist: rawpy; python_version < "3.13" and extra == "all"
25
25
  Requires-Dist: pillow-heif; extra == "all"
26
26
  Requires-Dist: pillow-jxl-plugin; extra == "all"
27
27
  Requires-Dist: pillow-jpls; extra == "all"
28
28
  Provides-Extra: girder
29
- Requires-Dist: girder-large-image>=1.30.6; extra == "girder"
29
+ Requires-Dist: girder-large-image>=1.30.6.dev2; extra == "girder"
30
30
 
31
31
  A Pillow tilesource for large_image.
32
32
 
@@ -0,0 +1,12 @@
1
+ large-image>=1.30.6.dev2
2
+
3
+ [all]
4
+ pillow-heif
5
+ pillow-jxl-plugin
6
+ pillow-jpls
7
+
8
+ [all:python_version < "3.13"]
9
+ rawpy
10
+
11
+ [girder]
12
+ girder-large-image>=1.30.6.dev2
@@ -19,7 +19,8 @@ def prerelease_local_scheme(version):
19
19
 
20
20
  if os.getenv('CIRCLE_BRANCH') in ('master', ):
21
21
  return ''
22
- return get_local_node_and_date(version)
22
+ else:
23
+ return get_local_node_and_date(version)
23
24
 
24
25
 
25
26
  try:
@@ -56,7 +57,7 @@ setup(
56
57
  ],
57
58
  extras_require={
58
59
  'all': [
59
- 'rawpy',
60
+ 'rawpy ; python_version < "3.13"',
60
61
  'pillow-heif',
61
62
  'pillow-jxl-plugin',
62
63
  'pillow-jpls',
@@ -1,10 +0,0 @@
1
- large-image>=1.30.6
2
-
3
- [all]
4
- rawpy
5
- pillow-heif
6
- pillow-jxl-plugin
7
- pillow-jpls
8
-
9
- [girder]
10
- girder-large-image>=1.30.6