convolve2
Contents: Description, Arguments, Usage, Examples, Images, Related Functions Supported Under Version: > 1.71 Current Davinci Version: 2.27 64-bit Safe: Yes
Description Computes a sliding window kernel convolution.(AKA kernel filter, smooth). Same as thm.convolve
Arguments and Return Values Arguments: A numeric array, a kernel (filtering array) and an ignore value Return Value: An array the size of the input object.
Usage Syntax: convolve2(object = VAL, kernel = VAL [, normalize = 1] [, ignore = VAL] [, kernreduce = 1]) 'object' - Any numeric array of up to 3 dimensions 'kernel' - A numeric array used to convolve the data. Boxcar filters simply take the average of all pixels within a certain 'radius'. Sawtooth and gaussian filters are used to favor pixels near to the pixel being convolved. 'normalize' - Whether to normalize the output to the weight of the kernel. Default is yes (1). 'ignore' - The value of pixels not filled with valid data. Default is 0. 'kernreduce' - thm.convolve() provides the user the option to reduce the size of the kernel as the convolve operation approaches an edge. This allows the convolution to not be weighted toward the values on the interior of the array. This is primarily useful in arrays where values roll-off or ramp-up near an edge. For each pixel in object, the weighted sum of the neighboring pixels is computed, with the weights being specified by the kernel. convolve2() will NOT fill in ignore values in the smoothed array with interpolated points. Instead it will fill null pixels in with the ignore value.
Examples dv> b 1x272x1 array of double, bsq format [2,176 bytes] dv> kern = clone(1.0,1,25,1) 1x25x1 array of float, bsq format [100 bytes] 1.00000 1.00000 1.00000 1.00000 1.00000 1.00000 1.00000 1.00000 1.00000 1.00000 1.00000 1.00000 1.00000 1.00000 1.00000 1.00000 1.00000 1.00000 1.00000 1.00000 1.00000 1.00000 1.00000 1.00000 1.00000 dv> thmconvolve = convolve(b,kern) 1x272x1 array of float, bsq format [1,088 bytes] dv> kernreduce = convolve(b,kern,kernreduce=1) 1x272x1 array of float, bsq format [1,088 bytes]
|
DavinciWiki Mini-Nav Bar Contents
Contact Developers
All other topics
Recent Core Changes Modified On: 07-06-2009 |