Fast 2-D convolution

버전 1.3.0.0 (5.77 KB) 작성자: David Young
Speeds up many 2-D convolutions using the SVD; also finds a fast approximation in other cases.
다운로드 수: 8.9K
업데이트 날짜: 2014/3/20

라이선스 보기

CONVOLVE2 can be used wherever CONV2 is used, taking the same arguments and returning the same results to within a small tolerance. The computation is speeded up by using the singular value decomposition of the mask to express it as a sum of outer products. Each of these can be computed efficiently as convolution with a row and a column vector. CONV2 is used to carry out the individual convolutions.

Separable masks are a particular case and are handled by CONVOLVE2 much as FILTER2 does. Many other masks which are not separable have low rank (e.g. Gabor function masks) and are handled more efficiently by CONVOLVE2.

The function will also compute a reduced-rank approximation to a given mask if required and will use this if it will speed up the computation. An extra argument allows control over the error.

Additional shape options allow: (a) 2-D "circular" convolution - that is, the input array is taken to be periodic rather than surrounded by zeros; (b) a "reflection" boundary condition - that is, the input array is taken to be surrounded by reflected copies of itself.

See 'Computer and Robot Vision' Vol I, by R.M. Haralick and L.G. Shapiro (Addison-Wesley 1992), pp. 298-299.

인용 양식

David Young (2024). Fast 2-D convolution (https://www.mathworks.com/matlabcentral/fileexchange/22619-fast-2-d-convolution), MATLAB Central File Exchange. 검색됨 .

MATLAB 릴리스 호환 정보
개발 환경: R2013b
모든 릴리스와 호환
플랫폼 호환성
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
버전 게시됨 릴리스 정보
1.3.0.0

Alternative names for shape options for consistency with other functions.

1.2.0.0

Minor correction to help comments; updated exindex to current version.

1.1.0.0

Now uses exindex to simplify the boundary condition computation.

1.0.0.0