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

averager

string

If --average is specified, this is the averager to use (e2help.py averager). Default=mean

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

calccont

bool

Compute the low resolution azimuthal contrast of each image and put it in the header as eval_contrast_lowres. Larger values imply more 'interesting' images.

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.

add

float

Adds a constant 'f' to the densities

addfile

string

Adds the volume to another volume of identical size

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

select

string

Works only on the images in named selection set from bdb:select

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.

extractboxes

bool

Extracts box locations from the image header to produce a set of .box files for only the particles in the .lst files

meanshrink

float

Reduce an image size by an integral (1.5 also allowed) scaling factor using average. eg - 2 will reduce image size to 1/2. Clip is not required.

medianshrink

int

Reduce an image size by an integral scaling factor, uses median filter. eg - 2 will reduce image size to 1/2. Clip is not required.

fouriershrink

float

Reduce an image size by an arbitrary scaling factor by clipping in Fourier space. eg - 2 will reduce image size to 1/2.

mraprep

bool

this is an experimental option

outmode

string

All EMAN2 programs write images with 4-byte floating point values when possible by default. This allows specifying an alternate format when supported (float, int8, int16, int32, uint8, uint16, uint32). Values are rescaled to fill MIN-MAX range.

outnorescale

bool

If specified, floating point values will not be rescaled when writing data as integers. Values outside of range are truncated.

mrc16bit

bool

(deprecated, use --outmode instead) output as 16 bit MRC file

mrc8bit

bool

(deprecated, use --outmode instead) output as 8 bit MRC file

fixintscaling

string

When writing to an 8 or 16 bit integer format the data must be scaled. 'noscale' will assume the pixel values are already correct, 'sane' will pick a good range, a number will set the range to mean+=sigma*number

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

rotavg

bool

Compute the 1-D rotational average of each image as a final step before writing the output

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.

anisotropic

string

Anisotropic scaling, stretches on one axis and compresses the orthogonal axis. Specify amount,angle. See e2evalrefine

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

headertransform

int

This will take the xform.align2d header value from each particle, and apply it. Pass 0 to perform the transform or 1 to perform the inverse.

writejunk

bool

Writes the image even if its sigma is 0.

swap

bool

Swap the byte order

threed2threed

bool

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

threed2twod

bool

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

twod2threed

bool

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

unstacking

bool

Process a stack of 2D images, then output a a series of numbered single image files

ppid

int

Set the PID of the parent process, used for cross platform PPID

step

string

Specify <init>,<step>. Processes only a subset of the input data. For example, 0,2 would process only the even numbered particles

-v

verbose

int

verbose level [0-9], higner number means higher level of verboseness

-P

parallel

string

Run in parallel, specify type:n=<proc>:option:option

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

EMAN2/Programs/e2proc2d (last edited 2016-10-20 14:06:05 by SteveLudtke)