Skip to content

Commit f38c0d4

Browse files
authored
Merge pull request #18 from dstansby/hipct
Add some HiP-CT docs
2 parents 11d69b4 + d3db219 commit f38c0d4

File tree

3 files changed

+85
-1
lines changed

3 files changed

+85
-1
lines changed

docs/data/hipct.md

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
# HiP-CT data
2+
3+
HiP-CT stands for hierarchical phase-contrast tomography.
4+
For more information on the modality see the [HiP-CT website](https://mecheng.ucl.ac.uk/hip-ct/).
5+
Most of the time HiP-CT consists of a single 'low' (but still quite high!) resolution scan of a whole sample, and then one or more 'high' resolution scans of particular volumes of interest within the same sample.
6+
7+
## Data acquisition and naming
8+
9+
There are HiP-CT scans of two donors, S45 and I58.
10+
The data are part of the [Pilot human brains dataset](https://lincbrain.org/dandiset/000005) on lincbrain.
11+
12+
Datasets have the name `sub-<donor>_sample-<sample name>_chunk<chunk number>_PC.ome.zarr`.
13+
The chunk number is set to `yyxx`, where yy is the resolution of the scan in micrometers, and xx is a scan number that is unique between datasets.
14+
For example, a chunk number of `402` is the second 4um scan.
15+
The lowest resolution dataset (equivalently, highest chunk number) is the overview dataset that contains an image of the whole sample.
16+
There are then one or more datasets at higher resolution.
17+
18+
## Registration
19+
20+
Each high resolution dataset is registered to the overview dataset using [`hipct-reg`](https://github.com/hipCTProject/hipct-reg).
21+
Each transform maps the pixel coordinates of the high resolution zoom datasets to the overview full-sample dataset.
22+
The transform is of the form:
23+
24+
$$
25+
T(\mathbf{x}) = s \left ( \mathbf{R} \cdot\mathbf{x} \right ) + \mathbf{t}
26+
$$
27+
28+
Where
29+
30+
- $s$ is a scaling factor
31+
- $\mathbf{R}$ is a rotation matrix that rotates about the z-axis.
32+
- $\mathbf{t}$ is a translation vector
33+
34+
The rotation matrix takes the form
35+
36+
$$
37+
\mathbf{R} = \begin{pmatrix}
38+
\cos(-\theta) & \sin(-\theta) & 0 \\
39+
-\sin(-\theta) & \cos(-\theta) & 0 \\
40+
0 & 0 & 1 \\
41+
\end{pmatrix}
42+
$$
43+
44+
The transform has 5 parameters (1 scaling, 1 rotation, 3 translation).
45+
46+
### Registration accuracy
47+
48+
The HiP-CT registration pipeline is designed to be accurate enough to approximately visually align two datasets. **It is not designed for pixel perfect registration.** We recommend anyone doing analysis relying on the registration between two datasets performs a more accurate registration themselves, using our registration as an initial starting point.
49+
50+
### Registration data
51+
52+
53+
| Dataset | Overview dataset | $\mathbf{t}$ | $s$ | $\theta$ (degrees) |
54+
| -------- | -------- | -------- | -------- | -------- |
55+
| `sub-I58_sample-blockIC2_chunk-101_PC` | `sub-I58_sample-blockIC2_chunk-401_PC` | (3746.4467746089194, 3660.0610535229666, 1127.3616712249263) | 0.2016106611944697 | -6.496401244495998 |
56+
| `sub-I58_sample-blockIC2_chunk-201_PC` | `sub-I58_sample-blockIC2_chunk-401_PC` | (2119.695989239648, 2321.6572801771194, 971.0041825720597) | 0.5181803632402424 | 0.5004912711693281 |

docs/javascripts/mathjax.js

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
window.MathJax = {
2+
tex: {
3+
inlineMath: [["\\(", "\\)"]],
4+
displayMath: [["\\[", "\\]"]],
5+
processEscapes: true,
6+
processEnvironments: true
7+
},
8+
options: {
9+
ignoreHtmlClass: ".*|",
10+
processHtmlClass: "arithmatex"
11+
}
12+
};
13+
14+
document$.subscribe(() => {
15+
MathJax.startup.output.clearCache()
16+
MathJax.typesetClear()
17+
MathJax.texReset()
18+
MathJax.typesetPromise()
19+
})

mkdocs.yml

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,8 @@ nav:
4040
- DANDI Docs: https://docs.dandiarchive.org
4141
- API:
4242
- DANDI Client: https://dandi.readthedocs.io
43+
- Data:
44+
- HiP-CT: "data/hipct.md"
4345
- Contribute documentation: "contribute.md"
4446
- About this doc: "about.md"
4547

@@ -51,6 +53,8 @@ markdown_extensions:
5153
- pymdownx.magiclink
5254
- toc:
5355
permalink: True
56+
- pymdownx.arithmatex:
57+
generic: true
5458

5559
# List of plugins
5660
plugins:
@@ -78,4 +82,9 @@ extra:
7882
name: Docker Hub
7983
- icon: fontawesome/brands/python
8084
link: https://pypi.org/project/lincbrain-cli
81-
name: PyPI
85+
name: PyPI
86+
87+
88+
extra_javascript:
89+
- javascripts/mathjax.js
90+
- https://unpkg.com/mathjax@3/es5/tex-mml-chtml.js

0 commit comments

Comments
 (0)