Skip to content

Commit d50ded8

Browse files
committed
deploy: c428c58
1 parent 3f2177b commit d50ded8

29 files changed

+1600
-1453
lines changed
Binary file not shown.
Binary file not shown.
53.1 KB
Loading
Binary file not shown.
62.7 KB
Loading
54.7 KB
Loading

_sources/extra/nifti.ipynb

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"cells": [
33
{
44
"cell_type": "markdown",
5-
"id": "45699bb0",
5+
"id": "b4785e6b",
66
"metadata": {},
77
"source": [
88
"# The extra mile\n",
@@ -16,7 +16,7 @@
1616
{
1717
"cell_type": "code",
1818
"execution_count": 1,
19-
"id": "066b379e",
19+
"id": "066f3029",
2020
"metadata": {},
2121
"outputs": [],
2222
"source": [
@@ -25,7 +25,7 @@
2525
},
2626
{
2727
"cell_type": "markdown",
28-
"id": "9b723296",
28+
"id": "99b65361",
2929
"metadata": {},
3030
"source": [
3131
"First, use the `load()` function to create a NiBabel image object from a NIfTI file.\n",
@@ -35,7 +35,7 @@
3535
{
3636
"cell_type": "code",
3737
"execution_count": 2,
38-
"id": "234480c7",
38+
"id": "8ced4eac",
3939
"metadata": {},
4040
"outputs": [],
4141
"source": [
@@ -46,7 +46,7 @@
4646
},
4747
{
4848
"cell_type": "markdown",
49-
"id": "5998cc6a",
49+
"id": "ba887b58",
5050
"metadata": {},
5151
"source": [
5252
"Loading in a NIfTI file with `NiBabel` gives us a special type of data object which encodes all the information in the file.\n",
@@ -60,7 +60,7 @@
6060
{
6161
"cell_type": "code",
6262
"execution_count": 3,
63-
"id": "994871f2",
63+
"id": "4796085c",
6464
"metadata": {},
6565
"outputs": [
6666
{
@@ -121,7 +121,7 @@
121121
},
122122
{
123123
"cell_type": "markdown",
124-
"id": "0aa6f2cc",
124+
"id": "6b606a6a",
125125
"metadata": {},
126126
"source": [
127127
"### 2. Data\n",
@@ -134,7 +134,7 @@
134134
{
135135
"cell_type": "code",
136136
"execution_count": 4,
137-
"id": "0917d0e8",
137+
"id": "bd6fb9f1",
138138
"metadata": {
139139
"tags": [
140140
"output_scroll"
@@ -465,7 +465,7 @@
465465
},
466466
{
467467
"cell_type": "markdown",
468-
"id": "d96aaa72",
468+
"id": "dd4bbd31",
469469
"metadata": {},
470470
"source": [
471471
"What type of data is this exactly? We can determine this by calling the `type()` function on `dwi_data`."
@@ -474,7 +474,7 @@
474474
{
475475
"cell_type": "code",
476476
"execution_count": 5,
477-
"id": "6e23a551",
477+
"id": "514617cf",
478478
"metadata": {},
479479
"outputs": [
480480
{
@@ -494,7 +494,7 @@
494494
},
495495
{
496496
"cell_type": "markdown",
497-
"id": "a651d0a0",
497+
"id": "4ef25796",
498498
"metadata": {},
499499
"source": [
500500
"The data is a multidimensional **array** representing the image data.\n",
@@ -505,7 +505,7 @@
505505
{
506506
"cell_type": "code",
507507
"execution_count": 6,
508-
"id": "a704429f",
508+
"id": "044a7a47",
509509
"metadata": {},
510510
"outputs": [
511511
{
@@ -525,7 +525,7 @@
525525
},
526526
{
527527
"cell_type": "markdown",
528-
"id": "a31d670c",
528+
"id": "0b941599",
529529
"metadata": {},
530530
"source": [
531531
"As expected, the data contains 4 dimensions (*i, j, k* and gradient number).\n",
@@ -536,7 +536,7 @@
536536
{
537537
"cell_type": "code",
538538
"execution_count": 7,
539-
"id": "175d7e3b",
539+
"id": "affa31cc",
540540
"metadata": {},
541541
"outputs": [
542542
{
@@ -556,7 +556,7 @@
556556
},
557557
{
558558
"cell_type": "markdown",
559-
"id": "ef4100d7",
559+
"id": "2b537736",
560560
"metadata": {},
561561
"source": [
562562
"This tells us that the image is 128, 128, 66\n",
@@ -567,7 +567,7 @@
567567
{
568568
"cell_type": "code",
569569
"execution_count": 8,
570-
"id": "fcea8d80",
570+
"id": "e3d01d98",
571571
"metadata": {
572572
"tags": [
573573
"output_scroll"
@@ -689,7 +689,7 @@
689689
},
690690
{
691691
"cell_type": "markdown",
692-
"id": "a4f6d500",
692+
"id": "74a5fcae",
693693
"metadata": {},
694694
"source": [
695695
"### 3. [Affine](https://nipy.org/nibabel/coordinate_systems.html): tells the position of the image array data in a reference space\n",
@@ -701,7 +701,7 @@
701701
{
702702
"cell_type": "code",
703703
"execution_count": 9,
704-
"id": "62e9859d",
704+
"id": "0d7a7633",
705705
"metadata": {},
706706
"outputs": [
707707
{
@@ -725,7 +725,7 @@
725725
},
726726
{
727727
"cell_type": "markdown",
728-
"id": "9eed4835",
728+
"id": "6847870c",
729729
"metadata": {},
730730
"source": [
731731
"To explain this concept, recall that we referred to coordinates in our data as *voxel coordinates (i,j,k)* coordinates such that:\n",

_sources/notebook/01-intro.ipynb

Lines changed: 7 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"cells": [
33
{
44
"cell_type": "markdown",
5-
"id": "07c0e96c",
5+
"id": "41f638b5",
66
"metadata": {},
77
"source": [
88
"# The problem of head-motion in dMRI"
@@ -11,7 +11,7 @@
1111
{
1212
"cell_type": "code",
1313
"execution_count": null,
14-
"id": "045bf720",
14+
"id": "c48d22ad",
1515
"metadata": {
1616
"tags": [
1717
"remove-cell"
@@ -28,7 +28,7 @@
2828
},
2929
{
3030
"cell_type": "markdown",
31-
"id": "1e062d91",
31+
"id": "0b4fe167",
3232
"metadata": {},
3333
"source": [
3434
"A recurring problem for any MRI acquisition is that image reconstruction and modeling are extremely sensitive to very small changes in the position of the imaged object.\n",
@@ -41,20 +41,20 @@
4141
{
4242
"cell_type": "code",
4343
"execution_count": null,
44-
"id": "53de77d7",
44+
"id": "607ba45b",
4545
"metadata": {
4646
"tags": [
4747
"remove-input"
4848
]
4949
},
5050
"outputs": [],
5151
"source": [
52-
"HTML(\"\"\"<video width=\"640\" height=\"680\" loop=\"yes\" muted=\"yes\" autoplay=\"yes\" controls=\"yes\"><source src=\"../assets/videos/hm-sagittal.mp4\" type=\"video/mp4\"/></video>\"\"\")"
52+
"HTML(\"\"\"<video width=\"640\" height=\"680\" loop=\"yes\" muted=\"yes\" autoplay=\"yes\" controls=\"yes\"><source src=\"../videos/hm-sagittal.mp4\" type=\"video/mp4\"/></video>\"\"\")"
5353
]
5454
},
5555
{
5656
"cell_type": "markdown",
57-
"id": "4e5c553c",
57+
"id": "28cc163f",
5858
"metadata": {},
5959
"source": [
6060
"## Dimensions of the head-motion problem\n",
@@ -145,36 +145,16 @@
145145
"* A reliable registration framework to estimate the misalignment.\n",
146146
"* The integration of the three elements above in an iterable loop."
147147
]
148-
},
149-
{
150-
"cell_type": "code",
151-
"execution_count": null,
152-
"id": "fd4f6138-709b-4368-b1f6-69123edcaf13",
153-
"metadata": {},
154-
"outputs": [],
155-
"source": []
156148
}
157149
],
158150
"metadata": {
159151
"jupytext": {
160-
"default_lexer": "python"
152+
"default_lexer": "ipython3"
161153
},
162154
"kernelspec": {
163155
"display_name": "Python 3 (ipykernel)",
164156
"language": "python",
165157
"name": "python3"
166-
},
167-
"language_info": {
168-
"codemirror_mode": {
169-
"name": "ipython",
170-
"version": 3
171-
},
172-
"file_extension": ".py",
173-
"mimetype": "text/x-python",
174-
"name": "python",
175-
"nbconvert_exporter": "python",
176-
"pygments_lexer": "ipython3",
177-
"version": "3.11.13"
178158
}
179159
},
180160
"nbformat": 4,

0 commit comments

Comments
 (0)