comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Cell boundary program?
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Cell boundary program? [message #21117] Mon, 07 August 2000 00:00 Go to next message
Alexandros Pertsinidi is currently offline  Alexandros Pertsinidi
Messages: 2
Registered: August 2000
Junior Member
I am looking for an IDL program that determines the boundary of a cell. I
have a lot of video of cells (neurons). Ideally, I would like track the
change in their shape/size as time progresses. Does anyone know of anything
like this? Thank you very much!

Rachel
Re: Cell boundary program? [message #21131 is a reply to message #21117] Fri, 11 August 2000 00:00 Go to previous message
Richard Adams is currently offline  Richard Adams
Messages: 9
Registered: January 2000
Junior Member
Rick,
Well, just to be a little defensive I would say that in this instance
objects are useful. (Actually, I use them all the time and think they are a
very nice way to program IDL.) RSI have given us an easy way to measure
parameters from an IDLanROI object that would be tricky to write yourself. I
would think it easier to read the couple of pages that describe the object
than the chapter that would be needed to calculate the perimeter and area
(to calculate shape parameters) from an irregular path. But still the data
of the path is available to use in your own code if needed and the objects
give a convenient place to keep all the outlines together. And they can be
plotted in just one line! What can be simpler than that? What I added in
this posting, over the earlier one I sent that Ben re-posted, was that the
perimeter once found by convolution can be traced out in order. If you look
at the code (not very pretty, I know, but I wrote quickly) it is all
'regular IDL code' until it gives the perimeter values to the object. I see
now that it would be better to add them to the object a step at a time since
it allocates space in blocks rather than resizing the array each time around
the loop as I had it. Although in practice it does not seem to make much
difference to performance. Clearly the code could be made much nicer and
for Rachel's application maybe she needs to deal with just one outline so
you could search then the list of vertices is the result.

Well, that's my 2p worth.

Richard.

>
>> I'm a new IDL user and I don't know much about objects. What would I do
>> with a IDLgrROIGroup once I have it? How would I plot an outline? Thanks a
>> lot!!
>
> If your new to IDL (and programming in general) I suggest playing with
> the first suggestion put forth by Richard. IDL Objects are great. I
> love them. But I would never suggest that someone new to IDL start
> programming with them.
>
> I would also suggest getting a book on IDL programming. The RSI docs
> leave much to be desired. There are a few of them available. I started
> with David Fanning's book and found it a great for the beginner. I have
> Ron Kling's book on order but I am under the assumption that this book
> is geared more towards the intermediate programmer so it might not be
> what you are looking for.
>
> Good Luck!
>
> -Rick Towler
>
>
>> Richard Adams wrote in message ...
>>>> The other method, convolution is also quick, but the returned indices are
>> in
>>>> scan-line order. In this case, all the boundary pixels are included.
>> This
>>>> method was suggested by ... uhoh, I forgotten who it was right now,
>> sorry.
>>>> Here's the steps as described on the newsgroup by the unknown author.
>>>>
>>>> bb = convol(Image, replicate(1,3,3),9,/center)
>>>> Edges = Where(bb gt 0 AND bb LT 255)
>>>> bb[*] = 0
>>>> bb[edges] = 255 ; make this new image just edges
>>>> bb = Image AND BB ; now keep just those edges inside your object
>>>> perimeter = where(bb eq 255); these are indices to final outline
>>>>
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Reading in text data
Next Topic: Re: Draw widget mouse position error

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Fri Oct 10 01:31:15 PDT 2025

Total time taken to generate the page: 0.47656 seconds