NMRPipe Processing Functions
IMG: Image Processing Utilities.

 Flag Argument Default Description ` -conv` Apply Convolution Filter (Default). Requires -kern ...
Statistical Filters and Options:
 ` -median` Median. ` -min` Minimum (Erosion). ` -max` Maximum (Dilation). ` -amin` Minimum Absolute Value. ` -amax` Maximum Absolute Value. ` -range` Range. ` -avg` Average. ` -dev` Standard Deviation. ` -thresh` `t` `0.0` Use Threshold t for Selection.
General Filter Parameters:
 ` -dx` `dx` `1` +/- Filter Width, Points. ` -dy` `dy` `1` +/- Filter Height, Points.
Convolution Filter Parameters:
 ` -kern` `kList` List of Kernel Values.

IMG provides some simple image processing filters primarily intended for 2D planes. Given a 2D plane Zi,j, a given filter creates a new 2D plane Z'i,j where a given point Z'i=x,j=y is a function F( ) of all points in a rectangular region of the original 2D plane, where the region sizes are specified in terms of +/- points dx and dy:

Z'i=x,j=y = F( Zk,m ) where k = x - dx to x + dx, and m = y - dy to y + dy.

Regions which extend past the edges of the image are wrapped to the opposite sides. The function applied is specified according to the following flags:

 Flag Function F( ) -conv Convolution (Default) -median Median -min Minimum (Erosion). -max Maximum (Dilation). -amin Minimum Absolute Value. -amax Maximum Absolute Value. -range Range. -avg Average. -dev Standard Deviation.

OPTIONS

`-kern cList`
This option is used to specify the coefficients Ck,m used in the case where a convolution in applied:

Z'i=x,j=y = Ck,mZi+k-dx,j+m-dy where k = 0 to 2 dx, and m = 0 to 2 dy.

`-dx dx`
Specifies dx, the +/- X-Axis size of the image processing neighborhood, in points.

`-dy dy`
Specifies dy, the +/- Y-Axis size of the image processing neighborhood, in points.

`-thresh t`
If a threshold option is given, only points in the original image which are greater than the specified will be used for computing F().

EXAMPLES

The following is an example of a convolution filter which corresponds to a simple form of image sharpening. The coefficients of the 3x3 convolution kernel are listed on multiple lines to emphasize their two-dimensional structure, although this is not required:

```   nmrPipe -in image.dat \
| nmrPipe -fn IMG -dx 1 -dy 1 -conv \
-kern   -1 -1 -1 \
-1  9 -1 \
-1 -1 -1 \
-out sharp.dat -ov
```

[ Home ] [ NIH ] [ NIDDK ] [ Disclaimer ] [ Copyright ]
last updated: Jul 24, 2011 / Webmaster