Skip to content

Commit

Permalink
various small changes to the notebook
Browse files Browse the repository at this point in the history
  • Loading branch information
maximlt committed Dec 10, 2024
1 parent 9ebfe8d commit 6b8e6c7
Showing 1 changed file with 134 additions and 19 deletions.
153 changes: 134 additions & 19 deletions volumetric_imaging/volumetric_imaging.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,13 @@
{
"cell_type": "markdown",
"id": "cc47db48-cd14-4874-a377-e4c13de91cdd",
"metadata": {},
"metadata": {
"panel-layout": {
"height": 106.01666259765625,
"visible": true,
"width": 100
}
},
"source": [
"# Volumetric Imaging\n",
"\n",
Expand All @@ -20,7 +26,16 @@
"cell_type": "code",
"execution_count": null,
"id": "ef81c950-38e8-4c18-aec0-63ce70c34b1f",
"metadata": {},
"metadata": {
"panel-layout": {
"height": 345,
"visible": true,
"width": 100
},
"tags": [
"remove-output"
]
},
"outputs": [],
"source": [
"from IPython.display import HTML\n",
Expand All @@ -34,7 +49,13 @@
{
"cell_type": "markdown",
"id": "e3b92a30-50eb-4d00-ad83-0354c947f767",
"metadata": {},
"metadata": {
"panel-layout": {
"height": 779.4500122070312,
"visible": true,
"width": 100
}
},
"source": [
"## Overview\n",
"\n",
Expand Down Expand Up @@ -88,6 +109,11 @@
"ExecuteTime": {
"end_time": "2024-03-29T17:25:02.532910Z",
"start_time": "2024-03-29T17:25:02.529856Z"
},
"panel-layout": {
"height": 50.850006103515625,
"visible": false,
"width": 100
}
},
"source": [
Expand All @@ -98,7 +124,13 @@
"cell_type": "code",
"execution_count": null,
"id": "c83a8253-e6da-485d-96cd-ce0e783ac00d",
"metadata": {},
"metadata": {
"panel-layout": {
"height": 101,
"visible": false,
"width": 79.249
}
},
"outputs": [],
"source": [
"import param\n",
Expand All @@ -111,7 +143,13 @@
{
"cell_type": "markdown",
"id": "64a50727-8c91-4d88-a82d-626e5a7715ba",
"metadata": {},
"metadata": {
"panel-layout": {
"height": 102.5,
"visible": true,
"width": 100
}
},
"source": [
"## Defining the `NeuroglancerNB` Class\n",
"\n",
Expand Down Expand Up @@ -247,15 +285,27 @@
{
"cell_type": "markdown",
"id": "4dac819c-c3e9-4a51-be83-bf54b28f62b2",
"metadata": {},
"metadata": {
"panel-layout": {
"height": 50.850006103515625,
"visible": true,
"width": 100
}
},
"source": [
"## Approach 1: Launching a New Viewer and Loading State from URL\n"
]
},
{
"cell_type": "markdown",
"id": "58f1de1e-d307-4e6a-8f49-ec7f4a04cc24",
"metadata": {},
"metadata": {
"panel-layout": {
"height": 110.35000610351562,
"visible": true,
"width": 100
}
},
"source": [
"In this workflow, we'll initialize a new Neuroglancer viewer and load a dataset using a parameterized URL. This allows us to explore different datasets by simply changing the URL.\n",
"\n",
Expand All @@ -267,17 +317,32 @@
{
"cell_type": "code",
"execution_count": null,
"id": "b5fb5bf4-83af-4180-b061-a7eac0f5ad6a",
"metadata": {},
"id": "615b234d-e8f3-4600-826d-c1db1d820bbf",
"metadata": {
"panel-layout": {
"height": 763.5833129882812,
"visible": true,
"width": 100
},
"tags": [
"remove-output"
]
},
"outputs": [],
"source": [
"# NeuroglancerNB(show_state=True, load_demo=True)"
"NeuroglancerNB(show_state=True, load_demo=True)"
]
},
{
"cell_type": "markdown",
"id": "9ab67ed5-625f-4be7-8c86-a5657c86a065",
"metadata": {},
"metadata": {
"panel-layout": {
"height": 68.30000305175781,
"visible": false,
"width": 100
}
},
"source": [
"<img \n",
" src=\"./assets/approach1.png\" \n",
Expand All @@ -293,15 +358,27 @@
{
"cell_type": "markdown",
"id": "afa26a39-e22f-4ae8-880e-559350e1bfc9",
"metadata": {},
"metadata": {
"panel-layout": {
"height": 50.850006103515625,
"visible": true,
"width": 100
}
},
"source": [
"## Approach 2: Displaying a Pre-specified Viewer"
]
},
{
"cell_type": "markdown",
"id": "2717e7f4-f098-4ba8-87a5-1e673496d740",
"metadata": {},
"metadata": {
"panel-layout": {
"height": 185,
"visible": true,
"width": 100
}
},
"source": [
"Alternatively, you can provide a pre-configured `neuroglancer.viewer.Viewer` object as the `source` to display that viewer in the notebook. This allows you to set up the viewer programmatically and then embed it.\n",
"\n",
Expand Down Expand Up @@ -338,16 +415,31 @@
"cell_type": "code",
"execution_count": null,
"id": "26d8d75a-4512-4d92-8c96-a5f974fc72c7",
"metadata": {},
"metadata": {
"panel-layout": {
"height": 664.2999877929688,
"visible": true,
"width": 100
},
"tags": [
"remove-output"
]
},
"outputs": [],
"source": [
"# NeuroglancerNB(source=viewer, show_state=True)"
"NeuroglancerNB(source=viewer, show_state=True)"
]
},
{
"cell_type": "markdown",
"id": "94b0e8a2-4fa3-44b0-b7a4-8b43f9ad081f",
"metadata": {},
"metadata": {
"panel-layout": {
"height": 68.29998779296875,
"visible": false,
"width": 100
}
},
"source": [
"<img \n",
" src=\"./assets/approach1.png\" \n",
Expand All @@ -363,7 +455,13 @@
{
"cell_type": "markdown",
"id": "1247343e-44b5-46a8-a05d-511d1a392e9d",
"metadata": {},
"metadata": {
"panel-layout": {
"height": 294.66668701171875,
"visible": true,
"width": 100
}
},
"source": [
"## Next Steps\n",
"\n",
Expand Down Expand Up @@ -400,8 +498,25 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.11.10"
}
"version": "3.11.11"
},
"panel-cell-order": [
"cc47db48-cd14-4874-a377-e4c13de91cdd",
"ef81c950-38e8-4c18-aec0-63ce70c34b1f",
"e3b92a30-50eb-4d00-ad83-0354c947f767",
"a2f77667-f42b-42f6-a13d-5abbe589d7ea",
"c83a8253-e6da-485d-96cd-ce0e783ac00d",
"64a50727-8c91-4d88-a82d-626e5a7715ba",
"4dac819c-c3e9-4a51-be83-bf54b28f62b2",
"58f1de1e-d307-4e6a-8f49-ec7f4a04cc24",
"615b234d-e8f3-4600-826d-c1db1d820bbf",
"9ab67ed5-625f-4be7-8c86-a5657c86a065",
"afa26a39-e22f-4ae8-880e-559350e1bfc9",
"2717e7f4-f098-4ba8-87a5-1e673496d740",
"26d8d75a-4512-4d92-8c96-a5f974fc72c7",
"94b0e8a2-4fa3-44b0-b7a4-8b43f9ad081f",
"1247343e-44b5-46a8-a05d-511d1a392e9d"
]
},
"nbformat": 4,
"nbformat_minor": 5
Expand Down

0 comments on commit 6b8e6c7

Please sign in to comment.