Path: news.mathworks.com!newsfeed-00.mathworks.com!NNTP.WPI.EDU!elk.ncren.net!newsflash.concordia.ca!canopus.cc.umanitoba.ca!not-for-mail
From: roberson@ibd.nrc-cnrc.gc.ca (Walter Roberson)
Newsgroups: comp.soft-sys.matlab
Subject: Re: How does bwlabel work?
Date: Thu, 31 Jan 2008 14:58:20 +0000 (UTC)
Organization: National Research Council Canada - Conseil national de rechereches Canada
Lines: 23
Message-ID: <fnsnmc$gar$1@canopus.cc.umanitoba.ca>
References: <fnrl3h$i3i$1@fred.mathworks.com> <14977013.1201760451936.JavaMail.jakarta@nitrogen.mathforum.org> <fnsdfi$it7$1@fred.mathworks.com> <fnsk56$1oh$1@fred.mathworks.com>
NNTP-Posting-Host: origin.ibd.nrc.ca
X-Trace: canopus.cc.umanitoba.ca 1201791500 16731 192.70.172.160 (31 Jan 2008 14:58:20 GMT)
X-Complaints-To: abuse@cc.umanitoba.ca
NNTP-Posting-Date: Thu, 31 Jan 2008 14:58:20 +0000 (UTC)
Originator: roberson@ibd.nrc-cnrc.gc.ca (Walter Roberson)
Xref: news.mathworks.com comp.soft-sys.matlab:448557


In article <fnsk56$1oh$1@fred.mathworks.com>,
Steve Eddins  <Steve.Eddins@mathworks.com> wrote:

>There's no way to tell bwlabel to search in a different order.  If it 
>did search in a different order, it would run significantly slower 
>because of memory cache effects.

You (the programmer desiring the "different order") could transpose
or fliplr or flipud the matrix first ;-)


I have never tried bwlabel(), so I do not have any feel for its
performance on different image sizes, and I have not looked at
the algorithm used. But as a user, I would think that if I have
good reasons to want a different search order, that I would accept
the performance implications that went along with chosing that
option. I would suggest, then, that you consider allowing an
optional parameter which is a permutation vector of the
(1-D) pixel indices, with the pixels to be visited in the order
of that vector.
-- 
   "I was very young in those days, but I was also rather dim."
   -- Christopher Priest