Commit c248088f authored by Victor Poughon's avatar Victor Poughon

DOC: fix cookbook warnings

parent ad7d7f72
......@@ -134,7 +134,7 @@ private:
void DoUpdateParameters() override
{
// Nothing to do here : all parameters are independent
// Nothing to do here: all parameters are independent
}
void DoExecute() override
......
......@@ -256,7 +256,7 @@ protected:
GetInternalApplication("training")->SetParameterString("io.out", modelFileName);
ExecuteInternal( "training" );
otbAppLogINFO("output model : " << GetInternalApplication("training")->GetParameterString("io.out"));
otbAppLogINFO("output model: " << GetInternalApplication("training")->GetParameterString("io.out"));
}
void ComputeImageStatistics( ImageBaseType * img,
......@@ -267,7 +267,7 @@ protected:
GetInternalApplication("imgstats")->SetParameterString("out", imagesStatsFileName);
ExecuteInternal( "imgstats" );
otbAppLogINFO("image statistics file : " << GetInternalApplication("imgstats")->GetParameterString("out"));
otbAppLogINFO("image statistics file: " << GetInternalApplication("imgstats")->GetParameterString("out"));
}
......@@ -288,7 +288,7 @@ protected:
std::ifstream infile(modelFileName);
if(!infile)
{
itkExceptionMacro(<< "File : " << modelFileName << " couldn't be opened");
itkExceptionMacro(<< "File: " << modelFileName << " couldn't be opened");
}
// get the line with the centroids (starts with "2 ")
......@@ -327,7 +327,7 @@ protected:
class KMeansFileNamesHandler
{
public :
public:
KMeansFileNamesHandler(const std::string &outPath)
{
tmpVectorFile = outPath + "_imgEnvelope.shp";
......@@ -403,21 +403,22 @@ private:
SetDescription("Unsupervised KMeans image classification");
SetDocName("Unsupervised KMeans image classification");
SetDocLongDescription("Performs unsupervised KMeans image classification."
SetDocLongDescription("Unsupervised KMeans image classification. "
"KMeansClassification is a composite application, "
"using an existing training and classification application."
"The SharkKMeans model is used.\n"
"using an existing training and classification application. "
"The SharkKMeans model is used.\n\n"
"KMeansClassification application is only available if OTB is compiled with Shark support"
"(CMake option OTB_USE_SHARK=ON)\n"
"The steps of this composite application :\n"
"1) ImageEnveloppe : create a shapefile (1 polygon),\n"
"2) PolygonClassStatistics : compute the statistics,\n"
"3) SampleSelection : select the samples by constant strategy in the shapefile "
"(CMake option :code:`OTB_USE_SHARK=ON`).\n\n"
"The steps of this composite application:\n\n"
"1) ImageEnvelope: create a shapefile (1 polygon),\n"
"2) PolygonClassStatistics: compute the statistics,\n"
"3) SampleSelection: select the samples by constant strategy in the shapefile "
"(1000000 samples max),\n"
"4) SamplesExtraction : extract the samples descriptors (update of SampleSelection output file),\n"
"5) ComputeImagesStatistics : compute images second order statistics,\n"
"6) TrainVectorClassifier : train the SharkKMeans model,\n"
"7) ImageClassifier : performs the classification of the input image "
"4) SampleExtraction: extract the samples descriptors (update of SampleSelection output file),\n"
"5) ComputeImagesStatistics: compute images second order statistics,\n"
"6) TrainVectorClassifier: train the SharkKMeans model,\n"
"7) ImageClassifier: performs the classification of the input image "
"according to a model file.\n\n"
"It's possible to choice random/periodic modes of the SampleSelection application.\n"
"If you want keep the temporary files (sample selected, model file, ...), "
......@@ -426,8 +427,8 @@ private:
SetDocLimitations("The application doesn't support NaN in the input image");
SetDocAuthors("OTB-Team");
SetDocSeeAlso("ImageEnveloppe PolygonClassStatistics SampleSelection SamplesExtraction "
"PolygonClassStatistics TrainVectorClassifier ImageClassifier\n"
SetDocSeeAlso("ImageEnvelope, PolygonClassStatistics, SampleSelection, SampleExtraction, "
"PolygonClassStatistics, TrainVectorClassifier, ImageClassifier.\n\n"
"[1] http://image.diku.dk/shark/sphinx_pages/build/html/rest_sources/tutorials/algorithms/kmeans.html");
AddDocTag(Tags::Learning);
......
......@@ -70,44 +70,45 @@ private:
"PolygonClassStatistics. The statistics file is then used to compute the "
"sampling rates for each class in each image. Several types of sampling "
" are implemented. Each one is a combination of a mono-image strategy "
"and a multi-image mode. The mono-image strategies are :\n\n"
" * smallest (default) : select the same number of sample in each "
"and a multi-image mode. The mono-image strategies are:\n\n"
"* smallest (default): select the same number of sample in each "
"class so that the smallest one is fully sampled.\n"
" * constant : select the same number of samples N in each class "
"* constant: select the same number of samples N in each class "
"(with N below or equal to the size of the smallest class).\n"
" * byclass : set the required number for each class manually, with an "
"* byclass: set the required number for each class manually, with an "
"input CSV file (first column is class name, second one is the required "
"samples number).\n\n"
"The multi-image modes (mim) are proportional, equal and custom. The custom "
"mode lets the users choose the distribution of samples among the "
"images. The different behaviours are described below. Ti(c) and Ni(c) "
" refers resp. to the total number and needed number of samples in "
"image i for class c. Let's call L the total number of images.\n"
" * strategy = all\n\n"
" - Same behaviour for all modes : take all samples\n\n"
" * strategy = constant :"
"image i for class c. Let's call L the total number of images.\n\n"
"* strategy = all\n\n"
" - Same behaviour for all modes: take all samples\n\n"
"* strategy = constant:"
" let's call M the global number of samples required per class."
" For each image i and each class c:\n\n"
" - if mim = proportional, then Ni( c ) = M * Ti( c ) / sum_k( Tk(c) )\n\n"
" - if mim = equal , then Ni( c ) = M / L\n\n"
" - if mim = custom , then Ni( c ) = Mi where Mi is the custom requested number of samples for image i\n\n"
" * strategy = byClass :"
"* strategy = byClass :"
" let's call M(c) the global number of samples for class c)."
" For each image i and each class c:\n\n"
" - if mim = proportional, then Ni( c ) = M(c) * Ti( c ) / sum_k( Tk(c) )\n\n"
" - if mim = equal , then Ni( c ) = M(c) / L\n\n"
" - if mim = custom , then Ni( c ) = Mi(c) where Mi(c) is the custom requested number of samples for image i and class c\n\n"
" * strategy = percent :"
"* strategy = percent :"
" For each image i and each class c:\n\n"
" - if mim = proportional, then Ni( c ) = p * Ti( c ) where p is the global percentage of samples\n\n"
" - if mim = equal , then Ni( c ) = p * sum_k(Tk(c)]/L where p is the global percentage of samples\n\n"
" - if mim = custom , then Ni( c ) = p(i) * Ti(c) where p(i) is the percentage of samples for image i. c\n\n"
" * strategy = total :"
"* strategy = total :"
" For each image i and each class c:\n\n"
" - if mim = proportional, then Ni( c ) = total * (sum_k(Ti(k))/sum_kl(Tl(k))) * (Ti(c)/sum_k(Ti(k))) where total is the total number of samples specified.\n\n"
" - if mim = equal , then Ni( c ) = (total / L) * (Ti(c)/sum_k(Ti(k))) where total is the total number of samples specified.\n\n"
" - if mim = custom , then Ni( c ) = total(i) * (Ti(c)/sum_k(Ti(k))) where total(i) is the total number of samples specified for image i. \n\n"
" * strategy = smallest class\n\n"
"* strategy = smallest class\n\n"
" - if mim = proportional, then the smallest class size (computed globally) is used for the strategy constant+proportional.\n\n"
" - if mim = equal , then the smallest class size (computed globally) is used for the strategy constant+equal.\n\n"
" - if mim = custom , then the smallest class is computed and used for each image separately."
......
......@@ -70,17 +70,17 @@ private:
AddParameter(ParameterType_InputVectorData, "inshp", "Name of the input shapefile");
SetParameterDescription("inshp","Name of the input shapefile");
AddParameter(ParameterType_InputFilename, "instats", "XML file containing mean and variance of each feature.");
AddParameter(ParameterType_InputFilename, "instats", "XML file containing mean and variance of each feature");
SetParameterDescription("instats", "XML file containing mean and variance of each feature.");
AddParameter(ParameterType_OutputFilename, "insvm", "Input model filename.");
AddParameter(ParameterType_OutputFilename, "insvm", "Input model filename");
SetParameterDescription("insvm", "Input model filename.");
AddParameter(ParameterType_ListView, "feat", "Features");
SetParameterDescription("feat","Features to be calculated");
AddParameter(ParameterType_String,"cfield","Field containing the predicted class.");
AddParameter(ParameterType_String,"cfield","Field containing the predicted class");
SetParameterDescription("cfield","Field containing the predicted class");
SetParameterString("cfield","predicted");
......
......@@ -74,18 +74,18 @@ private:
// Documentation
SetDocName("Polygon Class Statistics");
SetDocLongDescription("The application processes a set of geometries "
"intended for training (they should have a field giving the associated "
"class). The geometries are analyzed against a support image to compute "
"statistics : \n"
" - number of samples per class\n"
" - number of samples per geometry\n"
SetDocLongDescription("Process a set of geometries intended for training (they should have a field giving the associated "
"class). The geometries are analyzed against a support image to compute statistics:\n\n"
"* Number of samples per class\n"
"* Number of samples per geometry\n\n"
"An optional raster mask can be used to discard samples. Different types"
" of geometry are supported : polygons, lines, points. The behaviour is "
"different for each type of geometry :\n"
" - polygon: select pixels whose center is inside the polygon\n"
" - lines : select pixels intersecting the line\n"
" - points : select closest pixel to the point");
" of geometry are supported: polygons, lines, points. The behaviour is "
"different for each type of geometry:\n\n"
"* Polygon: select pixels whose center is inside the polygon\n"
"* Lines: select pixels intersecting the line\n"
"* Points: select closest pixel to the point");
SetDocLimitations("None");
SetDocAuthors("OTB-Team");
SetDocSeeAlso(" ");
......
......@@ -146,10 +146,11 @@ private:
SetParameterDescription("iv", "Maximum initial neuron weight");
MandatoryOff("iv");
AddRANDParameter();
AddRAMParameter();
// TODO : replace StreamingLines by RAM param ?
AddRANDParameter();
// Default parameters
SetDefaultParameterFloat("tp", 1.0);
SetDefaultParameterInt("sx", 32);
......
......@@ -94,7 +94,7 @@ private:
"be generated.");
SetDefaultParameterInt("samples",100);
AddParameter(ParameterType_ListView, "exclude", "Field names for excluded features.");
AddParameter(ParameterType_ListView, "exclude", "Field names for excluded features");
SetParameterDescription("exclude",
"List of field names in the input vector data that will not be generated in the output file.");
......@@ -122,8 +122,7 @@ private:
"by using the SMOTE algorithm (http://dx.doi.org/10.1613/jair.953) "
"on input samples which are "
"randomly selected with replacement.");
AddParameter(ParameterType_Int, "strategy.smote.neighbors",
"Number of nearest neighbors.");
AddParameter(ParameterType_Int, "strategy.smote.neighbors", "Number of nearest neighbors");
SetParameterDescription("strategy.smote.neighbors",
"Number of nearest neighbors to be used in the "
"SMOTE algorithm");
......
......@@ -213,10 +213,10 @@ private:
ElevationParametersHandler::AddElevationParameters(this, "elev");
AddRAMParameter();
AddRANDParameter();
AddRAMParameter();
// Doc example parameter settings
SetDocExampleParameterValue("in", "support_image.tif");
SetDocExampleParameterValue("vec", "variousVectors.sqlite");
......
......@@ -126,7 +126,7 @@ private:
"Caution, the 'cfield' must not exist in the input file if you are updating the file.");
SetParameterString("cfield","predicted");
AddParameter(ParameterType_ListView, "feat", "Field names to be calculated.");
AddParameter(ParameterType_ListView, "feat", "Field names to be calculated");
SetParameterDescription("feat","List of field names in the input vector data used as features for training. "
"Put the same field names as the TrainVectorClassifier application.");
......
......@@ -32,20 +32,18 @@ void LearningApplicationBase<TInputValue, TOutputValue>::InitSharkKMeansParams()
{
AddChoice( "classifier.sharkkm", "Shark kmeans classifier" );
SetParameterDescription("classifier.sharkkm", "http://image.diku.dk/shark/sphinx_pages/build/html/rest_sources/tutorials/algorithms/kmeans.html ");
//MaxNumberOfIterations
AddParameter( ParameterType_Int, "classifier.sharkkm.maxiter",
"Maximum number of iteration for the kmeans algorithm." );
SetParameterInt( "classifier.sharkkm.maxiter", 10 );
SetMinimumParameterIntValue( "classifier.sharkkm.maxiter", 0 );
SetParameterDescription( "classifier.sharkkm.maxiter",
"The maximum number of iteration for the kmeans algorithm. 0=unlimited" );
//MaxNumberOfIterations
AddParameter( ParameterType_Int, "classifier.sharkkm.k", "The number of class used for the kmeans algorithm." );
SetParameterInt( "classifier.sharkkm.k", 2 );
SetParameterDescription( "classifier.sharkkm.k",
"The number of class used for the kmeans algorithm. Default set to 2 class" );
SetMinimumParameterIntValue( "classifier.sharkkm.k", 2 );
// MaxNumberOfIterations
AddParameter(ParameterType_Int, "classifier.sharkkm.maxiter", "Maximum number of iterations for the kmeans algorithm");
SetParameterInt("classifier.sharkkm.maxiter", 10);
SetMinimumParameterIntValue("classifier.sharkkm.maxiter", 0);
SetParameterDescription("classifier.sharkkm.maxiter", "The maximum number of iterations for the kmeans algorithm. 0=unlimited");
// Number of classes
AddParameter(ParameterType_Int, "classifier.sharkkm.k", "Number of classes for the kmeans algorithm");
SetParameterInt("classifier.sharkkm.k", 2);
SetParameterDescription("classifier.sharkkm.k", "The number of classes used for the kmeans algorithm. Default set to 2 class");
SetMinimumParameterIntValue("classifier.sharkkm.k", 2);
}
template<class TInputValue, class TOutputValue>
......
......@@ -36,7 +36,7 @@ void TrainVectorBase::DoInit()
AddParameter( ParameterType_InputVectorDataList, "io.vd", "Input Vector Data" );
SetParameterDescription( "io.vd",
"Input geometries used for training (note : all geometries from the layer will be used)" );
"Input geometries used for training (note: all geometries from the layer will be used)" );
AddParameter( ParameterType_InputFilename, "io.stats", "Input XML image statistics file" );
MandatoryOff( "io.stats" );
......
......@@ -87,7 +87,7 @@ private:
SetDescription("Compute homologous points between images using keypoints");
SetDocLongDescription("This application allows computing homologous points between images using keypoints. "
" SIFT or SURF keypoints can be used and the band on which keypoints are computed can be set independently for both images."
" The application offers two modes :"
" The application offers two modes:"
" the first is the full mode where keypoints are extracted from the full extent of both images"
" (please note that in this mode large image file are not supported). "
"The second mode, called geobins, allows one to set-up spatial binning to get fewer points"
......@@ -143,7 +143,7 @@ private:
SetMinimumParameterFloatValue("threshold",0.0);
SetDefaultParameterFloat("threshold",0.6);
AddParameter(ParameterType_Bool,"backmatching","Use back-matching to filter matches.");
AddParameter(ParameterType_Bool,"backmatching","Use back-matching to filter matches");
SetParameterDescription("backmatching","If set to true, matches should be consistent in both ways.");
AddParameter(ParameterType_Choice,"mode","Keypoints search mode");
......@@ -179,7 +179,7 @@ private:
SetMinimumParameterIntValue("mode.geobins.margin",0);
SetDefaultParameterInt("mode.geobins.margin",10);
AddParameter(ParameterType_Float,"precision","Estimated precision of the colocalisation function (in pixels).");
AddParameter(ParameterType_Float,"precision","Estimated precision of the colocalisation function (in pixels)");
SetParameterDescription("precision","Estimated precision of the colocalisation function in pixels");
SetDefaultParameterFloat("precision",0.);
......@@ -425,7 +425,7 @@ private:
largestRegion.ShrinkByRadius(image_border_margin);
region1.Crop(largestRegion);
otbAppLogINFO("("<<i+1<<"/"<<nb_bins_x<<", "<<j+1<<"/"<<nb_bins_y<<") Considering region1 : "<<region1.GetIndex()<<", "<<region1.GetSize());
otbAppLogINFO("("<<i+1<<"/"<<nb_bins_x<<", "<<j+1<<"/"<<nb_bins_y<<") Considering region1: "<<region1.GetIndex()<<", "<<region1.GetSize());
extractChannel1->SetExtractionRegion(region1);
......
......@@ -88,8 +88,7 @@ private:
SetParameterDescription("io", "This group of parameters allows setting input and output data.");
AddParameter(ParameterType_InputVectorData, "io.vd", "Input Vector Data");
SetParameterDescription("io.vd", "Input geometries used for training (note "
": all geometries from the layer will be used)");
SetParameterDescription("io.vd", "Input geometries used for training (note: all geometries from the layer will be used)");
AddParameter(ParameterType_OutputFilename, "io.out", "Output model");
SetParameterDescription("io.out", "Output file containing the estimated model (.txt format).");
......@@ -98,9 +97,8 @@ private:
MandatoryOff("io.stats");
SetParameterDescription("io.stats", "XML file containing mean and variance of each feature.");
AddParameter(ParameterType_StringList, "feat", "Field names to be used for training."); //
SetParameterDescription("feat","List of field names in the input vector data"
" used as features for training."); //
AddParameter(ParameterType_StringList, "feat", "Field names to be used for training");
SetParameterDescription("feat","List of field names in the input vector data used as features for training.");
Superclass::DoInit();
......
......@@ -115,11 +115,10 @@ private:
"In overwrite mode, the original features will be lost.");
MandatoryOff("out");
AddParameter(ParameterType_ListView, "feat", "Input features to use for reduction."); //
SetParameterDescription("feat","List of field names in the input vector "
"data used as features for reduction."); //
AddParameter(ParameterType_ListView, "feat", "Input features to use for reduction");
SetParameterDescription("feat", "List of field names in the input vector data used as features for reduction.");
AddParameter(ParameterType_Choice, "featout", "Output feature"); //
AddParameter(ParameterType_Choice, "featout", "Output feature");
SetParameterDescription("featout", "Naming of output features");
AddChoice("featout.prefix", "Prefix");
......@@ -134,22 +133,24 @@ private:
SetParameterDescription("featout.list", "Use a list with all names");
AddParameter(ParameterType_StringList, "featout.list.names", "Feature name list");
SetParameterDescription("featout.list.names","List of field names for the output "
"features which result from the reduction."); //
SetParameterDescription("featout.list.names",
"List of field names for the output "
"features which result from the reduction.");
AddParameter(ParameterType_Int, "pcadim", "Principal component dimension"); //
SetParameterDescription("pcadim","This optional parameter can be set to "
AddParameter(ParameterType_Int, "pcadim", "Principal component dimension");
SetParameterDescription("pcadim",
"This optional parameter can be set to "
"reduce the number of eignevectors used in the PCA model file. This "
"parameter can't be used for other models"); //
"parameter can't be used for other models");
MandatoryOff("pcadim");
AddParameter(ParameterType_Choice, "mode", "Writing mode"); //
AddParameter(ParameterType_Choice, "mode", "Writing mode");
SetParameterDescription("mode", "This parameter determines if the output "
"file is overwritten or updated [overwrite/update]. If an output file "
"name is given, the original file is copied before creating the new features.");
AddChoice("mode.overwrite", "Overwrite");
SetParameterDescription("mode.overwrite","Overwrite mode"); //
SetParameterDescription("mode.overwrite", "Overwrite mode");
AddChoice("mode.update", "Update");
SetParameterDescription("mode.update", "Update mode");
......@@ -160,7 +161,7 @@ private:
SetDocExampleParameterValue("model", "model.txt");
SetDocExampleParameterValue("out", "vectorDataOut.shp");
SetDocExampleParameterValue("feat", "perimeter area width");
//SetOfficialDocLink();
SetOfficialDocLink();
}
void DoUpdateParameters() override
......
......@@ -87,8 +87,6 @@ private:
SetDefaultParameterInt("channel", 1);
SetMinimumParameterIntValue("channel", 1);
AddRAMParameter();
AddParameter(ParameterType_Choice, "filter", "Edge feature");
SetParameterDescription("filter", "Choice of edge feature");
......@@ -126,6 +124,8 @@ private:
SetDefaultParameterFloat("filter.canny.lowerthreshold", 3.0);
*/
AddRAMParameter();
// Doc example parameter settings
SetDocExampleParameterValue("in", "qb_RoadExtract.tif");
SetDocExampleParameterValue("channel", "1");
......
......@@ -62,7 +62,7 @@ private:
SetDocName( "Smoothing" );
SetDocLongDescription( "This application applies a smoothing filter to an "
"image. Three methodes can be used : a gaussian filter , a mean filter "
"image. Three methodes can be used: a gaussian filter , a mean filter "
", or an anisotropic diffusion using the Perona-Malik algorithm." );
SetDocLimitations( "None") ;
SetDocAuthors( "OTB-Team" );
......@@ -75,8 +75,6 @@ private:
AddParameter( ParameterType_OutputImage , "out" , "Output Image" );
SetParameterDescription( "out" , "Output smoothed image." );
AddRAMParameter();
AddParameter( ParameterType_Choice, "type" , "Smoothing Type" );
SetParameterDescription( "type", "Smoothing kernel to apply" );
......@@ -118,6 +116,8 @@ private:
SetParameterString( "type" , "anidif");
AddRAMParameter();
// Doc example parameter settings
SetExampleComment( "Image smoothing using a mean filter." , 0 );
SetDocExampleParameterValue( "in" , "Romania_Extract.tif" );
......@@ -138,7 +138,7 @@ private:
void DoUpdateParameters() override
{
// Nothing to do here : all parameters are independent
// Nothing to do here: all parameters are independent
}
void DoExecute() override
......
......@@ -103,13 +103,13 @@ private:
"spectrum associated with each pixel is a linear combination of pure"
"materials in the recovery area, commonly known as endmembers. Endmembers can"
"be estimated using the VertexComponentAnalysis application.\n\n"
"The application allows estimating the abundance maps with several algorithms :\n"
" * Unconstrained Least Square (ucls)\n"
//" * Fully Constrained Least Square (fcls)\n"
" * Image Space Reconstruction Algorithm (isra)\n"
" * Non-negative constrained\n"
" * Least Square (ncls)\n"
" * Minimum Dispersion Constrained Non Negative Matrix Factorization (MDMDNMF)."
"The application allows estimating the abundance maps with several algorithms:\n\n"
"* Unconstrained Least Square (ucls)\n"
// "* Fully Constrained Least Square (fcls)\n"
"* Image Space Reconstruction Algorithm (isra)\n"
"* Non-negative constrained\n"
"* Least Square (ncls)\n"
"* Minimum Dispersion Constrained Non Negative Matrix Factorization (MDMDNMF)."
);
SetDocLimitations("None");
SetDocAuthors("OTB-Team");
......
......@@ -80,8 +80,6 @@ private:
AddParameter(ParameterType_OutputImage, "out", "Output Image");
SetParameterDescription("out","will be used to get the prefix and the extension of the images to write");
AddRAMParameter();
AddParameter(ParameterType_Int, "level", "Number Of Levels");
SetDefaultParameterInt("level", 1);
SetParameterDescription( "level", "Number of levels in the pyramid (default is 1).");
......@@ -102,6 +100,8 @@ private:
<<" subsampling previous level of pyramid instead of processing the full input.";
SetParameterDescription("fast", desc.str());
AddRAMParameter();
// Doc example parameter settings
SetDocExampleParameterValue("in", "QB_Toulouse_Ortho_XS.tif");
SetDocExampleParameterValue("out", "multiResolutionImage.tif");
......
......@@ -98,7 +98,7 @@ private:
AddParameter(ParameterType_Int , "mode.epsg.code" , "EPSG code");
SetParameterDescription("mode.epsg.code" ,
"This code is used to define a geographical coordinate system. "
"If no system is specified, WGS84 (EPSG : 4326) is used by default.");
"If no system is specified, WGS84 (EPSG: 4326) is used by default.");
MandatoryOff("mode.epsg.code");
AddParameter(ParameterType_ListView,"cl","Channels");
......
......@@ -60,7 +60,7 @@ private:
AddDocTag(Tags::Manip);
AddParameter(ParameterType_InputImageList, "il", "Input Tile Images");
SetParameterDescription("il", "Input images to concatenate (in lexicographic order, for instance : (0,0) (1,0) (0,1) (1,1)).");
SetParameterDescription("il", "Input images to concatenate (in lexicographic order, for instance: (0,0) (1,0) (0,1) (1,1)).");
AddParameter(ParameterType_Int, "cols", "Number of tile columns");
SetParameterDescription("cols", "Number of columns in the tile array");
......
......@@ -150,8 +150,6 @@ private:
AddParameter(ParameterType_OutputImage, "out", "Output Image");
SetParameterDescription("out", "Radiometric indices output image");
AddRAMParameter();
AddParameter(ParameterType_Group, "channels", "Channels selection");
SetParameterDescription("channels", "Channels selection");
......@@ -199,6 +197,8 @@ private:
"* Soil:BI - Brightness index (Red, Green)\n"
"* Soil:BI2 - Brightness index 2 (NIR, Red, Green)");
AddRAMParameter();
// Doc example parameter settings
SetDocExampleParameterValue("in", "qb_RoadExtract.tif");
SetDocExampleParameterValue("list", "Vegetation:NDVI Vegetation:RVI Vegetation:IPVI");
......
......@@ -79,13 +79,13 @@ SetParameterDescription("channel", "The selected channel index");
SetDefaultParameterInt("channel", 1);
SetMinimumParameterIntValue("channel", 1);
AddRAMParameter();
AddParameter(ParameterType_Int, "radius", "Neighborhood radius");
SetParameterDescription("radius", "The computational window radius.");
SetMinimumParameterIntValue("radius",1);
SetDefaultParameterInt("radius",3);
AddRAMParameter();
// Doc example parameter settings
SetDocExampleParameterValue("in", "qb_RoadExtract.tif");
SetDocExampleParameterValue("channel", "1");
......
......@@ -101,8 +101,6 @@ SetParameterDescription( "channel" , "The selected channel index" );
SetDefaultParameterInt( "channel" , 1 );
SetMinimumParameterIntValue( "channel" , 1 );
AddRAMParameter();
AddParameter( ParameterType_Choice , "structype" ,
"Type of structuring element" );
SetParameterDescription( "structype" ,
......@@ -166,6 +164,8 @@ SetParameterDescription( "filter.closing.foreval" ,
"Set the foreground value, default is 1.0." );
SetDefaultParameterFloat( "filter.closing.foreval" , 1.0 );
AddRAMParameter();
// Doc example parameter settings
SetDocExampleParameterValue("in", "qb_RoadExtract.tif");
SetDocExampleParameterValue("out", "opened.tif");
......
......@@ -97,8 +97,6 @@ SetParameterDescription("channel", "The selected channel index");
SetDefaultParameterInt("channel", 1);
SetMinimumParameterIntValue("channel", 1);
AddRAMParameter();
AddParameter(ParameterType_Choice, "structype", "Structuring Element Type");
SetParameterDescription("structype", "Choice of the structuring element type");
AddParameter(ParameterType_Int, "xradius", "Structuring element X radius");
......@@ -120,6 +118,8 @@ AddChoice("filter.erode", "Erode");
AddChoice("filter.opening", "Opening");
AddChoice("filter.closing", "Closing");
AddRAMParameter();
// Doc example parameter settings
SetDocExampleParameterValue("in", "qb_RoadExtract.tif");
SetDocExampleParameterValue("out", "opened.tif");
......
......@@ -95,7 +95,7 @@ private:
"\n"
":math:`f(n) = \\begin{cases} \\stackrel{\\smile}{k} & : f-\\psi_{N}(f)>\\sigma \\\\ \\stackrel{\\frown}{k} & : \\psi_{N}(f)-f>\\sigma \\\\ \\bar{k} & : \\mid f - \\psi_{N}(f) \\mid \\leq \\sigma \\end{cases}`"
"\n\n"
"The output is a labeled image (0 : Flat, 1 : Convex, 2 : Concave)" );
"The output is a labeled image (0: Flat, 1: Convex, 2: Concave)" );
SetDocLimitations(
"Generation of the morphological classification is not streamable, "
"pay attention to this fact when setting the radius size of the "
......@@ -110,9 +110,7 @@ private:
SetParameterDescription( "in" , "The input image to be classified." );
AddParameter( ParameterType_OutputImage , "out" , "Output Image" );
SetParameterDescription( "out",
"The output classified image with 3 different values (0 : Flat, "
"1 : Convex, 2 : Concave)" );
SetParameterDescription( "out", "The output classified image with 3 different values (0: Flat, 1: Convex, 2: Concave)" );
AddParameter( ParameterType_Int , "channel" , "Selected Channel" );
SetParameterDescription( "channel" ,
......@@ -120,8 +118,6 @@ private:
SetDefaultParameterInt( "channel" , 1 );
SetMinimumParameterIntValue( "channel" , 1 );
AddRAMParameter();
// Structuring Element (Ball | Cross)
AddParameter( ParameterType_Choice , "structype" ,
"Structuring Element Type" );
......@@ -143,6 +139,8 @@ private:
SetDefaultParameterFloat( "sigma" , 0.5 );
SetMinimumParameterFloatValue( "sigma" , 0 );
AddRAMParameter();
SetDocExampleParameterValue( "in", "ROI_IKO_PAN_LesHalles.tif" );
SetDocExampleParameterValue( "channel", "1" );
SetDocExampleParameterValue( "structype", "ball" );
......
......@@ -119,8 +119,6 @@ private:
SetDefaultParameterInt( "channel", 1 );
SetMinimumParameterIntValue( "channel", 1 );
AddRAMParameter();
// Strucring Element (Ball | Cross)
AddParameter( ParameterType_Choice, "structype", "Structuring Element Type" );
SetParameterDescription( "structype", "Choice of the structuring element type" );
......@@ -132,7 +130,7 @@ private:
SetDefaultParameterInt( "radius", 5 );
SetMinimumParameterIntValue( "radius", 1 );
AddParameter( ParameterType_Int, "step", "Radius step." );
AddParameter( ParameterType_Int, "step", "Radius step" );
SetParameterDescription( "step", "Radius step along the profile (in pixels)" );
SetDefaultParameterInt( "step", 1 );
SetMinimumParameterIntValue( "step", 1 );
......@@ -142,6 +140,8 @@ private:
SetDefaultParameterInt( "levels", 1 );
SetMinimumParameterIntValue( "levels", 1 );
AddRAMParameter();
SetDocExampleParameterValue("in", "ROI_IKO_PAN_LesHalles.tif");
SetDocExampleParameterValue("structype", "ball");
SetDocExampleParameterValue("channel", "1");
......
......@@ -78,28 +78,29 @@ private:
// Documentation
SetDocName( "Morphological Profiles Analysis" );
SetDocLongDescription( "This algorithm is derived from the following publication:\n"
"\n"
SetDocLongDescription( "This algorithm is derived from the following publication:\n\n"
"Martino Pesaresi and Jon Alti Benediktsson, Member, IEEE: A new approach\n"
"for the morphological segmentation of high resolution satellite imagery.\n"
"IEEE Transactions on geoscience and remote sensing, vol. 39, NO. 2,\n"
"February 2001, p. 309-320.\n"
"\n"
"February 2001, p. 309-320.\n\n"
"Depending of the profile selection, the application provides::\n\n"
"- The multi scale geodesic morphological opening or closing profile of the input image.\n"
"- The multi scale derivative of the opening or closing profile.\n"