Skip to content

Commit

Permalink
Minor polishing commits
Browse files Browse the repository at this point in the history
  • Loading branch information
joshmoore committed Sep 4, 2023
1 parent ee4bdfc commit 4444536
Show file tree
Hide file tree
Showing 2 changed files with 73 additions and 8 deletions.
2 changes: 2 additions & 0 deletions 3_POSIX_Bash.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,8 @@
" <td>\n",
" <center>\n",
" <img src=\"images/falk/clara-shares-300dpi.png\"/>\n",
" </center>\n",
" <center>\n",
" <small>\n",
" <a href=\"https://github.com/zarr-developers/zarr-illustrations-falk-2022#clara-shares\">\"Clara shares\"</a>\n",
" by Henning Falk, ©2022 NumFOCUS, is used under a CC BY 4.0 license. Modifications to this photo include cropping.\n",
Expand Down
79 changes: 71 additions & 8 deletions 4_OMETiff_Python.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -32,19 +32,82 @@
" <li>aicsimageio</li>\n",
" <li>tifffile</li>\n",
" <li>and ome-types</li>\n",
" </ol>\n",
" </ul>\n",
" </p>\n",
" </td>\n",
" <td>\n",
" <center>\n",
" <img src=\"images/ome-tiff-support.png\" width=\"40%\"/>\n",
" </center>\n",
" <center>\n",
" <small>\n",
" <a href=\"https://ome-model.readthedocs.io/en/stable/ome-tiff/index.html#support\">https://ome-model.readthedocs.io/en/stable/ome-tiff/index.html#support</a>\n",
" </small>\n",
" </center>\n",
" </td>\n",
" </tr>\n",
"</table>\n",
"\n"
]
},
{
"cell_type": "code",
"execution_count": 1,
"id": "c2bb2db9-8423-475d-baec-575c5e3f34ad",
"metadata": {},
"outputs": [],
"source": [
"%%bash\n",
"##\n",
"## Setup & Sanity checks\n",
"##\n",
"\n",
"YOURNAME=$(whoami)\n",
"WORKDIR=/scratch/${YOURNAME}/session1/\n",
"test -e ${WORKDIR} || {\n",
" echo Please run the first the POSIX notebook first.\n",
" exit 1\n",
"}"
]
},
{
"cell_type": "code",
"execution_count": 2,
"id": "13b54bbb-865a-4f8a-ba6c-176aece5c55f",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"env: YOURNAME=jamoore\n"
]
}
],
"source": [
"import os\n",
"YOURNAME = os.getlogin()\n",
"%env YOURNAME=$YOURNAME"
]
},
{
"cell_type": "code",
"execution_count": 3,
"id": "3f3cb95c-e131-4282-965f-6f4d86cdca38",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"/System/Volumes/Data/scratch/jamoore/session1\n"
]
}
],
"source": [
"%cd /scratch/{YOURNAME}/session1"
]
},
{
"cell_type": "markdown",
"id": "5ef9f593-672a-46f5-bcd9-ccb74aa34848",
Expand All @@ -57,7 +120,7 @@
},
{
"cell_type": "code",
"execution_count": 1,
"execution_count": 4,
"id": "c65afca4-27bd-41f6-b59a-ce2fc7d9cd88",
"metadata": {},
"outputs": [],
Expand Down Expand Up @@ -86,7 +149,7 @@
},
{
"cell_type": "code",
"execution_count": 2,
"execution_count": 5,
"id": "b9ec37a2-5bd0-42a2-89a7-07bc03a614db",
"metadata": {},
"outputs": [],
Expand All @@ -108,7 +171,7 @@
},
{
"cell_type": "code",
"execution_count": 3,
"execution_count": 6,
"id": "79ded011-475a-4320-993d-2227b620681c",
"metadata": {},
"outputs": [],
Expand All @@ -131,15 +194,15 @@
},
{
"cell_type": "code",
"execution_count": 4,
"execution_count": 7,
"id": "8a8d96dc-e6d3-4e9d-944c-b66160811305",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"id='Image:0' name='data/a' pixels={'channels': [{'annotation_refs': [], 'light_path': {'excitation_filters': [], 'emission_filters': [], 'annotation_refs': []}, 'id': 'Channel:0:0', 'samples_per_pixel': 1, 'color': Color('white', rgb=(255, 255, 255))}], 'bin_data_blocks': [], 'tiff_data_blocks': [{'uuid': {'value': 'urn:uuid:d8f35575-5655-4b0e-8885-a952f05ebaeb', 'file_name': 'a.ome.tiff'}, 'plane_count': 1}], 'planes': [], 'id': 'Pixels:0', 'dimension_order': <Pixels_DimensionOrder.XYZCT: 'XYZCT'>, 'type': <PixelType.UINT8: 'uint8'>, 'significant_bits': 8, 'interleaved': False, 'big_endian': False, 'size_x': 512, 'size_y': 512, 'size_z': 1, 'size_c': 1, 'size_t': 1}\n"
"id='Image:0' name='a' pixels={'channels': [{'annotation_refs': [], 'light_path': {'excitation_filters': [], 'emission_filters': [], 'annotation_refs': []}, 'id': 'Channel:0:0', 'samples_per_pixel': 1, 'color': Color('white', rgb=(255, 255, 255))}], 'bin_data_blocks': [], 'tiff_data_blocks': [{'uuid': {'value': 'urn:uuid:a4331d69-3db3-419b-a28f-b4c6021bcf87', 'file_name': 'a.ome.tiff'}, 'plane_count': 1}], 'planes': [], 'id': 'Pixels:0', 'dimension_order': <Pixels_DimensionOrder.XYZCT: 'XYZCT'>, 'type': <PixelType.UINT8: 'uint8'>, 'significant_bits': 8, 'interleaved': False, 'big_endian': False, 'size_x': 512, 'size_y': 512, 'size_z': 1, 'size_c': 1, 'size_t': 1}\n"
]
}
],
Expand All @@ -152,7 +215,7 @@
},
{
"cell_type": "code",
"execution_count": 5,
"execution_count": 8,
"id": "2869cf30-3f91-44ef-8fc3-bdbc45ba242c",
"metadata": {
"scrolled": true
Expand All @@ -162,7 +225,7 @@
"name": "stdout",
"output_type": "stream",
"text": [
"id='Image:0' name='data/a' pixels={'channels': [{'annotation_refs': [], 'light_path': {'excitation_filters': [], 'emission_filters': [], 'annotation_refs': []}, 'id': 'Channel:0:0', 'samples_per_pixel': 1, 'color': Color('white', rgb=(255, 255, 255))}], 'bin_data_blocks': [], 'tiff_data_blocks': [{'uuid': {'value': 'urn:uuid:d8f35575-5655-4b0e-8885-a952f05ebaeb', 'file_name': 'a.ome.tiff'}, 'plane_count': 1}], 'planes': [], 'id': 'Pixels:0', 'dimension_order': <Pixels_DimensionOrder.XYZCT: 'XYZCT'>, 'type': <PixelType.UINT8: 'uint8'>, 'significant_bits': 8, 'interleaved': False, 'big_endian': False, 'size_x': 512, 'size_y': 512, 'size_z': 1, 'size_c': 1, 'size_t': 1}\n"
"id='Image:0' name='a' pixels={'channels': [{'annotation_refs': [], 'light_path': {'excitation_filters': [], 'emission_filters': [], 'annotation_refs': []}, 'id': 'Channel:0:0', 'samples_per_pixel': 1, 'color': Color('white', rgb=(255, 255, 255))}], 'bin_data_blocks': [], 'tiff_data_blocks': [{'uuid': {'value': 'urn:uuid:a4331d69-3db3-419b-a28f-b4c6021bcf87', 'file_name': 'a.ome.tiff'}, 'plane_count': 1}], 'planes': [], 'id': 'Pixels:0', 'dimension_order': <Pixels_DimensionOrder.XYZCT: 'XYZCT'>, 'type': <PixelType.UINT8: 'uint8'>, 'significant_bits': 8, 'interleaved': False, 'big_endian': False, 'size_x': 512, 'size_y': 512, 'size_z': 1, 'size_c': 1, 'size_t': 1}\n"
]
}
],
Expand Down

0 comments on commit 4444536

Please sign in to comment.