TITLE: Labeling of Dense Light Data in Amira 3D 2022.1 Classic Segmentation Workroom
AUTHORS: Alyson Petruncio, CellMap Project Team

[DESCRIPTION]
This protocol is optimized for densely labeling high dynamic range light data subvolumes requiring unique identification of each expressed structure.

Segmentation Summary

Set up Amira project and segmentation.
Segment slices across a single cell, interpolate, and add to a unique material.
Clean working material through exterior material interpolation across a second plane and universal smoothing.
Confirm segmentation boundaries in relation to cell signal, lock current material, and create a new working material.

[GUIDELINES]
Note: While Amira 3D 2022.1 Segmentation+ workroom supports an arbitrary number of unique label IDs, the Classic Segmentation workroom tools, which only support 8-bit label data, are better suited for this application. Multiple label fields can be merged after subvolume segmentation.

[STEPS]
SECTION: Amira Project and Segmentation Setup
1. After opening a new Amira project, select File → Open Data, or click and drag the raw data tiff to the empty space under the Project tab. Confirm coordinates and voxel size in the Image Read Parameters window. 

For higher label resolution: Select the arrow of the raw data object in the Project tab. In the window search bar, type ‘resample’. Select the Resample object. With the Resample object selected, adjust Voxel Size: under Properties to half of the original resolution value. Select Apply, and select the generated raw data object as the new working raw data object.

Select the Segmentation tab to automatically generate a label field. Confirm Image: dropdown under Segmentation Editor is the raw data. Under Materials, ensure the Exterior (Not Assigned) material remains unlocked (1 ). The existing Inside material may be renamed and used as the first cell segmentation material.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  
 
Note: Once material 256 is reached within a single label field, select New across Label Field: to continue segmentations in a new label field.

In order to track previously segmented cells in a new label field, select Exterior (Not Assigned) material in the previous label field, click the physical exterior space in the 2D viewer, and select Shift+I  to inverse 3D exterior material selection so that all cell materials are now selected. Under Label Field: dropdown, select the new label field and add current selection to the first material. All older segmentations should now be under a single locked material in the new label field.

  


SECTION: Segment, Interpolate, Add
2. With the first material highlighted under the Materials section, select the brush (2 ) under the Selection section. Above the 2D Viewer, select the XY plane icon (3 ); initial segmentation and interpolations should be performed down the imaged plane.
SECTION: Segment, Interpolate, Add
3. After adjusting 2D viewer zoom settings and brush size under the brush (2 ) window, paint in a single slice of a cell, using either a large brush size or 'F' to fill in the cell slice after painting a signal-inclusive boundary.
SECTION: Segment, Interpolate, Add
4. Scroll ~3-4 slices (~5-7 slices if raw data was resampled) and repeat the painting process from end to end of the cell. 
SECTION: Cleaning Interpolations and Universal Smoothing
6. Select the XZ plane icon (4 ) and locate the working material. Using the Exterior (Not Assigned) material, paint and interpolate across any false positive segmentations, one area at a time. Add ('A' or +) the selection to the Exterior (Not Assigned) material, which will remove any overlapping, unlocked working material. Continue to ‘clean’ the working material using this process until false positives from XY plane interpolations are removed. 

Note: Interpolated selections can also be removed from the working material by first highlighting the working material under the Materials section, and subtracting ('S' or -) the selection.
SECTION: Cleaning Interpolations and Universal Smoothing
7. With no selection, select Segmentation → Smooth labels. Under the Smooth Labels window, adjust the Size: to ~2-4, and change Mode: to 3D volume. While watching the working material in the 2D and 3D Viewers, select Apply until the working material is smoothed and inclusive of signal boundaries.
SECTION: Cleaning Interpolations and Universal Smoothing
8. If smoothing results in excessive merging with bordering labels, select locked, bordering label, grow the selected label using Grow Selection (5 ) under the Selection section. Then, highlight the Exterior (Not Assigned) material, and add ('A' or +) the extended selection. Only the portion of the selection that is outside of a locked material will be added to the Exterior (Not Assigned) material.
SECTION: Confirmation and Locking
9. After confirming working material has included sufficient cell boundary signal in all three planes, lock (6 ) the working material.
SECTION: Confirmation and Locking
10. Under the Materials section, select the Add button to create a new working material. After a working material is finalized, it should always be locked before creating and working on a new cell segmentation. While selection-based tools will not impact unlocked materials, universal, volume-based tools will modify any unlocked materials. 
SECTION: Confirmation and Locking
11. Repeat earlier steps for each new cell/material, ensuring all non-working materials are locked at all times. See Amira Project and Segmentation Setup section for raw data objects that require more than 256 unique ID labels.
SECTION: Confirmation and Locking
12. Export label fields for merging using Python (see Software link) or direct use by selecting the Project tab, selecting the arrow of the label field object, and selecting the Export Data As icon (7 ).

 


SECTION: Segment, Interpolate, Add
5. Select Ctrl+I  to interpolate across all painted slices, followed by Ctrl+W, which performs a more radial interpolation, eliminating the requirement for multiple interpolations across multiple planes. With the interpolations selected, select Selection → Smooth → All Slices. Add ('A' or +) the selection to the working material.