Skip to content

Commit

Permalink
general update (mostly read through)
Browse files Browse the repository at this point in the history
  • Loading branch information
joshmoore committed Aug 31, 2023
1 parent e1ba712 commit 2cc7195
Show file tree
Hide file tree
Showing 5 changed files with 608 additions and 723 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
data.zarr
METADATA.ome.xml
a.ome.tiff
23 changes: 22 additions & 1 deletion 3_POSIX_Bash.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -1227,7 +1227,7 @@
},
{
"cell_type": "code",
"execution_count": 20,
"execution_count": 35,
"id": "f709974e-a12d-46e5-86bb-324e8ba00642",
"metadata": {},
"outputs": [],
Expand Down Expand Up @@ -2215,6 +2215,27 @@
"</table>\n"
]
},
{
"cell_type": "markdown",
"id": "97256625-31f7-4d88-8faa-12b8d11df986",
"metadata": {},
"source": [
"## Excercise 2:\n",
"### Use the tools above to find inspect the data you chose, and convert it to OME-TIFF."
]
},
{
"cell_type": "code",
"execution_count": 36,
"id": "3d2aa171-0191-428a-8dc0-06a5fea0ccb2",
"metadata": {
"jp-MarkdownHeadingCollapsed": true
},
"outputs": [],
"source": [
"## Do something here or on the command-line. If you are having issues, ask."
]
},
{
"cell_type": "markdown",
"id": "c1a3d89a-e7f3-4180-b506-69865c12db9b",
Expand Down
65 changes: 50 additions & 15 deletions 4_OMETiff_Python.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,49 @@
"\n",
"## Day 2 - Session 1: Image Data Management - 10:15 to 11:15 \"Get set\"\n",
"\n",
"### Continuing from `3_Bash` in Python!..."
"### Continuing from `3_Bash` in Python!...\n",
"\n",
"Quick introduction to / comparison of:\n",
" * scikit-image\n",
" * aicsimageio\n",
" * tifffile\n",
" * and ome-types"
]
},
{
"cell_type": "code",
"execution_count": 48,
"execution_count": 9,
"id": "c65afca4-27bd-41f6-b59a-ce2fc7d9cd88",
"metadata": {},
"outputs": [],
"source": [
"import skimage as ski\n",
"image = ski.io.imread(\"a.ome.tiff\")"
]
},
{
"cell_type": "markdown",
"id": "bc8764bc-151a-46e0-8444-7344f5f65cd6",
"metadata": {},
"source": [
"https://datacarpentry.org/image-processing/"
]
},
{
"cell_type": "code",
"execution_count": 59,
"id": "b9ec37a2-5bd0-42a2-89a7-07bc03a614db",
"metadata": {},
"outputs": [],
"source": [
"from aicsimageio import AICSImage\n",
"\n",
"img = AICSImage(\"a.ome.tiff\") "
]
},
{
"cell_type": "code",
"execution_count": 1,
"id": "79ded011-475a-4320-993d-2227b620681c",
"metadata": {},
"outputs": [],
Expand All @@ -39,15 +76,15 @@
},
{
"cell_type": "code",
"execution_count": 55,
"execution_count": 11,
"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:0cc95cd0-950f-40bb-bc97-77a3fe7f7b64', '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='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"
]
}
],
Expand All @@ -60,15 +97,17 @@
},
{
"cell_type": "code",
"execution_count": 56,
"id": "289f0d8b-a10a-4bf4-8f8f-909117954b5f",
"metadata": {},
"execution_count": 12,
"id": "2869cf30-3f91-44ef-8fc3-bdbc45ba242c",
"metadata": {
"scrolled": true
},
"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:0cc95cd0-950f-40bb-bc97-77a3fe7f7b64', '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='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"
]
}
],
Expand All @@ -78,15 +117,11 @@
]
},
{
"cell_type": "code",
"execution_count": 59,
"id": "b9ec37a2-5bd0-42a2-89a7-07bc03a614db",
"cell_type": "markdown",
"id": "4db4f9ea-8e2b-42d4-a0e5-9216774e9940",
"metadata": {},
"outputs": [],
"source": [
"from aicsimageio import AICSImage\n",
"\n",
"img = AICSImage(\"a.ome.tiff\") "
"## Exercise 3: Play! (Time-permitting)"
]
},
{
Expand Down
Loading

0 comments on commit 2cc7195

Please sign in to comment.