You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
MitosisAnalyzer is reading image files using the [Bioio](https://github.com/bioio-devs/bioio) package. A variety of plugins exist to support common image file formats, including .tiff, .ome-tiff, .zarr, .nd2, .czi, .lif, etc.. By installing these additional bioio plugins you can easily expand MitosisAnalyzer's ability to process a large variety of image files without the need to touch the source code.
-i INPUT, --input INPUT .nd2 file or directory with .nd2 files to be processed
34
-
-o OUTPUT, --output OUTPUT output file or directory
35
-
-s SPINDLE, --spindle SPINDLE channel # for tracking spindle poles
36
-
-d DNA, --dna DNA channel # for tracking dna
37
-
-r REFFRAME, --refframe REFFRAME reference frame to determine spindle pole axis (0=autodetect based on cell long axis)
38
-
-t THRESHOLD, --threshold THRESHOLD threshold of cytoplasmic background signal in spindle channel; value relative to max
39
-
spindle intensity 0.0-1.0 (0.0=autodetect using Otsu)
40
-
-b BLUR, --blur BLUR applies a gaussian blur before segmenting spindle poles. The value determines the
41
-
blurring radius; a value of 0 omits blurring.
42
-
-c, --cellpose, --no-cellpose use Cellpose to detect cell contour
43
-
-f FRAMERATE, --framerate FRAMERATE number of frames per second
44
-
-e EXECUTOR, --executor EXECUTOR set executor. Options: sequential, concurrent, dask
45
-
-p PROCESSES, --processes PROCESSES number or parallel processes
35
+
-h, --help show this help message and exit
36
+
-i INPUT, --input INPUT .nd2 file or directory with .nd2 files to be processed
37
+
-o OUTPUT, --output OUTPUT output file or directory
38
+
-s SPINDLE, --spindle SPINDLE channel # for tracking spindle poles
39
+
-d DNA, --dna DNA channel # for tracking dna
40
+
-r REFFRAME, --refframe REFFRAME reference frame to determine spindle pole axis (0=autodetect based on cell long axis)
41
+
-t THRESHOLD, --threshold THRESHOLD threshold of cytoplasmic background signal in spindle channel; value relative to max
42
+
spindle intensity 0.0-1.0 (0.0=autodetect using Otsu)
43
+
-b BLUR, --blur BLUR applies a gaussian blur before segmenting spindle poles. The value determines the
44
+
blurring radius; a value of 0 omits blurring.
45
+
-c, --cellpose, --no-cellpose use Cellpose to detect cell contour
46
+
-f FRAMERATE, --framerate FRAMERATE number of frames per second
47
+
-e EXECUTOR, --executor EXECUTOR set executor. Options: sequential, concurrent, dask
48
+
--address ADDRESS provide address to existing Dask Scheduler. Default: local, spins up a new Dask
49
+
scheduler and clients on localhost using the --process and --threads options.
50
+
--processes PROCESSES number of parallel processes. Ignored when --adress is set.
51
+
--threads THREADS number of threads per process. Ignored when --address is set.
46
52
```
47
53
54
+
## Advanced Settings
55
+
56
+
### Prefect
57
+
58
+
Processing of images is orchestrated as [Prefect](https://www.prefect.io/) workflows. You may set up a Prefect API key which enables you to authenticate a local environment to work with [Prefect Cloud](https://docs.prefect.io/v3/manage/cloud/index). **Prefect Cloud is an *optional* tool to help you observe execution of your analysis pipeline; the MitosisAnalyzer executes just fine without Prefect Cloud.**
59
+
60
+
### Dask
61
+
62
+
By default, MitosisAnalyzer is executing pipeline tasks in concurrent mode on a single computer/node, i.e. **local concurrent mode** mode. For large processing workloads that involve very large or many image files, you may choose to distribute tasks via [Dask](https://www.dask.org/) using the `-e/--executor` flag, see above. By default, a local Dask cluster is spun up with the specified number of processes, each process with a single thread. The `--processes` and `--threads` options override these defaults and set the number of workers (processess) and threads per worker process. The local Dask Cluster is torn down after the analysis run is finished. However, you may connect execution of the MitosisAnalyzer pipeline to an existing cluster, using the `--cluster` command line argument, see above. The existing Dask cluster may run locally or on a different host, assuming that host can be reached from your execution environment.
63
+
64
+
When using the `-e dask` option, images are read as delayed Dask arrays, meaning that IO operations occur only for the image chunks needed at the specific computational step. This a large component contributing to the pipeline's scalability.
65
+
66
+
**Additonal environment variables:**
67
+
68
+
*DASK_CHUNK_DIMS*
69
+
70
+
By default image data are read as `ZYX` chunks, meaning that a single flocal plane is read to memory at a time. This offers maximal potential to scale out to distribute the large datasets but can impact overall performance. For relatively small image files, you likely get better performance by defining a different strategy to chunk the data. For example, if your dataset has a single focal plane (Z=1), the timeseries analysis will likely perform faster using `TYX` chunking.
71
+
72
+
You can set the chunking strategy via environment variable like so:
73
+
```
74
+
export DASK_CHUNK_DIMS=TYX
75
+
```
76
+
77
+
*DASK_PERSIST_INPUT*
78
+
79
+
When `DASK_PERSIST_INPUT` is set to `1` (or `"True"`), image dask arrays are persisted in memory. This can provide a significant performance boost for small image arrays. However, large image arrays may produce an out-of-memory error.
80
+
81
+
For example:
82
+
```
83
+
DASK_PERSIST_INPUT=1
84
+
```
85
+
86
+
*DASK_PERFORMANCE_REPORT*
87
+
88
+
When `DASK_PERFORMANCE_REPORT` is specified, the dask scheduler will write a performance report in html format to this location. The file location must be writeable by the dask scheduler.
0 commit comments