Skip to content

Filtering, thresholding, masking 3D models

Michael A. Cianfrocco edited this page Jun 9, 2018 · 2 revisions

Home > RCT OTR overall workflow > Filtering, thresholding, masking 3D models

##Filtering, thresholding, masking 3D models

There are times during EM analysis where it is useful to mask away densities that are outside of a given distance from your macromolecular structure. The following script will mask a 3D model given a specific threshold and output a masked volume.

Inputs required:

  • 3D volume in .mrc or .spi format
  • A threshold used to create a binary mask. This threshold number can be seen in Chimera's 'Volume Viewer', where the number shown along the histogram is the current viewed threshold of your structure. Select a threshold that shows your protein density without any satellite densities.
  • You also need a pixel value that will expand the thresholded mask. This will make sure that your mask is LARGER than your actual EM map density.

To run the script:

$ EM-processing-master/Analysis/threshold_mask_volume.py 
Usage: threshold_mask_volume.py -v  --thresh= --dilate=

Options:
  -h, --help      show this help message and exit
  -v FILE         Volume to be threshold-masked (.mrc or .spi)
  --thresh=float  Value to threshold the map density to create mask.
                  (Retrieved from Chimera's volume viewer histogram value when
                  viewing struture)
  --dilate=INT    Amount (in pixels) to expand the thresholded structure to
                  create a shape mask
  -d              debug

Example command:

$ EM-processing-master/Analysis/threshold_mask_volume.py -v run1_local_ct15_it015_class003.mrc --thresh=0.0078 --dilate=5

NOTE: You need to make sure that you are NOT masking away any protein density in your map. Instead, you should be masking away density that is outside of your protein density.

Clone this wiki locally