From c248088f95e6dcc111a8b916ecc079a371c79787 Mon Sep 17 00:00:00 2001 From: Victor Poughon <victor.poughon@cnes.fr> Date: Fri, 21 Dec 2018 11:51:38 +0100 Subject: [PATCH] DOC: fix cookbook warnings --- .../otbClassificationMapRegularization.cxx | 2 +- .../app/otbKMeansClassification.cxx | 37 ++++++++++--------- .../app/otbMultiImageSamplingRate.cxx | 25 +++++++------ .../app/otbOGRLayerClassifier.cxx | 6 +-- .../app/otbPolygonClassStatistics.cxx | 22 +++++------ .../app/otbSOMClassification.cxx | 3 +- .../app/otbSampleAugmentation.cxx | 5 +-- .../app/otbSampleSelection.cxx | 4 +- .../app/otbVectorClassifier.cxx | 2 +- .../include/otbTrainSharkKMeans.hxx | 24 ++++++------ .../include/otbTrainVectorBase.hxx | 2 +- .../app/otbHomologousPointsExtraction.cxx | 8 ++-- .../app/otbTrainDimensionalityReduction.cxx | 8 ++-- .../app/otbVectorDimensionalityReduction.cxx | 33 +++++++++-------- .../AppEdge/app/otbEdgeExtraction.cxx | 4 +- .../AppFiltering/app/otbSmoothing.cxx | 8 ++-- .../app/otbHyperspectralUnmixing.cxx | 14 +++---- .../app/otbMultiResolutionPyramid.cxx | 4 +- .../AppImageUtils/app/otbPixelValue.cxx | 2 +- .../AppImageUtils/app/otbTileFusion.cxx | 2 +- .../AppIndices/app/otbRadiometricIndices.cxx | 4 +- .../app/otbLocalStatisticExtraction.cxx | 4 +- .../app/otbBinaryMorphologicalOperation.cxx | 4 +- .../otbGrayScaleMorphologicalOperation.cxx | 4 +- .../app/otbMorphologicalClassification.cxx | 10 ++--- ...tbMorphologicalMultiScaleDecomposition.cxx | 6 +-- .../app/otbMorphologicalProfilesAnalysis.cxx | 33 +++++++++-------- .../app/otbOpticalCalibration.cxx | 14 +++---- .../app/otbSARCalibration.cxx | 4 +- .../AppSARUtils/app/otbDespeckle.cxx | 3 +- .../app/otbHooverCompareSegmentation.cxx | 2 +- .../app/otbMeanShiftSmoothing.cxx | 6 +-- .../AppSegmentation/app/otbSegmentation.cxx | 4 +- .../AppStereo/app/otbStereoFramework.cxx | 18 ++++----- .../otbStereoRectificationGridGenerator.cxx | 2 +- .../app/otbHaralickTextureExtraction.cxx | 3 +- .../app/otbSFSTextureExtraction.cxx | 4 +- .../src/otbWrapperApplication.cxx | 4 +- 38 files changed, 170 insertions(+), 174 deletions(-) diff --git a/Modules/Applications/AppClassification/app/otbClassificationMapRegularization.cxx b/Modules/Applications/AppClassification/app/otbClassificationMapRegularization.cxx index 970814f072..3a7c64aa3a 100644 --- a/Modules/Applications/AppClassification/app/otbClassificationMapRegularization.cxx +++ b/Modules/Applications/AppClassification/app/otbClassificationMapRegularization.cxx @@ -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 diff --git a/Modules/Applications/AppClassification/app/otbKMeansClassification.cxx b/Modules/Applications/AppClassification/app/otbKMeansClassification.cxx index d0a57ffa4b..813db65bcb 100644 --- a/Modules/Applications/AppClassification/app/otbKMeansClassification.cxx +++ b/Modules/Applications/AppClassification/app/otbKMeansClassification.cxx @@ -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); diff --git a/Modules/Applications/AppClassification/app/otbMultiImageSamplingRate.cxx b/Modules/Applications/AppClassification/app/otbMultiImageSamplingRate.cxx index ac4b60b7bf..981f4f3468 100644 --- a/Modules/Applications/AppClassification/app/otbMultiImageSamplingRate.cxx +++ b/Modules/Applications/AppClassification/app/otbMultiImageSamplingRate.cxx @@ -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." diff --git a/Modules/Applications/AppClassification/app/otbOGRLayerClassifier.cxx b/Modules/Applications/AppClassification/app/otbOGRLayerClassifier.cxx index af39d262e5..1b585d927f 100644 --- a/Modules/Applications/AppClassification/app/otbOGRLayerClassifier.cxx +++ b/Modules/Applications/AppClassification/app/otbOGRLayerClassifier.cxx @@ -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"); diff --git a/Modules/Applications/AppClassification/app/otbPolygonClassStatistics.cxx b/Modules/Applications/AppClassification/app/otbPolygonClassStatistics.cxx index 751cba5c08..4dd494df25 100644 --- a/Modules/Applications/AppClassification/app/otbPolygonClassStatistics.cxx +++ b/Modules/Applications/AppClassification/app/otbPolygonClassStatistics.cxx @@ -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(" "); diff --git a/Modules/Applications/AppClassification/app/otbSOMClassification.cxx b/Modules/Applications/AppClassification/app/otbSOMClassification.cxx index 1b0b7ffcc7..ebd8dc2140 100644 --- a/Modules/Applications/AppClassification/app/otbSOMClassification.cxx +++ b/Modules/Applications/AppClassification/app/otbSOMClassification.cxx @@ -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); diff --git a/Modules/Applications/AppClassification/app/otbSampleAugmentation.cxx b/Modules/Applications/AppClassification/app/otbSampleAugmentation.cxx index a9fbff3aa1..e36e22b8b2 100644 --- a/Modules/Applications/AppClassification/app/otbSampleAugmentation.cxx +++ b/Modules/Applications/AppClassification/app/otbSampleAugmentation.cxx @@ -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"); diff --git a/Modules/Applications/AppClassification/app/otbSampleSelection.cxx b/Modules/Applications/AppClassification/app/otbSampleSelection.cxx index 93af2fc2d6..531203f01a 100644 --- a/Modules/Applications/AppClassification/app/otbSampleSelection.cxx +++ b/Modules/Applications/AppClassification/app/otbSampleSelection.cxx @@ -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"); diff --git a/Modules/Applications/AppClassification/app/otbVectorClassifier.cxx b/Modules/Applications/AppClassification/app/otbVectorClassifier.cxx index 648b1d465f..286b6b0dd7 100644 --- a/Modules/Applications/AppClassification/app/otbVectorClassifier.cxx +++ b/Modules/Applications/AppClassification/app/otbVectorClassifier.cxx @@ -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."); diff --git a/Modules/Applications/AppClassification/include/otbTrainSharkKMeans.hxx b/Modules/Applications/AppClassification/include/otbTrainSharkKMeans.hxx index 4c24dc1287..89d5023c47 100644 --- a/Modules/Applications/AppClassification/include/otbTrainSharkKMeans.hxx +++ b/Modules/Applications/AppClassification/include/otbTrainSharkKMeans.hxx @@ -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> diff --git a/Modules/Applications/AppClassification/include/otbTrainVectorBase.hxx b/Modules/Applications/AppClassification/include/otbTrainVectorBase.hxx index 482fa32e0f..588e07ae8a 100644 --- a/Modules/Applications/AppClassification/include/otbTrainVectorBase.hxx +++ b/Modules/Applications/AppClassification/include/otbTrainVectorBase.hxx @@ -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" ); diff --git a/Modules/Applications/AppDescriptors/app/otbHomologousPointsExtraction.cxx b/Modules/Applications/AppDescriptors/app/otbHomologousPointsExtraction.cxx index d367a97ec1..2c4a2e2d79 100644 --- a/Modules/Applications/AppDescriptors/app/otbHomologousPointsExtraction.cxx +++ b/Modules/Applications/AppDescriptors/app/otbHomologousPointsExtraction.cxx @@ -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); diff --git a/Modules/Applications/AppDimensionalityReduction/app/otbTrainDimensionalityReduction.cxx b/Modules/Applications/AppDimensionalityReduction/app/otbTrainDimensionalityReduction.cxx index 34390791ab..1e4a984868 100644 --- a/Modules/Applications/AppDimensionalityReduction/app/otbTrainDimensionalityReduction.cxx +++ b/Modules/Applications/AppDimensionalityReduction/app/otbTrainDimensionalityReduction.cxx @@ -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(); diff --git a/Modules/Applications/AppDimensionalityReduction/app/otbVectorDimensionalityReduction.cxx b/Modules/Applications/AppDimensionalityReduction/app/otbVectorDimensionalityReduction.cxx index d9031f4cef..c83d379ebf 100644 --- a/Modules/Applications/AppDimensionalityReduction/app/otbVectorDimensionalityReduction.cxx +++ b/Modules/Applications/AppDimensionalityReduction/app/otbVectorDimensionalityReduction.cxx @@ -80,7 +80,7 @@ protected: DimensionalityReductionModelFactoryType::CleanFactories(); } -private: +private: void DoInit() override { SetName("VectorDimensionalityReduction"); @@ -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."); // - - 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"); // + 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 " + "reduce the number of eignevectors used in the PCA model file. This " + "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 diff --git a/Modules/Applications/AppEdge/app/otbEdgeExtraction.cxx b/Modules/Applications/AppEdge/app/otbEdgeExtraction.cxx index ec740ac5f4..c8f6a73910 100644 --- a/Modules/Applications/AppEdge/app/otbEdgeExtraction.cxx +++ b/Modules/Applications/AppEdge/app/otbEdgeExtraction.cxx @@ -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"); diff --git a/Modules/Applications/AppFiltering/app/otbSmoothing.cxx b/Modules/Applications/AppFiltering/app/otbSmoothing.cxx index 550cc25350..09649c86e1 100644 --- a/Modules/Applications/AppFiltering/app/otbSmoothing.cxx +++ b/Modules/Applications/AppFiltering/app/otbSmoothing.cxx @@ -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 diff --git a/Modules/Applications/AppHyperspectral/app/otbHyperspectralUnmixing.cxx b/Modules/Applications/AppHyperspectral/app/otbHyperspectralUnmixing.cxx index 38ee5a8c6f..3029dbd330 100644 --- a/Modules/Applications/AppHyperspectral/app/otbHyperspectralUnmixing.cxx +++ b/Modules/Applications/AppHyperspectral/app/otbHyperspectralUnmixing.cxx @@ -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"); diff --git a/Modules/Applications/AppImageUtils/app/otbMultiResolutionPyramid.cxx b/Modules/Applications/AppImageUtils/app/otbMultiResolutionPyramid.cxx index 15c5e1ea5a..d31a2271c1 100644 --- a/Modules/Applications/AppImageUtils/app/otbMultiResolutionPyramid.cxx +++ b/Modules/Applications/AppImageUtils/app/otbMultiResolutionPyramid.cxx @@ -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"); diff --git a/Modules/Applications/AppImageUtils/app/otbPixelValue.cxx b/Modules/Applications/AppImageUtils/app/otbPixelValue.cxx index ea8bb52d90..0fbc145ac9 100644 --- a/Modules/Applications/AppImageUtils/app/otbPixelValue.cxx +++ b/Modules/Applications/AppImageUtils/app/otbPixelValue.cxx @@ -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"); diff --git a/Modules/Applications/AppImageUtils/app/otbTileFusion.cxx b/Modules/Applications/AppImageUtils/app/otbTileFusion.cxx index 7ba75ba1a3..0712b8fae1 100644 --- a/Modules/Applications/AppImageUtils/app/otbTileFusion.cxx +++ b/Modules/Applications/AppImageUtils/app/otbTileFusion.cxx @@ -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"); diff --git a/Modules/Applications/AppIndices/app/otbRadiometricIndices.cxx b/Modules/Applications/AppIndices/app/otbRadiometricIndices.cxx index 4b6bdffed5..3328ea00c2 100644 --- a/Modules/Applications/AppIndices/app/otbRadiometricIndices.cxx +++ b/Modules/Applications/AppIndices/app/otbRadiometricIndices.cxx @@ -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"); diff --git a/Modules/Applications/AppMoments/app/otbLocalStatisticExtraction.cxx b/Modules/Applications/AppMoments/app/otbLocalStatisticExtraction.cxx index 388a96d55a..c5ebc83f24 100644 --- a/Modules/Applications/AppMoments/app/otbLocalStatisticExtraction.cxx +++ b/Modules/Applications/AppMoments/app/otbLocalStatisticExtraction.cxx @@ -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"); diff --git a/Modules/Applications/AppMorphology/app/otbBinaryMorphologicalOperation.cxx b/Modules/Applications/AppMorphology/app/otbBinaryMorphologicalOperation.cxx index 788cb5e191..44a1ccb002 100644 --- a/Modules/Applications/AppMorphology/app/otbBinaryMorphologicalOperation.cxx +++ b/Modules/Applications/AppMorphology/app/otbBinaryMorphologicalOperation.cxx @@ -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"); diff --git a/Modules/Applications/AppMorphology/app/otbGrayScaleMorphologicalOperation.cxx b/Modules/Applications/AppMorphology/app/otbGrayScaleMorphologicalOperation.cxx index 1176a8127c..f3d70518b6 100644 --- a/Modules/Applications/AppMorphology/app/otbGrayScaleMorphologicalOperation.cxx +++ b/Modules/Applications/AppMorphology/app/otbGrayScaleMorphologicalOperation.cxx @@ -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"); diff --git a/Modules/Applications/AppMorphology/app/otbMorphologicalClassification.cxx b/Modules/Applications/AppMorphology/app/otbMorphologicalClassification.cxx index bd47a89c76..4e80186a99 100644 --- a/Modules/Applications/AppMorphology/app/otbMorphologicalClassification.cxx +++ b/Modules/Applications/AppMorphology/app/otbMorphologicalClassification.cxx @@ -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" ); diff --git a/Modules/Applications/AppMorphology/app/otbMorphologicalMultiScaleDecomposition.cxx b/Modules/Applications/AppMorphology/app/otbMorphologicalMultiScaleDecomposition.cxx index 052e8d9be3..934d2996d1 100644 --- a/Modules/Applications/AppMorphology/app/otbMorphologicalMultiScaleDecomposition.cxx +++ b/Modules/Applications/AppMorphology/app/otbMorphologicalMultiScaleDecomposition.cxx @@ -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"); diff --git a/Modules/Applications/AppMorphology/app/otbMorphologicalProfilesAnalysis.cxx b/Modules/Applications/AppMorphology/app/otbMorphologicalProfilesAnalysis.cxx index a7bc15c56b..64afbb3e4d 100644 --- a/Modules/Applications/AppMorphology/app/otbMorphologicalProfilesAnalysis.cxx +++ b/Modules/Applications/AppMorphology/app/otbMorphologicalProfilesAnalysis.cxx @@ -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" - "- The parameter (called characteristic) of the maximum derivative value of the multi scale closing or opening profile for which this maxima occurs.\n" - "- The labeled classification of the input image.\n" - "\n" - "The behavior of the classification is :\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" + "* The parameter (called characteristic) of the maximum derivative value of the multi scale closing or opening profile for which this maxima occurs.\n" + "* The labeled classification of the input image.\n\n" + + "The behavior of the classification is:\n\n" + "Given :math:`x_1` and :math:`x_2` two membership values,\n" ":math:`L_1, L_2` two labels associated, and :math:`\\sigma` a tolerance\n" "value, the following decision rule is applied:\n" "\n" ":math:`L = \\begin{cases} L_{1} & : x_{1}>x_{2} \\quad and \\quad x_{1}>\\sigma \\\\ L_{2} & : x_{2}>x_{1} \\quad and \\quad x_{2}>\\sigma \\\\ 0 & : otherwise. \\end{cases}` \n" "\n" - "The output image can be :" + "The output image can be:" "- A :math:`N` multi band image for the opening/closing normal or derivative profiles.\n" "- A mono band image for the opening/closing characteristics.\n" "- A labeled image for the classification." ); @@ -121,8 +122,6 @@ private: SetDefaultParameterInt( "channel", 1 ); SetMinimumParameterIntValue( "channel", 1 ); - AddRAMParameter(); - // Structuring Element (Ball | Cross) AddParameter( ParameterType_Choice, "structype", "Structuring Element Type" ); SetParameterDescription( "structype", "Choice of the structuring element type" ); @@ -139,7 +138,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 ); @@ -160,6 +159,8 @@ private: SetDefaultParameterFloat( "profile.classification.sigma", 1 ); SetMinimumParameterFloatValue( "profile.classification.sigma", 0 ); + AddRAMParameter(); + SetDocExampleParameterValue( "in", "ROI_IKO_PAN_LesHalles.tif" ); SetDocExampleParameterValue( "channel", "1" ); SetDocExampleParameterValue( "structype", "ball" ); @@ -175,7 +176,7 @@ private: void DoUpdateParameters() override { - // Nothing to do here : all parameters are independent + // Nothing to do here: all parameters are independent } void DoExecute() override diff --git a/Modules/Applications/AppOpticalCalibration/app/otbOpticalCalibration.cxx b/Modules/Applications/AppOpticalCalibration/app/otbOpticalCalibration.cxx index 83bc425292..5d17c47f07 100644 --- a/Modules/Applications/AppOpticalCalibration/app/otbOpticalCalibration.cxx +++ b/Modules/Applications/AppOpticalCalibration/app/otbOpticalCalibration.cxx @@ -133,12 +133,12 @@ private: SetDocLongDescription("The application allows converting pixel values from DN (for Digital Numbers) to reflectance. Calibrated values are called surface reflectivity and its values lie in the range [0, 1].\nThe first level is called Top Of Atmosphere (TOA) reflectivity. It takes into account the sensor gain, sensor spectral response and the solar illuminations.\nThe second level is called Top Of Canopy (TOC) reflectivity. In addition to sensor gain and solar illuminations, it takes into account the optical thickness of the atmosphere, the atmospheric pressure, the water vapor amount, the ozone amount, as well as the composition and amount of aerosol gasses.\nIt is also possible to indicate an AERONET file which contains atmospheric parameters (version 1 and version 2 of Aeronet file are supported. Note that computing TOC reflectivity will internally compute first TOA and then TOC reflectance. \n" "\n--------------------------\n\n" "If the sensor is not supported by the metadata interface factory of OTB, users still have the possibility to give the needed parameters to the application.\n" -"For TOA conversion, these parameters are : \n" +"For TOA conversion, these parameters are: \n" "- day and month of acquisition, or flux normalization coefficient;\n" "- sun elevation angle;\n" "- gains and biases, one pair of values for each band (passed by a file);\n" "- solar illuminations, one value for each band (passed by a file).\n\n" -"For the conversion from DN (for Digital Numbers) to spectral radiance (or 'TOA radiance') L, the following formula is used :\n\n" +"For the conversion from DN (for Digital Numbers) to spectral radiance (or 'TOA radiance') L, the following formula is used:\n\n" "(1)\tL(b) = DN(b)/gain(b)+bias(b)\t(in W/m2/steradians/micrometers)\twith b being a band ID.\n\n" @@ -147,16 +147,16 @@ private: "Note that sometimes, the values provided by certain metadata files assume the formula L(b) = gain(b)*DC(b)+bias(b).\n" "In this case, be sure to provide the inverse gain values so that the application can correctly interpret them.\n\n" -"In order to convert TOA radiance to TOA reflectance, the following formula is used :\n\n" +"In order to convert TOA radiance to TOA reflectance, the following formula is used:\n\n" -"(2)\tR(b) = (pi*L(b)*d*d) / (ESUN(b)*cos(θ))\t(no dimension)\twhere : \n\n" +"(2)\tR(b) = (pi*L(b)*d*d) / (ESUN(b)*cos(θ))\t(no dimension)\twhere: \n\n" "- L(b) is the spectral radiance for band b \n" "- pi is the famous mathematical constant (3.14159...) \n" "- d is the earth-sun distance (in astronomical units) and depends on the acquisition's day and month \n" "- ESUN(b) is the mean TOA solar irradiance (or solar illumination) in W/m2/micrometers\n" "- θ is the solar zenith angle in degrees.\n\n" -"Note that the application asks for the solar elevation angle, and will perform the conversion to the zenith angle itself (zenith_angle = 90 - elevation_angle , units : degrees).\n" +"Note that the application asks for the solar elevation angle, and will perform the conversion to the zenith angle itself (zenith_angle = 90 - elevation_angle , units: degrees).\n" "Note also that ESUN(b) not only depends on the band b, but also on the spectral sensitivity of the sensor in this particular band. " "In other words, the influence of spectral sensitivities is included within the ESUN different values.\n" "These values are provided by the user thanks to a txt file following the same convention as before.\n" @@ -191,8 +191,6 @@ private: AddParameter(ParameterType_OutputImage, "out", "Output"); SetParameterDescription("out","Output calibrated image filename"); - AddRAMParameter(); - AddParameter(ParameterType_Choice, "level", "Calibration Level"); AddChoice("level.toa", "Image to Top Of Atmosphere reflectance"); AddChoice("level.toatoim", "TOA reflectance to Image"); @@ -345,6 +343,8 @@ private: MandatoryOff("atmo.pixsize"); + AddRAMParameter(); + // Doc example parameter settings SetDocExampleParameterValue("in", "QB_1_ortho.tif"); SetDocExampleParameterValue("level", "toa"); diff --git a/Modules/Applications/AppSARCalibration/app/otbSARCalibration.cxx b/Modules/Applications/AppSARCalibration/app/otbSARCalibration.cxx index 49e8d7ffd9..76b8fca048 100644 --- a/Modules/Applications/AppSARCalibration/app/otbSARCalibration.cxx +++ b/Modules/Applications/AppSARCalibration/app/otbSARCalibration.cxx @@ -66,8 +66,6 @@ private: AddParameter(ParameterType_OutputImage, "out", "Output Image"); SetParameterDescription("out", "Output calibrated image. This image contains the backscatter (sigmaNought) of the input image."); - AddRAMParameter(); - AddParameter(ParameterType_Bool, "noise", "Disable Noise"); SetParameterDescription("noise", "Flag to disable noise. For 5.2.0 release, the noise values are only read by TerraSARX product."); @@ -83,6 +81,8 @@ private: SetParameterDescription("lut.dn","Use DN value lookup value from product metadata"); SetDefaultParameterInt("lut", 0); + AddRAMParameter(); + // Doc example parameter settings SetDocExampleParameterValue("in", "RSAT_imagery_HH.tif"); SetDocExampleParameterValue("out", "SarRadiometricCalibration.tif" ); diff --git a/Modules/Applications/AppSARUtils/app/otbDespeckle.cxx b/Modules/Applications/AppSARUtils/app/otbDespeckle.cxx index ed17af2e2c..a3d2bf8593 100644 --- a/Modules/Applications/AppSARUtils/app/otbDespeckle.cxx +++ b/Modules/Applications/AppSARUtils/app/otbDespeckle.cxx @@ -105,8 +105,6 @@ private: AddParameter(ParameterType_OutputImage, "out", "Output Image"); SetParameterDescription("out", "Output image."); - AddRAMParameter(); - AddParameter(ParameterType_Choice,"filter","Speckle filtering method"); AddChoice("filter.lee","Lee"); @@ -157,6 +155,7 @@ private: SetDefaultParameterInt("filter.gammamap.rad", 1); SetDefaultParameterFloat("filter.gammamap.nblooks", 1.); + AddRAMParameter(); // Doc example parameter settings SetDocExampleParameterValue("in", "sar.tif"); diff --git a/Modules/Applications/AppSegmentation/app/otbHooverCompareSegmentation.cxx b/Modules/Applications/AppSegmentation/app/otbHooverCompareSegmentation.cxx index 637110043e..2ea55ae90f 100644 --- a/Modules/Applications/AppSegmentation/app/otbHooverCompareSegmentation.cxx +++ b/Modules/Applications/AppSegmentation/app/otbHooverCompareSegmentation.cxx @@ -144,7 +144,7 @@ private: "The application can output the overall Hoover scores along with colored" "images of the MS and GT segmentation showing the state of each region " "(correct detection, over-segmentation, under-segmentation, missed).\n\n" - "The Hoover metrics are described in : Hoover et al., \"An experimental" + "The Hoover metrics are described in: Hoover et al., \"An experimental" " comparison of range image segmentation algorithms\", IEEE PAMI vol. 18, no. 7, July 1996."); SetDocLimitations("None"); SetDocAuthors("OTB-Team"); diff --git a/Modules/Applications/AppSegmentation/app/otbMeanShiftSmoothing.cxx b/Modules/Applications/AppSegmentation/app/otbMeanShiftSmoothing.cxx index 1d30963c54..f0a67b1632 100644 --- a/Modules/Applications/AppSegmentation/app/otbMeanShiftSmoothing.cxx +++ b/Modules/Applications/AppSegmentation/app/otbMeanShiftSmoothing.cxx @@ -129,8 +129,6 @@ private: SetParameterDescription( "foutpos", " This output image contains the 2D displacement between the input pixel spatial position and the final position after convergence. Floating point encoding is mandatory. This output can be used as input image (in) of the LSMSSegmentation application [4,5]."); MandatoryOff("foutpos"); - AddRAMParameter(); - AddParameter(ParameterType_Int, "spatialr", "Spatial radius"); SetParameterDescription("spatialr", "Radius of the spatial neighborhood for averaging. Higher values will result in more smoothing and higher processing time."); SetDefaultParameterInt("spatialr", 5); @@ -159,9 +157,11 @@ private: SetMinimumParameterFloatValue("rangeramp", 0); MandatoryOff("rangeramp"); - AddParameter(ParameterType_Bool, "modesearch", "Mode search."); + AddParameter(ParameterType_Bool, "modesearch", "Mode search"); SetParameterDescription("modesearch", "If activated pixel iterative convergence is stopped if the path crosses an already converged pixel. Be careful, with this option, the result will slightly depend on thread number and the results will not be stable (see [4] for more details)."); + AddRAMParameter(); + // Doc example parameter settings SetDocExampleParameterValue("in", "maur_rgb.png"); SetDocExampleParameterValue("fout", "smooth.tif"); diff --git a/Modules/Applications/AppSegmentation/app/otbSegmentation.cxx b/Modules/Applications/AppSegmentation/app/otbSegmentation.cxx index ab2ea6779d..cbb87ed79d 100644 --- a/Modules/Applications/AppSegmentation/app/otbSegmentation.cxx +++ b/Modules/Applications/AppSegmentation/app/otbSegmentation.cxx @@ -209,7 +209,7 @@ private: SetParameterDescription("filter.cc", "Simple pixel-based connected-components algorithm with a user-defined connection condition."); AddParameter(ParameterType_String, "filter.cc.expr", "Condition"); - SetParameterDescription("filter.cc.expr", "User defined connection condition, written as a mathematical expression. Available variables are p(i)b(i), intensity_p(i) and distance (example of expression : distance < 10 )"); + SetParameterDescription("filter.cc.expr", "User defined connection condition, written as a mathematical expression. Available variables are p(i)b(i), intensity_p(i) and distance (example of expression: distance < 10 )"); // Watershed AddChoice("filter.watershed","Watershed"); @@ -247,7 +247,7 @@ private: SetParameterDescription("filter.mprofiles.start","Initial radius of the structuring element (in pixels)"); SetDefaultParameterInt("filter.mprofiles.start",1); SetMinimumParameterIntValue("filter.mprofiles.start",1); - AddParameter(ParameterType_Int,"filter.mprofiles.step","Radius step."); + AddParameter(ParameterType_Int,"filter.mprofiles.step","Radius step"); SetParameterDescription("filter.mprofiles.step","Radius step along the profile (in pixels)"); SetDefaultParameterInt("filter.mprofiles.step",1); SetMinimumParameterIntValue("filter.mprofiles.step",1); diff --git a/Modules/Applications/AppStereo/app/otbStereoFramework.cxx b/Modules/Applications/AppStereo/app/otbStereoFramework.cxx index 840b158b55..bfcf66c01d 100644 --- a/Modules/Applications/AppStereo/app/otbStereoFramework.cxx +++ b/Modules/Applications/AppStereo/app/otbStereoFramework.cxx @@ -327,14 +327,14 @@ private: "This application is chaining different processing steps. Some of them " "are also performed by other applications in the stereo-reconstruction " "framework:\n\n" - "* StereoRectificationGridGenerator [1] : for the generation of deformation grids\n" - "* GridBasedImageResampling [2] : resampling into epipolar geometry\n" - "* BlockMatching [3] : estimation of dense disparity maps\n\n" + "* StereoRectificationGridGenerator: for the generation of deformation grids\n" + "* GridBasedImageResampling: resampling into epipolar geometry\n" + "* BlockMatching: estimation of dense disparity maps\n\n" "The pipeline executes the following steps on each stereo pair:\n\n" "* compute the epipolar displacement grids from the stereo pair (direct and inverse)\n" "* resample the stereo pair into epipolar geometry using BCO interpolation\n" - "* create masks for each epipolar image : remove black borders and resample input masks\n" + "* create masks for each epipolar image: remove black borders and resample input masks\n" "* compute horizontal disparities with a block matching algorithm\n" "* refine disparities to sub-pixel precision with a dichotomy algorithm\n" "* apply an optional median filter\n" @@ -346,9 +346,9 @@ private: "DEM cell can be chosen between maximum, minimum and average."); SetDocLimitations(" "); SetDocAuthors("OTB-Team"); - SetDocSeeAlso("[1] StereoRectificationGridGenerator\n" - "[2] GridBasedImageResampling\n" - "[3] BlockMatching"); + SetDocSeeAlso("StereoRectificationGridGenerator\n" + "GridBasedImageResampling\n" + "BlockMatching"); AddDocTag(Tags::Stereo); @@ -362,7 +362,7 @@ private: AddParameter(ParameterType_String, "input.co", "Couples list"); SetParameterDescription("input.co","List of index of couples im image list." - " Couples must be separated by a comma (index start at 0). For example :" + " Couples must be separated by a comma (index start at 0). For example:" " 0 1,1 2 will process a first couple composed of the first and the" " second image in image list, then the second and the third image\n. " "Note that images are handled by pairs. If left empty, couples are " @@ -390,7 +390,7 @@ private: SetParameterString("map","wgs"); AddParameter(ParameterType_Float, "output.res","Output resolution"); - SetParameterDescription("output.res","Spatial sampling distance of the output elevation : the cell size (in m)"); + SetParameterDescription("output.res","Spatial sampling distance of the output elevation: the cell size (in m)"); SetDefaultParameterFloat("output.res",1.); AddParameter(ParameterType_Float, "output.nodata","NoData value"); diff --git a/Modules/Applications/AppStereo/app/otbStereoRectificationGridGenerator.cxx b/Modules/Applications/AppStereo/app/otbStereoRectificationGridGenerator.cxx index b2ac4174e3..b9b6fb008b 100644 --- a/Modules/Applications/AppStereo/app/otbStereoRectificationGridGenerator.cxx +++ b/Modules/Applications/AppStereo/app/otbStereoRectificationGridGenerator.cxx @@ -189,7 +189,7 @@ private: " zoomed-in (scale < 1) or zoomed-out (scale > 1) epipolar images."); SetDefaultParameterFloat("epi.scale",1.); - AddParameter(ParameterType_Int,"epi.step","Step of the deformation grid (in nb. of pixels)"); + AddParameter(ParameterType_Int,"epi.step","Step of the deformation grid (in number of pixels)"); SetParameterDescription("epi.step","Stereo-rectification deformation grid " "only varies slowly. Therefore, it is recommended to use a coarser grid " "(higher step value) in case of large images"); diff --git a/Modules/Applications/AppTextures/app/otbHaralickTextureExtraction.cxx b/Modules/Applications/AppTextures/app/otbHaralickTextureExtraction.cxx index 0f0373fb21..e7e1bb7668 100644 --- a/Modules/Applications/AppTextures/app/otbHaralickTextureExtraction.cxx +++ b/Modules/Applications/AppTextures/app/otbHaralickTextureExtraction.cxx @@ -120,8 +120,6 @@ SetDefaultParameterInt("step", 1); SetMinimumParameterIntValue("step", 1); MandatoryOff("step"); -AddRAMParameter(); - AddParameter(ParameterType_Group, "parameters", "Texture feature parameters"); SetParameterDescription("parameters","This group of parameters allows one to define " "texture parameters."); @@ -183,6 +181,7 @@ SetParameterDescription("out", "Output image containing the selected texture fea MandatoryOff("out"); EnableParameter("out"); +AddRAMParameter(); // Doc example parameter settings SetDocExampleParameterValue("in", "qb_RoadExtract.tif"); diff --git a/Modules/Applications/AppTextures/app/otbSFSTextureExtraction.cxx b/Modules/Applications/AppTextures/app/otbSFSTextureExtraction.cxx index 13ade82049..90e62b115d 100644 --- a/Modules/Applications/AppTextures/app/otbSFSTextureExtraction.cxx +++ b/Modules/Applications/AppTextures/app/otbSFSTextureExtraction.cxx @@ -89,8 +89,6 @@ SetParameterDescription("channel", "The selected channel index"); SetDefaultParameterInt("channel", 1); SetMinimumParameterIntValue("channel", 1); -AddRAMParameter(); - AddParameter(ParameterType_Group, "parameters", "Texture feature parameters"); SetParameterDescription("parameters","This group of parameters allows one to define SFS texture " "parameters. The available texture features are SFS'Length, SFS'Width, SFS'PSI, SFS'W-Mean, " @@ -119,6 +117,8 @@ SetDefaultParameterInt("parameters.maxcons", 5); AddParameter(ParameterType_OutputImage, "out", "Feature Output Image"); SetParameterDescription("out", "Output image containing the SFS texture features."); +AddRAMParameter(); + // Doc example parameter settings SetDocExampleParameterValue("in", "qb_RoadExtract.tif"); SetDocExampleParameterValue("channel", "1"); diff --git a/Modules/Wrappers/ApplicationEngine/src/otbWrapperApplication.cxx b/Modules/Wrappers/ApplicationEngine/src/otbWrapperApplication.cxx index dbeac1e3aa..f21fedb86e 100644 --- a/Modules/Wrappers/ApplicationEngine/src/otbWrapperApplication.cxx +++ b/Modules/Wrappers/ApplicationEngine/src/otbWrapperApplication.cxx @@ -2101,9 +2101,9 @@ void Application::AddRANDParameter(std::string paramKey) { // Get the RAND Parameter from the configuration file - GetParameterList()->AddParameter(ParameterType_Int, paramKey, "set user defined seed"); + GetParameterList()->AddParameter(ParameterType_Int, paramKey, "Random seed"); MandatoryOff(paramKey); - SetParameterDescription(paramKey, "Set specific seed. with integer value."); + SetParameterDescription(paramKey, "Set a specific random seed with integer value."); } -- GitLab