Commit 0dc226a9 authored by Julien Malik's avatar Julien Malik

DOC: improve doc and logs of classification chain

parent 8450523d
......@@ -44,7 +44,7 @@ private:
SetDescription("Estimate mean/standard deviation for all images in the input list. Possibility to write the output in an xml file or just display the result.");
SetDescription("Estimate mean/standard deviation for all images in the input list and optionally save the results in an XML file");
virtual ~EstimateImagesStatistics()
......@@ -54,8 +54,8 @@ private:
void DoCreateParameters()
AddParameter(ParameterType_InputImageList, "il", "Input Image List");
AddParameter(ParameterType_Filename, "out", "Output xml file");
SetParameterDescription( "out", "If set, will write the statistics into the given html file." );
AddParameter(ParameterType_Filename, "out", "Output XML file");
SetParameterDescription( "out", "Name of the XML file where the statistics are saved for future reuse" );
......@@ -70,7 +70,7 @@ private:
SetDescription("Perform SVM classification based a previous computed svm model to an new input image.");
SetDescription("Perform SVM classification based a previous computed SVM model");
virtual ~ImageSVMClassifier()
......@@ -91,7 +91,7 @@ private:
AddParameter(ParameterType_Filename, "svm", "SVM Model.");
SetParameterDescription("svm", "An estimated svm model previously computed");
SetParameterDescription("svm", "An estimated SVM model previously computed");
AddParameter(ParameterType_OutputImage, "out", "Output Image");
SetParameterDescription( "out", "Output labeled image");
......@@ -105,16 +105,15 @@ private:
void DoExecute()
otbAppLogDEBUG("Entering DoExecute");
// Load input image
FloatVectorImageType::Pointer inImage = GetParameterImage("in");
// Load svm model
otbAppLogINFO("Loading SVM model");
m_ModelSVM = ModelType::New();
otbAppLogINFO("SVM model loaded");
// Normalize input image (optional)
StatisticsReader::Pointer statisticsReader = StatisticsReader::New();
......@@ -129,13 +128,13 @@ private:
// Normalize input image if asked
if( HasValue("imstat") )
otbAppLogDEBUG("Input image normalization activated.");
otbAppLogINFO("Input image normalization activated.");
// Load input image statistics
meanMeasurementVector = statisticsReader->GetStatisticVectorByName("mean");
stddevMeasurementVector = statisticsReader->GetStatisticVectorByName("stddev");
otbAppLogDEBUG( "mean used: " << meanMeasurementVector );
otbAppLogDEBUG( "standard deviation used: " << stddevMeasurementVector );
otbAppLogINFO( "mean used: " << meanMeasurementVector );
otbAppLogINFO( "standard deviation used: " << stddevMeasurementVector );
// Rescale vector image
......@@ -145,14 +144,14 @@ private:
otbAppLogDEBUG("Input image normalization deactivated.");
otbAppLogINFO("Input image normalization deactivated.");
if( HasValue("mask") )
otbAppLogDEBUG("Use input mask.");
otbAppLogINFO("Using input mask");
// Load mask image and cast into LabeledImageType
FloatVectorImageType::Pointer inMask = GetParameterImage("mask");
ExtractImageFilterType::Pointer extract = ExtractImageFilterType::New();
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment