Tool: Segment Map
Segment Map partitions volume data
to create a surface model
with one or more segmentation regions
shown in different colors.
Along with the Fit to Segments tool,
Segment Map is part of the
Segger package described in:
Quantitative analysis of cryo-EM density map segmentation by watershed and
scale-space filtering, and fitting of structures by alignment to regions.
Pintilie GD, Zhang J, Goddard TD, Chiu W, Gossard DC.
J Struct Biol. 2010 Jun;170(3):427-38.
Comparison of Segger and other methods for segmentation and rigid-body docking of molecular components in cryo-EM density maps.
Pintilie G, Chiu W.
Biopolymers. 2012 Sep;97(9):742-60.
Segmentation regions can be measured with
Measure and Color Blobs
and saved as an index map with
segger exportmask.
For interactive (manual) segmentation of medical images, see the
Segmentations tool.
See also:
Volume Viewer,
Map Eraser,
Map Filter,
color zone,
volume mask,
segmentation,
EMDB segmentation file format (SFF),
Segger website,
Chimera-Segger how-to (2010)
[back to top: Segment Map]
Methodology
Segment Map performs watershed segmentation:
a density map is partitioned so that each local maximum has its
own region, and the boundaries between regions lie at the
valleys between the local maxima. The goal is usually
one region per protein or domain, but the initial segmentation
often gives more numerous and smaller regions than desired,
especially if the data are noisy.
Segger provides various ways to combine regions after the initial segmentation:
- automatic grouping
by scale-space filtering
(smoothing the data), done by default;
however, smoothing the data before segmentation
may be necessary, as discussed below
- interactive grouping by manual selection
- interactive grouping by connectivity
- interactive grouping using fitted atomic models
[back to top: Segment Map]
Preprocessing
It may be necessary to process a density map beforehand
for the segmentation to finish in a reasonable amount of time.
A map of size 2563 can have a million local maxima if it is noisy.
Gaussian smoothing to reduce the number of local maxima
can be performed with the command
volume gaussian.
Gaussian filtering reduces resolution to about six times the Gaussian
standard deviation.
After smoothing, it will also improve performance to reduce the size
of the map with
volume bin.
For visualization and analysis, it is desirable
for a density map to be oversampled by three times in each dimension,
so binning should aim for a grid spacing of approximately twice the
Gaussian standard deviation.
If interactive rotation speed is poor after segmentation, see
response time.
[back to top: Segment Map]
Dialog and Basic Usage
Segment Map can be started
from the Volume Data section of the Tools menu
(more...).
The map of interest should be chosen from the pulldown menu of open
volume data sets next to Segment map.
The threshold
(contour level) of the map should be adjusted
before segmentation, because the calculation will use only the voxels
with density values above that level.
Clicking Segment partitions the chosen map by the watershed method plus
smoothing and grouping as specified in the
segmenting options.
The segmentation result is shown as a surface model
with one or more segmentation regions
of different colors. The resulting number of regions is reported in the
dialog and the Log.
The segmentation is given the same name as the corresponding map except
with .seg appended.
The Current segmentation is indicated in the dialog and can be changed
by choosing a different segmentation name from the pulldown menu.
Designating a segmentation as the current segmentation
shows it and hides any others.
Grouping and ungrouping operations modify
the current segmentation model rather than creating a new one.
However, multiple segmentation models can be open at the same time,
and may have been generated from different density maps or opened from
previously saved segmentation files.
Grouping and ungrouping can be specified interactively
by selection. With default
mouse-button assignments,
Ctrl-click selects a region and Shift-Ctrl-click selects additional regions
without erasing the pre-existing selection.
- If no segmentation regions are selected,
clicking Ungroup backtracks to the previous stage of grouping of the
current segmentation. By default,
Segment automatically applies multiple rounds of smoothing
and grouping, so that different intermediate stages can be accessed
by clicking Ungroup multiple times. If regions are selected,
Ungroup will backtrack to the previous stage of grouping for
the selected region(s).
- If no segmentation regions are selected,
Group traverses the stages in the opposite direction as Ungroup,
or performs further grouping.
If regions are selected,
Group will combine the selected regions into a single group.
Segmentation region selection, showing/hiding,
and other manipulations can also be performed with the
shortcuts options or the
Segment Map Regions menu.
Segmentation results are included in saved
sessions.
They can also be saved separately using the Segment Map
File menu
or the save command.
Clicking Fit opens the
Fit to Segments tool.
Clicking Help shows
this page in the Help Viewer.
[back to top: Segment Map]
Segmenting Options:
-
Display at most [maxreg] regions, granularity
[triangle-size] voxels
– limit the number of displayed regions
to maxreg (default 60 largest) and set surface
triangle-size (default 1).
If more regions than maxreg are generated, however,
those which are not displayed will still be included in
subsequent smoothing and grouping calculations.
Smaller surface triangles give a smoother appearance,
but more triangles take longer to render. The default triangle-size
of 1 gives triangles comparable in size to the map grid spacing.
A value of 2 will make the triangles twice as large (quadruple the area)
and reduce their number by about a factor of 4.
If response time after segmentation is slow, try
decreasing maxreg and/or increasing triangle-size.
- Keep regions having at least [minsize] voxels,
[mincontact] contact voxels
– throw out regions containing fewer than minsize voxels
(default 1) or having fewer than
mincontact contact voxels (default 0) with other regions.
These apply only to the initial segmentation, not after smoothing.
The default settings retain all regions.
- Group by smoothing [N] steps of size [M],
stop at [minreg] regions
– whether to group by smoothing right after watershed segmentation
(when the Segment button is clicked),
and if so, how many rounds of automatic smoothing and grouping to perform
(default N=4) and how much smoothing to perform at each round
(default M=1).
If a round would give fewer than minreg regions (default 1),
the process is backtracked to the previous round of automatic grouping.
Grouping by smoothing is on by default and mutually exclusive with
grouping by connectivity.
If L is the minimum of the grid spacing along the three axes,
the standard deviation of the Gaussian used for smoothing
will be MxL in the first round and increase
by MxL in each subsequent round.
A single round consists of smoothing the data, then letting each
local maximum point from the previous round move by steepest ascent
to the location of a new local maximum.
If two or more previous maxima converge on a new maximum,
their regions from the previous round are coalesced into a single region.
In general, the number of rounds N is the dominant parameter to adjust
when fewer, larger regions are desired. A larger step size M may be
beneficial for noisier maps. However, a smaller step size gives more gradual
changes per round, thus more rounds to achieve a similar end result, and more
intermediate stages that can be traversed with the
Group and Ungroup buttons.
After the automatic rounds have completed, clicking Group
executes the minimum number of additional rounds needed to
change the grouping further.
-
Group by connectivity [N] steps, stop at [minreg] regions
☐ only visible
– whether to group watershed regions based on density connections,
and if so, whether to use only the visible regions.
If the density map has not been segmented already, watershed
segmentation will use only the voxels with density values above
the current threshold
without subsequent smoothing/grouping. Clicking Group
will then perform the specified number of rounds (steps) of
grouping by connectivity (default N=20).
Each round corresponds to one pass through contact list.
If a round would give fewer than minreg regions (default 1),
the process is backtracked to the previous round.
If grouping has already been performed,
some ungrouping may be needed before using the connectivity method,
as it will not group watershed regions together if they are already
in different groups.
[back to top: Segment Map]
Shortcuts Options:
- Select regions:
- All
- Over Sel. Atoms – those overlapping
selected atoms
- Invert – invert selection
- Not-Grp – those not containing any subregions
- Grouped – those comprising ≥ 2 subregions
- Selected regions:
(act on selected regions)
- Hide
- Show
- Delete
- Tr. – transparent surface
- Opaque – opaque surface
- Mesh
- Show regions:
- None
- All – all (but subject to the
Display at most... setting)
- Only Sel. –
selected regions
- Adj. – regions adjacent to any
selected regions
- Not-Grp – those not containing any subregions
- Grouped – those comprising ≥ 2 subregions
- Other tools:
- Fit – Fit to Segments
– not implemented –
- Extract – detailed options for extracting densities within
the selected regions
- iSeg – radial/icosahedral segmentation
- ProMod – probabilistic modeling of multiple conformations
- ModelZ – assess how well structural features are resolved
[back to top: Segment Map]
Segment Map Menu
Menu entries apply only to the current segmentation
unless stated otherwise.
File
- Open segmentation...
open a previously saved Segger segmentation file
- Save segmentation
– save the segmentation to a Segger file,
name/location previously specified
- Save segmentation as...
save the segmentation to a Segger file,
specify name/location
- Save selected regions to .mrc file...
save density map masked by the
selected segmentation regions
to an MRC file
(map dimensions set to the minimal box containing the regions)
- Save all regions to .mrc file...
save density map masked by all segmentation regions collectively
as an MRC file
(map dimensions set to the minimal box containing the regions)
- Save each region to .mrc file...
save density map masked by each
selected segmentation region
as a separate MRC file
(map dimensions set to the minimal box containing the corresponding region);
if no regions are selected, all are used
- Close segmentation
– close the current segmentation model
- Close all segmentations except displayed
– close all hidden segmentation models
- Close all segmentations
– close all segmentation models
- Associate Selected
– associate the current segmentation
with the map currently chosen in the dialog
(useful when the map has been opened separately or from a different
location than expected by the session with the segmentation results)
Regions
- Show all
– show all segmentation regions at the current level of grouping
- Show only selected
– show the selected
segmentation regions, hide all others
- Show adjacent
– show regions in contact with the
selected regions
- Show grouping
– show the watershed regions within groups
rather than the larger group surfaces;
affects the selected
regions, or if none are selected, all regions; does not change the
groupings, only how they are shown
- Unshow grouping
– show the larger group surfaces rather than the watershed regions;
affects the selected
regions, or if none are selected, all regions
- Hide
– undisplay the selected
regions, or if none are selected, all regions
- Make transparent
– make 55% transparent the selected
regions, or if none are selected, all regions
- Make opaque
– make opaque (0% transparent) the
selected
regions, or if none are selected, all regions
- Color density map
– color the density map display to match all regions
(subsequently changing the threshold
will erase the coloring for volume displays
in the surface or mesh style)
- Select groups
– select
all regions composed of grouped watershed regions
- Select boundary regions
– select
regions that contain at least one grid point within three voxels
of the edge of the density map
- Invert selection
– deselect the selected regions
and vice versa
- Regions overlapping current selection
– select
any regions that overlap well with the currently
selected atoms, deselect the atoms
- Delete selected regions
– delete the selected regions
(cannot be undone)
- Delete all except selected
– delete all regions except those which are
selected (cannot be undone)
- Enclosed volume
– report the approximate total volume enclosed by the
selected regions
(number of grid points and Å3 value obtained by multiplying
the number of grid points by the voxel volume); more precise measurements
can be obtained with Measure
and Color Blobs
- Mean and SD
– report density map mean and standard deviation within each
selected region
of the current segmentation, which could be
based on a binned version of the chosen map
- Extract densities...
not yet implemented
- Subtract selected from map
– inverse-mask the density map with the
selected regions
(create a new map: set the density values inside the regions to zero,
copy values elsewhere, maintain original map dimensions)
- Show axes for selected
– show principal axes of inertia as arrows for each
selected region
- Hide all axes
– remove all principal axes arrows
- Attributes table...
not yet implemented
- How many sub-regions
– report number of subregions that have been grouped into the
selected region(s)
[back to top: Segment Map]
Response Time
High number of surface triangles.
The number of surface triangles can be reduced by increasing the
granularity (triangle size).
Doubling the value will reduce the number of triangles by approximately
a factor of 4 and may improve rendering speed by a similar factor.
The display can also be limited to a specified
maximum number of regions.
Selected surfaces.
ChimeraX shows selections with
outlines, which increase the time to draw a frame.
Clearing a selection when it is not needed improves performance.
UCSF Resource for Biocomputing, Visualization, and Informatics /
July 2023