CZI flow
Immunofluorescence (IF) microscopy overview:
- The CZI file format has been developed by ZEISS to store multidimensional IF images such as:
z-stacks, time lapse, and multiposition experiments.
We rely on applications like OME Bio-Formats / OMERO, Fiji, python-bioformats to view and process czi files
The IF images are visualized with neuroglancer
The file also consists of metadata along with label and macro (RGB) images
Pipeline overview:
Convert czi file to OME-NGFF zarr format with OME XML
Generate neuroglancer meta-data from zarr sub-image for each IF image
Create thumbnail image from zarr label sub-image
- em_workflows.czi.flow.gen_thumb(image: HedwigZarrImage, file_path: FilePath, image_name: str) dict
Uses SimpleITK to extract and write jpeg thumbnail image for the zarr subimage
- em_workflows.czi.flow.rechunk_zarr(file_path: FilePath) None
Re-chunk the ZARR structure so that multi-channel/RGB channels are not split between chunks with the zarr_rechunk command provided by tomojs-pytools.
- em_workflows.czi.flow.copy_zarr_to_assets_dir(file_path: FilePath) None
Copy the zarr files generated from czi files using bioformats2raw to assets folder
- em_workflows.czi.flow.generate_imageset(file_path: FilePath) List[Dict]
- ImageSet consists of all the assets for a particular zarr sub-image and label imagesMacro image is ignoredLabel image is added as an thumbnail assetZarr sub-images are added as neurglancerZarr asset along with their metadataMetadata includes: - shader - dimensions - shaderParameters
- em_workflows.czi.flow.generate_zarr(file_path: FilePath)
Uses bioformats2raw command to convert czi file to OME-NGFF zarr file
- em_workflows.czi.flow.find_thumb_idx(callback: List[Dict]) List[Dict]
Locate the index of label image in the image set
- em_workflows.czi.flow.update_file_metadata(file_path: FilePath, callback_with_zarr: Dict) Dict
OME-xml metadata can be informative for developers to understand why the neuroglancer view is not appropriately rendering. This function attaches xml file location as the file metadata to the zarr group
- em_workflows.czi.flow.generate_czi_imageset(file_path: FilePath) List[Dict]
Subflow for heavy lifting operation
- Overview:
Generate zarr from czi
Rechunk zarr files
Copy zarr files to assets folder
Generate imageset for the assets
- em_workflows.czi.flow.gen_thumb(image: HedwigZarrImage, file_path: FilePath, image_name: str) dict
Uses SimpleITK to extract and write jpeg thumbnail image for the zarr subimage