dicube 0.2.0__cp38-cp38-win_amd64.whl → 0.2.2__cp38-cp38-win_amd64.whl

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.
dicube/core/io.py CHANGED
@@ -239,6 +239,12 @@ class DicomCubeImageIO:
239
239
  intercept = meta.get_shared_value(CommonTags.RescaleIntercept)
240
240
  wind_center = meta.get_shared_value(CommonTags.WindowCenter)
241
241
  wind_width = meta.get_shared_value(CommonTags.WindowWidth)
242
+ try:
243
+ wind_center = float(wind_center)
244
+ wind_width = float(wind_width)
245
+ except:
246
+ wind_center = None
247
+ wind_width = None
242
248
 
243
249
  # Create pixel_header
244
250
  pixel_header = PixelDataHeader(
@@ -246,8 +252,8 @@ class DicomCubeImageIO:
246
252
  RescaleIntercept=float(intercept) if intercept is not None else 0.0,
247
253
  OriginalPixelDtype=str(images[0].dtype),
248
254
  PixelDtype=str(images[0].dtype),
249
- WindowCenter=float(wind_center) if wind_center is not None else None,
250
- WindowWidth=float(wind_width) if wind_width is not None else None,
255
+ WindowCenter=wind_center,
256
+ WindowWidth=wind_width,
251
257
  )
252
258
 
253
259
  # Validate PixelDataHeader initialization success
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.2
2
2
  Name: dicube
3
- Version: 0.2.0
3
+ Version: 0.2.2
4
4
  Summary: Medical Image Storage Library with DICOM compatibility
5
5
  Author: Fangzhou Liao
6
6
  License: MIT
@@ -38,6 +38,7 @@ Requires-Dist: mypy>=1.0.0; extra == "dev"
38
38
  Requires-Dist: build>=0.8.0; extra == "dev"
39
39
  Requires-Dist: pylibjpeg>=2.0; extra == "dev"
40
40
  Requires-Dist: pylibjpeg-openjpeg>=2.0; extra == "dev"
41
+ Requires-Dist: nibabel>=3.2.0; extra == "dev"
41
42
  Provides-Extra: all
42
43
  Requires-Dist: pybind11>=2.10.0; extra == "all"
43
44
  Requires-Dist: nibabel>=3.2.0; extra == "all"
@@ -2,13 +2,11 @@ dicube/__init__.py,sha256=XI_Zeif8FOQ-i_G7LabwVFpubzDniXSFb-8H_WdYW8c,5059
2
2
  dicube/codecs/__init__.py,sha256=Tqw2vmQML-pcaNtnyTtj4W4kBqGhV2FTiVAT5bW5FgA,3905
3
3
  dicube/codecs/jph/__init__.py,sha256=pWYkTNWYeGZx3khsJBAKRdB2Vgyr0BX5aLDKaanfe_o,407
4
4
  dicube/codecs/jph/codec.py,sha256=BMZM3ReemQheraSIYn19aqH-1NrbjQTPAx3iCTms7KU,5620
5
- dicube/codecs/jph/ojph_complete.cp38-win32.pyd,sha256=Y3Nterl5act9QSkyfny-K0u6OkJnDg6KVMob14XdzQs,507904
6
- dicube/codecs/jph/ojph_complete.cp38-win_amd64.pyd,sha256=vjlAPdq-rTif10Ya8hRuj1KUrlU7djCMrwz3i1Z9egY,601600
7
- dicube/codecs/jph/ojph_decode_complete.cp38-win32.pyd,sha256=Drd29pmHMr6xKAEOYHbxIOzvvKi7HwUqphVFkBDUDcY,543232
8
- dicube/codecs/jph/ojph_decode_complete.cp38-win_amd64.pyd,sha256=KxoPWOvvtfNJD0mhiTLL6rjiGHRDS5tNTLz3gygYEiY,639488
5
+ dicube/codecs/jph/ojph_complete.cp38-win_amd64.pyd,sha256=5A8LW4oiuxFKTgM8g5QXcgFA1Jp8gT0-5Ag2n3JIWWw,601600
6
+ dicube/codecs/jph/ojph_decode_complete.cp38-win_amd64.pyd,sha256=ZsXsgMf-j47XI4gk0XiiyeLdLddvwM_PyYUjrqbrXj0,639488
9
7
  dicube/core/__init__.py,sha256=TJBS1xA2qVS7xxH6vZKPrd7YiQYtyLfNSs48tlmBCD8,676
10
8
  dicube/core/image.py,sha256=WR9GKat0st0ior7zw1wi_5Bpd5cZoHWvsPzjYJAwpcg,14525
11
- dicube/core/io.py,sha256=kMGiT20Gmkb55tFXxIDiU6RS3owHkqF7xk4IVq78eNU,15915
9
+ dicube/core/io.py,sha256=htVflYmSgB--2CSKftfEfNLEtIJ7Jrg02A1MveW3Xs8,16036
12
10
  dicube/core/pixel_header.py,sha256=gikXfkjTGVQUqTWUk8Q2xAPsDfWm0iRPcwdIxIImr94,4124
13
11
  dicube/dicom/__init__.py,sha256=OGnAHS3pCbb94Vpsc0x3d2gjv5UBAM9oUR3mxQVruYQ,383
14
12
  dicube/dicom/dcb_streaming.py,sha256=6b50m5SEHFkdkWYKl6_ClzvPZZJKlJlVNR08sWF-Xdo,9335
@@ -24,6 +22,6 @@ dicube/storage/dcb_file.py,sha256=tt7aYi4x_gxf4s6De6tSkpiwyoCp1ZcG-Piixai1Jw8,32
24
22
  dicube/storage/pixel_utils.py,sha256=_KrsMoKHsgGc9QFSkmpx5YlDNcTOYPkCSu-zGt3WS7k,10017
25
23
  dicube/utils/__init__.py,sha256=r4wAqNWphzYWaeYN9fcoFCX7mTcOtNACzZ4O-dDCQ10,154
26
24
  dicube/validation.py,sha256=aFu2lKW9NDl13eKedYhOjw1g50uOf_x0wx3y3g9cLsA,12857
27
- dicube-0.2.0.dist-info/METADATA,sha256=xDYbYiX9NKyLH0bAbBNOsziAxvXHyyQyELP8RlGA5ys,10581
28
- dicube-0.2.0.dist-info/WHEEL,sha256=AmELy_2Xx7O_V7LBv-s-ztFbR13e4jkKGwV7sVzppgU,104
29
- dicube-0.2.0.dist-info/RECORD,,
25
+ dicube-0.2.2.dist-info/METADATA,sha256=nBhXpfkqIUhGO2LUB-HmTwmDIolxcvd-cr8tW4CJNzM,10627
26
+ dicube-0.2.2.dist-info/WHEEL,sha256=AmELy_2Xx7O_V7LBv-s-ztFbR13e4jkKGwV7sVzppgU,104
27
+ dicube-0.2.2.dist-info/RECORD,,
File without changes