Hi,

Did not test it, but this should do the trick. If it works for you, I can push the patch.

Regards,

Julien

diff --git a/Modules/Applications/AppClassification/app/otbKMeansClassification.cxx b/Modules/Applications/AppClassification/app/otbKMeansClassification.cxx
index c7ba58f..e4b43ec 100644
--- a/Modules/Applications/AppClassification/app/otbKMeansClassification.cxx
+++ b/Modules/Applications/AppClassification/app/otbKMeansClassification.cxx
@@ -103,9 +103,9 @@ private:


 typedef FloatImageType::PixelType PixelType;
-typedef UInt8ImageType   LabeledImageType;
+typedef UInt16ImageType   LabeledImageType;

-typedef UInt8VectorImageType        VectorImageType;
+typedef UInt16VectorImageType        VectorImageType;
 typedef VectorImageType::PixelType  VectorPixelType;
 typedef UInt8RGBImageType           RGBImageType;
 typedef RGBImageType::PixelType     RGBPixelType;


Le 09/02/2016 16:42, Julien Radoux a écrit :
I've tried KMean application with 500 classes, and it seems to be internally limited to 255 classes. Is there a way to increase the number of classes (the number of classes was set to 500, and the output is in uint16, so this should be OK)
--
--
Check the OTB FAQ at
http://www.orfeo-toolbox.org/FAQ.html

You received this message because you are subscribed to the Google
Groups "otb-users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/otb-users?hl=en
---
You received this message because you are subscribed to the Google Groups "otb-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected] <mailto:[email protected]>.
For more options, visit https://groups.google.com/d/optout.


--
Julien MICHEL
CNES - DCT/SI/AP - BPI 1219
18, avenue Edouard Belin
31401 Toulouse Cedex 09 - France
Tel: +33 561 282 894 - Fax: +33 561 283 109

--
--
Check the OTB FAQ at
http://www.orfeo-toolbox.org/FAQ.html

You received this message because you are subscribed to the Google
Groups "otb-users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/otb-users?hl=en
--- You received this message because you are subscribed to the Google Groups "otb-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to