diff --git a/Modules/Applications/AppDimensionalityReduction/app/otbTrainDimensionalityReduction.cxx b/Modules/Applications/AppDimensionalityReduction/app/otbTrainDimensionalityReduction.cxx index fa3dd7bdcb2e609d39a40b15571dcc59ba624013..df735345a1bf1ae51dabe07927d5e519285d043a 100644 --- a/Modules/Applications/AppDimensionalityReduction/app/otbTrainDimensionalityReduction.cxx +++ b/Modules/Applications/AppDimensionalityReduction/app/otbTrainDimensionalityReduction.cxx @@ -73,7 +73,7 @@ private: SetName("TrainDimensionalityReduction"); SetDescription("Trainer for the dimensionality reduction algorithms used in" " the ImageDimensionalityReduction and VectorDimensionalityReduction applications."); - + AddParameter(ParameterType_Group, "io", "Input and output data"); SetParameterDescription("io", "This group of parameters allows setting input and output data."); @@ -83,8 +83,7 @@ private: AddParameter(ParameterType_OutputFilename, "io.out", "Output model"); SetParameterDescription("io.out", "Output file containing the estimated model (.txt format)."); - - + AddParameter(ParameterType_InputFilename, "io.stats", "Input XML image statistics file"); MandatoryOff("io.stats"); SetParameterDescription("io.stats", "XML file containing mean and variance of each feature."); diff --git a/Modules/Applications/AppDimensionalityReduction/include/otbDimensionalityReductionTrainAutoencoder.txx b/Modules/Applications/AppDimensionalityReduction/include/otbDimensionalityReductionTrainAutoencoder.txx index 6f073353f3e51af78b7c60aa332793f30d477097..f474167e38be7fe6f2a8e56fc8838811afec789b 100644 --- a/Modules/Applications/AppDimensionalityReduction/include/otbDimensionalityReductionTrainAutoencoder.txx +++ b/Modules/Applications/AppDimensionalityReduction/include/otbDimensionalityReductionTrainAutoencoder.txx @@ -33,22 +33,11 @@ void TrainDimensionalityReductionApplicationBase<TInputValue,TOutputValue> ::InitAutoencoderParams() { - AddChoice("algorithm.tiedautoencoder", "Shark Tied Autoencoder"); AddChoice("algorithm.autoencoder", "Shark Autoencoder"); SetParameterDescription("algorithm.autoencoder", "This group of parameters allows setting Shark autoencoder parameters. " ); - //Tied Autoencoder - AddParameter(ParameterType_Choice, "algorithm.autoencoder.istied", - "tied weighth <tied/untied>"); - SetParameterDescription( - "algorithm.autoencoder.istied", - "Parameter that determine if the weights are tied or not <tied/untied>"); - - AddChoice("algorithm.autoencoder.istied.yes","Tied weigths"); - AddChoice("algorithm.autoencoder.istied.no","Untied weights"); - //Number Of Iterations AddParameter(ParameterType_Int, "algorithm.autoencoder.nbiter", "Maximum number of iterations during training"); @@ -116,17 +105,7 @@ TrainDimensionalityReductionApplicationBase<TInputValue,TOutputValue> { typedef shark::LogisticNeuron NeuronType; typedef otb::AutoencoderModel<InputValueType, NeuronType> AutoencoderModelType; - std::string TiedWeigth = GetParameterString("algorithm.autoencoder.istied"); - std::cout << TiedWeigth << std::endl; - - if(TiedWeigth == "no") - { - TrainAutoencoder<AutoencoderModelType>(trainingListSample,modelPath); - } - if(TiedWeigth != "yes" && TiedWeigth != "no") - { - std::cerr << "istied : invalid choice <yes/no>" << std::endl; - } + TrainAutoencoder<AutoencoderModelType>(trainingListSample,modelPath); } template <class TInputValue, class TOutputValue>