isoview 0.1.0__py3-none-any.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.
- isoview/__init__.py +36 -0
- isoview/array.py +11 -0
- isoview/config.py +213 -0
- isoview/corrections.py +135 -0
- isoview/fusion.py +979 -0
- isoview/intensity.py +427 -0
- isoview/io.py +942 -0
- isoview/masks.py +421 -0
- isoview/pipeline.py +913 -0
- isoview/segmentation.py +173 -0
- isoview/temporal.py +373 -0
- isoview/transforms.py +1115 -0
- isoview/viz.py +723 -0
- isoview-0.1.0.dist-info/METADATA +370 -0
- isoview-0.1.0.dist-info/RECORD +17 -0
- isoview-0.1.0.dist-info/WHEEL +4 -0
- isoview-0.1.0.dist-info/entry_points.txt +2 -0
|
@@ -0,0 +1,370 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: isoview
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: Multi-view light sheet microscopy image processing pipeline
|
|
5
|
+
Project-URL: Homepage, https://github.com/MillerBrainObservatory/isoview
|
|
6
|
+
Project-URL: Repository, https://github.com/MillerBrainObservatory/isoview
|
|
7
|
+
Author: Miller Brain Observatory
|
|
8
|
+
License: MIT
|
|
9
|
+
Classifier: Development Status :: 3 - Alpha
|
|
10
|
+
Classifier: Intended Audience :: Science/Research
|
|
11
|
+
Classifier: Programming Language :: Python :: 3
|
|
12
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
13
|
+
Classifier: Topic :: Scientific/Engineering :: Bio-Informatics
|
|
14
|
+
Classifier: Topic :: Scientific/Engineering :: Image Processing
|
|
15
|
+
Requires-Python: ==3.12.9
|
|
16
|
+
Requires-Dist: cellpose>=3.0.0
|
|
17
|
+
Requires-Dist: dask[array]>=2024.1.0
|
|
18
|
+
Requires-Dist: fsspec>=2023.12.0
|
|
19
|
+
Requires-Dist: glfw>=2.8.0
|
|
20
|
+
Requires-Dist: h5py>=3.10.0
|
|
21
|
+
Requires-Dist: imageio>=2.31.0
|
|
22
|
+
Requires-Dist: ipywidgets>=8.1.0
|
|
23
|
+
Requires-Dist: jupyterlab
|
|
24
|
+
Requires-Dist: jupyterlab-vim>=4.1.0
|
|
25
|
+
Requires-Dist: matplotlib>=3.7.0
|
|
26
|
+
Requires-Dist: mbo-fastplotlib[imgui,notebook]
|
|
27
|
+
Requires-Dist: mbo-utilities
|
|
28
|
+
Requires-Dist: numpy<3.0,>=1.26.0
|
|
29
|
+
Requires-Dist: ome-zarr>=0.9.0
|
|
30
|
+
Requires-Dist: opencv-python>=4.8.0
|
|
31
|
+
Requires-Dist: pyklb>=0.3.0
|
|
32
|
+
Requires-Dist: scikit-image>=0.22.0
|
|
33
|
+
Requires-Dist: scikit-learn>=1.3.0
|
|
34
|
+
Requires-Dist: scipy>=1.11.0
|
|
35
|
+
Requires-Dist: tifffile>=2023.7.0
|
|
36
|
+
Requires-Dist: xmltodict>=0.13.0
|
|
37
|
+
Requires-Dist: zarr>=3.0.0
|
|
38
|
+
Provides-Extra: dev
|
|
39
|
+
Requires-Dist: mypy>=1.5.0; extra == 'dev'
|
|
40
|
+
Requires-Dist: pytest-cov>=4.1.0; extra == 'dev'
|
|
41
|
+
Requires-Dist: pytest>=7.4.0; extra == 'dev'
|
|
42
|
+
Requires-Dist: ruff>=0.0.280; extra == 'dev'
|
|
43
|
+
Description-Content-Type: text/markdown
|
|
44
|
+
|
|
45
|
+
# Isoview Pipeline: MATLAB -> Python
|
|
46
|
+
|
|
47
|
+
*Conversion/Validation TODO*
|
|
48
|
+
|
|
49
|
+
- [x] readKLB.m
|
|
50
|
+
- [x] clusterPT_RC.m
|
|
51
|
+
- [x] clusterPT with zarr benchmarks
|
|
52
|
+
- [ ] clusterMF.m
|
|
53
|
+
|
|
54
|
+
Note: Multiprocessing is not yet implemented, as it is in the MATLAB pipeline.
|
|
55
|
+
|
|
56
|
+
---
|
|
57
|
+
|
|
58
|
+
## `readKLB.m` -> `pyklb`
|
|
59
|
+
|
|
60
|
+
Using our fork of [pyklb](https://github.com/MillerBrainObservatory/pyklb), on [pypi](https://pypi.org/project/pyklb/).
|
|
61
|
+
|
|
62
|
+
**1. Generate MATLAB Reference**
|
|
63
|
+
|
|
64
|
+
```bash
|
|
65
|
+
matlab -batch \
|
|
66
|
+
"run('C://Users//RBO//repos//isoview//excludes//save_matlab_klb.m')"
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
**2. Validate with Python**
|
|
70
|
+
|
|
71
|
+
```bash
|
|
72
|
+
uv run --no-sync python excludes/test_klb_matlab_python.py
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
| File | MATLAB Shape | Python Shape | Max Diff |
|
|
76
|
+
|------|--------------|--------------|----------|
|
|
77
|
+
| SPM00_TM000000_CM00_CHN00.klb | (2048, 2048, 543) | (543, 2048, 2048) -> (2048, 2048, 543) | 0.0 |
|
|
78
|
+
| SPM00_TM000000_CM01_CHN00.klb | (2048, 2048, 543) | (543, 2048, 2048) -> (2048, 2048, 543) | 0.0 |
|
|
79
|
+
| SPM00_TM000000_CM02_CHN01.klb | (2048, 2048, 592) | (592, 2048, 2048) -> (2048, 2048, 592) | 0.0 |
|
|
80
|
+
| SPM00_TM000000_CM03_CHN01.klb | (2048, 2048, 592) | (592, 2048, 2048) -> (2048, 2048, 592) | 0.0 |
|
|
81
|
+
|
|
82
|
+
**Total:** 4/4 files exactly equal (100%)
|
|
83
|
+
|
|
84
|
+
- **MATLAB**: Stores volumes as `(Y, X, Z)` = `(2048, 2048, 543/592)`
|
|
85
|
+
- **Python pyklb**: Returns volumes as `(Z, Y, X)` = `(543/592, 2048, 2048)`
|
|
86
|
+
|
|
87
|
+
---
|
|
88
|
+
|
|
89
|
+
## clusterPT_RC.m
|
|
90
|
+
|
|
91
|
+
D:\W2_DATA\foconnell\isoview_development\mosquito-larva_20250930_165806.corrected\SPM00\TM000000
|
|
92
|
+
|
|
93
|
+
**File structure**
|
|
94
|
+
|
|
95
|
+
```
|
|
96
|
+
project_root\
|
|
97
|
+
SPM00\
|
|
98
|
+
Background_0.tif (one per camera)
|
|
99
|
+
Background_1.tif
|
|
100
|
+
Background_2.tif
|
|
101
|
+
Background_3.tif
|
|
102
|
+
TM00000\ (one folder per timepoint)
|
|
103
|
+
ch0.xml (rename from ch00_spec00.xml)
|
|
104
|
+
ch1.xml (rename from ch01_spec00.xml)
|
|
105
|
+
ANG000\
|
|
106
|
+
SPC00_TM00000_ANG000_CM0_CHN00_PH0.stack
|
|
107
|
+
SPC00_TM00000_ANG000_CM1_CHN00_PH0.stack
|
|
108
|
+
SPC00_TM00000_ANG000_CM2_CHN01_PH0.stack
|
|
109
|
+
SPC00_TM00000_ANG000_CM3_CHN01_PH0.stack
|
|
110
|
+
```
|
|
111
|
+
|
|
112
|
+
```matlab
|
|
113
|
+
inputFolder = 'D:\W2_DATA\foconnell\isoview_development\mosquito-larva_20250930_165806';
|
|
114
|
+
inputType = 2;
|
|
115
|
+
specimen = 0;
|
|
116
|
+
|
|
117
|
+
% Run 1: Cameras 0,1 with Channel 0
|
|
118
|
+
cameras = [0 1];
|
|
119
|
+
channels = 0;
|
|
120
|
+
|
|
121
|
+
% Run 2: Cameras 2,3 with Channel 1
|
|
122
|
+
cameras = [2 3];
|
|
123
|
+
channels = 1;
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
1. Background TIFFs: Place in SPM00 root (one per camera)
|
|
127
|
+
2. XML files: Rename ch00_spec00.xml to ch0.xml, ch01_spec00.xml to ch1.xml
|
|
128
|
+
3. XML files: Copy to each TM folder (TM00000, TM00001, etc.)
|
|
129
|
+
|
|
130
|
+
### Comparison
|
|
131
|
+
|
|
132
|
+
See the full notebook [here](https://github.com/MillerBrainObservatory/isoview/blob/master/clusterPT_comparison.ipynb)
|
|
133
|
+
|
|
134
|
+
Most of the differences happen in the non-dense regions on the edge of the FOV:
|
|
135
|
+
|
|
136
|
+
<img width="1097" height="508" alt="Image" src="https://github.com/user-attachments/assets/bf06d440-24f9-41d0-a5f7-c2f8737b7281" />
|
|
137
|
+
|
|
138
|
+
---
|
|
139
|
+
|
|
140
|
+
## clusterMF.m
|
|
141
|
+
|
|
142
|
+
Multi-view fusion pipeline. Python implementation in `isoview/fusion.py`.
|
|
143
|
+
|
|
144
|
+
**MATLAB equivalent**
|
|
145
|
+
|
|
146
|
+
```matlab
|
|
147
|
+
inputFolder = 'D:\W2_DATA\foconnell\isoview_development\mosquito-larva_20250930_165806.corrected_python_zarr';
|
|
148
|
+
specimen = 0;
|
|
149
|
+
timepoints = 0;
|
|
150
|
+
cameras = [0 1 2 3];
|
|
151
|
+
channels = [0 1];
|
|
152
|
+
|
|
153
|
+
% Fusion parameters
|
|
154
|
+
fusionType = 1; % adaptive blending
|
|
155
|
+
blendingRange = [20 4]; % [channel, camera]
|
|
156
|
+
cameraPairs = [0 1; 2 3];
|
|
157
|
+
flipH = true;
|
|
158
|
+
flipV = false;
|
|
159
|
+
```
|
|
160
|
+
|
|
161
|
+
**Python equivalent**
|
|
162
|
+
|
|
163
|
+
```python
|
|
164
|
+
from isoview import ProcessingConfig, fuse
|
|
165
|
+
|
|
166
|
+
config = ProcessingConfig(
|
|
167
|
+
input_dir=Path("D:/W2_DATA/.../mosquito-larva_20250930_165806.corrected_python_zarr"),
|
|
168
|
+
output_dir=Path("D:/W2_DATA/.../mosquito-larva_20250930_165806.corrected_python_zarr"),
|
|
169
|
+
specimen=0,
|
|
170
|
+
timepoints=[0],
|
|
171
|
+
cameras=[0, 1, 2, 3],
|
|
172
|
+
channels=[0, 1],
|
|
173
|
+
fusion_enable=True,
|
|
174
|
+
fusion_type="adaptive_blending",
|
|
175
|
+
fusion_blending_range=(20, 4),
|
|
176
|
+
fusion_camera_pairs=[(0, 1), (2, 3)],
|
|
177
|
+
fusion_flip_h=True,
|
|
178
|
+
fusion_flip_v=False,
|
|
179
|
+
)
|
|
180
|
+
|
|
181
|
+
fuse(config, estimate_params=True, apply_fusion=True)
|
|
182
|
+
```
|
|
183
|
+
|
|
184
|
+
### Feature Flags
|
|
185
|
+
|
|
186
|
+
All MATLAB clusterMF features are available as config flags (disabled by default):
|
|
187
|
+
|
|
188
|
+
| Feature | MATLAB | Python Flag |
|
|
189
|
+
|---------|--------|-------------|
|
|
190
|
+
| Temporal smoothing | rloess | `fusion_temporal_smoothing=True` |
|
|
191
|
+
| Smoothing window | smoothingRange | `fusion_smoothing_window=100` |
|
|
192
|
+
| Static parameters | staticFlag | `fusion_static=True` |
|
|
193
|
+
| Mask fusion mode | maskFusionMode | `fusion_mask_fusion_mode=1` |
|
|
194
|
+
| Mask padding | padding | `fusion_mask_padding=2` |
|
|
195
|
+
| Small object removal | bwareaopen | `fusion_mask_min_object_size=1e-5` |
|
|
196
|
+
| Slab processing | slabSize | `fusion_slab_size_cameras=3` |
|
|
197
|
+
| Median filtering | medianFilterRange | `fusion_median_filter_range=100` |
|
|
198
|
+
| Gaussian precision | preciseGauss | `fusion_precise_gauss=True` |
|
|
199
|
+
| Lookup tables | generateLUT | `fusion_generate_lookup_table=True` |
|
|
200
|
+
|
|
201
|
+
See [MATLAB_FEATURES.md](MATLAB_FEATURES.md) for complete documentation.
|
|
202
|
+
|
|
203
|
+
### Diagnostic Output
|
|
204
|
+
|
|
205
|
+
Pipeline generates diagnostic PNGs when `save_diagnostics=True` (default):
|
|
206
|
+
|
|
207
|
+
```
|
|
208
|
+
output_dir/
|
|
209
|
+
diagnostics/
|
|
210
|
+
TM000000/
|
|
211
|
+
cam0_1/
|
|
212
|
+
registration.png
|
|
213
|
+
intensity_correction.png
|
|
214
|
+
fusion_result.png
|
|
215
|
+
blending_weights.png
|
|
216
|
+
fused_overview.png
|
|
217
|
+
```
|
|
218
|
+
|
|
219
|
+
---
|
|
220
|
+
|
|
221
|
+
## Zarr I/O Integration and Benchmarks
|
|
222
|
+
|
|
223
|
+
**Dataset Parameters**
|
|
224
|
+
|
|
225
|
+
- Data volume: (543, 2048, 2048) uint16
|
|
226
|
+
- Uncompressed size: 4344.00 MB (4.242 GB)
|
|
227
|
+
- Pixel spacing: [2.0, 0.406, 0.406] um
|
|
228
|
+
- Chunk size: (10, 128, 128)
|
|
229
|
+
|
|
230
|
+
### Quick Compression Performance
|
|
231
|
+
|
|
232
|
+
Based on a single raw `.stack` from a mosquito recorded on isoview: `mosquito-larva_20250930_165806`
|
|
233
|
+
|
|
234
|
+
| Method | Compression | Level | Write (s) | Read (s) | Size (MB) | Ratio | Write Speed (GB/s) | Read Speed (GB/s) |
|
|
235
|
+
|--------|-------------|-------|-----------|----------|-----------|-------|-------------------|-------------------|
|
|
236
|
+
| blosc-zstd-5-sharded | blosc-zstd | 5 | 42.71 | 2.55 | 1780.3 | 2.44x | 0.099 | 1.663 |
|
|
237
|
+
| blosc-zstd-9-sharded | blosc-zstd | 9 | 52.96 | 2.52 | 1679.5 | 2.59x | 0.080 | 1.682 |
|
|
238
|
+
| blosc-lz4-3-sharded | blosc-lz4 | 3 | 40.12 | 2.50 | 2205.0 | 1.97x | 0.106 | 1.698 |
|
|
239
|
+
| blosc-zstd-5-no-shard | blosc-zstd | 5 | 44.99 | 2.25 | 1780.3 | 2.44x | 0.094 | 1.887 |
|
|
240
|
+
| blosc-lz4-3-no-shard | blosc-lz4 | 3 | 44.01 | 2.50 | 2205.0 | 1.97x | 0.096 | 1.698 |
|
|
241
|
+
| none-sharded | none | 0 | 45.34 | 2.28 | 4344.0 | 1.00x | 0.094 | 1.863 |
|
|
242
|
+
| none-no-shard | none | 0 | 52.18 | 1.90 | 4344.0 | 1.00x | 0.081 | 2.237 |
|
|
243
|
+
|
|
244
|
+
### Pipeline Compression Performance
|
|
245
|
+
|
|
246
|
+
Now, instead of converting a `.stack`, we run the full `clusterPT` pipeline and compare `.tiff`, `.klb` and `.zarr`.
|
|
247
|
+
|
|
248
|
+
From the KLB source code (`keller-lab-block-filetype/src/klb_imageIO.cpp`):
|
|
249
|
+
|
|
250
|
+
```cpp
|
|
251
|
+
int BWTblockSize = 9; // maximum compression
|
|
252
|
+
// compress the memory buffer (blocksize=9*100k, verbose=0, worklevel=30)
|
|
253
|
+
int ret = BZ2_bzBuffToBuffCompress(bufferOutPtr, &sizeCompressed,
|
|
254
|
+
bufferIn, gcount, BWTblockSize, 0, 30);
|
|
255
|
+
```
|
|
256
|
+
|
|
257
|
+
**KLB uses bzip2 with level 9** (block size 9x100k = 900,000 bytes)
|
|
258
|
+
|
|
259
|
+
```
|
|
260
|
+
Testing 11 configurations:
|
|
261
|
+
|
|
262
|
+
Baselines:
|
|
263
|
+
KLB_bzip2_9 - KLB format with bzip2, level 9 (block size 9x100k)
|
|
264
|
+
TIFF_uncompressed - Uncompressed TIFF for size reference
|
|
265
|
+
|
|
266
|
+
Zarr configurations (all with sharding: 10 frames/shard, 1 frame/chunk, full FOV):
|
|
267
|
+
Zarr_bzip2_9 - bzip2 level 9 (match KLB)
|
|
268
|
+
Zarr_zstd_6 - blosc-zstd at level 6
|
|
269
|
+
Zarr_zstd_9 - blosc-zstd at level 9
|
|
270
|
+
Zarr_lz4_6 - blosc-lz4 at level 6
|
|
271
|
+
Zarr_lz4_9 - blosc-lz4 at level 9
|
|
272
|
+
Zarr_lz4hc_6 - blosc-lz4hc at level 6
|
|
273
|
+
Zarr_lz4hc_9 - blosc-lz4hc at level 9
|
|
274
|
+
Zarr_gzip_6 - gzip at level 6
|
|
275
|
+
Zarr_gzip_9 - gzip at level 9
|
|
276
|
+
```
|
|
277
|
+
|
|
278
|
+
<img width="843" height="364" alt="Image" src="https://github.com/user-attachments/assets/0764e115-b731-4075-b1e9-43997a4c11d7" />
|
|
279
|
+
|
|
280
|
+
## Compression Benchmark Results
|
|
281
|
+
|
|
282
|
+
Tested on dataset: (543, 2048, 2048) uint16, ~4.24 GB uncompressed
|
|
283
|
+
|
|
284
|
+
| Format | Compression | Level | Size (MB) | Ratio | vs Uncompressed |
|
|
285
|
+
|--------|-------------|-------|-----------|-------|-----------------|
|
|
286
|
+
| **KLB_bzip2_9** | bzip2 | 9 | 1107.99 | **3.92x** | **74.5% reduction** |
|
|
287
|
+
| Zarr_bzip2_9 | bzip2 | 9 | 1127.56 | 3.85x | 74.0% reduction |
|
|
288
|
+
| Zarr_zstd_9 | blosc-zstd | 9 | 1255.15 | 3.46x | 71.1% reduction |
|
|
289
|
+
| Zarr_zstd_6 | blosc-zstd | 6 | 1297.95 | 3.35x | 70.1% reduction |
|
|
290
|
+
| Zarr_lz4hc_9 | blosc-lz4hc | 9 | 1332.07 | 3.26x | 69.3% reduction |
|
|
291
|
+
| Zarr_lz4hc_6 | blosc-lz4hc | 6 | 1337.21 | 3.25x | 69.2% reduction |
|
|
292
|
+
| Zarr_gzip_9 | gzip | 9 | 1434.98 | 3.03x | 67.0% reduction |
|
|
293
|
+
| Zarr_gzip_6 | gzip | 6 | 1457.96 | 2.98x | 66.4% reduction |
|
|
294
|
+
| Zarr_lz4_9 | blosc-lz4 | 9 | 1517.57 | 2.86x | 65.1% reduction |
|
|
295
|
+
| Zarr_lz4_6 | blosc-lz4 | 6 | 1519.42 | 2.86x | 65.0% reduction |
|
|
296
|
+
| TIFF_uncompressed | none | - | 4344.13 | 1.00x | - |
|
|
297
|
+
|
|
298
|
+
---
|
|
299
|
+
|
|
300
|
+
## Module Overview
|
|
301
|
+
|
|
302
|
+
### Core Pipeline
|
|
303
|
+
|
|
304
|
+
| Module | Description | Key Functions |
|
|
305
|
+
|--------|-------------|---------------|
|
|
306
|
+
| `pipeline.py` | Main processing orchestrator | `IsoviewProcessor`, `process_dataset()` |
|
|
307
|
+
| `config.py` | All configuration flags | `ProcessingConfig` dataclass |
|
|
308
|
+
| `io.py` | File I/O (klb, tiff, zarr, stack) | `read_volume()`, `write_volume()`, `read_xml_metadata()` |
|
|
309
|
+
| `array.py` | Lazy loader for processed data | `IsoviewArray` class |
|
|
310
|
+
|
|
311
|
+
### Image Processing
|
|
312
|
+
|
|
313
|
+
| Module | Description | Key Functions |
|
|
314
|
+
|--------|-------------|---------------|
|
|
315
|
+
| `corrections.py` | Dead pixel detection/correction | `correct_dead_pixels()`, `estimate_background()` |
|
|
316
|
+
| `segmentation.py` | Foreground segmentation | `segment_foreground()`, `fuse_masks()`, `create_coordinate_masks()` |
|
|
317
|
+
| `transforms.py` | Geometric transforms | `rotate_volume()`, `flip_volume()`, `crop_volume()`, `estimate_registration()`, `apply_registration()` |
|
|
318
|
+
|
|
319
|
+
### Fusion Pipeline
|
|
320
|
+
|
|
321
|
+
| Module | Description | Key Functions |
|
|
322
|
+
|--------|-------------|---------------|
|
|
323
|
+
| `fusion.py` | Multi-view fusion | `fuse()`, `blend_views()` |
|
|
324
|
+
| `temporal.py` | Temporal parameter processing | `smooth_parameters_rloess()`, `apply_temporal_averaging()`, `create_lookup_table()` |
|
|
325
|
+
| `masks.py` | Mask processing for fusion | `combine_masks()`, `pad_mask_to_center()`, `apply_bwareaopen()` |
|
|
326
|
+
| `intensity.py` | Intensity correction/filtering | `apply_median_filter()`, `apply_gauss_filter()` |
|
|
327
|
+
|
|
328
|
+
### Utilities
|
|
329
|
+
|
|
330
|
+
| Module | Description | Key Functions |
|
|
331
|
+
|--------|-------------|---------------|
|
|
332
|
+
| `viz.py` | Diagnostic visualization | `plot_projections()`, `plot_registration_result()`, `plot_fusion_result()`, `plot_volume_overview()` |
|
|
333
|
+
|
|
334
|
+
### Public API
|
|
335
|
+
|
|
336
|
+
```python
|
|
337
|
+
from isoview import (
|
|
338
|
+
ProcessingConfig, # configuration dataclass
|
|
339
|
+
IsoviewProcessor, # main processor class
|
|
340
|
+
process_dataset, # process clusterPT pipeline
|
|
341
|
+
fuse, # run clusterMF fusion
|
|
342
|
+
blend_views, # blend two registered views
|
|
343
|
+
temporal, # temporal processing submodule
|
|
344
|
+
viz, # visualization submodule
|
|
345
|
+
)
|
|
346
|
+
```
|
|
347
|
+
|
|
348
|
+
### IsoviewArray
|
|
349
|
+
|
|
350
|
+
Lazy loader for processed data with napari/visualization tool compatibility:
|
|
351
|
+
|
|
352
|
+
```python
|
|
353
|
+
from isoview.array import IsoviewArray
|
|
354
|
+
|
|
355
|
+
arr = IsoviewArray("path/to/output/TM000000")
|
|
356
|
+
|
|
357
|
+
# Shape: (Z, Views, Y, X) for single timepoint
|
|
358
|
+
# Shape: (T, Z, Views, Y, X) for multi-timepoint
|
|
359
|
+
print(arr.shape) # (543, 4, 2048, 2048)
|
|
360
|
+
print(arr.views) # [(0, 0), (1, 0), (2, 1), (3, 1)]
|
|
361
|
+
print(arr.metadata) # microscope metadata dict
|
|
362
|
+
|
|
363
|
+
# Lazy indexing
|
|
364
|
+
frame = arr[100, 0] # single Z-slice, first view
|
|
365
|
+
volume = arr[:, 0] # full Z-stack, first view
|
|
366
|
+
|
|
367
|
+
# Access labels/projections (consolidated structure)
|
|
368
|
+
mask = arr.get_labels(timepoint=0, camera=0, label_type='segmentation')
|
|
369
|
+
proj = arr.get_projection(timepoint=0, camera=0, proj_type='xy')
|
|
370
|
+
```
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
isoview/__init__.py,sha256=OJ9RNLyYcfWovPFemypkrDd9juBYizSQlgA49RcdzNw,927
|
|
2
|
+
isoview/array.py,sha256=h2ovjPQKjrdmP1aouVn9vTJxTPYiAIrAvFrNHtVhzJg,329
|
|
3
|
+
isoview/config.py,sha256=V9tLk2rEz7wVxYQImxa1XPDOzOlNi7KHvXZvXG5Ee6o,10000
|
|
4
|
+
isoview/corrections.py,sha256=8GIHT-0UEmrvq5ffKQyl8aWvEMYBhDv9_dGBA28c-DQ,4182
|
|
5
|
+
isoview/fusion.py,sha256=d1d8F1ggzf6XiNzkaSnY4FtpMTuPDqpcC_cLDaUT9is,36911
|
|
6
|
+
isoview/intensity.py,sha256=hZaaPyC2wJ7oWzyXqbOQjrQHJfXl-V_RoCGltfrwwrU,12369
|
|
7
|
+
isoview/io.py,sha256=PApW31HgrIcxtXocv3NP86JbCUhVO8d7ZLWf53FuCZI,33232
|
|
8
|
+
isoview/masks.py,sha256=fFJuXuKnA1mdUPjdUFRzcPU4c4GgNLfrp0I2mwLolBk,12089
|
|
9
|
+
isoview/pipeline.py,sha256=uT-fyAgityg8rE4RxI5e06qWNq-wlRUWPE_DLJBU-eM,35437
|
|
10
|
+
isoview/segmentation.py,sha256=nl8lAEQw-68ybwZTE6CQ1paDOVLXmfZ-n2SLMQOUzBs,6332
|
|
11
|
+
isoview/temporal.py,sha256=M_eVSLSkXBhaF0uTucGNFZ2izDJw7SaXVG3GXG1J3A4,11289
|
|
12
|
+
isoview/transforms.py,sha256=hmmP30i8Le1Xe1Zl_lDQbEOiW2yQU5naP3OQfInNcWc,32471
|
|
13
|
+
isoview/viz.py,sha256=mYAI61p70Pe6V9kt0TttEk_1-oL2Sc5DXUeZtd6a-ww,26256
|
|
14
|
+
isoview-0.1.0.dist-info/METADATA,sha256=URGKvkHBkx69JlohllHUVzJKOwUZgTW-iDWYkHj7_zM,13185
|
|
15
|
+
isoview-0.1.0.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
|
|
16
|
+
isoview-0.1.0.dist-info/entry_points.txt,sha256=14TDYPl9a12ot5K6j-aW042aacgUjiq0Stmeyx2wyVQ,45
|
|
17
|
+
isoview-0.1.0.dist-info/RECORD,,
|