dcccpy 0.1.2__tar.gz → 0.1.3__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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: dcccpy
3
- Version: 0.1.2
3
+ Version: 0.1.3
4
4
  Summary: Python wrapper for the DCCCcore PET biomarker command-line tool
5
5
  Author: DCCCSlicer contributors
6
6
  License-Expression: CC-BY-NC-ND-4.0
@@ -17,7 +17,12 @@ Requires-Python: >=3.9
17
17
  Description-Content-Type: text/markdown
18
18
  Requires-Dist: nibabel>=5
19
19
  Provides-Extra: linux-runtime
20
- Requires-Dist: dcccpy-linux-runtime==0.1.0; extra == "linux-runtime"
20
+ Requires-Dist: dcccpy-linux-runtime==0.1.0; (sys_platform == "linux" and platform_machine == "x86_64") and extra == "linux-runtime"
21
+ Provides-Extra: windows-runtime
22
+ Requires-Dist: dcccpy-windows-runtime==0.1.0; (sys_platform == "win32" and platform_machine == "AMD64") and extra == "windows-runtime"
23
+ Provides-Extra: runtime
24
+ Requires-Dist: dcccpy-linux-runtime==0.1.0; (sys_platform == "linux" and platform_machine == "x86_64") and extra == "runtime"
25
+ Requires-Dist: dcccpy-windows-runtime==0.1.0; (sys_platform == "win32" and platform_machine == "AMD64") and extra == "runtime"
21
26
 
22
27
  # dcccpy
23
28
 
@@ -37,13 +42,27 @@ The first call downloads the matching `DCCCcore` release package into the local
37
42
  user cache if no native runtime is otherwise available. The slim package also
38
43
  installs `nibabel` for image loading and nibabel-style image inputs.
39
44
 
40
- For Linux users who prefer `pip install` to include the native runtime and avoid
41
- first-run download:
45
+ The downloaded GitHub release is the full `DCCCcore` runtime. The optional PyPI
46
+ runtime wheels are smaller and omit the `fast_and_acc` registration model/config
47
+ and ADAD decoupler ONNX ensemble.
48
+
49
+ Users who prefer `pip install` to include the native runtime and avoid first-run
50
+ download can use the platform-selecting runtime extra:
51
+
52
+ ```bash
53
+ pip install "dcccpy[runtime]"
54
+ ```
55
+
56
+ Platform-specific runtime extras are also available:
42
57
 
43
58
  ```bash
44
59
  pip install "dcccpy[linux-runtime]"
60
+ pip install "dcccpy[windows-runtime]"
45
61
  ```
46
62
 
63
+ The platform-specific extras are guarded by environment markers, so they only
64
+ install a runtime wheel on the matching platform.
65
+
47
66
  ## Python API
48
67
 
49
68
  ```python
@@ -109,7 +128,8 @@ At runtime, `dcccpy` looks for `DCCCcore` in this order:
109
128
 
110
129
  1. `DCCCPY_DCCCCORE` environment variable.
111
130
  2. A vendored binary inside the installed `dcccpy` wheel.
112
- 3. A binary from `dcccpy-linux-runtime`, installed by `dcccpy[linux-runtime]`.
131
+ 3. A binary from `dcccpy-linux-runtime` or `dcccpy-windows-runtime`, installed by
132
+ `dcccpy[runtime]` or the platform-specific runtime extras.
113
133
  4. The local dcccpy cache populated by automatic download.
114
134
  5. `DCCCcore` on `PATH`.
115
135
  6. Automatic download from GitHub releases, unless disabled.
@@ -138,15 +158,16 @@ The preferred distribution layout is:
138
158
 
139
159
  - `dcccpy`: slim Python package with nibabel; downloads runtime on first use.
140
160
  - `dcccpy-linux-runtime`: optional Linux runtime wheel.
141
- - `dcccpy[linux-runtime]`: installs both packages.
161
+ - `dcccpy-windows-runtime`: optional Windows runtime wheel.
162
+ - `dcccpy[runtime]`: installs the matching runtime package on supported platforms.
142
163
 
143
164
  ## Packaging note
144
165
 
145
- The Linux `DCCCcore-4.2.3-ubuntu-latest-x64.zip` release asset contains the
146
- native executable, `libtbb`, ONNX registration/decoupling models, configuration
147
- files, and NIfTI template/mask assets. That full runtime is the correct unit to
148
- vendor for a wheel that works immediately after `pip install dcccpy`.
166
+ The runtime wheels use a PyPI-size profile for version 4.2.3. They omit the
167
+ `fast_and_acc` registration model/config and the ADAD decoupler ONNX ensemble,
168
+ while keeping the default spatial normalization model and assets needed by
169
+ common Centiloid/CenTauR/CenTauRz workflows.
149
170
 
150
- The full Linux runtime wheel is about 167 MB for version 4.2.3, so a public
151
- PyPI upload may require a file size limit increase unless a future release
152
- splits a smaller runtime profile from the full `DCCCcore` package.
171
+ The plain `dcccpy` package remains slim and downloads the full matching
172
+ `DCCCcore` release package from GitHub on first use when no installed runtime is
173
+ available.
@@ -16,13 +16,27 @@ The first call downloads the matching `DCCCcore` release package into the local
16
16
  user cache if no native runtime is otherwise available. The slim package also
17
17
  installs `nibabel` for image loading and nibabel-style image inputs.
18
18
 
19
- For Linux users who prefer `pip install` to include the native runtime and avoid
20
- first-run download:
19
+ The downloaded GitHub release is the full `DCCCcore` runtime. The optional PyPI
20
+ runtime wheels are smaller and omit the `fast_and_acc` registration model/config
21
+ and ADAD decoupler ONNX ensemble.
22
+
23
+ Users who prefer `pip install` to include the native runtime and avoid first-run
24
+ download can use the platform-selecting runtime extra:
25
+
26
+ ```bash
27
+ pip install "dcccpy[runtime]"
28
+ ```
29
+
30
+ Platform-specific runtime extras are also available:
21
31
 
22
32
  ```bash
23
33
  pip install "dcccpy[linux-runtime]"
34
+ pip install "dcccpy[windows-runtime]"
24
35
  ```
25
36
 
37
+ The platform-specific extras are guarded by environment markers, so they only
38
+ install a runtime wheel on the matching platform.
39
+
26
40
  ## Python API
27
41
 
28
42
  ```python
@@ -88,7 +102,8 @@ At runtime, `dcccpy` looks for `DCCCcore` in this order:
88
102
 
89
103
  1. `DCCCPY_DCCCCORE` environment variable.
90
104
  2. A vendored binary inside the installed `dcccpy` wheel.
91
- 3. A binary from `dcccpy-linux-runtime`, installed by `dcccpy[linux-runtime]`.
105
+ 3. A binary from `dcccpy-linux-runtime` or `dcccpy-windows-runtime`, installed by
106
+ `dcccpy[runtime]` or the platform-specific runtime extras.
92
107
  4. The local dcccpy cache populated by automatic download.
93
108
  5. `DCCCcore` on `PATH`.
94
109
  6. Automatic download from GitHub releases, unless disabled.
@@ -117,15 +132,16 @@ The preferred distribution layout is:
117
132
 
118
133
  - `dcccpy`: slim Python package with nibabel; downloads runtime on first use.
119
134
  - `dcccpy-linux-runtime`: optional Linux runtime wheel.
120
- - `dcccpy[linux-runtime]`: installs both packages.
135
+ - `dcccpy-windows-runtime`: optional Windows runtime wheel.
136
+ - `dcccpy[runtime]`: installs the matching runtime package on supported platforms.
121
137
 
122
138
  ## Packaging note
123
139
 
124
- The Linux `DCCCcore-4.2.3-ubuntu-latest-x64.zip` release asset contains the
125
- native executable, `libtbb`, ONNX registration/decoupling models, configuration
126
- files, and NIfTI template/mask assets. That full runtime is the correct unit to
127
- vendor for a wheel that works immediately after `pip install dcccpy`.
140
+ The runtime wheels use a PyPI-size profile for version 4.2.3. They omit the
141
+ `fast_and_acc` registration model/config and the ADAD decoupler ONNX ensemble,
142
+ while keeping the default spatial normalization model and assets needed by
143
+ common Centiloid/CenTauR/CenTauRz workflows.
128
144
 
129
- The full Linux runtime wheel is about 167 MB for version 4.2.3, so a public
130
- PyPI upload may require a file size limit increase unless a future release
131
- splits a smaller runtime profile from the full `DCCCcore` package.
145
+ The plain `dcccpy` package remains slim and downloads the full matching
146
+ `DCCCcore` release package from GitHub on first use when no installed runtime is
147
+ available.
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "dcccpy"
7
- version = "0.1.2"
7
+ version = "0.1.3"
8
8
  description = "Python wrapper for the DCCCcore PET biomarker command-line tool"
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.9"
@@ -30,7 +30,12 @@ Repository = "https://github.com/tctco/DCCCSlicer"
30
30
  Issues = "https://github.com/tctco/DCCCSlicer/issues"
31
31
 
32
32
  [project.optional-dependencies]
33
- linux-runtime = ["dcccpy-linux-runtime==0.1.0"]
33
+ linux-runtime = ["dcccpy-linux-runtime==0.1.0; sys_platform == 'linux' and platform_machine == 'x86_64'"]
34
+ windows-runtime = ["dcccpy-windows-runtime==0.1.0; sys_platform == 'win32' and platform_machine == 'AMD64'"]
35
+ runtime = [
36
+ "dcccpy-linux-runtime==0.1.0; sys_platform == 'linux' and platform_machine == 'x86_64'",
37
+ "dcccpy-windows-runtime==0.1.0; sys_platform == 'win32' and platform_machine == 'AMD64'",
38
+ ]
34
39
 
35
40
  [project.scripts]
36
41
  dcccpy = "dcccpy.cli:main"
@@ -99,13 +99,22 @@ def _main_package_vendor_dirs() -> list[Path]:
99
99
 
100
100
 
101
101
  def _runtime_package_dirs() -> list[Path]:
102
+ roots: list[Path] = []
102
103
  try:
103
104
  import dcccpy_linux_runtime
104
105
  except Exception:
105
- return []
106
+ pass
107
+ else:
108
+ roots.append(Path(dcccpy_linux_runtime.dccccore_root()))
109
+
110
+ try:
111
+ import dcccpy_windows_runtime
112
+ except Exception:
113
+ pass
114
+ else:
115
+ roots.append(Path(dcccpy_windows_runtime.dccccore_root()))
106
116
 
107
- root = dcccpy_linux_runtime.dccccore_root()
108
- return [Path(root)]
117
+ return roots
109
118
 
110
119
 
111
120
  def _cached_dirs(version: str = DCCCCORE_VERSION) -> list[Path]:
@@ -232,6 +241,6 @@ def dccccore_path(
232
241
  return download_dccccore(version=version)
233
242
 
234
243
  raise DCCCcoreNotFoundError(
235
- "Could not find DCCCcore. Install dcccpy[linux-runtime], set DCCCPY_DCCCCORE, "
244
+ "Could not find DCCCcore. Install dcccpy[runtime], set DCCCPY_DCCCCORE, "
236
245
  "put DCCCcore on PATH, or enable automatic download with DCCCPY_AUTO_DOWNLOAD=1."
237
246
  )
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: dcccpy
3
- Version: 0.1.2
3
+ Version: 0.1.3
4
4
  Summary: Python wrapper for the DCCCcore PET biomarker command-line tool
5
5
  Author: DCCCSlicer contributors
6
6
  License-Expression: CC-BY-NC-ND-4.0
@@ -17,7 +17,12 @@ Requires-Python: >=3.9
17
17
  Description-Content-Type: text/markdown
18
18
  Requires-Dist: nibabel>=5
19
19
  Provides-Extra: linux-runtime
20
- Requires-Dist: dcccpy-linux-runtime==0.1.0; extra == "linux-runtime"
20
+ Requires-Dist: dcccpy-linux-runtime==0.1.0; (sys_platform == "linux" and platform_machine == "x86_64") and extra == "linux-runtime"
21
+ Provides-Extra: windows-runtime
22
+ Requires-Dist: dcccpy-windows-runtime==0.1.0; (sys_platform == "win32" and platform_machine == "AMD64") and extra == "windows-runtime"
23
+ Provides-Extra: runtime
24
+ Requires-Dist: dcccpy-linux-runtime==0.1.0; (sys_platform == "linux" and platform_machine == "x86_64") and extra == "runtime"
25
+ Requires-Dist: dcccpy-windows-runtime==0.1.0; (sys_platform == "win32" and platform_machine == "AMD64") and extra == "runtime"
21
26
 
22
27
  # dcccpy
23
28
 
@@ -37,13 +42,27 @@ The first call downloads the matching `DCCCcore` release package into the local
37
42
  user cache if no native runtime is otherwise available. The slim package also
38
43
  installs `nibabel` for image loading and nibabel-style image inputs.
39
44
 
40
- For Linux users who prefer `pip install` to include the native runtime and avoid
41
- first-run download:
45
+ The downloaded GitHub release is the full `DCCCcore` runtime. The optional PyPI
46
+ runtime wheels are smaller and omit the `fast_and_acc` registration model/config
47
+ and ADAD decoupler ONNX ensemble.
48
+
49
+ Users who prefer `pip install` to include the native runtime and avoid first-run
50
+ download can use the platform-selecting runtime extra:
51
+
52
+ ```bash
53
+ pip install "dcccpy[runtime]"
54
+ ```
55
+
56
+ Platform-specific runtime extras are also available:
42
57
 
43
58
  ```bash
44
59
  pip install "dcccpy[linux-runtime]"
60
+ pip install "dcccpy[windows-runtime]"
45
61
  ```
46
62
 
63
+ The platform-specific extras are guarded by environment markers, so they only
64
+ install a runtime wheel on the matching platform.
65
+
47
66
  ## Python API
48
67
 
49
68
  ```python
@@ -109,7 +128,8 @@ At runtime, `dcccpy` looks for `DCCCcore` in this order:
109
128
 
110
129
  1. `DCCCPY_DCCCCORE` environment variable.
111
130
  2. A vendored binary inside the installed `dcccpy` wheel.
112
- 3. A binary from `dcccpy-linux-runtime`, installed by `dcccpy[linux-runtime]`.
131
+ 3. A binary from `dcccpy-linux-runtime` or `dcccpy-windows-runtime`, installed by
132
+ `dcccpy[runtime]` or the platform-specific runtime extras.
113
133
  4. The local dcccpy cache populated by automatic download.
114
134
  5. `DCCCcore` on `PATH`.
115
135
  6. Automatic download from GitHub releases, unless disabled.
@@ -138,15 +158,16 @@ The preferred distribution layout is:
138
158
 
139
159
  - `dcccpy`: slim Python package with nibabel; downloads runtime on first use.
140
160
  - `dcccpy-linux-runtime`: optional Linux runtime wheel.
141
- - `dcccpy[linux-runtime]`: installs both packages.
161
+ - `dcccpy-windows-runtime`: optional Windows runtime wheel.
162
+ - `dcccpy[runtime]`: installs the matching runtime package on supported platforms.
142
163
 
143
164
  ## Packaging note
144
165
 
145
- The Linux `DCCCcore-4.2.3-ubuntu-latest-x64.zip` release asset contains the
146
- native executable, `libtbb`, ONNX registration/decoupling models, configuration
147
- files, and NIfTI template/mask assets. That full runtime is the correct unit to
148
- vendor for a wheel that works immediately after `pip install dcccpy`.
166
+ The runtime wheels use a PyPI-size profile for version 4.2.3. They omit the
167
+ `fast_and_acc` registration model/config and the ADAD decoupler ONNX ensemble,
168
+ while keeping the default spatial normalization model and assets needed by
169
+ common Centiloid/CenTauR/CenTauRz workflows.
149
170
 
150
- The full Linux runtime wheel is about 167 MB for version 4.2.3, so a public
151
- PyPI upload may require a file size limit increase unless a future release
152
- splits a smaller runtime profile from the full `DCCCcore` package.
171
+ The plain `dcccpy` package remains slim and downloads the full matching
172
+ `DCCCcore` release package from GitHub on first use when no installed runtime is
173
+ available.
@@ -0,0 +1,19 @@
1
+ nibabel>=5
2
+
3
+ [linux-runtime]
4
+
5
+ [linux-runtime:sys_platform == "linux" and platform_machine == "x86_64"]
6
+ dcccpy-linux-runtime==0.1.0
7
+
8
+ [runtime]
9
+
10
+ [runtime:sys_platform == "linux" and platform_machine == "x86_64"]
11
+ dcccpy-linux-runtime==0.1.0
12
+
13
+ [runtime:sys_platform == "win32" and platform_machine == "AMD64"]
14
+ dcccpy-windows-runtime==0.1.0
15
+
16
+ [windows-runtime]
17
+
18
+ [windows-runtime:sys_platform == "win32" and platform_machine == "AMD64"]
19
+ dcccpy-windows-runtime==0.1.0
@@ -1,4 +0,0 @@
1
- nibabel>=5
2
-
3
- [linux-runtime]
4
- dcccpy-linux-runtime==0.1.0
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes