calculation of ostu threshold while computing PFTAS descriptor

16 views
Skip to first unread message

Arvind Kumar

unread,
Oct 28, 2018, 12:42:16 AM10/28/18
to pythonvision
 Hi all,
Please someone explain me, why we are only considering gray level threshold while calculating PFTAS features over color images in mahotas. It should be computed independently over each RGB channel.
But in the implementation we are using only single gray level otsu threshold.

Thank You.

Luis Pedro Coelho

unread,
Oct 28, 2018, 12:45:05 AM10/28/18
to Arvind Kumar, pythonvision
PFTAS is a grey-level feature, but can be computed on 3D images.

As mahotas uses numpy arrays, if you pass it an array (s0,s1,3), it is going to treat that as a 3D image, not an RGB image of size s0 x s1.

You have to iterate over the different channels yourself.

HTH,
Luis

Luis Pedro Coelho | Fudan University | http://luispedro.org
--
You received this message because you are subscribed to the Google Groups "pythonvision" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pythonvision...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Arvind Kumar

unread,
Oct 28, 2018, 1:31:19 AM10/28/18
to lu...@luispedro.org, python...@googlegroups.com
Thanks for replying Luis.
Would you please suggest that whether it would be better to use global grey level threshold or threshold for each channel in case of RGB images.
As Mahotas's pftas descriptor provide support for color images, but it uses grey level threshold only. Is there some specific reason for this approach?

Luis Pedro Coelho

unread,
Oct 28, 2018, 1:33:12 AM10/28/18
to Arvind Kumar, python...@googlegroups.com
On Mon, 29 Oct 2018, at 6:26 AM, Arvind Kumar wrote:
Thanks for replying Luis.
Would you please suggest that whether it would be better to use global grey level threshold or threshold for each channel in case of RGB images.

Almost always, it would say it should be channel specific.

As Mahotas's pftas descriptor provide support for color images, but it uses grey level threshold only. Is there some specific reason for this approach?

As I wrote, there is no support for color images. mahotas is interpreting the RGB image as a volume (Which is probably not what you want!)

HTH,
Luis

--
Luis Pedro Coelho | Fudan University | http://luispedro.org




Reply all
Reply to author
Forward
0 new messages