diff --git a/Modules/Applications/AppClassification/app/otbTrainRegression.cxx b/Modules/Applications/AppClassification/app/otbTrainRegression.cxx index 0140e5f8d1bc0526f2db915c78ef571cc83dceab..e1ea2d673d24db7ff5391ad40eed73bda1cd34ba 100644 --- a/Modules/Applications/AppClassification/app/otbTrainRegression.cxx +++ b/Modules/Applications/AppClassification/app/otbTrainRegression.cxx @@ -117,53 +117,74 @@ void DoInit() ITK_OVERRIDE "lists are built such that their size is inferior to maximum bounds given " "by the user, and the proportion corresponds to the balance parameter. " "Several classifier parameters can be set depending on the chosen " - "classifier. In the validation process, the mean square error is computed\n" + "classifier. In the validation process, the mean square error is computed " + "between the ground truth and the estimated model.\n" " This application is based on LibSVM and on OpenCV Machine Learning " "classifiers, and is compatible with OpenCV 2.3.1 and later."); SetDocLimitations("None"); SetDocAuthors("OTB-Team"); - SetDocSeeAlso("OpenCV documentation for machine learning http://docs.opencv.org/modules/ml/doc/ml.html "); + SetDocSeeAlso("OpenCV documentation for machine learning " + "http://docs.opencv.org/modules/ml/doc/ml.html "); //Group IO - AddParameter(ParameterType_Group, "io", "Input and output data"); - SetParameterDescription("io", "This group of parameters allows setting input and output data."); - AddParameter(ParameterType_InputImageList, "io.il", "Input Image List"); - SetParameterDescription("io.il", "A list of input images. First (n-1) bands should contain the predictor. The last band should contain the output value to predict."); - AddParameter(ParameterType_InputFilename, "io.csv", "Input CSV file"); - SetParameterDescription("io.csv","Input CSV file containing the predictors, and the output values in last column. Only used when no input image is given"); - MandatoryOff("io.csv"); - - AddParameter(ParameterType_InputFilename, "io.imstat", "Input XML image statistics file"); - MandatoryOff("io.imstat"); - SetParameterDescription("io.imstat", - "Input XML file containing the mean and the standard deviation of the input images."); - AddParameter(ParameterType_OutputFilename, "io.out", "Output regression model"); - SetParameterDescription("io.out", "Output file containing the model estimated (.txt format)."); - - AddParameter(ParameterType_Float,"io.mse","Mean Square Error"); - SetParameterDescription("io.mse","Mean square error computed with the validation predictors"); - SetParameterRole("io.mse",Role_Output); - DisableParameter("io.mse"); + AddParameter( ParameterType_Group , "io" , "Input and output data" ); + SetParameterDescription("io" , + "This group of parameters allows setting input and output data." ); + AddParameter( ParameterType_InputImageList , "io.il", "Input Image List" ); + SetParameterDescription( "io.il" , + "A list of input images. First (n-1) bands should contain the predictor. " + "The last band should contain the output value to predict." ); + AddParameter( ParameterType_InputFilename , "io.csv" , "Input CSV file" ); + SetParameterDescription( "io.csv" , + "Input CSV file containing the predictors, and the output values in last " + "column. Only used when no input image is given" ); + MandatoryOff( "io.csv" ); + + AddParameter( ParameterType_InputFilename , "io.imstat" , + "Input XML image statistics file" ); + MandatoryOff( "io.imstat" ); + SetParameterDescription( "io.imstat", + "Input XML file containing the mean and the standard deviation of the " + "input images." ); + AddParameter( ParameterType_OutputFilename , "io.out" , + "Output regression model" ); + SetParameterDescription( "io.out" , + "Output file containing the model estimated (.txt format)." ); + + AddParameter( ParameterType_Float , "io.mse" , "Mean Square Error" ); + SetParameterDescription( "io.mse" , + "Mean square error computed with the validation predictors" ); + SetParameterRole( "io.mse" , Role_Output ); + DisableParameter( "io.mse" ); //Group Sample list - AddParameter(ParameterType_Group, "sample", "Training and validation samples parameters"); - SetParameterDescription("sample", - "This group of parameters allows you to set training and validation sample lists parameters."); - - AddParameter(ParameterType_Int, "sample.mt", "Maximum training predictors"); + AddParameter( ParameterType_Group , "sample" , + "Training and validation samples parameters" ); + SetParameterDescription( "sample" , + "This group of parameters allows you to set training and validation sample " + "lists parameters." ); + + AddParameter( ParameterType_Int , "sample.mt" , + "Maximum training predictors"); //MandatoryOff("mt"); - SetDefaultParameterInt("sample.mt", 1000); - SetParameterDescription("sample.mt", "Maximum number of training predictors (default = 1000) (no limit = -1)."); + SetDefaultParameterInt( "sample.mt" , 1000 ); + SetParameterDescription( "sample.mt" , + "Maximum number of training predictors (default = 1000) (no limit = -1)."); - AddParameter(ParameterType_Int, "sample.mv", "Maximum validation predictors"); + AddParameter( ParameterType_Int , "sample.mv" , + "Maximum validation predictors"); // MandatoryOff("mv"); - SetDefaultParameterInt("sample.mv", 1000); - SetParameterDescription("sample.mv", "Maximum number of validation predictors (default = 1000) (no limit = -1)."); - - AddParameter(ParameterType_Float, "sample.vtr", "Training and validation sample ratio"); - SetParameterDescription("sample.vtr", - "Ratio between training and validation samples (0.0 = all training, 1.0 = all validation) (default = 0.5)."); - SetParameterFloat("sample.vtr",0.5, false); + SetDefaultParameterInt( "sample.mv" , 1000 ); + SetParameterDescription( "sample.mv" , + "Maximum number of validation predictors (default = 1000) " + "(no limit = -1)."); + + AddParameter( ParameterType_Float , "sample.vtr" , + "Training and validation sample ratio"); + SetParameterDescription( "sample.vtr" , + "Ratio between training and validation samples (0.0 = all training, " + "1.0 = all validation) (default = 0.5)."); + SetParameterFloat( "sample.vtr" , 0.5 , false ); Superclass::DoInit(); diff --git a/Modules/Applications/AppClassification/app/otbTrainVectorClassifier.cxx b/Modules/Applications/AppClassification/app/otbTrainVectorClassifier.cxx index 1d1d387c131d3c49fe9402f108e6f1880dd24792..f37eb3020f4934146d3ad4cfa9d402c19d058026 100644 --- a/Modules/Applications/AppClassification/app/otbTrainVectorClassifier.cxx +++ b/Modules/Applications/AppClassification/app/otbTrainVectorClassifier.cxx @@ -57,11 +57,13 @@ protected: void DoInit() { SetName( "TrainVectorClassifier" ); - SetDescription( "Train a classifier based on labeled geometries and a list of features to consider." ); + SetDescription( "Train a classifier based on labeled geometries and a " + "list of features to consider." ); SetDocName( "Train Vector Classifier" ); SetDocLongDescription( "This application trains a classifier based on " - "labeled geometries and a list of features to consider for classification." ); + "labeled geometries and a list of features to consider for " + "classification." ); SetDocLimitations( " " ); SetDocAuthors( "OTB Team" ); SetDocSeeAlso( " " ); diff --git a/Modules/Applications/AppFiltering/app/otbSmoothing.cxx b/Modules/Applications/AppFiltering/app/otbSmoothing.cxx index e80df1eea21a22aaa0c9473aaa0bda8b8efe2421..a31dc933881f65e3e50618d151f880fc87c90e9c 100644 --- a/Modules/Applications/AppFiltering/app/otbSmoothing.cxx +++ b/Modules/Applications/AppFiltering/app/otbSmoothing.cxx @@ -57,70 +57,81 @@ public: private: void DoInit() ITK_OVERRIDE { - SetName("Smoothing"); - SetDescription("Apply a smoothing filter to an image"); - - SetDocName("Smoothing"); - SetDocLongDescription("This application applies smoothing filter to an image." - " Either gaussian, mean, or anisotropic diffusion are available."); - SetDocLimitations("None"); - SetDocAuthors("OTB-Team"); + SetName( "Smoothing" ); + SetDescription( "Apply a smoothing filter to an image" ); + + SetDocName( "Smoothing" ); + SetDocLongDescription( "This application applies a smoothing filter to an " + "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" ); SetDocSeeAlso(" "); AddDocTag(Tags::Filter); - AddParameter(ParameterType_InputImage, "in", "Input Image"); - SetParameterDescription("in", "Input image to smooth."); - AddParameter(ParameterType_OutputImage, "out", "Output Image"); - SetParameterDescription("out", "Output smoothed image."); + AddParameter( ParameterType_InputImage , "in" , "Input Image" ); + SetParameterDescription( "in", "Input image to smooth." ); + AddParameter( ParameterType_OutputImage , "out" , "Output Image" ); + SetParameterDescription( "out" , "Output smoothed image." ); AddRAMParameter(); - AddParameter(ParameterType_Choice, "type", "Smoothing Type"); - SetParameterDescription("type", "Smoothing kernel to apply"); + AddParameter( ParameterType_Choice, "type" , "Smoothing Type" ); + SetParameterDescription( "type", "Smoothing kernel to apply" ); - AddChoice("type.mean", "Mean"); + AddChoice( "type.mean" , "Mean" ); - AddParameter(ParameterType_Radius, "type.mean.radius", "Radius"); - SetParameterDescription("type.mean.radius", "Mean radius (in pixels)"); - SetDefaultParameterInt("type.mean.radius", 2); + AddParameter( ParameterType_Radius , "type.mean.radius" , "Radius" ); + SetParameterDescription( "type.mean.radius" , + "Kernel's radius (in pixels)" ); + SetDefaultParameterInt( "type.mean.radius" , 2 ); - AddChoice("type.gaussian", "Gaussian"); + AddChoice( "type.gaussian" , "Gaussian" ); - AddParameter(ParameterType_Float, "type.gaussian.radius", "Radius"); - SetParameterDescription("type.gaussian.radius", "Gaussian radius (in pixels)"); - SetDefaultParameterFloat("type.gaussian.radius", 2.0); + AddParameter( ParameterType_Float, "type.gaussian.radius" , "Radius" ); + SetParameterDescription( "type.gaussian.radius", + "Standard deviation of the gaussian kernel used to filter the image"); + SetDefaultParameterFloat( "type.gaussian.radius" , 2.0 ); + // TODO rename this parameter - AddChoice("type.anidif", "Anisotropic Diffusion"); + AddChoice( "type.anidif" , "Anisotropic Diffusion" ); - AddParameter(ParameterType_Float, "type.anidif.timestep", "Time Step"); - SetParameterDescription("type.anidif.timestep", "Diffusion equation time step"); - AddParameter(ParameterType_Int, "type.anidif.nbiter", "Nb Iterations"); - SetParameterDescription("type.anidif.nbiter", "Number of iterations"); + AddParameter( ParameterType_Float , "type.anidif.timestep", "Time Step" ); + SetParameterDescription( "type.anidif.timestep" , + "Time step that will be used to discretize the diffusion equation" ); - AddParameter(ParameterType_Float, "type.anidif.conductance", "Conductance"); - SetParameterDescription("type.anidif.nbiter", "Controls the sensitivity of the conductance term"); + AddParameter( ParameterType_Int , "type.anidif.nbiter" , "Nb Iterations" ); + SetParameterDescription( "type.anidif.nbiter" , + "Number of iterations needed to get the result" ); - SetDefaultParameterFloat("type.anidif.timestep", 0.125); - SetDefaultParameterInt("type.anidif.nbiter", 10); - SetDefaultParameterInt("type.anidif.conductance", 1.); + AddParameter( ParameterType_Float , "type.anidif.conductance" , + "Conductance" ); + SetParameterDescription( "type.anidif.conductance" , + "Controls the sensitivity of the conductance term in the diffusion " + "equation. The lower it is the stronger the features will be preserved" ); - SetParameterString("type", "anidif", false); + SetDefaultParameterFloat( "type.anidif.timestep" , 0.125 ); + SetDefaultParameterInt( "type.anidif.nbiter" , 10 ); + SetDefaultParameterInt( "type.anidif.conductance" , 1. ); + + SetParameterString( "type" , "anidif" , false ); // Doc example parameter settings - SetExampleComment("Image smoothing using a mean filter.", 0); - SetDocExampleParameterValue("in", "Romania_Extract.tif"); - SetDocExampleParameterValue("out", "smoothedImage_mean.png uchar"); - SetDocExampleParameterValue("type", "mean"); - - unsigned int exId = AddExample( "Image smoothing using an anisotropic diffusion filter." ); - SetDocExampleParameterValue("in", "Romania_Extract.tif", exId); - SetDocExampleParameterValue("out", "smoothedImage_ani.png float", exId); - SetDocExampleParameterValue("type", "anidif", exId); - SetDocExampleParameterValue("type.anidif.timestep", "0.1", exId); - SetDocExampleParameterValue("type.anidif.nbiter", "5", exId); - SetDocExampleParameterValue("type.anidif.conductance", "1.5", exId); + SetExampleComment( "Image smoothing using a mean filter." , 0 ); + SetDocExampleParameterValue( "in" , "Romania_Extract.tif" ); + SetDocExampleParameterValue( "out" , "smoothedImage_mean.png uchar" ); + SetDocExampleParameterValue( "type" , "mean"); + + unsigned int exId = AddExample( "Image smoothing using an anisotropic " + "diffusion filter." ); + SetDocExampleParameterValue( "in" , "Romania_Extract.tif" , exId ); + SetDocExampleParameterValue( "out" , "smoothedImage_ani.png float" , exId ); + SetDocExampleParameterValue( "type" , "anidif" , exId ); + SetDocExampleParameterValue( "type.anidif.timestep" , "0.1" , exId ); + SetDocExampleParameterValue( "type.anidif.nbiter" , "5" , exId ); + SetDocExampleParameterValue( "type.anidif.conductance" , "1.5" , exId ); SetOfficialDocLink(); } diff --git a/Modules/Applications/AppHyperspectral/app/otbVertexComponentAnalysis.cxx b/Modules/Applications/AppHyperspectral/app/otbVertexComponentAnalysis.cxx index 4fe87620f4a2aa88bf6eb1ba246b9b5e99402e71..68c99058b4ea89e0ab2bdd1c1dd399f971708c39 100644 --- a/Modules/Applications/AppHyperspectral/app/otbVertexComponentAnalysis.cxx +++ b/Modules/Applications/AppHyperspectral/app/otbVertexComponentAnalysis.cxx @@ -50,16 +50,28 @@ private: void DoInit() ITK_OVERRIDE { SetName("VertexComponentAnalysis"); - SetDescription("Find endmembers in hyperspectral images with Vertex Component Analysis"); + SetDescription("Given a set of mixed spectral vectors, estimate" + "reference subtances also known as endmembers using the Vertex" + "Component Analysis algorithm."); // Documentation SetDocName("Vertex Component Analysis"); - SetDocLongDescription("Applies the Vertex Component Analysis to an hyperspectral image to extract endmembers"); + SetDocLongDescription("Apply the Vertex Component Analysis [1] to" + "an hyperspectral image to extract endmembers. Given a set of mixed" + "spectral vectors (multispectral or hyperspectral), the application" + "estimates the spectral signature of reference subtances also known" + "as endmembers."); SetDocLimitations("None"); SetDocAuthors("OTB-Team"); - SetDocSeeAlso(" "); - - AddDocTag("Miscellaneous"); + SetDocSeeAlso("[1] J. M. P. Nascimento and J. M. B. Dias, Vertex" + "component analysis: a fast algorithm to unmix hyperspectral data," + "in IEEE Transactions on Geoscience and Remote Sensing, vol. 43," + "no. 4, pp. 898-910, April 2005.J. M. P. Nascimento and" + "J. M. B. Dias, Vertex component analysis: a fast algorithm to" + "unmix hyperspectral data, in IEEE Transactions on Geoscience and" + "Remote Sensing, vol. 43, no. 4, pp. 898-910, April 2005."); + + AddDocTag("Miscellaneous"); AddDocTag(Tags::Hyperspectral); AddDocTag(Tags::DimensionReduction); @@ -67,12 +79,15 @@ private: SetParameterDescription("in","Input hyperspectral data cube"); AddParameter(ParameterType_Int, "ne", "Number of endmembers"); - SetParameterDescription("ne","The number of endmembers to extract from the data cube"); + SetParameterDescription("ne","The number of endmembers to extract from the hyperspectral image."); SetParameterInt("ne",1, false); MandatoryOn("ne"); AddParameter(ParameterType_OutputImage, "outendm", "Output Endmembers"); - SetParameterDescription("outendm","The endmebers, stored in a one-line multi-spectral image, each pixel representing an endmember"); + SetParameterDescription("outendm","Endmembers, stored in a" + "one-line multi-spectral image.Each pixel corresponds to one" + "endmembers and each band values corresponds to the spectral" + "signature of the corresponding endmember."); MandatoryOn("outendm"); AddRANDParameter(); diff --git a/Modules/Applications/AppImageUtils/app/otbConcatenateImages.cxx b/Modules/Applications/AppImageUtils/app/otbConcatenateImages.cxx index 5ebe69ddb418378e02d3808e4fd129ed4c51537c..185872b828b9299a1e807ee02d48b5da26f67931 100644 --- a/Modules/Applications/AppImageUtils/app/otbConcatenateImages.cxx +++ b/Modules/Applications/AppImageUtils/app/otbConcatenateImages.cxx @@ -61,10 +61,12 @@ private: // Documentation SetDocName("Images Concatenation"); - SetDocLongDescription("This application performs images channels concatenation. It will walk the input image list (single or multi-channel) and generates a single multi-channel image. The channel order is the one of the list."); + SetDocLongDescription("This application performs images channels concatenation. " + "It reads the input image list (single or multi-channel) " + "and generates a single multi-channel image. The channel order is the same as the list."); SetDocLimitations("All input images must have the same size."); SetDocAuthors("OTB-Team"); - SetDocSeeAlso("Rescale application, Convert"); + SetDocSeeAlso("Rescale application, Convert, SplitImage"); AddDocTag(Tags::Manip); AddDocTag("Concatenation"); @@ -75,10 +77,10 @@ private: m_ImageList = ImageListType::New(); AddParameter(ParameterType_InputImageList, "il", "Input images list"); - SetParameterDescription("il", "The list of images to concatenate"); + SetParameterDescription("il", "The list of images to concatenate, must have the same size."); AddParameter(ParameterType_OutputImage, "out", "Output Image"); - SetParameterDescription("out", "The concatenated output image"); + SetParameterDescription("out", "The concatenated output image."); AddRAMParameter(); diff --git a/Modules/Applications/AppImageUtils/app/otbSplitImage.cxx b/Modules/Applications/AppImageUtils/app/otbSplitImage.cxx index ece8b815a3b7252b5d243833bf327c1b08842195..e23eaa57eb5697fc6805aeac63725d69c76f342c 100644 --- a/Modules/Applications/AppImageUtils/app/otbSplitImage.cxx +++ b/Modules/Applications/AppImageUtils/app/otbSplitImage.cxx @@ -52,13 +52,16 @@ private: void DoInit() ITK_OVERRIDE { SetName("SplitImage"); - SetDescription("Split a N multiband image into N images"); + SetDescription("Split a N multiband image into N images."); SetDocName("Split Image"); - SetDocLongDescription("This application splits a N-bands image into N mono-band images. The output images filename will be generated from the output parameter. Thus if the input image has 2 channels, and the user has set an output outimage.tif, the generated images will be outimage_0.tif and outimage_1.tif"); + SetDocLongDescription("This application splits a N-bands image into N mono-band images. " + "The output images filename will be generated from the output parameter. " + "Thus, if the input image has 2 channels, and the user has set as output parameter, outimage.tif, " + "the generated images will be outimage_0.tif and outimage_1.tif."); SetDocLimitations("None"); SetDocAuthors("OTB-Team"); - SetDocSeeAlso(" "); + SetDocSeeAlso("ConcatenateImages"); AddDocTag(Tags::Manip); @@ -66,8 +69,10 @@ private: SetParameterDescription("in","Input multiband image filename."); AddParameter(ParameterType_OutputImage, "out", "Output Image"); - SetParameterDescription("out", - "Output filename that will be used to get the prefix and the extension of the output images to write"); + SetParameterDescription("out", "The output filename will be used to get the prefix " + "an the extension of the output written's image. For example with outimage.tif as output filename, " + "the generated images will had an indice (corresponding at each bands) " + "between the prefix and the extension, such as: outimage_0.tif and outimage_1.tif (if 2 bands)."); AddRAMParameter(); diff --git a/Modules/Applications/AppImageUtils/app/otbTileFusion.cxx b/Modules/Applications/AppImageUtils/app/otbTileFusion.cxx index a3f6a688aebd5402ef489e07e8c4e28311b6b4a7..5dd80bc10e6bc37c46f3302b8978272a6be973e7 100644 --- a/Modules/Applications/AppImageUtils/app/otbTileFusion.cxx +++ b/Modules/Applications/AppImageUtils/app/otbTileFusion.cxx @@ -52,7 +52,7 @@ private: // Documentation SetDocName("Image Tile Fusion"); - SetDocLongDescription("Concatenate several tile files into a single image file."); + SetDocLongDescription("Automatically mosaic a set of non overlapping tile files into a single image. Images must have a matching number of bands and they must be listed in lexicographic order."); SetDocLimitations("None"); SetDocAuthors("OTB-Team"); SetDocSeeAlso(" "); @@ -60,7 +60,7 @@ private: AddDocTag(Tags::Manip); AddParameter(ParameterType_InputImageList, "il", "Input Tile Images"); - SetParameterDescription("il", "Input tiles to concatenate (in lexicographic order : (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/AppMorphology/app/otbBinaryMorphologicalOperation.cxx b/Modules/Applications/AppMorphology/app/otbBinaryMorphologicalOperation.cxx index 486dd179452aca498030c435bea314084c3ac8f6..5db8cd97566d36c60d9c342068aa73bc8b4de699 100644 --- a/Modules/Applications/AppMorphology/app/otbBinaryMorphologicalOperation.cxx +++ b/Modules/Applications/AppMorphology/app/otbBinaryMorphologicalOperation.cxx @@ -78,77 +78,101 @@ private: void DoInit() ITK_OVERRIDE { -SetName("BinaryMorphologicalOperation"); -SetDescription("Performs morphological operations on an input image channel"); +SetName( "BinaryMorphologicalOperation" ); +SetDescription( "Performs morphological operations on an input image channel" ); // Documentation -SetDocName("Binary Morphological Operation"); -SetDocLongDescription("This application performs binary morphological operations on a mono band image"); -SetDocLimitations("None"); -SetDocAuthors("OTB-Team"); -SetDocSeeAlso("itkBinaryDilateImageFilter, itkBinaryErodeImageFilter, itkBinaryMorphologicalOpeningImageFilter and itkBinaryMorphologicalClosingImageFilter classes"); +SetDocName( "Binary Morphological Operation" ); +SetDocLongDescription( "This application performs binary morphological " + "operations on a mono band image or a channel of the input." ); +SetDocLimitations( "None" ); +SetDocAuthors( "OTB-Team" ); +SetDocSeeAlso( "itkBinaryDilateImageFilter, itkBinaryErodeImageFilter, " + "itkBinaryMorphologicalOpeningImageFilter and " + "itkBinaryMorphologicalClosingImageFilter classes." ); AddDocTag(Tags::FeatureExtraction); AddDocTag("Morphology"); -AddParameter(ParameterType_InputImage, "in", "Input Image"); -SetParameterDescription("in", "The input image to be filtered."); +AddParameter( ParameterType_InputImage , "in" , "Input Image" ); +SetParameterDescription( "in" , "The input image to be filtered." ); -AddParameter(ParameterType_OutputImage, "out", "Feature Output Image"); -SetParameterDescription("out", "Output image containing the filtered output image."); +AddParameter( ParameterType_OutputImage , "out" , "Output Image" ); +SetParameterDescription( "out" , "Output image" ); -AddParameter(ParameterType_Int, "channel", "Selected Channel"); -SetParameterDescription("channel", "The selected channel index"); -SetDefaultParameterInt("channel", 1); -SetMinimumParameterIntValue("channel", 1); +AddParameter( ParameterType_Int , "channel" , "Selected Channel" ); +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_Choice , "structype" , + "Type of structuring element" ); +SetParameterDescription( "structype" , + "Choice of the structuring element type"); //Ball -AddChoice("structype.ball", "Ball"); -AddParameter(ParameterType_Int, "structype.ball.xradius", "The Structuring Element X Radius"); -SetParameterDescription("structype.ball.xradius", "The Structuring Element X Radius"); -SetDefaultParameterInt("structype.ball.xradius", 5); -AddParameter(ParameterType_Int, "structype.ball.yradius", "The Structuring Element Y Radius"); -SetParameterDescription("structype.ball.yradius", "The Structuring Element Y Radius"); -SetDefaultParameterInt("structype.ball.yradius", 5); +AddChoice( "structype.ball" , "Ball" ); +AddParameter( ParameterType_Int , "structype.ball.xradius" , + "Structuring element X radius" ); +SetParameterDescription( "structype.ball.xradius" , + "The structuring element radius along the X axis." ); +SetDefaultParameterInt( "structype.ball.xradius" , 5 ); +AddParameter( ParameterType_Int , "structype.ball.yradius" , + "Structuring element Y radiuss" ); +SetParameterDescription( "structype.ball.yradius" , + "The structuring element radius along the y axis." ); +SetDefaultParameterInt( "structype.ball.yradius" , 5 ); //Cross -AddChoice("structype.cross", "Cross"); +AddChoice( "structype.cross" , "Cross" ); AddParameter(ParameterType_Choice, "filter", "Morphological Operation"); SetParameterDescription("filter", "Choice of the morphological operation"); //Dilate -AddChoice("filter.dilate", "Dilate"); -AddParameter(ParameterType_Float, "filter.dilate.foreval", "Foreground Value"); -SetParameterDescription("filter.dilate.foreval", "The Foreground Value"); -SetDefaultParameterFloat("filter.dilate.foreval", 1.0); -AddParameter(ParameterType_Float, "filter.dilate.backval", "Background Value"); -SetParameterDescription("filter.dilate.backval", "The Background Value"); -SetDefaultParameterFloat("filter.dilate.backval", 0.0); +AddChoice( "filter.dilate" , "Dilate" ); +AddParameter( ParameterType_Float , "filter.dilate.foreval" , + "Foreground value" ); +SetParameterDescription( "filter.dilate.foreval" , + "Set the foreground value, default is 1.0." ); +SetDefaultParameterFloat( "filter.dilate.foreval" , 1.0 ); +AddParameter( ParameterType_Float , "filter.dilate.backval" , + "Background value" ); +SetParameterDescription( "filter.dilate.backval" , + "Set the background value, default is 0.0." ); +SetDefaultParameterFloat( "filter.dilate.backval" , 0.0 ); //Erode -AddChoice("filter.erode", "Erode"); -AddParameter(ParameterType_Float, "filter.erode.foreval", "Foreground Value"); -SetParameterDescription("filter.erode.foreval", "The Foreground Value"); -SetDefaultParameterFloat("filter.erode.foreval", 1.0); -AddParameter(ParameterType_Float, "filter.erode.backval", "Background Value"); -SetParameterDescription("filter.erode.backval", "The Background Value"); +AddChoice( "filter.erode" , "Erode" ); +AddParameter( ParameterType_Float , "filter.erode.foreval" , + "Foreground value" ); +SetParameterDescription( "filter.erode.foreval" , + "Set the foreground value, default is 1.0." ); +SetDefaultParameterFloat( "filter.erode.foreval" , 1.0 ); +AddParameter( ParameterType_Float , "filter.erode.backval" , + "Background value" ); +SetParameterDescription("filter.erode.backval", + "Set the background value, default is 0.0." ); SetDefaultParameterFloat("filter.erode.backval", 0.0); + //Opening -AddChoice("filter.opening", "Opening"); -AddParameter(ParameterType_Float, "filter.opening.foreval", "Foreground Value"); -SetParameterDescription("filter.opening.foreval", "The Foreground Value"); +AddChoice( "filter.opening" , "Opening" ); +AddParameter( ParameterType_Float , "filter.opening.foreval" , + "Foreground value" ); +SetParameterDescription( "filter.opening.foreval" , + "Set the foreground value, default is 1.0." ); SetDefaultParameterFloat("filter.opening.foreval", 1.0); -AddParameter(ParameterType_Float, "filter.opening.backval", "Background Value"); -SetParameterDescription("filter.opening.backval", "The Background Value"); -SetDefaultParameterFloat("filter.opening.backval", 0.0); +AddParameter( ParameterType_Float , "filter.opening.backval" , + "Background value" ); +SetParameterDescription( "filter.opening.backval" , + "Set the background value, default is 0.0." ); +SetDefaultParameterFloat( "filter.opening.backval" , 0.0 ); //Closing -AddChoice("filter.closing", "Closing"); -AddParameter(ParameterType_Float, "filter.closing.foreval", "Foreground Value"); -SetParameterDescription("filter.closing.foreval", "The Foreground Value"); -SetDefaultParameterFloat("filter.closing.foreval", 1.0); +AddChoice( "filter.closing" , "Closing" ); +AddParameter( ParameterType_Float , "filter.closing.foreval" , + "Foreground value" ); +SetParameterDescription( "filter.closing.foreval" , + "Set the foreground value, default is 1.0." ); +SetDefaultParameterFloat( "filter.closing.foreval" , 1.0 ); // Doc example parameter settings SetDocExampleParameterValue("in", "qb_RoadExtract.tif"); diff --git a/Modules/Applications/AppMorphology/app/otbMorphologicalClassification.cxx b/Modules/Applications/AppMorphology/app/otbMorphologicalClassification.cxx index 3e6d338a0979dade558c2e19ee6278ee93c097fc..4bc606ac3fcc3e5f385f94e5b9d8540df40317c2 100644 --- a/Modules/Applications/AppMorphology/app/otbMorphologicalClassification.cxx +++ b/Modules/Applications/AppMorphology/app/otbMorphologicalClassification.cxx @@ -74,64 +74,75 @@ private: void DoInit() ITK_OVERRIDE { SetName( "MorphologicalClassification" ); - SetDescription( "Performs morphological convex, concave and flat classification on an input image channel" ); + SetDescription( "Performs morphological convex, concave and flat " + "classification on an input image channel" ); // Documentation SetDocName( "Morphological Classification" ); - SetDocLongDescription( "This algorithm is based on 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" - "This application perform the following decision rule to classify a pixel\n" - "between the three classes Convex, Concave and Flat. Let :math:`f` denote\n" - "the input image and :math:`\\psi_{N}(f)` the geodesic leveling of\n" - ":math:`f` with a structuring element of size :math:`N`. One can derive\n" - "the following decision rule to classify :math:`f` into Convex (label\n" - ":math:`\\stackrel{\\smile}{k}`), Concave (label\n" - ":math:`\\stackrel{\\frown}{k}`) and Flat (label :math:`\\bar{k}`): \n" - "\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" - "This 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 structuring element." ); + SetDocLongDescription( + "This algorithm is based on the following publication:\n" + "Martino Pesaresi and Jon Alti Benediktsson, Member, IEEE: A new approach " + "for the morphological segmentation of high resolution satellite imagery.\n" + "IEEE Transactions on geoscience and remote sensing, vol. 39, NO. 2, " + "February 2001, p. 309-320.\n" + "\n" + "This application perform the following decision rule to classify a pixel " + "between the three classes Convex, Concave and Flat. Let :math:`f` denote " + "the input image and :math:`\\psi_{N}(f)` the geodesic leveling of " + ":math:`f` with a structuring element of size :math:`N`. One can derive " + "the following decision rule to classify :math:`f` into Convex (label " + ":math:`\\stackrel{\\smile}{k}`), Concave (label " + ":math:`\\stackrel{\\frown}{k}`) and Flat (label :math:`\\bar{k}`): " + "\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)" ); + SetDocLimitations( + "Generation of the morphological classification is not streamable, " + "pay attention to this fact when setting the radius size of the " + "structuring element." ); SetDocAuthors( "OTB-Team" ); SetDocSeeAlso( "otbConvexOrConcaveClassificationFilter class" ); - AddDocTag(Tags::FeatureExtraction); - AddDocTag("Morphology"); + AddDocTag( Tags::FeatureExtraction ); + AddDocTag( "Morphology" ); - AddParameter( ParameterType_InputImage, "in", "Input Image" ); - SetParameterDescription( "in", "The input image to be classified." ); + AddParameter( ParameterType_InputImage , "in" , "Input Image" ); + SetParameterDescription( "in" , "The input image to be classified." ); - AddParameter( ParameterType_OutputImage, "out", "Output Image" ); + AddParameter( ParameterType_OutputImage , "out" , "Output Image" ); SetParameterDescription( "out", - "The output classified image with 3 different values (0 : Flat, 1 : Convex, 2 : Concave)" ); + "The output classified image with 3 different values (0 : Flat, " + "1 : Convex, 2 : Concave)" ); - AddParameter( ParameterType_Int, "channel", "Selected Channel" ); - SetParameterDescription( "channel", "The selected channel index for input image" ); - SetDefaultParameterInt( "channel", 1 ); - SetMinimumParameterIntValue( "channel", 1 ); + AddParameter( ParameterType_Int , "channel" , "Selected Channel" ); + SetParameterDescription( "channel" , + "The selected channel index for input image" ); + 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" ); - AddChoice( "structype.ball", "Ball" ); - AddChoice( "structype.cross", "Cross" ); - - AddParameter( ParameterType_Int, "radius", "Radius" ); - SetParameterDescription( "radius", "Radius of the structuring element (in pixels)" ); - SetDefaultParameterInt( "radius", 5 ); - SetMinimumParameterIntValue( "radius", 1 ); - - AddParameter( ParameterType_Float, "sigma", "Sigma value for leveling tolerance" ); - SetParameterDescription( "sigma", "Sigma value for leveling tolerance" ); - SetDefaultParameterFloat( "sigma", 0.5 ); - SetMinimumParameterFloatValue( "sigma", 0 ); + AddParameter( ParameterType_Choice , "structype" , + "Structuring Element Type" ); + SetParameterDescription( "structype" , + "Choice of the structuring element type" ); + AddChoice( "structype.ball" , "Ball" ); + AddChoice( "structype.cross" , "Cross" ); + + AddParameter( ParameterType_Int , "radius" , "Radius" ); + SetParameterDescription( "radius" , + "Radius of the structuring element (in pixels), default value is 5." ); + SetDefaultParameterInt( "radius" , 5 ); + SetMinimumParameterIntValue( "radius" , 1 ); + + AddParameter( ParameterType_Float , "sigma" , + "Sigma value for leveling tolerance" ); + SetParameterDescription( "sigma" , + "Sigma value for leveling tolerance, default value is 0.5." ); + SetDefaultParameterFloat( "sigma" , 0.5 ); + SetMinimumParameterFloatValue( "sigma" , 0 ); SetDocExampleParameterValue( "in", "ROI_IKO_PAN_LesHalles.tif" ); SetDocExampleParameterValue( "channel", "1" ); diff --git a/Modules/Applications/AppProjection/app/otbConvertCartoToGeoPoint.cxx b/Modules/Applications/AppProjection/app/otbConvertCartoToGeoPoint.cxx index 1d9642aa01d6577af4743d7da28310d63d52c3db..dfecb742eab6f21f8bbeb72794f15aa68c5c849b 100644 --- a/Modules/Applications/AppProjection/app/otbConvertCartoToGeoPoint.cxx +++ b/Modules/Applications/AppProjection/app/otbConvertCartoToGeoPoint.cxx @@ -53,11 +53,11 @@ private: void DoInit() ITK_OVERRIDE { SetName("ConvertCartoToGeoPoint"); - SetDescription("Convert cartographic coordinates to geographic one."); + SetDescription("Convert cartographic coordinates to geographic ones."); // Documentation SetDocName("Cartographic to geographic coordinates conversion"); - SetDocLongDescription("This application computes the geographic coordinates from a cartographic one. User has to give the X and Y coordinate and the cartographic projection (UTM/LAMBERT/LAMBERT2/LAMBERT93/SINUS/ECKERT4/TRANSMERCATOR/MOLLWEID/SVY21)."); + SetDocLongDescription("This application computes the geographic coordinates from cartographic ones. User has to give the X and Y coordinate and the cartographic projection (see mapproj parameter for details)."); SetDocLimitations("None"); SetDocAuthors("OTB-Team"); SetDocSeeAlso(" "); @@ -67,20 +67,20 @@ private: AddParameter(ParameterType_Group, "carto", "Input cartographic coordinates"); AddParameter(ParameterType_Float, "carto.x", "X cartographic coordinates"); - SetParameterDescription("carto.x", "X cartographic coordinates in the specified projection."); + SetParameterDescription("carto.x", "X cartographic coordinates in the projection defined by mapproj parameter"); AddParameter(ParameterType_Float, "carto.y", "Y cartographic coordinates"); - SetParameterDescription("carto.y", "Y cartographic coordinates in the specified projection."); + SetParameterDescription("carto.y", "Y cartographic coordinates in the projection defined by mapproj parameter"); // Add the MapProjectionParameters MapProjectionParametersHandler::AddMapProjectionParameters(this, "mapproj"); AddParameter(ParameterType_Float, "long", "Output long"); - SetParameterDescription("long", "Point longitude coordinates."); + SetParameterDescription("long", "Point longitude coordinates in decimal degrees."); SetParameterRole("long", Role_Output); AddParameter(ParameterType_Float, "lat", "Output lat"); - SetParameterDescription("lat", "Point latitude coordinates."); + SetParameterDescription("lat", "Point latitude coordinates in decimal degrees."); SetParameterRole("lat", Role_Output); // Doc example parameter settings diff --git a/Modules/Applications/AppProjection/app/otbOrthoRectification.cxx b/Modules/Applications/AppProjection/app/otbOrthoRectification.cxx index 2dc6a6119f70ce75cd81e2483d32392e10933fc6..8629ebe78966f0c94879bb2a5b184d117f3589a1 100644 --- a/Modules/Applications/AppProjection/app/otbOrthoRectification.cxx +++ b/Modules/Applications/AppProjection/app/otbOrthoRectification.cxx @@ -91,17 +91,18 @@ private: { SetName("OrthoRectification"); std::ostringstream oss; - oss << "This application allows ortho-rectification of optical and radar images from supported sensors." << std::endl; + oss << "This application allows to ortho-rectify optical and radar images from supported sensors." << std::endl; SetDescription(oss.str()); // Documentation SetDocName("Ortho-rectification"); oss.str(""); - oss<<"An inverse sensor model is built from the input image metadata to convert geographical to raw geometry coordinates. "; - oss<<"This inverse sensor model is then combined with the chosen map projection to build a global coordinate mapping grid. Last, this grid is used to resample using the chosen interpolation algorithm. "; - oss<<"A Digital Elevation Model can be specified to account for terrain deformations. "<<std::endl; + oss<<"This application uses inverse sensor modelling combined with a choice of interpolation functions to resample a sensor geometry image into a ground geometry regular grid. "; + oss<<"The ground geometry regular grid is defined with respect to a map projection (see map parameter). The application offers several modes to estimate the output grid parameters (origin and ground sampling distance), including automatic estimation of image size, ground sampling distance, or both, from image metadata, user-defined ROI corners, or another ortho-image."; + oss<<"A digital Elevation Model along with a geoid file can be specified to account for terrain deformations."; oss<<"In case of SPOT5 images, the sensor model can be approximated by an RPC model in order to speed-up computation."; + SetDocLongDescription(oss.str()); - SetDocLimitations("Supported sensors (both optical and radar) are: GeoEye, Ikonos, Pleiades, Quickbird, RadarSat, Sentinel-1, SPOT5 (TIF format), SPOT6/7, TerraSAR-X, Worldview 1/2/3."); + SetDocLimitations("Supported sensors (both optical and radar) are: GeoEye, Ikonos, Pleiades, Quickbird, RadarSat, Sentinel-1, SPOT5 (TIF format), SPOT6/7, TerraSAR-X, Worldview 1/2/3, and any TIF image with embedded RPC tags.\n Also note that the opt.gridspacing default value may not be suitable for all sensors. In particular, if this value is lower than the target ground sampling distance, the processing time may increase a lot. A warning is issued in this case. Typical values should be half the DEM ground sampling distance."); SetDocAuthors("OTB-Team"); SetDocSeeAlso("Ortho-rectification chapter from the OTB Software Guide"); diff --git a/Modules/Applications/AppStereo/app/otbStereoFramework.cxx b/Modules/Applications/AppStereo/app/otbStereoFramework.cxx index 312cff69e50867b3ac2ee6d0b5c4ce9bce98b4b5..74998367bbd597018ca24cc4c4dbb9aa20b269a3 100644 --- a/Modules/Applications/AppStereo/app/otbStereoFramework.cxx +++ b/Modules/Applications/AppStereo/app/otbStereoFramework.cxx @@ -313,47 +313,66 @@ private: void DoInit() ITK_OVERRIDE { + // TODO : implement this application as a CompositeApplication... SetName("StereoFramework"); SetDescription("Compute the ground elevation based on one or multiple stereo pair(s)"); SetDocName("Stereo Framework"); - SetDocLongDescription("Compute the ground elevation with a stereo block matching algorithm " - "between one or multiple stereo pair in sensor geometry. The output is projected in " - "desired geographic or cartographic map projection (UTM by default). The pipeline is made of the following steps:\n" - "for each sensor pair :\n\n" - "\t- compute the epipolar displacement grids from the stereo pair (direct and inverse)\n" - "\t- resample the stereo pair into epipolar geometry using BCO interpolation\n" - "\t- create masks for each epipolar image : remove black borders and resample" - " input masks\n" - "\t- compute horizontal disparities with a block matching algorithm\n" - "\t- refine disparities to sub-pixel precision with a dichotomy algorithm\n" - "\t- apply an optional median filter\n" - "\t- filter disparities based on the correlation score and exploration bounds\n" - "\t- translate disparities in sensor geometry\n" - "\t convert disparity to 3D Map.\n\n" - "Then fuse all 3D maps to produce DSM."); + SetDocLongDescription( + "Compute the ground elevation with a stereo block matching algorithm " + "between one or multiple stereo pair in sensor geometry. The output is " + "projected in desired geographic or cartographic map projection (WGS84 by" + " default).\n\n" + "This application is chaining different processing steps. Some of them " + "are also performed by other applications in the stereo-reconstruction " + "framework:\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" + "The pipeline executes the following steps on each stereo pair:\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" + " - 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" + " - filter disparities based on the correlation score and exploration bounds\n" + " - translate disparities in sensor geometry\n" + " - convert disparity to 3D Map.\n\n" + "Then all 3D maps are fused to produce DSM. The fusion method in each " + "DEM cell can be chosen between maximum, minimum and average."); SetDocLimitations(" "); SetDocAuthors("OTB-Team"); - SetDocSeeAlso(" "); + SetDocSeeAlso("[1] StereoRectificationGridGenerator\n" + "[2] GridBasedImageResampling\n" + "[3] BlockMatching"); AddDocTag(Tags::Stereo); // Add the output parameters in a group AddParameter(ParameterType_Group, "input", "Input parameters"); - SetParameterDescription("input","This group of parameters allows one to parametrize input data."); + SetParameterDescription("input","This group of parameters allows one to set input data."); - AddParameter(ParameterType_InputImageList, "input.il", "Input images list"); - SetParameterDescription("input.il", "The list of images."); + AddParameter(ParameterType_InputImageList, "input.il", "Input images list"); + SetParameterDescription("input.il", "List of images corresponding to " + "multiple views on a single scene, in sensor geometry."); 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 : 0 1,1 2 will process a first couple composed of the first and the second image in image list, then the first and the third image\n. note that images are handled by pairs." - " if left empty couples are created from input index i.e. a first couple will be composed of the first and second image, a second couple with third and fourth image etc. (in this case image list must be even)."); + SetParameterDescription("input.co","List of index of couples im image list." + " 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 " + "created from input index i.e. a first couple will be composed of the " + "first and second image, a second couple with third and fourth image etc." + " (in this case image list must be even)."); MandatoryOff("input.co"); SetParameterString("input.co","", false); DisableParameter("input.co"); - AddParameter(ParameterType_Int, "input.channel", "Image channel used for the block matching"); - SetParameterDescription("input.channel", "Used channel for block matching (used for all images)"); + AddParameter(ParameterType_Int, "input.channel", "Input Image channel"); + SetParameterDescription("input.channel", "Channel used for block matching (the same for all images)"); SetDefaultParameterInt("input.channel", 1); SetMinimumParameterIntValue("input.channel", 1); @@ -380,10 +399,18 @@ private: // UserDefined values AddParameter(ParameterType_Choice, "output.fusionmethod", "Method to fuse measures in each DSM cell"); SetParameterDescription("output.fusionmethod","This parameter allows one to choose the method used to fuse elevation measurements in each output DSM cell"); - AddChoice("output.fusionmethod.max", "The cell is filled with the maximum measured elevation values"); - AddChoice("output.fusionmethod.min", "The cell is filled with the minimum measured elevation values"); - AddChoice("output.fusionmethod.mean","The cell is filled with the mean of measured elevation values"); - AddChoice("output.fusionmethod.acc", "accumulator mode. The cell is filled with the the number of values (for debugging purposes)."); + AddChoice("output.fusionmethod.max", "Maximum"); + SetParameterDescription("output.fusionmethod.max","The cell is filled with" + " the maximum measured elevation values"); + AddChoice("output.fusionmethod.min", "Minimum"); + SetParameterDescription("output.fusionmethod.min", "The cell is filled with" + " the minimum measured elevation values"); + AddChoice("output.fusionmethod.mean","Mean"); + SetParameterDescription("output.fusionmethod.mean","The cell is filled with" + " the mean of measured elevation values"); + AddChoice("output.fusionmethod.acc", "Accumulator"); + SetParameterDescription("output.fusionmethod.acc", "Accumulator mode. The" + " cell is filled with the the number of values (for debugging purposes)."); AddParameter(ParameterType_OutputImage,"output.out","Output DSM"); SetParameterDescription("output.out","Output elevation image"); @@ -396,55 +423,76 @@ private: SetParameterDescription("output.mode.user","This mode allows you to fully modify default values."); // Upper left point coordinates AddParameter(ParameterType_Float, "output.mode.user.ulx", "Upper Left X "); - SetParameterDescription("output.mode.user.ulx","Cartographic X coordinate of upper-left corner (meters for cartographic projections, degrees for geographic ones)"); + SetParameterDescription("output.mode.user.ulx","Cartographic X coordinate " + "of upper-left corner (meters for cartographic projections, degrees for" + " geographic ones)"); AddParameter(ParameterType_Float, "output.mode.user.uly", "Upper Left Y "); - SetParameterDescription("output.mode.user.uly","Cartographic Y coordinate of the upper-left corner (meters for cartographic projections, degrees for geographic ones)"); + SetParameterDescription("output.mode.user.uly","Cartographic Y coordinate " + "of the upper-left corner (meters for cartographic projections, degrees " + "for geographic ones)"); // Size of the output image AddParameter(ParameterType_Int, "output.mode.user.sizex", "Size X "); - SetParameterDescription("output.mode.user.sizex","Size of projected image along X (in pixels)"); + SetParameterDescription("output.mode.user.sizex","Size of projected image" + " along X (in pixels)"); AddParameter(ParameterType_Int, "output.mode.user.sizey", "Size Y "); - SetParameterDescription("output.mode.user.sizey","Size of projected image along Y (in pixels)"); + SetParameterDescription("output.mode.user.sizey","Size of projected image" + " along Y (in pixels)"); // Spacing of the output image AddParameter(ParameterType_Float, "output.mode.user.spacingx", "Pixel Size X "); - SetParameterDescription("output.mode.user.spacingx","Size of each pixel along X axis (meters for cartographic projections, degrees for geographic ones)"); + SetParameterDescription("output.mode.user.spacingx","Size of each pixel " + "along X axis (meters for cartographic projections, degrees for geographic ones)"); AddParameter(ParameterType_Float, "output.mode.user.spacingy", "Pixel Size Y "); - SetParameterDescription("output.mode.user.spacingy","Size of each pixel along Y axis (meters for cartographic projections, degrees for geographic ones)"); + SetParameterDescription("output.mode.user.spacingy","Size of each pixel " + "along Y axis (meters for cartographic projections, degrees for geographic ones)"); // Add the output parameters in a group AddParameter(ParameterType_Group, "stereorect", "Stereorectification Grid parameters"); - SetParameterDescription("stereorect","This group of parameters allows one to choose direct and inverse grid subsampling. These parameters are very useful to tune time and memory consumption."); + SetParameterDescription("stereorect","This group of parameters allows one " + "to choose direct and inverse grid subsampling. These parameters are very" + " useful to tune time and memory consumption."); AddParameter(ParameterType_Int,"stereorect.fwdgridstep","Step of the displacement grid (in pixels)"); - SetParameterDescription("stereorect.fwdgridstep","Stereo-rectification displacement grid only varies slowly. Therefore, it is recommended to use a coarser grid (higher step value) in case of large images"); + SetParameterDescription("stereorect.fwdgridstep","Stereo-rectification " + "displacement grid only varies slowly. Therefore, it is recommended to " + "use a coarser grid (higher step value) in case of large images"); SetDefaultParameterInt("stereorect.fwdgridstep",16); MandatoryOff("stereorect.fwdgridstep"); AddParameter(ParameterType_Int, "stereorect.invgridssrate", "Sub-sampling rate for epipolar grid inversion"); - SetParameterDescription("stereorect.invgridssrate","Grid inversion is an heavy process that implies spline regression on control points. To avoid eating to much memory, this parameter allows one to first sub-sample the field to invert."); + SetParameterDescription("stereorect.invgridssrate","Grid inversion is an " + "heavy process that implies spline regression on control points. To avoid" + " eating to much memory, this parameter allows one to first sub-sample " + "the field to invert."); SetDefaultParameterInt("stereorect.invgridssrate",10); SetMinimumParameterIntValue("stereorect.invgridssrate",1); MandatoryOff("stereorect.invgridssrate"); AddParameter(ParameterType_Group,"bm","Block matching parameters"); - SetParameterDescription("bm","This group of parameters allow tuning the block-matching behavior"); + SetParameterDescription("bm","This group of parameters allow tuning the " + "block-matching behavior"); AddParameter(ParameterType_Choice, "bm.metric", "Block-matching metric"); + SetParameterDescription("bm.metric", "Metric used to compute matching score"); //SetDefaultParameterInt("bm.metric",3); AddChoice("bm.metric.ssdmean","Sum of Squared Distances divided by mean of block"); - SetParameterDescription("bm.metric.ssdmean","derived version of Sum of Squared Distances between pixels value in the metric window (SSD divided by mean over window)"); + SetParameterDescription("bm.metric.ssdmean","derived version of Sum of " + "Squared Distances between pixels value in the metric window (SSD divided" + " by mean over window)"); AddChoice("bm.metric.ssd","Sum of Squared Distances"); - SetParameterDescription("bm.metric.ssd","Sum of squared distances between pixels value in the metric window"); + SetParameterDescription("bm.metric.ssd","Sum of squared distances between " + "pixels value in the metric window"); AddChoice("bm.metric.ncc","Normalized Cross-Correlation"); - SetParameterDescription("bm.metric.ncc","Normalized Cross-Correlation between the left and right windows"); + SetParameterDescription("bm.metric.ncc","Normalized Cross-Correlation " + "between the left and right windows"); AddChoice("bm.metric.lp","Lp pseudo-norm"); SetParameterDescription("bm.metric.lp","Lp pseudo-norm between the left and right windows"); @@ -454,20 +502,22 @@ private: SetDefaultParameterFloat("bm.metric.lp.p", 1.0); SetMinimumParameterFloatValue("bm.metric.lp.p", 0.0); - AddParameter(ParameterType_Int,"bm.radius","Radius of blocks for matching filter (in pixels)"); + AddParameter(ParameterType_Int,"bm.radius","Correlation window radius (in pixels)"); SetParameterDescription("bm.radius","The radius of blocks in Block-Matching (in pixels)"); SetDefaultParameterInt("bm.radius",2); SetMinimumParameterIntValue("bm.radius",1); MandatoryOff("bm.radius"); AddParameter(ParameterType_Float,"bm.minhoffset","Minimum altitude offset (in meters)"); - SetParameterDescription("bm.minhoffset","Minimum altitude below the selected elevation source (in meters)"); + SetParameterDescription("bm.minhoffset","Minimum altitude below the " + "selected elevation source (in meters)"); //MandatoryOff("bm.minhoffset"); SetDefaultParameterFloat("bm.minhoffset",-20.0); DisableParameter("bm.minhoffset"); AddParameter(ParameterType_Float,"bm.maxhoffset","Maximum altitude offset (in meters)"); - SetParameterDescription("bm.maxhoffset","Maximum altitude above the selected elevation source (in meters)"); + SetParameterDescription("bm.maxhoffset","Maximum altitude above the " + "selected elevation source (in meters)"); //MandatoryOff("bm.maxhoffset"); SetDefaultParameterFloat("bm.maxhoffset",20.0); DisableParameter("bm.maxhoffset"); @@ -475,19 +525,25 @@ private: AddParameter(ParameterType_Group,"postproc","Postprocessing parameters"); SetParameterDescription("postproc","This group of parameters allow use optional filters."); - AddParameter(ParameterType_Empty,"postproc.bij","Use bijection consistency in block matching strategy"); - SetParameterDescription("postproc.bij","use bijection consistency. Right to Left correlation is computed to validate Left to Right disparities. If bijection is not found pixel is rejected."); + AddParameter(ParameterType_Empty,"postproc.bij","Use bijection consistency" + " in block matching strategy"); + SetParameterDescription("postproc.bij","Use bijection consistency. " + "Right to Left correlation is computed to validate Left to Right " + "disparities. If bijection is not found, the disparity is rejected."); MandatoryOff("postproc.bij"); EnableParameter("postproc.bij"); AddParameter(ParameterType_Empty,"postproc.med","Use median disparities filtering"); - SetParameterDescription("postproc.med","disparities output can be filtered using median post filtering (disabled by default)."); + SetParameterDescription("postproc.med","Disparity map can be filtered using" + " median post filtering (disabled by default)."); MandatoryOff("postproc.med"); DisableParameter("postproc.med"); AddParameter(ParameterType_Float,"postproc.metrict","Correlation metric threshold"); - SetParameterDescription("postproc.metrict","Use block matching metric output to discard pixels with low correlation value (disabled by default, float value)"); + SetParameterDescription("postproc.metrict","Use block matching metric " + "output to discard pixels with low correlation value (disabled by " + "default, float value)"); MandatoryOff("postproc.metrict"); SetDefaultParameterFloat("postproc.metrict",0.6); DisableParameter("postproc.metrict"); @@ -495,24 +551,28 @@ private: AddParameter(ParameterType_Group,"mask","Masks"); AddParameter(ParameterType_InputImage, "mask.left","Input left mask"); - SetParameterDescription("mask.left","Mask for left input image"); + SetParameterDescription("mask.left","Mask for left input image. Pixel with" + " a null mask value are discarded."); MandatoryOff("mask.left"); DisableParameter("mask.left"); AddParameter(ParameterType_InputImage, "mask.right","Input right mask"); - SetParameterDescription("mask.right","Mask for right input image"); + SetParameterDescription("mask.right","Mask for right input image. Pixel " + "with a null mask value are discarded."); MandatoryOff("mask.right"); DisableParameter("mask.right"); - AddParameter(ParameterType_Float,"mask.variancet","Discard pixels with low local variance"); - SetParameterDescription("mask.variancet","This parameter allows one to discard pixels whose local variance is too small (the size of the neighborhood is given by the radius parameter)"); + AddParameter(ParameterType_Float,"mask.variancet","Discard pixels with low" + " local variance"); + SetParameterDescription("mask.variancet","This parameter allows one to " + "discard pixels whose local variance is too small (the size of the " + "neighborhood is given by the correlation window radius)"); MandatoryOff("mask.variancet"); SetDefaultParameterFloat("mask.variancet",50.); //DisableParameter("mask.variancet"); AddRAMParameter(); - SetDocExampleParameterValue("input.il","sensor_stereo_left.tif sensor_stereo_right.tif"); SetDocExampleParameterValue("elev.default","200"); SetDocExampleParameterValue("stereorect.fwdgridstep", "8"); diff --git a/Modules/Applications/AppStereo/app/otbStereoRectificationGridGenerator.cxx b/Modules/Applications/AppStereo/app/otbStereoRectificationGridGenerator.cxx index ed0d0fddb05a79d64082bdbbf236409064f02a03..41a3b205c39214c6a52390270b3f09f11920e49a 100644 --- a/Modules/Applications/AppStereo/app/otbStereoRectificationGridGenerator.cxx +++ b/Modules/Applications/AppStereo/app/otbStereoRectificationGridGenerator.cxx @@ -102,11 +102,28 @@ private: void DoInit() ITK_OVERRIDE { SetName("StereoRectificationGridGenerator"); - SetDescription("Generates two deformation fields to stereo-rectify (i.e. resample in epipolar geometry) a pair of stereo images up to the sensor model precision"); + SetDescription("Generates two deformation fields to resample in epipolar " + "geometry, a pair of stereo images up to the sensor model precision"); SetDocName("Stereo-rectification deformation grid generator"); - SetDocLongDescription("This application generates a pair of deformation grid to stereo-rectify a pair of stereo images according to sensor modelling and a mean elevation hypothesis. The deformation grids can be passed to the GridBasedImageResampling application for actual resampling in epipolar geometry."); - SetDocLimitations("Generation of the deformation grid is not streamable, pay attention to this fact when setting the grid step."); + SetDocLongDescription("This application generates a pair of deformation " + "grid to stereo-rectify a pair of stereo images according to sensor " + "modelling and a mean elevation hypothesis.\n\n" + "This application is the first part of the stereo reconstruction " + "framework. The output deformation grids can be passed to the " + "GridBasedImageResampling application for actual resampling into epipolar" + " geometry.\n\n" + "There are several ways to set the elevation source:\n" + " * An arbitrary constant elevation\n" + " * A DEM directoy\n" + " * Compute an average elevation from a DEM\n\n" + "If needed, the application can compute inverse resampling grids (from " + "epipolar to original sensor geometry). Don't forget to check the other " + "outputs from the application. For instance, the application gives the " + "X and Y size of the rectified images, along with an estimated baseline " + "ratio."); + SetDocLimitations("Generation of the deformation grid is not streamable, " + "pay attention to this fact when setting the grid step."); SetDocAuthors("OTB-Team"); AddDocTag(Tags::Stereo); @@ -116,16 +133,20 @@ private: AddParameter(ParameterType_Group,"io","Input and output data"); SetParameterDescription("io","This group of parameters allows setting the input and output images."); AddParameter(ParameterType_InputImage,"io.inleft","Left input image"); - SetParameterDescription("io.inleft","The left input image to resample"); + SetParameterDescription("io.inleft","The left image from the stereo pair," + " in sensor geometry."); AddParameter(ParameterType_InputImage,"io.inright","Right input image"); - SetParameterDescription("io.inright","The right input image to resample"); + SetParameterDescription("io.inright","The right image from the stereo pair," + " in sensor geometry."); AddParameter(ParameterType_OutputImage, "io.outleft", "Left output deformation grid"); - SetParameterDescription("io.outleft","The output deformation grid to be used to resample the left input image"); + SetParameterDescription("io.outleft","The deformation grid to resample the" + " left image from sensor geometry to epipolar geometry."); AddParameter(ParameterType_OutputImage, "io.outright", "Right output deformation grid"); - SetParameterDescription("io.outright","The output deformation grid to be used to resample the right input image"); + SetParameterDescription("io.outright","The deformation grid to resample the" + " right image from sensor geometry to epipolar geometry."); AddParameter(ParameterType_Group,"epi","Epipolar geometry and grid parameters"); SetParameterDescription("epi","Parameters of the epipolar geometry and output grids"); @@ -148,48 +169,73 @@ private: DisableParameter("epi.elevation.avgdem.value"); AddParameter(ParameterType_Float,"epi.elevation.avgdem.mindisp","Minimum disparity from DEM"); - SetParameterDescription("epi.elevation.avgdem.mindisp","Disparity corresponding to estimated minimum elevation over the left image"); + SetParameterDescription("epi.elevation.avgdem.mindisp","Disparity " + "corresponding to estimated minimum elevation over the left image"); SetParameterRole("epi.elevation.avgdem.mindisp",Role_Output); DisableParameter("epi.elevation.avgdem.mindisp"); AddParameter(ParameterType_Float,"epi.elevation.avgdem.maxdisp","Maximum disparity from DEM"); - SetParameterDescription("epi.elevation.avgdem.maxdisp","Disparity corresponding to estimated maximum elevation over the left image"); + SetParameterDescription("epi.elevation.avgdem.maxdisp","Disparity " + "corresponding to estimated maximum elevation over the left image"); SetParameterRole("epi.elevation.avgdem.maxdisp",Role_Output); DisableParameter("epi.elevation.avgdem.maxdisp"); AddParameter(ParameterType_Float,"epi.scale","Scale of epipolar images"); - SetParameterDescription("epi.scale","The scale parameter allows generating zoomed-in (scale < 1) or zoomed-out (scale > 1) epipolar images."); + SetParameterDescription("epi.scale","The scale parameter allows generating" + " 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)"); - 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"); + 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"); SetDefaultParameterInt("epi.step",1); AddParameter(ParameterType_Int,"epi.rectsizex","Rectified image size X"); - SetParameterDescription("epi.rectsizex","The application computes the optimal rectified image size so that the whole left input image fits into the rectified area. However, due to the scale and step parameter, this size may not match the size of the deformation field output. In this case, one can use these output values."); + SetParameterDescription("epi.rectsizex","The application computes the " + "optimal rectified image size so that the whole left input image fits " + "into the rectified area. However, due to the scale and step parameter, " + "this size may not match the size of the deformation field output. In " + "this case, one can use these output values."); SetParameterRole("epi.rectsizex", Role_Output); AddParameter(ParameterType_Int,"epi.rectsizey","Rectified image size Y"); - SetParameterDescription("epi.rectsizey","The application computes the optimal rectified image size so that the whole left input image fits into the rectified area. However, due to the scale and step parameter, this size may not match the size of the deformation field output. In this case, one can use these output values."); + SetParameterDescription("epi.rectsizey","The application computes the " + "optimal rectified image size so that the whole left input image fits " + "into the rectified area. However, due to the scale and step parameter, " + "this size may not match the size of the deformation field output. In " + "this case, one can use these output values."); SetParameterRole("epi.rectsizey", Role_Output); AddParameter(ParameterType_Float,"epi.baseline","Mean baseline ratio"); - SetParameterDescription("epi.baseline","This parameter is the mean value, in pixels.meters^-1, of the baseline to sensor altitude ratio. It can be used to convert disparities to physical elevation, since a disparity of one pixel will correspond to an elevation offset of the invert of this value with respect to the mean elevation."); + SetParameterDescription("epi.baseline","This parameter is the mean value, " + "in pixels.meters^-1, of the baseline to sensor altitude ratio. It can be" + " used to convert disparities to physical elevation, since a disparity of" + " one pixel will correspond to an elevation offset of the invert of this" + " value with respect to the mean elevation."); SetParameterRole("epi.baseline", Role_Output); AddParameter(ParameterType_Group,"inverse","Write inverse fields"); - SetParameterDescription("inverse","This group of parameter allows generating the inverse fields as well"); + SetParameterDescription("inverse","This group of parameter allows " + "generating the inverse fields as well"); AddParameter(ParameterType_OutputImage, "inverse.outleft", "Left inverse deformation grid"); - SetParameterDescription("inverse.outleft","The output deformation grid to be used to resample the epipolar left image"); + SetParameterDescription("inverse.outleft","The deformation grid to resample" + " the left image from the epipolar geometry back into its original sensor" + " geometry."); MandatoryOff("inverse.outleft"); AddParameter(ParameterType_OutputImage, "inverse.outright", "Right inverse deformation grid"); - SetParameterDescription("inverse.outright","The output deformation grid to be used to resample the epipolar right image"); + SetParameterDescription("inverse.outright","The output deformation grid to" + " resample the right image from the epipolar geometry back into its " + "original sensor geometry."); MandatoryOff("inverse.outright"); AddParameter(ParameterType_Int, "inverse.ssrate", "Sub-sampling rate for inversion"); - SetParameterDescription("inverse.ssrate","Grid inversion is an heavy process that implies spline regression on control points. To avoid eating to much memory, this parameter allows one to first sub-sample the field to invert."); + SetParameterDescription("inverse.ssrate","Grid inversion is an heavy " + "process that implies spline regression on control points. To avoid " + "eating to much memory, this parameter allows one to first sub-sample " + "the field to invert."); SetDefaultParameterInt("inverse.ssrate",16); SetMinimumParameterIntValue("inverse.ssrate",1); diff --git a/Modules/Applications/AppTextures/app/otbHaralickTextureExtraction.cxx b/Modules/Applications/AppTextures/app/otbHaralickTextureExtraction.cxx index cdde4cc990a6c8db672160ddb5be2ec955755722..43e6b0b0e1e69e44a6eac18428c299e2bbe5e316 100644 --- a/Modules/Applications/AppTextures/app/otbHaralickTextureExtraction.cxx +++ b/Modules/Applications/AppTextures/app/otbHaralickTextureExtraction.cxx @@ -70,14 +70,34 @@ private: void DoInit() ITK_OVERRIDE { SetName("HaralickTextureExtraction"); -SetDescription("Computes textures on every pixel of the input image selected channel"); +SetDescription("Computes Haralick textural features on the selected channel of the input image"); // Documentation SetDocName("Haralick Texture Extraction"); -SetDocLongDescription("This application computes Haralick, advanced and higher order textures on a mono band image"); -SetDocLimitations("None"); +SetDocLongDescription("This application computes three sets of Haralick features [1][2].\n" + " * simple:Â a set of 8 local Haralick features: Energy (texture uniformity) , " + "Entropy (measure of randomness of intensity image), Correlation (how " + "correlated a pixel is to its neighborhood), Inverse Difference Moment (measures " + "the texture homogeneity), Inertia (intensity contrast between a pixel and its " + "neighborhood), Cluster Shade, Cluster Prominence, Haralick Correlation;\n" + " * advanced: a set of 10 advanced Haralick features : Mean, Variance (measures the " + "texture heterogeneity), Dissimilarity, Sum Average, Sum Variance, Sum Entropy, " + "Difference of Entropies, Difference of Variances, IC1, IC2;\n" + " * higher: a set of 11 higher Haralick features : Short Run Emphasis (measures the " + "texture sharpness), Long Run Emphasis (measures the texture roughness), Grey-Level " + "Nonuniformity, Run Length Nonuniformity, Run Percentage (measures the texture " + "sharpness homogeneity), Low Grey-Level Run Emphasis, High Grey-Level Run Emphasis, " + "Short Run Low Grey-Level Emphasis, Short Run High Grey-Level Emphasis, Long Run Low " + "Grey-Level Emphasis and Long Run High Grey-Level Emphasis."); +SetDocLimitations("The computation of the features is based on a Gray Level Co-occurrence " + "matrix (GLCM) from the quantized input image. Consequently the quantization " + "parameters (min, max, nbbin) must be appropriate to the range of the pixel values."); SetDocAuthors("OTB-Team"); -SetDocSeeAlso("otbScalarImageToTexturesFilter, otbScalarImageToAdvancedTexturesFilter and otbScalarImageToHigherOrderTexturesFilter classes"); +SetDocSeeAlso("[1] HARALICK, Robert M., SHANMUGAM, Karthikeyan, et al. " + "Textural features for image classification. IEEE Transactions on systems, " + "man, and cybernetics, 1973, no 6, p. 610-621.\n" + "[2] otbScalarImageToTexturesFilter, otbScalarImageToAdvancedTexturesFilter and " + "otbScalarImageToHigherOrderTexturesFilter classes"); AddDocTag(Tags::FeatureExtraction); AddDocTag("Textures"); @@ -100,7 +120,8 @@ MandatoryOff("step"); AddRAMParameter(); AddParameter(ParameterType_Group, "parameters", "Texture feature parameters"); -SetParameterDescription("parameters","This group of parameters allows one to define texture parameters."); +SetParameterDescription("parameters","This group of parameters allows one to define " + "texture parameters."); AddParameter(ParameterType_Int,"parameters.xrad","X Radius"); SetParameterDescription("parameters.xrad", "X Radius"); @@ -134,20 +155,25 @@ AddParameter(ParameterType_Choice, "texture", "Texture Set Selection"); SetParameterDescription("texture", "Choice of The Texture Set"); AddChoice("texture.simple", "Simple Haralick Texture Features"); -SetParameterDescription("texture.simple","This group of parameters defines the 8 local Haralick texture feature output image.\ - The image channels are: Energy, Entropy, Correlation, Inverse Difference Moment,\ - Inertia, Cluster Shade, Cluster Prominence and Haralick Correlation"); +SetParameterDescription("texture.simple", "This group of parameters defines " + "the 8 local Haralick texture feature output image. The image channels are: " + "Energy, Entropy, Correlation, Inverse Difference Moment, Inertia, Cluster " + "Shade, Cluster Prominence and Haralick Correlation"); AddChoice("texture.advanced", "Advanced Texture Features"); -SetParameterDescription("texture.advanced","This group of parameters defines the 10 advanced texture feature output image.\ - The image channels are: Mean, Variance, Dissimilarity, Sum Average, Sum Variance,\ - Sum Entropy, Difference of Entropies, Difference of Variances, IC1 and IC2"); +SetParameterDescription("texture.advanced", "This group of parameters defines " + "the 10 advanced texture feature output image. The image channels are: Mean, " + "Variance, Dissimilarity, Sum Average, Sum Variance, Sum Entropy, Difference " + "of Entropies, Difference of Variances, IC1 and IC2"); AddChoice("texture.higher", "Higher Order Texture Features"); -SetParameterDescription("texture.higher","This group of parameters defines the 11 higher order texture feature output image.\ - The image channels are: Short Run Emphasis, Long Run Emphasis, Grey-Level Nonuniformity, Run Length Nonuniformity, Run Percentage, \ - Low Grey-Level Run Emphasis, High Grey-Level Run Emphasis, Short Run Low Grey-Level Emphasis, Short Run High Grey-Level Emphasis, \ - Long Run Low Grey-Level Emphasis and Long Run High Grey-Level Emphasis"); +SetParameterDescription("texture.higher", "This group of parameters defines the " + "11 higher order texture feature output image. The image channels are: " + "Short Run Emphasis, Long Run Emphasis, Grey-Level Nonuniformity, " + "Run Length Nonuniformity, Run Percentage, Low Grey-Level Run Emphasis, " + "High Grey-Level Run Emphasis, Short Run Low Grey-Level Emphasis, " + "Short Run High Grey-Level Emphasis, Long Run Low Grey-Level Emphasis and " + "Long Run High Grey-Level Emphasis"); AddParameter(ParameterType_OutputImage, "out", "Output Image"); SetParameterDescription("out", "Output image containing the selected texture features."); diff --git a/Modules/Applications/AppTextures/app/otbSFSTextureExtraction.cxx b/Modules/Applications/AppTextures/app/otbSFSTextureExtraction.cxx index 14fb6df2b3ee8499943cc14dbb27a34a6bcd5c51..0475acab406aed600a156d82cc568c73bf0baaa3 100644 --- a/Modules/Applications/AppTextures/app/otbSFSTextureExtraction.cxx +++ b/Modules/Applications/AppTextures/app/otbSFSTextureExtraction.cxx @@ -61,14 +61,24 @@ private: void DoInit() ITK_OVERRIDE { SetName("SFSTextureExtraction"); -SetDescription("Computes Structural Feature Set textures on every pixel of the input image selected channel"); +SetDescription("Computes Structural Feature Set textures on every pixel of the " + "input image selected channel"); // Documentation SetDocName("SFS Texture Extraction"); -SetDocLongDescription("This application computes SFS textures on a mono band image"); +SetDocLongDescription("Structural Feature Set [1] are based on the histograms of " + "the pixels in multiple directions of the image. The SFSTextureExtraction application " + "computes the 6 following features: SFS'Length, SFS'Width, SFS'PSI, SFS'W-Mean, " + "SFS'Ratio and SFS'SD (Standard Deviation). The texture indices are computed from " + "the neighborhood of each pixel. It is possible to change the length of the calculation " + "line (spatial threshold), as well as the maximum difference between a pixel of the line " + "and the pixel at the center of the neighborhood (spectral threshold) [2]."); SetDocLimitations("None"); SetDocAuthors("OTB-Team"); -SetDocSeeAlso("otbSFSTexturesImageFilter class"); +SetDocSeeAlso("[1] HUANG, Xin, ZHANG, Liangpei, et LI, Pingxiang. Classification and extraction " + "of spatial features in urban areas using high-resolution multispectral imagery. " + "IEEE Geoscience and Remote Sensing Letters, 2007, vol. 4, no 2, p. 260-264.\n" + "[2] otbSFSTexturesImageFilter class"); AddDocTag(Tags::FeatureExtraction); AddDocTag("Textures"); @@ -84,9 +94,9 @@ 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, SFS'Ratio and SFS'SD.\ - They are provided in this exact order in the output image."); +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, " + "SFS'Ratio and SFS'SD. They are provided in this exact order in the output image."); AddParameter(ParameterType_Float,"parameters.spethre","Spectral Threshold"); SetParameterDescription("parameters.spethre", "Spectral Threshold"); diff --git a/Modules/Applications/AppVectorUtils/app/otbConcatenateVectorData.cxx b/Modules/Applications/AppVectorUtils/app/otbConcatenateVectorData.cxx index 0710b1bf50ff0772fa6ce96ec4eda04879edb969..92b972eafc02587d0636bdfaf3771625b8824beb 100644 --- a/Modules/Applications/AppVectorUtils/app/otbConcatenateVectorData.cxx +++ b/Modules/Applications/AppVectorUtils/app/otbConcatenateVectorData.cxx @@ -50,22 +50,28 @@ private: void DoInit() ITK_OVERRIDE { SetName("ConcatenateVectorData"); - SetDescription("Concatenate VectorDatas"); - - SetDocName("Concatenate"); - SetDocLongDescription("This application concatenates a list of VectorData to produce a unique VectorData as output." - "Note that the VectorDatas must be of the same type (Storing polygons only, lines only, or points only)"); - SetDocLimitations("None"); + SetDescription("Concatenate vector data files"); + + SetDocName("Concatenate Vector Data"); + SetDocLongDescription("This application concatenates a list of vector data " + "files to produce a unique vector data output file.\n\n" + "This application will gather all the geometries from the input files and" + " write them into an output vector data file. Any format supported by OGR" + " can be used. Ideally, all inputs should have the same set of fields and" + " the same spatial reference system."); + SetDocLimitations("The vector data must be contain the same type of " + "geometries (point / lines / polygons). The fields present in the output " + "file are the ones from the first input."); SetDocAuthors("OTB-Team"); SetDocSeeAlso(" "); AddDocTag(Tags::Vector); - AddParameter(ParameterType_InputVectorDataList, "vd", "Input VectorDatas to concatenate"); - SetParameterDescription("vd", "VectorData files to be concatenated in an unique VectorData"); + AddParameter(ParameterType_InputVectorDataList, "vd", "Input vector files"); + SetParameterDescription("vd", "Vector data files to be concatenated."); - AddParameter(ParameterType_OutputVectorData, "out", "Concatenated VectorData"); - SetParameterDescription("out", "Output conctenated VectorData"); + AddParameter(ParameterType_OutputVectorData, "out", "Concatenated output"); + SetParameterDescription("out", "Output conctenated vector data file."); // Doc example parameter settings SetDocExampleParameterValue("vd", "ToulousePoints-examples.shp ToulouseRoad-examples.shp"); diff --git a/Modules/Applications/AppVectorUtils/app/otbOSMDownloader.cxx b/Modules/Applications/AppVectorUtils/app/otbOSMDownloader.cxx index 0cc82f51d11a29ae4f492af0f1c7dbe1f3541bc8..d55626ed0bb0f79d3696a4a2940c59a870038217 100644 --- a/Modules/Applications/AppVectorUtils/app/otbOSMDownloader.cxx +++ b/Modules/Applications/AppVectorUtils/app/otbOSMDownloader.cxx @@ -53,40 +53,55 @@ private: void DoInit() ITK_OVERRIDE { SetName("OSMDownloader"); - SetDescription("Generate a vector data from OSM on the input image extend"); + SetDescription("Download vector data from OSM and store it to file"); // Documentation - SetDocName("Open Street Map layers importations applications"); - SetDocLongDescription("Generate a vector data from Open Street Map data. A DEM could be use. By default, the entire layer is downloaded, an image can be use as support for the OSM data. The application can provide also available classes in layers . This application required an Internet access. Information about the OSM project : http://www.openstreetmap.fr/"); - SetDocLimitations("None"); + SetDocName("Open Street Map layers import"); + SetDocLongDescription("The application connects to Open Street Map server" + ", downloads the data corresponding to the spatial extent of the support" + " image, and filters the geometries based on OSM tags to produce a vector" + " data file.\n\n" + "This application can be used to download reference data to perform the " + "training of a machine learning model (see for instance [1]).\n\n" + "By default, the entire layer is downloaded. The application has a " + "special mode to provide the list of available classes in the layers. " + "The downloaded features are filtered by giving an OSM tag 'key'. In " + "addition, the user can also choose what 'value' this key should have. " + "More information about the OSM project at [2]."); + SetDocLimitations("This application requires an Internet access."); SetDocAuthors("OTB-Team"); - SetDocSeeAlso("Conversion"); + SetDocSeeAlso("[1] TrainImagesClassifier \n" + "[2] http://www.openstreetmap.fr/"); AddDocTag("Miscellaneous"); AddDocTag(Tags::Meta); AddDocTag(Tags::Vector); - AddParameter(ParameterType_OutputVectorData, "out", "Output vector data"); - SetParameterDescription("out", "Generated output vector data path"); + AddParameter(ParameterType_OutputVectorData, "out", "Output vector data"); + SetParameterDescription("out", "Vector data file to store downloaded features"); - AddParameter(ParameterType_InputImage, "support", "Support image"); - SetParameterDescription("support", "Image used as support to estimate the models"); + AddParameter(ParameterType_InputImage, "support", "Support image"); + SetParameterDescription("support", "Image used to derive the spatial extent" + " to be requested from OSM server (the bounding box of the extent is " + "used). Be aware that a request with a large extent may be rejected by " + "the server."); AddParameter(ParameterType_String, "key", "OSM tag key"); - SetParameterDescription("key", "OSM tag key to extract (highway, building...)"); + SetParameterDescription("key", "OSM tag key to extract (highway, building" + "...). It defines a category to select features."); MandatoryOff("key"); AddParameter(ParameterType_String, "value", "OSM tag value"); - SetParameterDescription("value", "OSM tag value to extract (motorway, footway...)"); + SetParameterDescription("value", "OSM tag value to extract (motorway, " + "footway...). It defines the type of feature to select inside a category."); MandatoryOff("value"); // Elevation ElevationParametersHandler::AddElevationParameters(this, "elev"); - AddParameter(ParameterType_Empty, "printclasses", "option to display available key/value classes"); - std::ostringstream oss; - oss << "Print the key/value classes available for the bounding box of the input image "<<std::endl; - oss << "\t\t\t\t ** If not used : Note that the options OSMKey (-key) and Output (-out) become mandatory"; - SetParameterDescription("printclasses", oss.str().c_str()); + AddParameter(ParameterType_Empty, "printclasses", "Displays available key/value classes"); + SetParameterDescription("printclasses","Print the key/value classes " + "available for the selected support image. If enabled, the OSM tag Key " + "(-key) and the output (-out) become optional" ); MandatoryOff("printclasses"); // Doc example parameter settings diff --git a/Modules/Applications/AppVectorUtils/app/otbVectorDataTransform.cxx b/Modules/Applications/AppVectorUtils/app/otbVectorDataTransform.cxx index 8dc890b605564e56f7dc813f114fed0e97a53823..b6ed3b2eaa90edae05e24f5d34f5c83a7a566401 100644 --- a/Modules/Applications/AppVectorUtils/app/otbVectorDataTransform.cxx +++ b/Modules/Applications/AppVectorUtils/app/otbVectorDataTransform.cxx @@ -60,46 +60,64 @@ private: SetDescription("Apply a transform to each vertex of the input VectorData"); SetDocName("Vector Data Transformation"); - SetDocLongDescription("This application performs a transformation of an input vector data transforming each vertex in the vector data. The applied transformation manages translation, rotation and scale, and can be centered or not."); + SetDocLongDescription("This application iterates over each vertex in the " + "input vector data file and performs a transformation on this vertex.\n\n" + "It is the equivalent of [1] that transforms images. For instance, if you" + " extract the envelope of an image with [2], and you transform this image" + " with [1], you may want to use this application to operate the same " + "transform on the envelope.\n\n" + "The applied transformation is a 2D similarity. It manages translation, " + "rotation, scaling, and can be centered or not. Note that the support " + "image is used to define the reference coordinate system in which the " + "transform is applied. For instance the input vector data can have WGS84" + " coordinates, the support image is in UTM, so a translation of 1 pixel " + "along X corresponds to the X pixel size of the input image along the " + "X axis of the UTM coordinates frame. This image can also be in sensor " + "geometry."); SetDocLimitations("None"); SetDocAuthors("OTB-Team"); - SetDocSeeAlso(" "); + SetDocSeeAlso("[1] RigidTransformResample\n" + "[2] ImageEnvelope"); AddDocTag(Tags::Vector); AddParameter(ParameterType_InputVectorData, "vd", "Input Vector data"); - SetParameterDescription("vd", "Input vector data to transform"); + SetParameterDescription("vd", "Input vector data file to transform"); AddParameter(ParameterType_OutputVectorData,"out","Output Vector data"); - SetParameterDescription("out", "Output transformed vector data"); + SetParameterDescription("out", "Output vector data with "); AddParameter(ParameterType_InputImage, "in", "Support image"); - SetParameterDescription("in","Image needed as a support to the vector data"); + SetParameterDescription("in","Image defining the reference coordinate " + "system in which the tranform is applied. Both projected and sensor " + "images are supported."); // Transform Group AddParameter(ParameterType_Group, "transform", "Transform parameters"); SetParameterDescription("transform", "Group of parameters to define the transform"); - AddParameter(ParameterType_Float, "transform.tx", "Translation X"); + AddParameter(ParameterType_Float, "transform.tx", "X Translation"); SetParameterDescription("transform.tx","Translation in the X direction (in pixels)"); - AddParameter(ParameterType_Float, "transform.ty", "Translation Y"); + AddParameter(ParameterType_Float, "transform.ty", "Y Translation"); SetParameterDescription("transform.ty","Translation in the Y direction (in pixels)"); SetDefaultParameterFloat("transform.tx", 0.); SetDefaultParameterFloat("transform.ty", 0.); AddParameter(ParameterType_Float, "transform.ro", "Rotation Angle"); - SetParameterDescription("transform.ro","Angle of the rotation to apply in degrees"); + SetParameterDescription("transform.ro","Angle of the rotation (in degrees)"); SetDefaultParameterFloat("transform.ro", 0.); AddParameter(ParameterType_Float, "transform.centerx", "Center X"); - SetParameterDescription("transform.centerx","X coordinate of the rotation center (in physical units)"); + SetParameterDescription("transform.centerx","X coordinate of the rotation " + "and scaling center (in physical units)"); AddParameter(ParameterType_Float, "transform.centery", "Center Y"); - SetParameterDescription("transform.centery","Y coordinate of the rotation center (in physical units)"); + SetParameterDescription("transform.centery","Y coordinate of the rotation " + "and scaling center (in physical units)"); SetDefaultParameterFloat("transform.centerx", 0.); SetDefaultParameterFloat("transform.centery", 0.); AddParameter(ParameterType_Float, "transform.scale", "Scale"); - SetParameterDescription("transform.scale","The scale to apply"); + SetParameterDescription("transform.scale","The scale coefficient to apply"); SetDefaultParameterFloat("transform.scale", 1.); // Doc example parameter settings diff --git a/Modules/Wrappers/ApplicationEngine/src/otbWrapperMapProjectionParametersHandler.cxx b/Modules/Wrappers/ApplicationEngine/src/otbWrapperMapProjectionParametersHandler.cxx index 364fb600359f0964f7d4b35a99e5a8bb0e63c0ec..493191677c554686770604ca734effe4017c3784 100644 --- a/Modules/Wrappers/ApplicationEngine/src/otbWrapperMapProjectionParametersHandler.cxx +++ b/Modules/Wrappers/ApplicationEngine/src/otbWrapperMapProjectionParametersHandler.cxx @@ -33,8 +33,8 @@ namespace Wrapper void MapProjectionParametersHandler::AddMapProjectionParameters( Application::Pointer app, const std::string & key) { - app->AddParameter(ParameterType_Choice, key, "Output Cartographic Map Projection"); - app->SetParameterDescription(key,"Parameters of the output map projection to be used."); + app->AddParameter(ParameterType_Choice, key, "Map Projection"); + app->SetParameterDescription(key,"Defines the map projection to be used."); // utm std::ostringstream oss; diff --git a/Modules/Wrappers/CommandLine/src/otbWrapperCommandLineLauncher.cxx b/Modules/Wrappers/CommandLine/src/otbWrapperCommandLineLauncher.cxx index fc529ef9e1bd713d380c9766ba1189ace1af51f5..cf70dc07b7bd8e50922a313f4bc6ff21ecaa973c 100644 --- a/Modules/Wrappers/CommandLine/src/otbWrapperCommandLineLauncher.cxx +++ b/Modules/Wrappers/CommandLine/src/otbWrapperCommandLineLauncher.cxx @@ -600,12 +600,6 @@ void CommandLineLauncher::DisplayHelp(bool longHelp) for(unsigned int i=0; i<maxKeySize-std::string("progress").size(); i++) bigKey.append(" "); - std::cerr << " -"<<bigKey<<" <boolean> Report progress " << std::endl; - bigKey = "help"; - for(unsigned int i=0; i<maxKeySize-std::string("help").size(); i++) - bigKey.append(" "); - std::cerr << " -"<<bigKey<<" <string list> Display long help (empty list), or help for given parameters keys" << std::endl; - for (unsigned int i = 0; i < nbOfParam; i++) { Parameter::Pointer param = m_Application->GetParameterByKey(appKeyList[i]); @@ -615,6 +609,12 @@ void CommandLineLauncher::DisplayHelp(bool longHelp) } } + std::cerr << " -"<<bigKey<<" <boolean> Report progress " << std::endl; + bigKey = "help"; + for(unsigned int i=0; i<maxKeySize-std::string("help").size(); i++) + bigKey.append(" "); + std::cerr << " -"<<bigKey<<" <string list> Display long help (empty list), or help for given parameters keys" << std::endl; + std::cerr<<std::endl; //std::string cl(m_Application->GetCLExample()); @@ -653,11 +653,9 @@ std::string CommandLineLauncher::DisplayParameterHelp(const Parameter::Pointer & // Display the type the type ParameterType type = m_Application->GetParameterType(paramKey); - // Discard Group parameters (they don't need a value) - if (type == ParameterType_Group) - { - return ""; - } + std::string bigKey = paramKey; + + unsigned int maxKeySize = GetMaxKeySize(); bool singleSelectionForListView = false; @@ -677,10 +675,6 @@ std::string CommandLineLauncher::DisplayParameterHelp(const Parameter::Pointer & { oss << " "; } - - std::string bigKey = paramKey; - - unsigned int maxKeySize = GetMaxKeySize(); for(unsigned int i=0; i<maxKeySize-paramKey.size(); i++) bigKey.append(" "); @@ -716,6 +710,10 @@ std::string CommandLineLauncher::DisplayParameterHelp(const Parameter::Pointer & { oss << "<string list> "; } + else if(type == ParameterType_Group) + { + oss<< "<group> "; + } else itkExceptionMacro("Not handled parameter type."); @@ -767,30 +765,33 @@ std::string CommandLineLauncher::DisplayParameterHelp(const Parameter::Pointer & } } - if(m_Application->IsMandatory(paramKey)) + if(type != ParameterType_Group) { - oss<<" (mandatory"; - } - else - { - oss<<" (optional"; - if(m_Application->IsParameterEnabled(paramKey)) + if(m_Application->IsMandatory(paramKey)) { - oss<<", on by default"; + oss<<" (mandatory"; } else { - oss<<", off by default"; - } - } + oss<<" (optional"; - if(m_Application->HasValue(paramKey)) - { - oss<<", default value is "<<m_Application->GetParameterAsString(paramKey); + if(m_Application->IsParameterEnabled(paramKey)) + { + oss<<", on by default"; + } + else + { + oss<<", off by default"; + } + } + + if(m_Application->HasValue(paramKey)) + { + oss<<", default value is "<<m_Application->GetParameterAsString(paramKey); + } + oss<<")"; } - oss<<")"; - oss << std::endl; if(longHelp) @@ -801,8 +802,25 @@ std::string CommandLineLauncher::DisplayParameterHelp(const Parameter::Pointer & oss<<" "; oss<<m_Application->GetParameterDescription(paramKey)<<std::endl; + + if (type == ParameterType_Choice) + { + std::vector<std::string> keys = dynamic_cast<ChoiceParameter*>(param.GetPointer())->GetChoiceKeys(); + std::vector<std::string> names = dynamic_cast<ChoiceParameter*>(param.GetPointer())->GetChoiceNames(); + + auto keyIt = keys.begin(); + auto nameIt = names.begin(); + + for( ; keyIt!=keys.end()&&nameIt!=names.end();++keyIt,++nameIt) + { + oss << " "; + for(unsigned int i=0; i<maxKeySize;++i) + oss<<" "; + oss<<" "; + oss<<"- "<<*nameIt<<" ("<<*keyIt<<"): "<<m_Application->GetParameterDescription(paramKey+"."+(*keyIt))<<std::endl; + } + } } - return oss.str(); }