Skip to content

Commit

Permalink
tidy up
Browse files Browse the repository at this point in the history
  • Loading branch information
bmandracchia committed Sep 3, 2024
1 parent e4c0c28 commit 184764b
Show file tree
Hide file tree
Showing 7 changed files with 224 additions and 82 deletions.
78 changes: 76 additions & 2 deletions _proc/00_core.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
"text/markdown": [
"---\n",
"\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/core.py#L26){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/core.py#L29){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"\n",
"### attributesFromDict\n",
"\n",
Expand All @@ -53,7 +53,7 @@
"text/plain": [
"---\n",
"\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/core.py#L26){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/core.py#L29){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"\n",
"### attributesFromDict\n",
"\n",
Expand All @@ -71,6 +71,80 @@
"show_doc(attributesFromDict)"
]
},
{
"cell_type": "code",
"execution_count": 2,
"metadata": {},
"outputs": [
{
"data": {
"text/markdown": [
"---\n",
"\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/core.py#L35){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"\n",
"### img2float\n",
"\n",
"> img2float (image, force_copy=False)"
],
"text/plain": [
"---\n",
"\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/core.py#L35){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"\n",
"### img2float\n",
"\n",
"> img2float (image, force_copy=False)"
]
},
"execution_count": 2,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"#| echo: false\n",
"#| output: asis\n",
"show_doc(img2float)"
]
},
{
"cell_type": "code",
"execution_count": 3,
"metadata": {},
"outputs": [
{
"data": {
"text/markdown": [
"---\n",
"\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/core.py#L39){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"\n",
"### img2Tensor\n",
"\n",
"> img2Tensor (image)"
],
"text/plain": [
"---\n",
"\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/core.py#L39){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"\n",
"### img2Tensor\n",
"\n",
"> img2Tensor (image)"
]
},
"execution_count": 3,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"#| echo: false\n",
"#| output: asis\n",
"show_doc(img2Tensor)"
]
},
{
"cell_type": "markdown",
"metadata": {},
Expand Down
4 changes: 0 additions & 4 deletions _proc/04_nets.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -1199,10 +1199,6 @@
"language": "python",
"name": "python3"
},
"language_info": {
"name": "python",
"version": "3.11.5"
},
"widgets": {
"application/vnd.jupyter.widget-state+json": {
"state": {},
Expand Down
4 changes: 4 additions & 0 deletions _proc/06_metrics.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,17 @@
"text/markdown": [
"---\n",
"\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/metrics.py#L20){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"\n",
"### SSIMMetric\n",
"\n",
"> SSIMMetric (x, y, spatial_dims=2)"
],
"text/plain": [
"---\n",
"\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/metrics.py#L20){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"\n",
"### SSIMMetric\n",
"\n",
"> SSIMMetric (x, y, spatial_dims=2)"
Expand Down
30 changes: 15 additions & 15 deletions _proc/09_visualize.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
"outputs": [],
"source": [
"# load sample data\n",
"data4D = util.img_as_float(cells3d())\n",
"data4D = img2float(cells3d())\n",
"data = data4D[:, 1, :, :] # load the nuclei channel"
]
},
Expand All @@ -52,7 +52,7 @@
"text/markdown": [
"---\n",
"\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L23){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L22){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"\n",
"### plot_image\n",
"\n",
Expand All @@ -69,7 +69,7 @@
"text/plain": [
"---\n",
"\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L23){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L22){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"\n",
"### plot_image\n",
"\n",
Expand Down Expand Up @@ -126,7 +126,7 @@
"text/markdown": [
"---\n",
"\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L57){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L56){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"\n",
"### mosaic_image_3d\n",
"\n",
Expand All @@ -147,7 +147,7 @@
"text/plain": [
"---\n",
"\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L57){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L56){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"\n",
"### mosaic_image_3d\n",
"\n",
Expand Down Expand Up @@ -187,7 +187,7 @@
"text/markdown": [
"---\n",
"\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L112){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L111){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"\n",
"### show_images_grid\n",
"\n",
Expand Down Expand Up @@ -216,7 +216,7 @@
"text/plain": [
"---\n",
"\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L112){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L111){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"\n",
"### show_images_grid\n",
"\n",
Expand Down Expand Up @@ -315,7 +315,7 @@
"text/markdown": [
"---\n",
"\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L184){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L183){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"\n",
"### show_plane\n",
"\n",
Expand All @@ -334,7 +334,7 @@
"text/plain": [
"---\n",
"\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L184){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L183){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"\n",
"### show_plane\n",
"\n",
Expand Down Expand Up @@ -372,7 +372,7 @@
"text/markdown": [
"---\n",
"\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L208){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L207){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"\n",
"### visualize_slices\n",
"\n",
Expand All @@ -387,7 +387,7 @@
"text/plain": [
"---\n",
"\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L208){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L207){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"\n",
"### visualize_slices\n",
"\n",
Expand Down Expand Up @@ -465,7 +465,7 @@
"text/markdown": [
"---\n",
"\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L243){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L242){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"\n",
"### slice_explorer\n",
"\n",
Expand All @@ -482,7 +482,7 @@
"text/plain": [
"---\n",
"\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L243){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L242){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"\n",
"### slice_explorer\n",
"\n",
Expand Down Expand Up @@ -7457,7 +7457,7 @@
"text/markdown": [
"---\n",
"\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L273){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L272){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"\n",
"### plot_volume\n",
"\n",
Expand All @@ -7481,7 +7481,7 @@
"text/plain": [
"---\n",
"\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L273){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"[source](https://github.com/bmandracchia/bioMONAI/blob/main/bioMONAI/visualize.py#L272){target=\"_blank\" style=\"float:right; font-size:smaller\"}\n",
"\n",
"### plot_volume\n",
"\n",
Expand Down
3 changes: 2 additions & 1 deletion bioMONAI/_modidx.py
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,8 @@
'bioMONAI.nets.get_padding': ('nets.html#get_padding', 'bioMONAI/nets.py'),
'bioMONAI.nets.interpolate': ('nets.html#interpolate', 'bioMONAI/nets.py')},
'bioMONAI.template': {'bioMONAI.template.foo': ('template.html#foo', 'bioMONAI/template.py')},
'bioMONAI.transforms': { 'bioMONAI.transforms.RandCrop2D': ('transforms.html#randcrop2d', 'bioMONAI/transforms.py'),
'bioMONAI.transforms': { 'bioMONAI.transforms.RandCameraNoise': ('transforms.html#randcameranoise', 'bioMONAI/transforms.py'),
'bioMONAI.transforms.RandCrop2D': ('transforms.html#randcrop2d', 'bioMONAI/transforms.py'),
'bioMONAI.transforms.RandCrop2D.__init__': ( 'transforms.html#randcrop2d.__init__',
'bioMONAI/transforms.py'),
'bioMONAI.transforms.RandCrop2D.before_call': ( 'transforms.html#randcrop2d.before_call',
Expand Down
Loading

0 comments on commit 184764b

Please sign in to comment.