patchworks 1.3.3__tar.gz → 1.3.4__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 (89) hide show
  1. {patchworks-1.3.3 → patchworks-1.3.4}/PKG-INFO +14 -1
  2. {patchworks-1.3.3 → patchworks-1.3.4}/README.md +13 -0
  3. {patchworks-1.3.3 → patchworks-1.3.4}/docs/getting_started.md +13 -0
  4. {patchworks-1.3.3 → patchworks-1.3.4}/docs/guide/custom_segmentation.md +7 -2
  5. {patchworks-1.3.3 → patchworks-1.3.4}/.github/workflows/docs.yml +0 -0
  6. {patchworks-1.3.3 → patchworks-1.3.4}/.github/workflows/lint.yml +0 -0
  7. {patchworks-1.3.3 → patchworks-1.3.4}/.github/workflows/release.yml +0 -0
  8. {patchworks-1.3.3 → patchworks-1.3.4}/.gitignore +0 -0
  9. {patchworks-1.3.3 → patchworks-1.3.4}/.markdownlint-cli2.yaml +0 -0
  10. {patchworks-1.3.3 → patchworks-1.3.4}/LICENSE +0 -0
  11. {patchworks-1.3.3 → patchworks-1.3.4}/cliff.toml +0 -0
  12. {patchworks-1.3.3 → patchworks-1.3.4}/docs/api/chunks.md +0 -0
  13. {patchworks-1.3.3 → patchworks-1.3.4}/docs/api/cluster.md +0 -0
  14. {patchworks-1.3.3 → patchworks-1.3.4}/docs/api/io.md +0 -0
  15. {patchworks-1.3.3 → patchworks-1.3.4}/docs/api/merge_tile_labels.md +0 -0
  16. {patchworks-1.3.3 → patchworks-1.3.4}/docs/api/plugins/cellpose.md +0 -0
  17. {patchworks-1.3.3 → patchworks-1.3.4}/docs/api/plugins/dog.md +0 -0
  18. {patchworks-1.3.3 → patchworks-1.3.4}/docs/api/plugins/napari.md +0 -0
  19. {patchworks-1.3.3 → patchworks-1.3.4}/docs/api/plugins/ome_zarr.md +0 -0
  20. {patchworks-1.3.3 → patchworks-1.3.4}/docs/api/postprocess.md +0 -0
  21. {patchworks-1.3.3 → patchworks-1.3.4}/docs/api/relabel.md +0 -0
  22. {patchworks-1.3.3 → patchworks-1.3.4}/docs/api/tile_process.md +0 -0
  23. {patchworks-1.3.3 → patchworks-1.3.4}/docs/assets/logo.png +0 -0
  24. {patchworks-1.3.3 → patchworks-1.3.4}/docs/examples/cellpose_2d.md +0 -0
  25. {patchworks-1.3.3 → patchworks-1.3.4}/docs/examples/cellpose_2d.py +0 -0
  26. {patchworks-1.3.3 → patchworks-1.3.4}/docs/examples/cellpose_3d.md +0 -0
  27. {patchworks-1.3.3 → patchworks-1.3.4}/docs/examples/cellpose_3d.py +0 -0
  28. {patchworks-1.3.3 → patchworks-1.3.4}/docs/examples/custom.md +0 -0
  29. {patchworks-1.3.3 → patchworks-1.3.4}/docs/examples/custom_method.py +0 -0
  30. {patchworks-1.3.3 → patchworks-1.3.4}/docs/examples/dog.md +0 -0
  31. {patchworks-1.3.3 → patchworks-1.3.4}/docs/examples/dog.py +0 -0
  32. {patchworks-1.3.3 → patchworks-1.3.4}/docs/examples/standalone_merge.md +0 -0
  33. {patchworks-1.3.3 → patchworks-1.3.4}/docs/examples/stardist.md +0 -0
  34. {patchworks-1.3.3 → patchworks-1.3.4}/docs/examples/stardist_2d.py +0 -0
  35. {patchworks-1.3.3 → patchworks-1.3.4}/docs/guide/gpu_distributed.md +0 -0
  36. {patchworks-1.3.3 → patchworks-1.3.4}/docs/guide/label_relations.md +0 -0
  37. {patchworks-1.3.3 → patchworks-1.3.4}/docs/guide/measurements.md +0 -0
  38. {patchworks-1.3.3 → patchworks-1.3.4}/docs/guide/merging.md +0 -0
  39. {patchworks-1.3.3 → patchworks-1.3.4}/docs/guide/ome_zarr_napari.md +0 -0
  40. {patchworks-1.3.3 → patchworks-1.3.4}/docs/guide/performance.md +0 -0
  41. {patchworks-1.3.3 → patchworks-1.3.4}/docs/guide/pitfalls.md +0 -0
  42. {patchworks-1.3.3 → patchworks-1.3.4}/docs/guide/skip_empty.md +0 -0
  43. {patchworks-1.3.3 → patchworks-1.3.4}/docs/guide/snakemake.md +0 -0
  44. {patchworks-1.3.3 → patchworks-1.3.4}/docs/guide/tiling.md +0 -0
  45. {patchworks-1.3.3 → patchworks-1.3.4}/docs/index.md +0 -0
  46. {patchworks-1.3.3 → patchworks-1.3.4}/mkdocs.yml +0 -0
  47. {patchworks-1.3.3 → patchworks-1.3.4}/pyproject.toml +0 -0
  48. {patchworks-1.3.3 → patchworks-1.3.4}/src/patchworks/__init__.py +0 -0
  49. {patchworks-1.3.3 → patchworks-1.3.4}/src/patchworks/_chunks.py +0 -0
  50. {patchworks-1.3.3 → patchworks-1.3.4}/src/patchworks/_cluster.py +0 -0
  51. {patchworks-1.3.3 → patchworks-1.3.4}/src/patchworks/_core.py +0 -0
  52. {patchworks-1.3.3 → patchworks-1.3.4}/src/patchworks/_distributed.py +0 -0
  53. {patchworks-1.3.3 → patchworks-1.3.4}/src/patchworks/_io.py +0 -0
  54. {patchworks-1.3.3 → patchworks-1.3.4}/src/patchworks/_merge.py +0 -0
  55. {patchworks-1.3.3 → patchworks-1.3.4}/src/patchworks/_postprocess.py +0 -0
  56. {patchworks-1.3.3 → patchworks-1.3.4}/src/patchworks/_relabel.py +0 -0
  57. {patchworks-1.3.3 → patchworks-1.3.4}/src/patchworks/_relations.py +0 -0
  58. {patchworks-1.3.3 → patchworks-1.3.4}/src/patchworks/plugins/__init__.py +0 -0
  59. {patchworks-1.3.3 → patchworks-1.3.4}/src/patchworks/plugins/cellpose.py +0 -0
  60. {patchworks-1.3.3 → patchworks-1.3.4}/src/patchworks/plugins/dog.py +0 -0
  61. {patchworks-1.3.3 → patchworks-1.3.4}/src/patchworks/plugins/napari.py +0 -0
  62. {patchworks-1.3.3 → patchworks-1.3.4}/src/patchworks/plugins/ome_zarr.py +0 -0
  63. {patchworks-1.3.3 → patchworks-1.3.4}/tests/test_core.py +0 -0
  64. {patchworks-1.3.3 → patchworks-1.3.4}/tests/test_distributed.py +0 -0
  65. {patchworks-1.3.3 → patchworks-1.3.4}/tests/test_dog.py +0 -0
  66. {patchworks-1.3.3 → patchworks-1.3.4}/tests/test_napari.py +0 -0
  67. {patchworks-1.3.3 → patchworks-1.3.4}/tests/test_ome_zarr.py +0 -0
  68. {patchworks-1.3.3 → patchworks-1.3.4}/tests/test_postprocess.py +0 -0
  69. {patchworks-1.3.3 → patchworks-1.3.4}/tests/test_relations.py +0 -0
  70. {patchworks-1.3.3 → patchworks-1.3.4}/workflow/README.md +0 -0
  71. {patchworks-1.3.3 → patchworks-1.3.4}/workflow/Snakefile +0 -0
  72. {patchworks-1.3.3 → patchworks-1.3.4}/workflow/config/config.yaml +0 -0
  73. {patchworks-1.3.3 → patchworks-1.3.4}/workflow/config/config_cilia.yaml +0 -0
  74. {patchworks-1.3.3 → patchworks-1.3.4}/workflow/config/config_cyto.yaml +0 -0
  75. {patchworks-1.3.3 → patchworks-1.3.4}/workflow/config/config_nuclei.yaml +0 -0
  76. {patchworks-1.3.3 → patchworks-1.3.4}/workflow/config/multi.yaml +0 -0
  77. {patchworks-1.3.3 → patchworks-1.3.4}/workflow/pixi.toml +0 -0
  78. {patchworks-1.3.3 → patchworks-1.3.4}/workflow/profile/slurm/config.yaml +0 -0
  79. {patchworks-1.3.3 → patchworks-1.3.4}/workflow/rules/common.smk +0 -0
  80. {patchworks-1.3.3 → patchworks-1.3.4}/workflow/rules/convert.smk +0 -0
  81. {patchworks-1.3.3 → patchworks-1.3.4}/workflow/rules/merge.smk +0 -0
  82. {patchworks-1.3.3 → patchworks-1.3.4}/workflow/rules/segment.smk +0 -0
  83. {patchworks-1.3.3 → patchworks-1.3.4}/workflow/scripts/_pw.py +0 -0
  84. {patchworks-1.3.3 → patchworks-1.3.4}/workflow/scripts/convert.py +0 -0
  85. {patchworks-1.3.3 → patchworks-1.3.4}/workflow/scripts/fetch_model.py +0 -0
  86. {patchworks-1.3.3 → patchworks-1.3.4}/workflow/scripts/merge.py +0 -0
  87. {patchworks-1.3.3 → patchworks-1.3.4}/workflow/scripts/prepare_tiles.py +0 -0
  88. {patchworks-1.3.3 → patchworks-1.3.4}/workflow/scripts/run_multi.py +0 -0
  89. {patchworks-1.3.3 → patchworks-1.3.4}/workflow/scripts/segment_tile.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: patchworks
3
- Version: 1.3.3
3
+ Version: 1.3.4
4
4
  Summary: Tiled processing of arbitrarily large images with globally consistent labels
5
5
  Project-URL: Homepage, https://github.com/imcf/patchworks
6
6
  Project-URL: Issues, https://github.com/imcf/patchworks/issues
@@ -130,6 +130,7 @@ pip install "patchworks[gpu]" # GPU VRAM querying (nvidia-ml-py)
130
130
  pip install "patchworks[cellpose]" # Cellpose plugin (>=3.0, v3 or v4)
131
131
  pip install "patchworks[cellpose3]" # Cellpose plugin, pinned to v3.x
132
132
  pip install "patchworks[cellpose4]" # Cellpose plugin, pinned to v4+
133
+ pip install "patchworks[dog]" # deconvolution + DoG plugin (pycudadecon)
133
134
  pip install "patchworks[bioio]" # convert any image format to OME-ZARR
134
135
  pip install "patchworks[imaris]" # convert Imaris .ims files to OME-ZARR
135
136
  pip install "patchworks[napari]" # interactive napari viewer plugin
@@ -142,6 +143,14 @@ pip install "patchworks[all]" # Everything, incl. the napari viewer
142
143
  > `[imaris]` adds native `.ims` support (HDF5, no JVM). Physical pixel
143
144
  > calibration is read from the input and written into the OME-ZARR.
144
145
 
146
+ > **`cupy` is never installed automatically**, unlike Cellpose's GPU support
147
+ > (which comes for free via PyTorch's self-contained CUDA wheels). Any
148
+ > `use_gpu=True`/`dilate_gpu: true` option (the `dog` plugin, `dilate_labels`)
149
+ > needs `cupy` installed separately, matching your CUDA version — e.g.
150
+ > `pip install cupy-cuda12x`. Not bundled because cupy ships one wheel per
151
+ > CUDA major version; a generic pin would resolve to the wrong build (or fail
152
+ > to resolve) depending on the machine.
153
+
145
154
  ---
146
155
 
147
156
  ## Quick start — 5 lines
@@ -397,10 +406,14 @@ Optional:
397
406
  - `tqdm` — progress bars
398
407
  - `cellpose` — Cellpose plugin, v3 or v4 (`patchworks[cellpose]`);
399
408
  pin with `[cellpose3]` or `[cellpose4]`
409
+ - `pycudadecon` — deconvolution step of the `dog` plugin (`patchworks[dog]`)
400
410
  - `bioio` + readers — convert CZI/LIF/ND2/OME-TIFF/… to OME-ZARR
401
411
  (`patchworks[bioio]`)
402
412
  - `imaris-ims-file-reader` — convert Imaris `.ims` (`patchworks[imaris]`)
403
413
  - `napari` — interactive viewer plugin (`patchworks[napari]`)
414
+ - `cupy` — **install manually**, matching your CUDA version (e.g.
415
+ `pip install cupy-cuda12x`); not offered as an extra since it isn't one
416
+ generic pin. Needed for `use_gpu=True`/`dilate_gpu: true`.
404
417
 
405
418
  ---
406
419
 
@@ -40,6 +40,7 @@ pip install "patchworks[gpu]" # GPU VRAM querying (nvidia-ml-py)
40
40
  pip install "patchworks[cellpose]" # Cellpose plugin (>=3.0, v3 or v4)
41
41
  pip install "patchworks[cellpose3]" # Cellpose plugin, pinned to v3.x
42
42
  pip install "patchworks[cellpose4]" # Cellpose plugin, pinned to v4+
43
+ pip install "patchworks[dog]" # deconvolution + DoG plugin (pycudadecon)
43
44
  pip install "patchworks[bioio]" # convert any image format to OME-ZARR
44
45
  pip install "patchworks[imaris]" # convert Imaris .ims files to OME-ZARR
45
46
  pip install "patchworks[napari]" # interactive napari viewer plugin
@@ -52,6 +53,14 @@ pip install "patchworks[all]" # Everything, incl. the napari viewer
52
53
  > `[imaris]` adds native `.ims` support (HDF5, no JVM). Physical pixel
53
54
  > calibration is read from the input and written into the OME-ZARR.
54
55
 
56
+ > **`cupy` is never installed automatically**, unlike Cellpose's GPU support
57
+ > (which comes for free via PyTorch's self-contained CUDA wheels). Any
58
+ > `use_gpu=True`/`dilate_gpu: true` option (the `dog` plugin, `dilate_labels`)
59
+ > needs `cupy` installed separately, matching your CUDA version — e.g.
60
+ > `pip install cupy-cuda12x`. Not bundled because cupy ships one wheel per
61
+ > CUDA major version; a generic pin would resolve to the wrong build (or fail
62
+ > to resolve) depending on the machine.
63
+
55
64
  ---
56
65
 
57
66
  ## Quick start — 5 lines
@@ -307,10 +316,14 @@ Optional:
307
316
  - `tqdm` — progress bars
308
317
  - `cellpose` — Cellpose plugin, v3 or v4 (`patchworks[cellpose]`);
309
318
  pin with `[cellpose3]` or `[cellpose4]`
319
+ - `pycudadecon` — deconvolution step of the `dog` plugin (`patchworks[dog]`)
310
320
  - `bioio` + readers — convert CZI/LIF/ND2/OME-TIFF/… to OME-ZARR
311
321
  (`patchworks[bioio]`)
312
322
  - `imaris-ims-file-reader` — convert Imaris `.ims` (`patchworks[imaris]`)
313
323
  - `napari` — interactive viewer plugin (`patchworks[napari]`)
324
+ - `cupy` — **install manually**, matching your CUDA version (e.g.
325
+ `pip install cupy-cuda12x`); not offered as an extra since it isn't one
326
+ generic pin. Needed for `use_gpu=True`/`dilate_gpu: true`.
314
327
 
315
328
  ---
316
329
 
@@ -36,12 +36,25 @@ patchworks can be installed from PyPI on all operating systems, for Python ≥ 3
36
36
  pip install "patchworks[cellpose]"
37
37
  ```
38
38
 
39
+ === "With deconvolution + DoG plugin"
40
+
41
+ ```bash
42
+ pip install "patchworks[dog]"
43
+ ```
44
+
39
45
  === "Everything"
40
46
 
41
47
  ```bash
42
48
  pip install "patchworks[all]"
43
49
  ```
44
50
 
51
+ !!! note "cupy is always a manual install"
52
+ `use_gpu=True` (the `dog` plugin, `dilate_labels`) needs `cupy`, but it's
53
+ never pulled in automatically — unlike Cellpose, which gets GPU support
54
+ for free via PyTorch's self-contained CUDA wheels, `cupy` ships one wheel
55
+ per CUDA major version. Install the one matching your CUDA version
56
+ yourself, e.g. `pip install cupy-cuda12x`.
57
+
45
58
  ---
46
59
 
47
60
  ## The one function you need
@@ -78,10 +78,15 @@ By default the dilation itself runs on CPU (scipy), independent of whatever
78
78
  backend `fn` used — pass `use_gpu=True` to dilate via cupy instead:
79
79
 
80
80
  ```python
81
- fn = dilate_labels(fn, iterations=2, use_gpu=True) # needs cupy installed
81
+ fn = dilate_labels(fn, iterations=2, use_gpu=True)
82
82
  ```
83
83
 
84
- On the cluster, this is the `dilate_gpu: true` config key.
84
+ Needs `cupy` installed **manually**, matching your CUDA version (e.g.
85
+ `pip install cupy-cuda12x`) — it's never installed automatically by
86
+ patchworks, unlike Cellpose's GPU support (which comes for free via
87
+ PyTorch's self-contained CUDA wheels); cupy ships one wheel per CUDA major
88
+ version, so there's no single generic pin that works everywhere. On the
89
+ cluster, this is the `dilate_gpu: true` config key.
85
90
 
86
91
  ## Real example: StarDist 3-D, with model caching
87
92
 
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes