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

Home » Public Forums » archive » Re: Q: uniq value in an image?
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
Re: Q: uniq value in an image? [message #11834] Fri, 29 May 1998 00:00
davidf is currently offline  davidf
Messages: 2866
Registered: September 1996
Senior Member
Herbert Tsang (htsang@mda.ca) writes:

> I am using this to find the unique values in an image:
>
> uniqPixelValue = data(uniq(data, sort(data)))
>
> and the sorting part is taking a long time when the image is big.
>
> Just wonder, if anyone out there has any bright idea to do this?

I'm too tired tonight to test this, but how about something
like this:

unique_values = Where(Histogram(image) EQ 1)
Print, (Histogram(image))[unique_values]

Cheers,

David

-----------------------------------------------------------
David Fanning, Ph.D.
Fanning Software Consulting
E-Mail: davidf@dfanning.com
Phone: 970-221-0438
Coyote's Guide to IDL Programming: http://www.dfanning.com/
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: PostScript and IDL,
Next Topic: Re: IDL & SNAKES!

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

Current Time: Fri Oct 10 23:13:28 PDT 2025

Total time taken to generate the page: 0.32247 seconds