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
{{ message }}
This repository was archived by the owner on Feb 26, 2025. It is now read-only.
Copy file name to clipboardExpand all lines: flatmap/README.md
+18-16Lines changed: 18 additions & 16 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,10 +4,10 @@
4
4
5
5
Contents:
6
6
7
-
+`flatpath`: C code to compute streamline-related tasks.
7
+
+`flatpath`: C code to compute streamlines and streamline-derived quantities.
8
8
+`metrics`: Python code to compute flatmap metrics.
9
-
+`surf_cgal`: C++ code for CGAL-powered code to work with meshes.
10
-
+`utils`: mostly Python scripts and two AWK helper scripts to perform various tasks.
9
+
+`surf_cgal`: C++ code using CGALto work with meshes (flattening, etc.).
10
+
+`utils`: Python helper scripts to perform various tasks.
11
11
12
12
To compile:
13
13
@@ -18,15 +18,16 @@ To compile:
18
18
19
19
## Workflow
20
20
21
-
Contents (stages):
21
+
Stages:
22
22
23
23
+`01_stageI`: run stage I "flat mesh generation", independent from stage II.
24
24
+`02_stageII`: run stage II "voxel projection", independent from stage I.
25
25
+`03_stageIII`: run stage III "flatmap generation", depends on stages I and II.
26
-
+`metrics`: run metrics for flatmap characterization, with the flatmap generated in stage III.
27
-
+`applications`: run applications of flatmaps, with the flatmap generated in stage III.
26
+
+`postproc`: perform post-processing tasks, with the flatmap generated in stage III.
27
+
+`metrics`: compute metrics for flatmap characterization, with the flatmap generated in stage III.
28
+
+`applications`: implement applications of flatmaps, with the flatmap generated in stage III.
28
29
29
-
The flatmapping workflow is implemented using Makefiles. Each stage has multiple steps, each with clearly defined `input` and `output` files. The workflow is designed to be self-contained, and no user modification of files is required (except paths to optional programs in `config.mk`).
30
+
The flatmapping workflow is implemented using Makefiles. Each stage has multiple steps, each with clearly defined `input` and `output` files. The workflow is designed to be self-contained, and no user modification of files is required (except possibly paths to binaries in `config.mk`).
30
31
31
32
To create a flatmap:
32
33
@@ -41,13 +42,14 @@ To create a flatmap:
41
42
42
43
### Input file requirements
43
44
44
-
+`config.mk`: configuration file tuning the flatmapping algorithm. Use the provided `user_config_sscx.mk` or `user_config_isocortex.mk` as examples.
45
-
+`relative_depth.nrrd`: relative depth field as 32-bit floating-point (float) NRRD dataset. Values must be 1 at the top shell and 0 at the bottom shell. Background value must be NaN.
46
-
+`orientation_{x,y,z}.nrrd`: components of the local orientation vector as 32-bit floating-point (float) NRRD datasets. Background value must be 0. The vector must point towards the top shell (where `relative_depth.nrrd` is 1).
47
-
+`annotations.nrrd` (optional): region labels as an integer NRRD dataset. Used to visualize the flatmap in `applications/flatview_annotations`.
48
-
+`mask.nrrd` (optional): labeling of inner (1) and outer (0) voxels, and top (4) / sides (2) / bottom (3) shells, as an integer NRRD dataset.
45
+
NRRD datasets must include voxel dimensions and space origin metadata, and must have the same data dimensions. Check files in Zenodo repo for examples. Preferably generate/save these files using the Python package `voxcell`.
49
46
50
-
+ NRRD datasets must include voxel dimensions and space origin metadata, and must have the same data dimensions. Check files in Zenodo repo for examples. Preferably generate/save these files using the Python package `voxcell`.
47
+
+`config.mk`: configuration file for the flatmapping algorithm. For example, see the provided [user_config_sscx.mk](examples/user_config_sscx.mk) or [user_config_isocortex.mk](examples/user_config_isocortex.mk).
48
+
+`relative_depth.nrrd`: relative depth field as 32-bit floating-point NRRD dataset. Values must be 1 at the top shell and 0 at the bottom shell. Background value must be NaN.
49
+
+`orientation_{x,y,z}.nrrd`: components of the local orientation vector as 32-bit floating-point NRRD datasets. Background value must be 0. The vector must point towards the top shell (where `relative_depth.nrrd` is 1).
50
+
+`annotations.nrrd` (optional): sequential region labels as an integer NRRD dataset. Used to visualize region annotations in flat space in `applications/flatview_annotations`.
51
+
+`mask.nrrd` (optional): labeling of inner (1) and outer (0) voxels, and top (4) / sides (2) / bottom (3) shells, as an integer NRRD dataset.
52
+
+`hemispheres.nrrd` (optional): labeling of right (1) and left (2) hemispheres, as an integer NRRD dataset. Used to mirror flatmaps in `postproc/both_hemispheres`.
51
53
52
54
## Dependencies
53
55
@@ -65,8 +67,8 @@ To create a flatmap:
65
67
66
68
## Optional dependencies
67
69
68
-
+ Intel MKL (proprietary), to speed up iterative flattening algorithm.
69
-
+ GNU Parallel (`parallel`), to compute streamlines in parallel across a cluster.
70
+
+ Intel MKL (proprietary), to speed up iterative mesh flattening.
71
+
+ GNU Parallel (`parallel`), to compute streamlines in parallel.
70
72
+ gnuplot (`gnuplot`), to view diagnostic plots.
71
-
+ Some image viewer, to view generated heatmaps.
73
+
+ Some image viewer (e.g., `feh`), to view generated heatmaps.
72
74
+ Some NRRD viewer (e.g., `xgrid3d` or `itk-snap`), to view generated NRRD datasets.
0 commit comments