bmorph - binary morphological transforms

버전 1.4.0.0 (152 KB) 작성자: tudor dima
Fast binary erosion and dilation, with even faster iterative calls.
다운로드 수: 1.6K
업데이트 날짜: 2012/4/30

라이선스 보기

This function performs binary erosion or dilation.

It is faster than imerode.m and imdilate.m -- by more than an order of magnitude for any structuring element other than 'square' or 'disk' .
The only time it is slightly slower (about 10%) is for very small 'square' or 'disk' strels only.
Moreover, ’disk’ structuring elements in Matlab are actually octagonal, and often times a
true ’circular’ element is necessity.

It also comes in very handy when you don't have the Matlab Image Processing Toolbox :-)...

The function also allows very fast iterative calls which re-use the work done at previous iterations. (for instance when sweeping the size/size+shape of the structuring element while looking for a certain effect, a threshold in image statistics, etc.)
This re-use will make the speed increase compound exponentially, and one can also break the execution when desired.

For 2-3M pix images and strels in the range of 10-20 pixels the speed increase can be around 20x - 100x (depending on the machine cache, slightly on strel shape, etc.), with higher values as the image and/or strel size increase.

Simple call:
------------------------------------------
IMG_OUT = BMORPH(IMG_IN, SE, DilateNotErode, [], ObjStopAtEdge)

IMG_DIL = BMORPH(IMG_IN, SE, true); % dilate
IMG_ERO = BMORPH(IMG_IN, SE, false); % erode
% erode assuming the objects stop at edge :
IMG_ERO = BMORPH(IMG_IN, SE, false, [], true);

For iterative calls and more info on execution speed see the help in bmorph.m and the attached .pdf file.

인용 양식

tudor dima (2026). bmorph - binary morphological transforms (https://kr.mathworks.com/matlabcentral/fileexchange/26493-bmorph-binary-morphological-transforms), MATLAB Central File Exchange. 검색 날짜: .

MATLAB 릴리스 호환 정보
개발 환경: R2007b
모든 릴리스와 호환
플랫폼 호환성
Windows macOS Linux
카테고리
Help CenterMATLAB Answers에서 Morphological Operations에 대해 자세히 알아보기
버전 게시됨 릴리스 정보
1.4.0.0

v.0.3b, 29.04.2012
- allow asymmetrical strels
- small speed improvements

1.0.0.0