<root>
  <key>TrainRegression-gbt</key>
  <exec>otbcli_TrainRegression</exec>
  <longname>TrainRegression (gbt)</longname>
  <group>Learning</group>
  <description>Train a classifier from multiple images to perform regression.</description>
  <parameter>
    <parameter_type source_parameter_type="ParameterType_InputImageList">ParameterMultipleInput</parameter_type>
    <key>io.il</key>
    <name>Input Image List</name>
    <description>A list of input images. First (n-1) bands should contain the predictor. The last band should contain the output value to predict.</description>
    <datatype />
    <optional>False</optional>
  </parameter>
  <parameter>
    <parameter_type source_parameter_type="ParameterType_InputFilename">ParameterFile</parameter_type>
    <key>io.csv</key>
    <name>Input CSV file</name>
    <description>Input CSV file containing the predictors, and the output values in last column. Only used when no input image is given</description>
    <isFolder />
    <optional>True</optional>
  </parameter>
  <parameter>
    <parameter_type source_parameter_type="ParameterType_InputFilename">ParameterFile</parameter_type>
    <key>io.imstat</key>
    <name>Input XML image statistics file</name>
    <description>Input XML file containing the mean and the standard deviation of the input images.</description>
    <isFolder />
    <optional>True</optional>
  </parameter>
  <parameter>
    <parameter_type source_parameter_type="ParameterType_OutputFilename">OutputFile</parameter_type>
    <key>io.out</key>
    <name>Output regression model</name>
    <description>Output file containing the model estimated (.txt format).</description>
  </parameter>
  <parameter>
    <parameter_type source_parameter_type="ParameterType_Float">ParameterNumber</parameter_type>
    <key>io.mse</key>
    <name>Mean Square Error</name>
    <description>Mean square error computed with the validation predictors</description>
    <minValue />
    <maxValue />
    <default>0.0</default>
    <optional>False</optional>
  </parameter>
  <parameter>
    <parameter_type source_parameter_type="ParameterType_Int">ParameterNumber</parameter_type>
    <key>sample.mt</key>
    <name>Maximum training predictors</name>
    <description>Maximum number of training predictors (default = 1000) (no limit = -1).</description>
    <minValue />
    <maxValue />
    <default>1000</default>
    <optional>False</optional>
  </parameter>
  <parameter>
    <parameter_type source_parameter_type="ParameterType_Int">ParameterNumber</parameter_type>
    <key>sample.mv</key>
    <name>Maximum validation predictors</name>
    <description>Maximum number of validation predictors (default = 1000) (no limit = -1).</description>
    <minValue />
    <maxValue />
    <default>1000</default>
    <optional>False</optional>
  </parameter>
  <parameter>
    <parameter_type source_parameter_type="ParameterType_Float">ParameterNumber</parameter_type>
    <key>sample.vtr</key>
    <name>Training and validation sample ratio</name>
    <description>Ratio between training and validation samples (0.0 = all training, 1.0 = all validation) (default = 0.5).</description>
    <minValue />
    <maxValue />
    <default>0.5</default>
    <optional>False</optional>
  </parameter>
  <parameter>
    <parameter_type source_parameter_type="ParameterType_Choice">ParameterSelection</parameter_type>
    <key>classifier</key>
    <name>Classifier to use for the training</name>
    <description>Choice of the classifier to use for the training.</description>
    <options>
      <choices>
        <choice>gbt</choice>
        </choices>
    </options>
    <default>0</default>
    <optional>False</optional>
  </parameter>
  <parameter>
    <parameter_type source_parameter_type="ParameterType_Choice">ParameterSelection</parameter_type>
    <key>classifier.gbt.t</key>
    <name>Loss Function Type</name>
    <description>Type of loss functionused for training.</description>
    <options>
      <choices>
        <choice>sqr</choice>
        <choice>abs</choice>
        <choice>hub</choice>
      </choices>
    </options>
    <default>0</default>
    <optional>False</optional>
  </parameter>
  <parameter>
    <parameter_type source_parameter_type="ParameterType_Int">ParameterNumber</parameter_type>
    <key>classifier.gbt.w</key>
    <name>Number of boosting algorithm iterations</name>
    <description>Number "w" of boosting algorithm iterations, with w*K being the total number of trees in the GBT model, where K is the output number of classes.</description>
    <minValue />
    <maxValue />
    <default>200</default>
    <optional>False</optional>
  </parameter>
  <parameter>
    <parameter_type source_parameter_type="ParameterType_Float">ParameterNumber</parameter_type>
    <key>classifier.gbt.s</key>
    <name>Regularization parameter</name>
    <description>Regularization parameter.</description>
    <minValue />
    <maxValue />
    <default>0.01</default>
    <optional>False</optional>
  </parameter>
  <parameter>
    <parameter_type source_parameter_type="ParameterType_Float">ParameterNumber</parameter_type>
    <key>classifier.gbt.p</key>
    <name>Portion of the whole training set used for each algorithm iteration</name>
    <description>Portion of the whole training set used for each algorithm iteration. The subset is generated randomly.</description>
    <minValue />
    <maxValue />
    <default>0.8</default>
    <optional>False</optional>
  </parameter>
  <parameter>
    <parameter_type source_parameter_type="ParameterType_Int">ParameterNumber</parameter_type>
    <key>classifier.gbt.max</key>
    <name>Maximum depth of the tree</name>
    <description>The training algorithm attempts to split each node while its depth is smaller than the maximum possible depth of the tree. The actual depth may be smaller if the other termination criteria are met, and/or if the tree is pruned.</description>
    <minValue />
    <maxValue />
    <default>3</default>
    <optional>False</optional>
  </parameter>
  <parameter>
    <parameter_type source_parameter_type="ParameterType_Int">ParameterNumber</parameter_type>
    <key>rand</key>
    <name>set user defined seed</name>
    <description>Set specific seed. with integer value.</description>
    <minValue />
    <maxValue />
    <default>0</default>
    <optional>True</optional>
  </parameter>
</root>
