e2proc2d

Generic 2-D image processing program. The main tasks this program can be used for are:

Options:

--apix

float

A/pixel for S scaling

--average

bool

Averages all input images (without alignment) and writes a single output image

--calcsf

string

calculate a radial structure factor for the image and write it to the output file, must specify apix. divide into <n> angular bins

--clip

string

Specify the output size in pixels xsize,ysize[,xcenter,ycenter], images can be made larger or smaller.

--exclude

string

Excludes image numbers in EXCLUDE file

--fftavg

string

Incoherent Fourier average of all images and write a single power spectrum image

--process

string

apply a processor named 'processorname' with all its parameters/values.

--mult

float

Multiply image by a constant. mult=-1 to invert contrast.

--first

int

the first image in the input to process [0 - n-1])

--last

int

the last image in the input to process

--list

string

Works only on the image numbers in LIST file

--inplace

bool

Output overwrites input, USE SAME FILENAME, DO NOT 'clip' images.

--interlv

string

Specifies a 2nd input file. Output will be 2 files interleaved.

--meanshrink

int

Reduce an image size by an integral scaling factor using average. Clip is not required.

--medianshrink

int

Reduce an image size by an integral scaling factor, uses median filter. Clip is not required.

--mraprep

bool

this is an experimental option

--mrc16bit

bool

output as 16 bit MRC file

--mrc8bit

bool

output as 8 bit MRC file

--multfile

string

Multiplies the volume by another volume of identical size. This can be used to apply masks, etc.

--norefs

bool

Skip any input images which are marked as references (usually used with classes.*)

--outtype

string

output image format, 'mrc', 'imagic', 'hdf', etc. if specify spidersingle will output single 2D image rather than 2D stack.

--radon

bool

Do Radon transform

--randomize

string

Randomly rotate/translate the image. Specify: da,dxy,flip da is a uniform distribution over +-da degrees, dxy is a uniform distribution on x/y, if flip is 1, random handedness changes will occur

--rotate

float

Rotate clockwise (in degrees)

--rfp

bool

this is an experimental option

--fp

int

This generates rotational/translational 'footprints' for each input particle, the number indicates which algorithm to use (0-6)

--scale

float

Scale by specified scaling factor. Clip must also be specified to change the dimensions of the output map.

--selfcl

int

Output file will be a 180x180 self-common lines map for each image.

--setsfpairs

bool

Applies the radial structure factor of the 1st image to the 2nd, the 3rd to the 4th, etc

--split

int

Splits the input file into a set of n output files

--translate

string

Translate by x,y pixels

--writejunk

bool

Writes the image even if its sigma is 0.

--swap

bool

Swap the byte order

--threed2threed

bool

Process 3D image as a statck of 2D slice, then output as a 3D image

--threed2twod

bool

Process 3D image as a statck of 2D slice, then output as a 2D stack

--twod2threed

bool

Process a stack of 2D images, then output as a 3D image

This program operates on both single 2-D image files, image stacks, EMAN2 BDB databases, and can even treat 3-D volumes as a stack of 2-D images for individual processing. It has many command-line options for specific tasks. The generic '--process' option is by far the most powerful, offering access to 180+ different image processing operations. For a list, type e2help.py processors.

For specific details on various options, use e2proc2d.py --help.

Examples

convert IMAGIC format test.hed to HDF format:

e2proc2d.py test.hed test.hdf           

extract a subset of particles from a BDB database and convert to HDF format

e2proc2d.py bdb:particles#stack1 newfile.hdf --first=100 --last=150

apply a 10 A low-pass filter to a stack of particles and write output to a new file.

e2proc2d.py ptcl.hdf ptcl.filt.hdf --process=filter.lowpass.gauss:cutoff_freq=0.1

invert the contrast in a BDB database. Overwrite the original images

e2proc2d.py bdb:particles#set1 bdb:particles#set1 --inplace --mult=-1