ngio 0.3.0a1__tar.gz → 0.3.2__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 (223) hide show
  1. ngio-0.3.2/.github/pull_request_template.md +3 -0
  2. ngio-0.3.2/CHANGELOG.md +12 -0
  3. {ngio-0.3.0a1 → ngio-0.3.2}/PKG-INFO +68 -35
  4. ngio-0.3.2/README.md +74 -0
  5. {ngio-0.3.0a1 → ngio-0.3.2}/docs/index.md +2 -1
  6. {ngio-0.3.0a1 → ngio-0.3.2}/docs/table_specs/backend.md +2 -1
  7. {ngio-0.3.0a1 → ngio-0.3.2}/docs/table_specs/table_types/roi_table.md +1 -1
  8. {ngio-0.3.0a1 → ngio-0.3.2}/mkdocs.yml +1 -0
  9. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/common/_array_pipe.py +50 -27
  10. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/common/_roi.py +2 -0
  11. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/common/_table_ops.py +1 -1
  12. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/hcs/__init__.py +1 -1
  13. ngio-0.3.0a1/src/ngio/hcs/plate.py → ngio-0.3.2/src/ngio/hcs/_plate.py +25 -9
  14. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/images/__init__.py +3 -3
  15. ngio-0.3.0a1/src/ngio/images/image.py → ngio-0.3.2/src/ngio/images/_image.py +26 -21
  16. ngio-0.3.0a1/src/ngio/images/label.py → ngio-0.3.2/src/ngio/images/_label.py +6 -4
  17. ngio-0.3.0a1/src/ngio/images/masked_image.py → ngio-0.3.2/src/ngio/images/_masked_image.py +2 -2
  18. ngio-0.3.0a1/src/ngio/images/ome_zarr_container.py → ngio-0.3.2/src/ngio/images/_ome_zarr_container.py +58 -22
  19. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/ome_zarr_meta/ngio_specs/_axes.py +4 -7
  20. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/ome_zarr_meta/ngio_specs/_channels.py +41 -29
  21. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/tables/__init__.py +8 -6
  22. ngio-0.3.0a1/src/ngio/tables/abstract_table.py → ngio-0.3.2/src/ngio/tables/_abstract_table.py +2 -1
  23. ngio-0.3.0a1/src/ngio/tables/tables_container.py → ngio-0.3.2/src/ngio/tables/_tables_container.py +33 -19
  24. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/tables/backends/__init__.py +2 -0
  25. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/tables/backends/_abstract_backend.py +1 -1
  26. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/tables/backends/_table_backends.py +35 -12
  27. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/tables/v1/_condition_table.py +1 -1
  28. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/tables/v1/_feature_table.py +2 -2
  29. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/tables/v1/_generic_table.py +1 -1
  30. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/tables/v1/_roi_table.py +13 -3
  31. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/utils/_fractal_fsspec_store.py +1 -1
  32. {ngio-0.3.0a1 → ngio-0.3.2}/tests/unit/common/test_roi.py +1 -0
  33. {ngio-0.3.0a1 → ngio-0.3.2}/tests/unit/images/test_masked_images.py +4 -1
  34. {ngio-0.3.0a1 → ngio-0.3.2}/tests/unit/tables/test_backends.py +10 -6
  35. {ngio-0.3.0a1 → ngio-0.3.2}/tests/unit/tables/test_feature_table.py +1 -1
  36. {ngio-0.3.0a1 → ngio-0.3.2}/tests/unit/tables/test_generic_table.py +7 -1
  37. {ngio-0.3.0a1 → ngio-0.3.2}/tests/unit/tables/test_masking_roi_table_v1.py +3 -1
  38. {ngio-0.3.0a1 → ngio-0.3.2}/tests/unit/tables/test_roi_table_v1.py +1 -1
  39. {ngio-0.3.0a1 → ngio-0.3.2}/tests/unit/tables/test_table_group.py +1 -1
  40. ngio-0.3.0a1/CHANGELOG.md +0 -7
  41. ngio-0.3.0a1/README.md +0 -41
  42. {ngio-0.3.0a1 → ngio-0.3.2}/.copier-answers.yml +0 -0
  43. {ngio-0.3.0a1 → ngio-0.3.2}/.gitattributes +0 -0
  44. {ngio-0.3.0a1 → ngio-0.3.2}/.github/ISSUE_TEMPLATE.md +0 -0
  45. {ngio-0.3.0a1 → ngio-0.3.2}/.github/TEST_FAIL_TEMPLATE.md +0 -0
  46. {ngio-0.3.0a1 → ngio-0.3.2}/.github/dependabot.yml +0 -0
  47. {ngio-0.3.0a1 → ngio-0.3.2}/.github/scripts/download_data.sh +0 -0
  48. {ngio-0.3.0a1 → ngio-0.3.2}/.github/workflows/build_docs.yml +0 -0
  49. {ngio-0.3.0a1 → ngio-0.3.2}/.github/workflows/ci.yml +0 -0
  50. {ngio-0.3.0a1 → ngio-0.3.2}/.gitignore +0 -0
  51. {ngio-0.3.0a1 → ngio-0.3.2}/.pre-commit-config.yaml +0 -0
  52. {ngio-0.3.0a1 → ngio-0.3.2}/LICENSE +0 -0
  53. {ngio-0.3.0a1 → ngio-0.3.2}/_typos.toml +0 -0
  54. {ngio-0.3.0a1 → ngio-0.3.2}/docs/api/common.md +0 -0
  55. {ngio-0.3.0a1 → ngio-0.3.2}/docs/api/hcs.md +0 -0
  56. {ngio-0.3.0a1 → ngio-0.3.2}/docs/api/images.md +0 -0
  57. {ngio-0.3.0a1 → ngio-0.3.2}/docs/api/ngio.md +0 -0
  58. {ngio-0.3.0a1 → ngio-0.3.2}/docs/api/tables.md +0 -0
  59. {ngio-0.3.0a1 → ngio-0.3.2}/docs/api/utils.md +0 -0
  60. {ngio-0.3.0a1 → ngio-0.3.2}/docs/changelog.md +0 -0
  61. {ngio-0.3.0a1 → ngio-0.3.2}/docs/code_of_conduct.md +0 -0
  62. {ngio-0.3.0a1 → ngio-0.3.2}/docs/contributing.md +0 -0
  63. {ngio-0.3.0a1 → ngio-0.3.2}/docs/getting_started/0_quickstart.md +0 -0
  64. {ngio-0.3.0a1 → ngio-0.3.2}/docs/getting_started/1_ome_zarr_containers.md +0 -0
  65. {ngio-0.3.0a1 → ngio-0.3.2}/docs/getting_started/2_images.md +0 -0
  66. {ngio-0.3.0a1 → ngio-0.3.2}/docs/getting_started/3_tables.md +0 -0
  67. {ngio-0.3.0a1 → ngio-0.3.2}/docs/getting_started/4_masked_images.md +0 -0
  68. {ngio-0.3.0a1 → ngio-0.3.2}/docs/getting_started/5_hcs.md +0 -0
  69. {ngio-0.3.0a1 → ngio-0.3.2}/docs/table_specs/overview.md +0 -0
  70. {ngio-0.3.0a1 → ngio-0.3.2}/docs/table_specs/table_types/condition_table.md +0 -0
  71. {ngio-0.3.0a1 → ngio-0.3.2}/docs/table_specs/table_types/custom_table.md +0 -0
  72. {ngio-0.3.0a1 → ngio-0.3.2}/docs/table_specs/table_types/feature_table.md +0 -0
  73. {ngio-0.3.0a1 → ngio-0.3.2}/docs/table_specs/table_types/generic_table.md +0 -0
  74. {ngio-0.3.0a1 → ngio-0.3.2}/docs/table_specs/table_types/masking_roi_table.md +0 -0
  75. {ngio-0.3.0a1 → ngio-0.3.2}/docs/tutorials/feature_extraction.ipynb +0 -0
  76. {ngio-0.3.0a1 → ngio-0.3.2}/docs/tutorials/hcs_processing.ipynb +0 -0
  77. {ngio-0.3.0a1 → ngio-0.3.2}/docs/tutorials/image_processing.ipynb +0 -0
  78. {ngio-0.3.0a1 → ngio-0.3.2}/docs/tutorials/image_segmentation.ipynb +0 -0
  79. {ngio-0.3.0a1 → ngio-0.3.2}/pyproject.toml +0 -0
  80. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/__init__.py +0 -0
  81. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/common/__init__.py +0 -0
  82. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/common/_axes_transforms.py +0 -0
  83. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/common/_common_types.py +0 -0
  84. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/common/_dimensions.py +0 -0
  85. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/common/_masking_roi.py +0 -0
  86. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/common/_pyramid.py +0 -0
  87. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/common/_slicer.py +0 -0
  88. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/common/_zoom.py +0 -0
  89. /ngio-0.3.0a1/src/ngio/images/abstract_image.py → /ngio-0.3.2/src/ngio/images/_abstract_image.py +0 -0
  90. /ngio-0.3.0a1/src/ngio/images/create.py → /ngio-0.3.2/src/ngio/images/_create.py +0 -0
  91. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/ome_zarr_meta/__init__.py +0 -0
  92. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/ome_zarr_meta/_meta_handlers.py +0 -0
  93. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/ome_zarr_meta/ngio_specs/__init__.py +0 -0
  94. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/ome_zarr_meta/ngio_specs/_dataset.py +0 -0
  95. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/ome_zarr_meta/ngio_specs/_ngio_hcs.py +0 -0
  96. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/ome_zarr_meta/ngio_specs/_ngio_image.py +0 -0
  97. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/ome_zarr_meta/ngio_specs/_pixel_size.py +0 -0
  98. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/ome_zarr_meta/v04/__init__.py +0 -0
  99. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/ome_zarr_meta/v04/_custom_models.py +0 -0
  100. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/ome_zarr_meta/v04/_v04_spec_utils.py +0 -0
  101. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/tables/backends/_anndata.py +0 -0
  102. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/tables/backends/_anndata_utils.py +0 -0
  103. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/tables/backends/_csv.py +0 -0
  104. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/tables/backends/_json.py +0 -0
  105. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/tables/backends/_non_zarr_backends.py +0 -0
  106. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/tables/backends/_parquet.py +0 -0
  107. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/tables/backends/_utils.py +0 -0
  108. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/tables/v1/__init__.py +0 -0
  109. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/utils/__init__.py +0 -0
  110. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/utils/_datasets.py +0 -0
  111. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/utils/_errors.py +0 -0
  112. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/utils/_logger.py +0 -0
  113. {ngio-0.3.0a1 → ngio-0.3.2}/src/ngio/utils/_zarr_utils.py +0 -0
  114. {ngio-0.3.0a1 → ngio-0.3.2}/tests/conftest.py +0 -0
  115. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_c1yx.zarr/.zattrs +0 -0
  116. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_c1yx.zarr/.zgroup +0 -0
  117. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_c1yx.zarr/0/.zarray +0 -0
  118. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_c1yx.zarr/1/.zarray +0 -0
  119. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_c1yx.zarr/labels/.zattrs +0 -0
  120. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_c1yx.zarr/labels/.zgroup +0 -0
  121. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_c1yx.zarr/labels/label/.zattrs +0 -0
  122. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_c1yx.zarr/labels/label/.zgroup +0 -0
  123. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_c1yx.zarr/labels/label/0/.zarray +0 -0
  124. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_c1yx.zarr/labels/label/1/.zarray +0 -0
  125. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_cyx.zarr/.zattrs +0 -0
  126. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_cyx.zarr/.zgroup +0 -0
  127. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_cyx.zarr/0/.zarray +0 -0
  128. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_cyx.zarr/1/.zarray +0 -0
  129. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_cyx.zarr/labels/.zattrs +0 -0
  130. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_cyx.zarr/labels/.zgroup +0 -0
  131. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_cyx.zarr/labels/label/.zattrs +0 -0
  132. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_cyx.zarr/labels/label/.zgroup +0 -0
  133. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_cyx.zarr/labels/label/0/.zarray +0 -0
  134. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_cyx.zarr/labels/label/1/.zarray +0 -0
  135. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_czyx.zarr/.zattrs +0 -0
  136. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_czyx.zarr/.zgroup +0 -0
  137. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_czyx.zarr/0/.zarray +0 -0
  138. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_czyx.zarr/1/.zarray +0 -0
  139. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_czyx.zarr/labels/.zattrs +0 -0
  140. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_czyx.zarr/labels/.zgroup +0 -0
  141. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_czyx.zarr/labels/label/.zattrs +0 -0
  142. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_czyx.zarr/labels/label/.zgroup +0 -0
  143. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_czyx.zarr/labels/label/0/.zarray +0 -0
  144. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_czyx.zarr/labels/label/1/.zarray +0 -0
  145. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tcyx.zarr/.zattrs +0 -0
  146. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tcyx.zarr/.zgroup +0 -0
  147. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tcyx.zarr/0/.zarray +0 -0
  148. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tcyx.zarr/1/.zarray +0 -0
  149. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tcyx.zarr/labels/.zattrs +0 -0
  150. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tcyx.zarr/labels/.zgroup +0 -0
  151. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tcyx.zarr/labels/label/.zattrs +0 -0
  152. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tcyx.zarr/labels/label/.zgroup +0 -0
  153. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tcyx.zarr/labels/label/0/.zarray +0 -0
  154. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tcyx.zarr/labels/label/1/.zarray +0 -0
  155. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tczyx.zarr/.zattrs +0 -0
  156. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tczyx.zarr/.zgroup +0 -0
  157. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tczyx.zarr/0/.zarray +0 -0
  158. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tczyx.zarr/1/.zarray +0 -0
  159. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tczyx.zarr/labels/.zattrs +0 -0
  160. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tczyx.zarr/labels/.zgroup +0 -0
  161. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tczyx.zarr/labels/label/.zattrs +0 -0
  162. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tczyx.zarr/labels/label/.zgroup +0 -0
  163. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tczyx.zarr/labels/label/0/.zarray +0 -0
  164. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tczyx.zarr/labels/label/1/.zarray +0 -0
  165. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tyx.zarr/.zattrs +0 -0
  166. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tyx.zarr/.zgroup +0 -0
  167. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tyx.zarr/0/.zarray +0 -0
  168. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tyx.zarr/1/.zarray +0 -0
  169. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tyx.zarr/labels/.zattrs +0 -0
  170. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tyx.zarr/labels/.zgroup +0 -0
  171. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tyx.zarr/labels/label/.zattrs +0 -0
  172. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tyx.zarr/labels/label/.zgroup +0 -0
  173. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tyx.zarr/labels/label/0/.zarray +0 -0
  174. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tyx.zarr/labels/label/1/.zarray +0 -0
  175. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tzyx.zarr/.zattrs +0 -0
  176. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tzyx.zarr/.zgroup +0 -0
  177. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tzyx.zarr/0/.zarray +0 -0
  178. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tzyx.zarr/1/.zarray +0 -0
  179. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tzyx.zarr/labels/.zattrs +0 -0
  180. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tzyx.zarr/labels/.zgroup +0 -0
  181. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tzyx.zarr/labels/label/.zattrs +0 -0
  182. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tzyx.zarr/labels/label/.zgroup +0 -0
  183. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tzyx.zarr/labels/label/0/.zarray +0 -0
  184. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_tzyx.zarr/labels/label/1/.zarray +0 -0
  185. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_yx.zarr/.zattrs +0 -0
  186. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_yx.zarr/.zgroup +0 -0
  187. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_yx.zarr/0/.zarray +0 -0
  188. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_yx.zarr/1/.zarray +0 -0
  189. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_yx.zarr/labels/.zattrs +0 -0
  190. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_yx.zarr/labels/.zgroup +0 -0
  191. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_yx.zarr/labels/label/.zattrs +0 -0
  192. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_yx.zarr/labels/label/.zgroup +0 -0
  193. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_yx.zarr/labels/label/0/.zarray +0 -0
  194. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_yx.zarr/labels/label/1/.zarray +0 -0
  195. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_zyx.zarr/.zattrs +0 -0
  196. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_zyx.zarr/.zgroup +0 -0
  197. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_zyx.zarr/0/.zarray +0 -0
  198. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_zyx.zarr/1/.zarray +0 -0
  199. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_zyx.zarr/labels/.zattrs +0 -0
  200. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_zyx.zarr/labels/.zgroup +0 -0
  201. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_zyx.zarr/labels/label/.zattrs +0 -0
  202. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_zyx.zarr/labels/label/.zgroup +0 -0
  203. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_zyx.zarr/labels/label/0/.zarray +0 -0
  204. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/images/test_image_zyx.zarr/labels/label/1/.zarray +0 -0
  205. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/meta/base_ome_zarr_image_meta.json +0 -0
  206. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/meta/base_ome_zarr_image_meta_wrong_axis_order.json +0 -0
  207. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/meta/base_ome_zarr_label_meta.json +0 -0
  208. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/meta/base_ome_zarr_well_meta.json +0 -0
  209. {ngio-0.3.0a1 → ngio-0.3.2}/tests/data/v04/meta/ome_zarr_well_path_normalization_meta.json +0 -0
  210. {ngio-0.3.0a1 → ngio-0.3.2}/tests/unit/common/test_dimensions.py +0 -0
  211. {ngio-0.3.0a1 → ngio-0.3.2}/tests/unit/common/test_pyramid.py +0 -0
  212. {ngio-0.3.0a1 → ngio-0.3.2}/tests/unit/common/test_table_ops.py +0 -0
  213. {ngio-0.3.0a1 → ngio-0.3.2}/tests/unit/hcs/test_plate.py +0 -0
  214. {ngio-0.3.0a1 → ngio-0.3.2}/tests/unit/hcs/test_well.py +0 -0
  215. {ngio-0.3.0a1 → ngio-0.3.2}/tests/unit/images/test_create.py +0 -0
  216. {ngio-0.3.0a1 → ngio-0.3.2}/tests/unit/images/test_images.py +0 -0
  217. {ngio-0.3.0a1 → ngio-0.3.2}/tests/unit/images/test_omezarr_container.py +0 -0
  218. {ngio-0.3.0a1 → ngio-0.3.2}/tests/unit/ome_zarr_meta/test_image_handler.py +0 -0
  219. {ngio-0.3.0a1 → ngio-0.3.2}/tests/unit/ome_zarr_meta/test_unit_ngio_specs.py +0 -0
  220. {ngio-0.3.0a1 → ngio-0.3.2}/tests/unit/ome_zarr_meta/test_unit_v04_utils.py +0 -0
  221. {ngio-0.3.0a1 → ngio-0.3.2}/tests/unit/tables/test_backends_utils.py +0 -0
  222. {ngio-0.3.0a1 → ngio-0.3.2}/tests/unit/utils/test_download_datasets.py +0 -0
  223. {ngio-0.3.0a1 → ngio-0.3.2}/tests/unit/utils/test_zarr_utils.py +0 -0
@@ -0,0 +1,3 @@
1
+
2
+ ## Checklist before merging
3
+ - [ ] I added an appropriate entry to `CHANGELOG.md`
@@ -0,0 +1,12 @@
1
+ # Changelog
2
+
3
+ ## [v0.3.2]
4
+
5
+ ### API Changes
6
+
7
+ - change table backend default to `anndata_v1` for backward compatibility. This will be chaanged again when ngio `v0.2.x` is no longer supported.
8
+
9
+ ### Bug Fixes
10
+
11
+ - fix [#13](https://github.com/fractal-analytics-platform/fractal-converters-tools/issues/13) (converters tools)
12
+ - fix [#88](https://github.com/fractal-analytics-platform/ngio/issues/88)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ngio
3
- Version: 0.3.0a1
3
+ Version: 0.3.2
4
4
  Summary: Next Generation file format IO
5
5
  Project-URL: homepage, https://github.com/fractal-analytics-platform/ngio
6
6
  Project-URL: repository, https://github.com/fractal-analytics-platform/ngio
@@ -63,7 +63,7 @@ Requires-Dist: pytest-cov; extra == 'test'
63
63
  Requires-Dist: scikit-image; extra == 'test'
64
64
  Description-Content-Type: text/markdown
65
65
 
66
- # NGIO - Next Generation file format IO
66
+ # Ngio - Next Generation file format IO
67
67
 
68
68
  [![License](https://img.shields.io/pypi/l/ngio.svg?color=green)](https://github.com/lorenzocerrone/ngio/raw/main/LICENSE)
69
69
  [![PyPI](https://img.shields.io/pypi/v/ngio.svg?color=green)](https://pypi.org/project/ngio)
@@ -71,36 +71,69 @@ Description-Content-Type: text/markdown
71
71
  [![CI](https://github.com/fractal-analytics-platform/ngio/actions/workflows/ci.yml/badge.svg)](https://github.com/fractal-analytics-platform/ngio/actions/workflows/ci.yml)
72
72
  [![codecov](https://codecov.io/gh/fractal-analytics-platform/ngio/graph/badge.svg?token=FkmF26FZki)](https://codecov.io/gh/fractal-analytics-platform/ngio)
73
73
 
74
- NGIO is a Python library to streamline OME-Zarr image analysis workflows.
75
-
76
- **Main Goals:**
77
-
78
- - Abstract object base API for handling OME-Zarr files
79
- - Powerful iterators for processing data using common access patterns
80
- - Tight integration with [Fractal's Table Fractal](https://fractal-analytics-platform.github.io/fractal-tasks-core/tables/)
81
- - Validation of OME-Zarr files
82
-
83
- To get started, check out the [Getting Started](https://fractal-analytics-platform.github.io/ngio/getting-started/) guide. Or checkout our [Documentation](https://fractal-analytics-platform.github.io/ngio/)
84
-
85
- ## 🚧 Ngio is Under active Development 🚧
86
-
87
- ### Roadmap
88
-
89
- | Feature | Status | ETA | Description |
90
- |---------|--------|-----|-------------|
91
- | Metadata Handling | | | Read, Write, Validate OME-Zarr Metadata (0.4 supported, 0.5 ready) |
92
- | OME-Zarr Validation | ✅ | | Validate OME-Zarr files for compliance with the OME-Zarr Specification + Compliance between Metadata and Data |
93
- | Base Image Handling | ✅ | | Load data from OME-Zarr files, retrieve basic metadata, and write data |
94
- | ROI Handling | | | Common ROI models |
95
- | Label Handling | ✅ | Mid-September | Based on Image Handling |
96
- | Table Validation | ✅ | Mid-September | Validate Table fractal V1 + Compliance between Metadata and Data |
97
- | Table Handling | ✅ | Mid-September | Read, Write ROI, Features, and Masked Tables |
98
- | Basic Iterators | Ongoing | End-September | Read and Write Iterators for common access patterns |
99
- | Base Documentation | ✅ | End-September | API Documentation and Examples |
100
- | Beta Ready Testing | ✅ | End-September | Beta Testing; Library is ready for testing, but the API is not stable |
101
- | Streaming from Fractal | Ongoing | December | Ngio can stream OME-Zarr from fractal |
102
- | Mask Iterators | Ongoing | Early 2025 | Iterators over Masked Tables |
103
- | Advanced Iterators | Not started | mid-2025 | Iterators for advanced access patterns |
104
- | Parallel Iterators | Not started | mid-2025 | Concurrent Iterators for parallel read and write |
105
- | Full Documentation | Not started | 2025 | Complete Documentation |
106
- | Release 1.0 (Commitment to API) | Not started | 2025 | API is stable; breaking changes will be avoided |
74
+ ngio is a Python library designed to simplify bioimage analysis workflows, offering an intuitive interface for working with OME-Zarr files.
75
+
76
+ ## What is Ngio?
77
+
78
+ Ngio is built for the [OME-Zarr](https://ngff.openmicroscopy.org/) file format, a modern, cloud-optimized format for biological imaging data. OME-Zarr stores large, multi-dimensional microscopy images and metadata in an efficient and scalable way.
79
+
80
+ Ngio's mission is to streamline working with OME-Zarr files by providing a simple, object-based API for opening, exploring, and manipulating OME-Zarr images and high-content screening (HCS) plates. It also offers comprehensive support for labels, tables and regions of interest (ROIs), making it easy to extract and analyze specific regions in your data.
81
+
82
+ ## Key Features
83
+
84
+ ### 📊 Simple Object-Based API
85
+
86
+ - Easily open, explore, and manipulate OME-Zarr images and HCS plates
87
+ - Create and derive new images and labels with minimal boilerplate code
88
+
89
+ ### 🔍 Rich Tables and Regions of Interest (ROI) Support
90
+
91
+ - Extract and analyze specific regions of interest
92
+ - Tight integration with [Tabular Data](https://fractal-analytics-platform.github.io/ngio/stable/table_specs/overview/)
93
+
94
+ ### 🔄 Scalable Data Processing (Coming Soon)
95
+
96
+ - Powerful iterators for processing data at scale
97
+ - Efficient memory management for large datasets
98
+
99
+ ## Installation
100
+
101
+ You can install ngio via pip:
102
+
103
+ ```bash
104
+ pip install ngio
105
+ ```
106
+
107
+ To get started check out the [Quickstart Guide](https://fractal-analytics-platform.github.io/ngio/stable/getting_started/0_quickstart/).
108
+
109
+ ## Supported OME-Zarr versions
110
+
111
+ Currently, ngio only supports OME-Zarr v0.4. Support for version 0.5 and higher is planned for future releases.
112
+
113
+ ## Development Status
114
+
115
+ !!! warning
116
+ Ngio is under active development and is not yet stable. The API is subject to change, and bugs and breaking changes are expected.
117
+ We follow [Semantic Versioning](https://semver.org/). Which means for 0.x releases potentially breaking changes can be introduced in minor releases.
118
+
119
+ ### Available Features
120
+
121
+ - ✅ OME-Zarr metadata handling and validation
122
+ - ✅ Image and label access across pyramid levels
123
+ - ✅ ROI and table support
124
+ - ✅ Streaming from remote sources
125
+ - ✅ Documentation and examples
126
+
127
+ ### Upcoming Features
128
+
129
+ - Advanced image processing iterators
130
+ - Parallel processing capabilities
131
+ - Support for OME-Zarr v0.5 and Zarr v3
132
+
133
+ ## Contributors
134
+
135
+ Ngio is developed at the [BioVisionCenter](https://www.biovisioncenter.uzh.ch/en.html), University of Zurich, by [@lorenzocerrone](https://github.com/lorenzocerrone) and [@jluethi](https://github.com/jluethi).
136
+
137
+ ## License
138
+
139
+ Ngio is released under the BSD-3-Clause License. See [LICENSE](https://github.com/fractal-analytics-platform/ngio/blob/main/LICENSE) for details.
ngio-0.3.2/README.md ADDED
@@ -0,0 +1,74 @@
1
+ # Ngio - Next Generation file format IO
2
+
3
+ [![License](https://img.shields.io/pypi/l/ngio.svg?color=green)](https://github.com/lorenzocerrone/ngio/raw/main/LICENSE)
4
+ [![PyPI](https://img.shields.io/pypi/v/ngio.svg?color=green)](https://pypi.org/project/ngio)
5
+ [![Python Version](https://img.shields.io/pypi/pyversions/ngio.svg?color=green)](https://python.org)
6
+ [![CI](https://github.com/fractal-analytics-platform/ngio/actions/workflows/ci.yml/badge.svg)](https://github.com/fractal-analytics-platform/ngio/actions/workflows/ci.yml)
7
+ [![codecov](https://codecov.io/gh/fractal-analytics-platform/ngio/graph/badge.svg?token=FkmF26FZki)](https://codecov.io/gh/fractal-analytics-platform/ngio)
8
+
9
+ ngio is a Python library designed to simplify bioimage analysis workflows, offering an intuitive interface for working with OME-Zarr files.
10
+
11
+ ## What is Ngio?
12
+
13
+ Ngio is built for the [OME-Zarr](https://ngff.openmicroscopy.org/) file format, a modern, cloud-optimized format for biological imaging data. OME-Zarr stores large, multi-dimensional microscopy images and metadata in an efficient and scalable way.
14
+
15
+ Ngio's mission is to streamline working with OME-Zarr files by providing a simple, object-based API for opening, exploring, and manipulating OME-Zarr images and high-content screening (HCS) plates. It also offers comprehensive support for labels, tables and regions of interest (ROIs), making it easy to extract and analyze specific regions in your data.
16
+
17
+ ## Key Features
18
+
19
+ ### 📊 Simple Object-Based API
20
+
21
+ - Easily open, explore, and manipulate OME-Zarr images and HCS plates
22
+ - Create and derive new images and labels with minimal boilerplate code
23
+
24
+ ### 🔍 Rich Tables and Regions of Interest (ROI) Support
25
+
26
+ - Extract and analyze specific regions of interest
27
+ - Tight integration with [Tabular Data](https://fractal-analytics-platform.github.io/ngio/stable/table_specs/overview/)
28
+
29
+ ### 🔄 Scalable Data Processing (Coming Soon)
30
+
31
+ - Powerful iterators for processing data at scale
32
+ - Efficient memory management for large datasets
33
+
34
+ ## Installation
35
+
36
+ You can install ngio via pip:
37
+
38
+ ```bash
39
+ pip install ngio
40
+ ```
41
+
42
+ To get started check out the [Quickstart Guide](https://fractal-analytics-platform.github.io/ngio/stable/getting_started/0_quickstart/).
43
+
44
+ ## Supported OME-Zarr versions
45
+
46
+ Currently, ngio only supports OME-Zarr v0.4. Support for version 0.5 and higher is planned for future releases.
47
+
48
+ ## Development Status
49
+
50
+ !!! warning
51
+ Ngio is under active development and is not yet stable. The API is subject to change, and bugs and breaking changes are expected.
52
+ We follow [Semantic Versioning](https://semver.org/). Which means for 0.x releases potentially breaking changes can be introduced in minor releases.
53
+
54
+ ### Available Features
55
+
56
+ - ✅ OME-Zarr metadata handling and validation
57
+ - ✅ Image and label access across pyramid levels
58
+ - ✅ ROI and table support
59
+ - ✅ Streaming from remote sources
60
+ - ✅ Documentation and examples
61
+
62
+ ### Upcoming Features
63
+
64
+ - Advanced image processing iterators
65
+ - Parallel processing capabilities
66
+ - Support for OME-Zarr v0.5 and Zarr v3
67
+
68
+ ## Contributors
69
+
70
+ Ngio is developed at the [BioVisionCenter](https://www.biovisioncenter.uzh.ch/en.html), University of Zurich, by [@lorenzocerrone](https://github.com/lorenzocerrone) and [@jluethi](https://github.com/jluethi).
71
+
72
+ ## License
73
+
74
+ Ngio is released under the BSD-3-Clause License. See [LICENSE](https://github.com/fractal-analytics-platform/ngio/blob/main/LICENSE) for details.
@@ -1,4 +1,3 @@
1
-
2
1
  ngio is a Python library designed to simplify bioimage analysis workflows, offering an intuitive interface for working with OME-Zarr files.
3
2
 
4
3
  ## What is Ngio?
@@ -30,12 +29,14 @@ Refer to the [Getting Started](getting_started/0_quickstart.md) guide to integra
30
29
  For more advanced usage and API documentation, see our [API Reference](api/ngio.md).
31
30
 
32
31
  ## Supported OME-Zarr versions
32
+
33
33
  Currently, ngio only supports OME-Zarr v0.4. Support for version 0.5 and higher is planned for future releases.
34
34
 
35
35
  ## Development Status
36
36
 
37
37
  !!! warning
38
38
  Ngio is under active development and is not yet stable. The API is subject to change, and bugs and breaking changes are expected.
39
+ We follow [Semantic Versioning](https://semver.org/). Which means for 0.x releases potentially breaking changes can be introduced in minor releases.
39
40
 
40
41
  ### Available Features
41
42
 
@@ -14,7 +14,8 @@ AnnData is a widely used format in single-cell genomics, and can natively store
14
14
  The following normalization steps are applied to each table before saving it to the AnnData backend:
15
15
 
16
16
  - We separate the table in two parts: The floating point columns are casted to `float32` and stored as `X` in the AnnData object, while the categorical, boolean, and integer columns are stored as `obs`.
17
- - The index column is cast to a string, and the name and original type is stored in the zarr attributes.
17
+ - The index column is cast to a string, and is stored in the `obs` index.
18
+ - The index column name must match the `index_key` specified in the metadata.
18
19
 
19
20
  AnnData backend metadata:
20
21
 
@@ -33,7 +33,7 @@ Moreover the ROI table must include the following columns:
33
33
 
34
34
  Additionally, each ROI can include the following optional columns:
35
35
 
36
- - `x_micrometer_original` and `y_micrometer_original` which are the original coordinates of the ROI in micrometers. These are typically used when the data is saved in different coordinates during conversion, e.g. to avoid overwriting data from overlapping ROIs.
36
+ - `x_micrometer_original`, `y_micrometer_original` and `z_micrometer_original` which are the original coordinates of the ROI in micrometers. These are typically used when the data is saved in different coordinates during conversion, e.g. to avoid overwriting data from overlapping ROIs.
37
37
  - `translation_x`, `translation_y` and `translation_z`, which are used during registration of multiplexing acquisitions.
38
38
 
39
39
  The user can also add additional columns to the ROI table, but these columns will not be exposed in the ROI table API.
@@ -104,6 +104,7 @@ nav:
104
104
  - "Overview": table_specs/overview.md
105
105
  - "Table Backends": table_specs/backend.md
106
106
  - "Table Types":
107
+ - "Generic Table": table_specs/table_types/generic_table.md
107
108
  - "ROI Table": table_specs/table_types/roi_table.md
108
109
  - "Masking ROI Table": table_specs/table_types/masking_roi_table.md
109
110
  - "Feature Table": table_specs/table_types/feature_table.md
@@ -1,10 +1,11 @@
1
1
  from collections.abc import Collection, Iterable
2
2
  from typing import Literal
3
3
 
4
- import dask
5
- import dask.delayed
4
+ import dask.array as da
6
5
  import numpy as np
7
6
  import zarr
7
+ from dask.array import Array as DaskArray
8
+ from dask.delayed import Delayed, delayed
8
9
 
9
10
  from ngio.common._axes_transforms import transform_dask_array, transform_numpy_array
10
11
  from ngio.common._common_types import ArrayLike
@@ -55,26 +56,26 @@ def _numpy_get_pipe(
55
56
  slices: SliceTransform,
56
57
  transformations: tuple[AxesTransformation, ...],
57
58
  ) -> np.ndarray:
58
- array = numpy_get_slice(array, slices)
59
- return transform_numpy_array(array, transformations)
59
+ _array = numpy_get_slice(array, slices)
60
+ return transform_numpy_array(_array, transformations)
60
61
 
61
62
 
62
63
  def _delayed_numpy_get_pipe(
63
64
  array: zarr.Array,
64
65
  slices: SliceTransform,
65
66
  transformations: tuple[AxesTransformation, ...],
66
- ) -> dask.delayed:
67
- array = dask.delayed(numpy_get_slice)(array, slices)
68
- return dask.delayed(transform_numpy_array)(array, transformations)
67
+ ) -> Delayed:
68
+ _array = delayed(numpy_get_slice)(array, slices)
69
+ return delayed(transform_numpy_array)(_array, transformations)
69
70
 
70
71
 
71
72
  def _dask_get_pipe(
72
73
  array: zarr.Array,
73
74
  slices: SliceTransform,
74
75
  transformations: tuple[AxesTransformation, ...],
75
- ) -> dask.array:
76
- array = dask_get_slice(array, slices)
77
- return transform_dask_array(array, transformations)
76
+ ) -> DaskArray:
77
+ _array = dask_get_slice(array, slices)
78
+ return transform_dask_array(_array, transformations)
78
79
 
79
80
 
80
81
  def _numpy_set_pipe(
@@ -89,22 +90,22 @@ def _numpy_set_pipe(
89
90
 
90
91
  def _dask_set_pipe(
91
92
  array: zarr.Array,
92
- patch: np.ndarray,
93
+ patch: DaskArray,
93
94
  slices: SliceTransform,
94
95
  transformations: tuple[AxesTransformation, ...],
95
96
  ) -> None:
96
- patch = transform_dask_array(patch, transformations)
97
- dask_set_slice(array, patch, slices)
97
+ _patch = transform_dask_array(patch, transformations)
98
+ dask_set_slice(array, _patch, slices)
98
99
 
99
100
 
100
101
  def _delayed_numpy_set_pipe(
101
102
  array: zarr.Array,
102
- patch: np.ndarray,
103
+ patch: np.ndarray | Delayed,
103
104
  slices: SliceTransform,
104
105
  transformations: tuple[AxesTransformation, ...],
105
- ) -> dask.delayed:
106
- patch = dask.delayed(transform_numpy_array)(patch, transformations)
107
- return dask.delayed(numpy_set_slice)(array, patch, slices)
106
+ ) -> Delayed:
107
+ _patch = delayed(transform_numpy_array)(patch, transformations)
108
+ return delayed(numpy_set_slice)(array, _patch, slices)
108
109
 
109
110
 
110
111
  def get_pipe(
@@ -144,7 +145,7 @@ def set_pipe(
144
145
  slices, transformations = _compute_to_disk_transforms(
145
146
  dimensions=dimensions, axes_order=axes_order, **slice_kwargs
146
147
  )
147
- if isinstance(patch, dask.array.Array):
148
+ if isinstance(patch, DaskArray):
148
149
  _dask_set_pipe(
149
150
  array=array, patch=patch, slices=slices, transformations=transformations
150
151
  )
@@ -152,7 +153,7 @@ def set_pipe(
152
153
  _numpy_set_pipe(
153
154
  array=array, patch=patch, slices=slices, transformations=transformations
154
155
  )
155
- elif isinstance(patch, dask.delayed.Delayed):
156
+ elif isinstance(patch, Delayed):
156
157
  _delayed_numpy_set_pipe(
157
158
  array=array, patch=patch, slices=slices, transformations=transformations
158
159
  )
@@ -193,12 +194,15 @@ def _mask_pipe_common(
193
194
  **slice_kwargs,
194
195
  )
195
196
 
196
- if isinstance(array_patch, np.ndarray):
197
+ if isinstance(array_patch, np.ndarray) and isinstance(label_patch, np.ndarray):
197
198
  label_patch = np.broadcast_to(label_patch, array_patch.shape)
198
- elif isinstance(array_patch, dask.array.Array):
199
- label_patch = dask.array.broadcast_to(label_patch, array_patch.shape)
199
+ elif isinstance(array_patch, DaskArray) and isinstance(label_patch, DaskArray):
200
+ label_patch = da.broadcast_to(label_patch, array_patch.shape)
200
201
  else:
201
- raise NgioValueError(f"Mode {mode} not yet supported for masked array.")
202
+ raise NgioValueError(
203
+ "Incompatible types for array and label: "
204
+ f"{type(array_patch)} and {type(label_patch)}"
205
+ )
202
206
 
203
207
  mask = label_patch == label
204
208
  return array_patch, mask
@@ -225,7 +229,14 @@ def get_masked_pipe(
225
229
  mode=mode,
226
230
  **slice_kwargs,
227
231
  )
228
- array_patch[~mask] = 0
232
+ if isinstance(array_patch, np.ndarray):
233
+ array_patch[~mask] = 0
234
+ elif isinstance(array_patch, DaskArray):
235
+ array_patch = da.where(mask, array_patch, 0)
236
+ else:
237
+ raise NgioValueError(
238
+ "Mode not yet supported for masked array. Expected a numpy or dask array."
239
+ )
229
240
  return array_patch
230
241
 
231
242
 
@@ -240,7 +251,7 @@ def set_masked_pipe(
240
251
  axes_order: Collection[str] | None = None,
241
252
  **slice_kwargs: slice | int | Iterable[int],
242
253
  ):
243
- if isinstance(patch, dask.array.Array):
254
+ if isinstance(patch, DaskArray):
244
255
  mode = "dask"
245
256
  elif isinstance(patch, np.ndarray):
246
257
  mode = "numpy"
@@ -259,7 +270,19 @@ def set_masked_pipe(
259
270
  mode=mode,
260
271
  **slice_kwargs,
261
272
  )
262
- patch = np.where(mask, patch, array_patch)
273
+ if isinstance(patch, np.ndarray):
274
+ assert isinstance(array_patch, np.ndarray)
275
+ _patch = np.where(mask, patch, array_patch)
276
+ elif isinstance(patch, DaskArray):
277
+ _patch = da.where(mask, patch, array_patch)
278
+ else:
279
+ raise NgioValueError(
280
+ "Mode not yet supported for masked array. Expected a numpy or dask array."
281
+ )
263
282
  set_pipe(
264
- array, patch, dimensions=dimensions_array, axes_order=axes_order, **slice_kwargs
283
+ array,
284
+ _patch,
285
+ dimensions=dimensions_array,
286
+ axes_order=axes_order,
287
+ **slice_kwargs,
265
288
  )
@@ -57,6 +57,7 @@ class Roi(BaseModel):
57
57
  x_length=_to_raster(self.x_length, pixel_size.x, dim_x),
58
58
  y_length=_to_raster(self.y_length, pixel_size.y, dim_y),
59
59
  z_length=_to_raster(self.z_length, pixel_size.z, dim_z),
60
+ **self.model_extra,
60
61
  )
61
62
 
62
63
  def zoom(self, zoom_factor: float = 1) -> "Roi":
@@ -94,6 +95,7 @@ class RoiPixels(BaseModel):
94
95
  y_length=_to_world(self.y_length, pixel_size.y),
95
96
  z_length=_to_world(self.z_length, pixel_size.z),
96
97
  unit=pixel_size.space_unit,
98
+ **self.model_extra,
97
99
  )
98
100
 
99
101
  def to_slices(self) -> dict[str, slice]:
@@ -9,7 +9,7 @@ from typing import Literal
9
9
  import pandas as pd
10
10
  import polars as pl
11
11
 
12
- from ngio.images.ome_zarr_container import OmeZarrContainer
12
+ from ngio.images._ome_zarr_container import OmeZarrContainer
13
13
  from ngio.tables import Table, TableType
14
14
 
15
15
 
@@ -1,6 +1,6 @@
1
1
  """OME-Zarr HCS objects models."""
2
2
 
3
- from ngio.hcs.plate import (
3
+ from ngio.hcs._plate import (
4
4
  OmeZarrPlate,
5
5
  OmeZarrWell,
6
6
  create_empty_plate,
@@ -27,6 +27,7 @@ from ngio.ome_zarr_meta import (
27
27
  )
28
28
  from ngio.tables import (
29
29
  ConditionTable,
30
+ DefaultTableBackend,
30
31
  FeatureTable,
31
32
  GenericRoiTable,
32
33
  MaskingRoiTable,
@@ -39,7 +40,6 @@ from ngio.tables import (
39
40
  )
40
41
  from ngio.utils import (
41
42
  AccessModeLiteral,
42
- NgioValidationError,
43
43
  NgioValueError,
44
44
  StoreOrGroup,
45
45
  ZarrGroupHandler,
@@ -805,22 +805,38 @@ class OmeZarrPlate:
805
805
  parallel_safe=parallel_safe,
806
806
  )
807
807
 
808
- @property
809
- def tables_container(self) -> TablesContainer:
808
+ def _get_tables_container(self) -> TablesContainer | None:
810
809
  """Return the tables container."""
811
810
  if self._tables_container is None:
812
- self._tables_container = _default_table_container(self._group_handler)
813
- if self._tables_container is None:
814
- raise NgioValidationError("No tables found in the image.")
811
+ _tables_container = _default_table_container(self._group_handler)
812
+ if _tables_container is None:
813
+ return None
814
+ self._tables_container = _tables_container
815
815
  return self._tables_container
816
816
 
817
- def list_tables(self, filter_types: str | None = None) -> list[str]:
817
+ @property
818
+ def tables_container(self) -> TablesContainer:
819
+ """Return the tables container."""
820
+ _table_container = self._get_tables_container()
821
+ if _table_container is None:
822
+ raise NgioValueError(
823
+ "No tables container found. Please add a tables container to the plate."
824
+ )
825
+ return _table_container
826
+
827
+ def list_tables(self, filter_types: TypedTable | str | None = None) -> list[str]:
818
828
  """List all tables in the image."""
819
829
  return self.tables_container.list(filter_types=filter_types)
820
830
 
821
831
  def list_roi_tables(self) -> list[str]:
822
832
  """List all ROI tables in the image."""
823
- return self.tables_container.list_roi_tables()
833
+ masking_roi = self.tables_container.list(
834
+ filter_types="masking_roi_table",
835
+ )
836
+ roi = self.tables_container.list(
837
+ filter_types="roi_table",
838
+ )
839
+ return masking_roi + roi
824
840
 
825
841
  def get_roi_table(self, name: str) -> RoiTable:
826
842
  """Get a ROI table from the image.
@@ -929,7 +945,7 @@ class OmeZarrPlate:
929
945
  self,
930
946
  name: str,
931
947
  table: Table,
932
- backend: TableBackend = "anndata",
948
+ backend: TableBackend = DefaultTableBackend,
933
949
  overwrite: bool = False,
934
950
  ) -> None:
935
951
  """Add a table to the image."""
@@ -1,8 +1,8 @@
1
1
  """OME-Zarr object models."""
2
2
 
3
- from ngio.images.image import Image, ImagesContainer
4
- from ngio.images.label import Label, LabelsContainer
5
- from ngio.images.ome_zarr_container import (
3
+ from ngio.images._image import Image, ImagesContainer
4
+ from ngio.images._label import Label, LabelsContainer
5
+ from ngio.images._ome_zarr_container import (
6
6
  OmeZarrContainer,
7
7
  create_empty_ome_zarr,
8
8
  create_ome_zarr_from_array,
@@ -3,11 +3,11 @@
3
3
  from collections.abc import Collection
4
4
  from typing import Literal
5
5
 
6
- from dask import array as da
6
+ import dask.array as da
7
7
 
8
8
  from ngio.common import Dimensions
9
- from ngio.images.abstract_image import AbstractImage, consolidate_image
10
- from ngio.images.create import create_empty_image_container
9
+ from ngio.images._abstract_image import AbstractImage, consolidate_image
10
+ from ngio.images._create import create_empty_image_container
11
11
  from ngio.ome_zarr_meta import (
12
12
  ImageMetaHandler,
13
13
  NgioImageMeta,
@@ -152,31 +152,33 @@ class ImagesContainer:
152
152
 
153
153
  def set_channel_meta(
154
154
  self,
155
- labels: Collection[str] | int | None = None,
156
- wavelength_id: Collection[str] | None = None,
157
- start: Collection[float] | None = None,
158
- end: Collection[float] | None = None,
155
+ labels: Collection[str | None] | int | None = None,
156
+ wavelength_id: Collection[str | None] | None = None,
157
+ start: Collection[float | None] | None = None,
158
+ end: Collection[float | None] | None = None,
159
159
  percentiles: tuple[float, float] | None = None,
160
- colors: Collection[str] | None = None,
161
- active: Collection[bool] | None = None,
160
+ colors: Collection[str | None] | None = None,
161
+ active: Collection[bool | None] | None = None,
162
162
  **omero_kwargs: dict,
163
163
  ) -> None:
164
164
  """Create a ChannelsMeta object with the default unit.
165
165
 
166
166
  Args:
167
- labels(Collection[str] | int): The list of channels names in the image.
168
- If an integer is provided, the channels will be named "channel_i".
169
- wavelength_id(Collection[str] | None): The wavelength ID of the channel.
167
+ labels(Collection[str | None] | int): The list of channels names
168
+ in the image. If an integer is provided, the channels will
169
+ be named "channel_i".
170
+ wavelength_id(Collection[str | None]): The wavelength ID of the channel.
170
171
  If None, the wavelength ID will be the same as the channel name.
171
- start(Collection[float] | None): The start value for each channel.
172
+ start(Collection[float | None]): The start value for each channel.
172
173
  If None, the start value will be computed from the image.
173
- end(Collection[float] | None): The end value for each channel.
174
+ end(Collection[float | None]): The end value for each channel.
174
175
  If None, the end value will be computed from the image.
175
- percentiles(tuple[float, float] | None): The start and end percentiles
176
- for each channel. If None, the percentiles will not be computed.
177
- colors(Collection[str, NgioColors] | None): The list of colors for the
176
+ percentiles(tuple[float, float] | None): The start and end
177
+ percentiles for each channel. If None, the percentiles will
178
+ not be computed.
179
+ colors(Collection[str | None]): The list of colors for the
178
180
  channels. If None, the colors will be random.
179
- active (Collection[bool] | None):active(bool): Whether the channel should
181
+ active (Collection[bool | None]): Whether the channel should
180
182
  be shown by default.
181
183
  omero_kwargs(dict): Extra fields to store in the omero attributes.
182
184
  """
@@ -376,9 +378,12 @@ def compute_image_percentile(
376
378
  starts, ends = [], []
377
379
  for c in range(image.num_channels):
378
380
  if image.num_channels == 1:
379
- data = image.get_array(mode="dask").ravel()
381
+ data = image.get_array(mode="dask")
380
382
  else:
381
- data = image.get_array(c=c, mode="dask").ravel()
383
+ data = image.get_array(c=c, mode="dask")
384
+
385
+ assert isinstance(data, da.Array), "Data must be a Dask array."
386
+ data = da.ravel(data)
382
387
  # remove all the zeros
383
388
  mask = data > 1e-16
384
389
  data = data[mask]
@@ -391,7 +396,7 @@ def compute_image_percentile(
391
396
  # compute the percentiles
392
397
  _s_perc, _e_perc = da.percentile(
393
398
  data, [start_percentile, end_percentile], method="nearest"
394
- ).compute()
399
+ ).compute() # type: ignore
395
400
 
396
401
  starts.append(float(_s_perc))
397
402
  ends.append(float(_e_perc))