/// <summary>
        /// Initializes a new instance of the <see cref="RandomForestOptimizationConfig" /> class.
        /// </summary>
        /// <param name="datasetId">Data set id on which to train model.</param>
        /// <param name="validationSetId">Data set id on which to validate model.</param>
        /// <param name="inputs">Define min and max value for each output column(feature), and is input optional.</param>
        /// <param name="outputRanges">Define min and max value for each output column(feature).</param>
        /// <param name="problemType">Defines the problem type. In case of binary classification,  there must be only one output column..</param>
        /// <param name="binaryOptimizationMetric">USED ONLY IN BINARY CLASSIFICATION.  Default metric: ROC_AUC (Area under ROC curve).   Depending on the task at hand, it is recommended to choose an appropriate metric to optimize..</param>
        /// <param name="regressionOptimizationMetric">USED ONLY IN REGRESSION.  Default metric: MAE (MEAN ABSOLUTE ERROR).   Depending on the task at hand, it is recommended to choose an appropriate metric to optimize..</param>
        /// <param name="validationSplit">Portion of data set to use for validation, must be between 0 and 1.   Used only when CrossValidation &#x3D; false. (required) (default to 0.2D).</param>
        /// <param name="randomSeed">Random number generator seed, if the value is zero, the rows will not be randomly shuffled  Used only if CrossValidation &#x3D; false (default to 300).</param>
        /// <param name="engineConfig">Optimization engine config.</param>
        /// <param name="numberOfEstimators">Number of estimators (required).</param>
        /// <param name="maxDepth">Max depth of tree (required).</param>
        /// <param name="maxFeatures">Max features (required).</param>
        public RandomForestOptimizationConfig(string datasetId = default(string), string validationSetId = default(string), List <InputConfig> inputs = default(List <InputConfig>), List <Range> outputRanges = default(List <Range>), ProblemType?problemType = default(ProblemType?), BinaryMetric?binaryOptimizationMetric = default(BinaryMetric?), RegressionMetric?regressionOptimizationMetric = default(RegressionMetric?), double validationSplit = 0.2D, int?randomSeed = 300, OptimizationEngineConfig engineConfig = default(OptimizationEngineConfig), RangeInt numberOfEstimators = default(RangeInt), RangeInt maxDepth = default(RangeInt), Range maxFeatures = default(Range))
        {
            this.DatasetId       = datasetId;
            this.ValidationSetId = validationSetId;
            this.Inputs          = inputs;
            this.OutputRanges    = outputRanges;
            // to ensure "validationSplit" is required (not null)
            if (validationSplit == null)
            {
                throw new InvalidDataException("validationSplit is a required property for RandomForestOptimizationConfig and cannot be null");
            }
            else
            {
                this.ValidationSplit = validationSplit;
            }

            this.RandomSeed   = randomSeed;
            this.EngineConfig = engineConfig;
            // to ensure "numberOfEstimators" is required (not null)
            if (numberOfEstimators == null)
            {
                throw new InvalidDataException("numberOfEstimators is a required property for RandomForestOptimizationConfig and cannot be null");
            }
            else
            {
                this.NumberOfEstimators = numberOfEstimators;
            }

            // to ensure "maxDepth" is required (not null)
            if (maxDepth == null)
            {
                throw new InvalidDataException("maxDepth is a required property for RandomForestOptimizationConfig and cannot be null");
            }
            else
            {
                this.MaxDepth = maxDepth;
            }

            // to ensure "maxFeatures" is required (not null)
            if (maxFeatures == null)
            {
                throw new InvalidDataException("maxFeatures is a required property for RandomForestOptimizationConfig and cannot be null");
            }
            else
            {
                this.MaxFeatures = maxFeatures;
            }

            this.DatasetId                    = datasetId;
            this.ValidationSetId              = validationSetId;
            this.Inputs                       = inputs;
            this.OutputRanges                 = outputRanges;
            this.ProblemType                  = problemType;
            this.BinaryOptimizationMetric     = binaryOptimizationMetric;
            this.RegressionOptimizationMetric = regressionOptimizationMetric;
            // use default value if no "randomSeed" provided
            if (randomSeed == null)
            {
                this.RandomSeed = 300;
            }
            else
            {
                this.RandomSeed = randomSeed;
            }
            this.EngineConfig = engineConfig;
        }
        /// <summary>
        /// Initializes a new instance of the <see cref="XGBoostOptimizationConfig" /> class.
        /// </summary>
        /// <param name="datasetId">datasetId.</param>
        /// <param name="validationSetId">validationSetId.</param>
        /// <param name="inputs">inputs.</param>
        /// <param name="outputRanges">outputRanges.</param>
        /// <param name="validationSplit">validationSplit (default to 0.2D).</param>
        /// <param name="randomSeed">randomSeed (default to 300).</param>
        /// <param name="problemType">Defines the problem type. In case of binary classification,  there must be only one output column..</param>
        /// <param name="binaryOptimizationMetric">USED ONLY IN BINARY CLASSIFICATION.  Default metric: ROC_AUC (Area under ROC curve).   Depending on the task at hand, it is recommended to choose an appropriate metric to optimize..</param>
        /// <param name="regressionOptimizationMetric">USED ONLY IN REGRESSION.  Default metric: MAE (MEAN ABSOLUTE ERROR).   Depending on the task at hand, it is recommended to choose an appropriate metric to optimize..</param>
        /// <param name="nEstimators">N Estimators (required).</param>
        /// <param name="maxDepth">MaxDepth (required).</param>
        /// <param name="minChildWeight">MinChildWeight (required).</param>
        /// <param name="gamma">Gamma (required).</param>
        /// <param name="subsample">Subsample (required).</param>
        /// <param name="colsampleBytree">ColsampleBytree (required).</param>
        /// <param name="regAlpha">RegAlpha (required).</param>
        /// <param name="learningRate">LearningRate (required).</param>
        /// <param name="engineConfig">Optimization engine config.</param>
        public XGBoostOptimizationConfig(string datasetId = default(string), string validationSetId = default(string), List <InputConfig> inputs = default(List <InputConfig>), List <Range> outputRanges = default(List <Range>), double validationSplit = 0.2D, int?randomSeed = 300, ProblemType?problemType = default(ProblemType?), BinaryMetric?binaryOptimizationMetric = default(BinaryMetric?), RegressionMetric?regressionOptimizationMetric = default(RegressionMetric?), RangeInt nEstimators = default(RangeInt), RangeInt maxDepth = default(RangeInt), RangeInt minChildWeight = default(RangeInt), Range gamma = default(Range), Range subsample = default(Range), Range colsampleBytree = default(Range), Range regAlpha = default(Range), Range learningRate = default(Range), OptimizationEngineConfig engineConfig = default(OptimizationEngineConfig))
        {
            this.DatasetId       = datasetId;
            this.ValidationSetId = validationSetId;
            this.Inputs          = inputs;
            this.OutputRanges    = outputRanges;
            this.RandomSeed      = randomSeed;
            // to ensure "nEstimators" is required (not null)
            if (nEstimators == null)
            {
                throw new InvalidDataException("nEstimators is a required property for XGBoostOptimizationConfig and cannot be null");
            }
            else
            {
                this.NEstimators = nEstimators;
            }

            // to ensure "maxDepth" is required (not null)
            if (maxDepth == null)
            {
                throw new InvalidDataException("maxDepth is a required property for XGBoostOptimizationConfig and cannot be null");
            }
            else
            {
                this.MaxDepth = maxDepth;
            }

            // to ensure "minChildWeight" is required (not null)
            if (minChildWeight == null)
            {
                throw new InvalidDataException("minChildWeight is a required property for XGBoostOptimizationConfig and cannot be null");
            }
            else
            {
                this.MinChildWeight = minChildWeight;
            }

            // to ensure "gamma" is required (not null)
            if (gamma == null)
            {
                throw new InvalidDataException("gamma is a required property for XGBoostOptimizationConfig and cannot be null");
            }
            else
            {
                this.Gamma = gamma;
            }

            // to ensure "subsample" is required (not null)
            if (subsample == null)
            {
                throw new InvalidDataException("subsample is a required property for XGBoostOptimizationConfig and cannot be null");
            }
            else
            {
                this.Subsample = subsample;
            }

            // to ensure "colsampleBytree" is required (not null)
            if (colsampleBytree == null)
            {
                throw new InvalidDataException("colsampleBytree is a required property for XGBoostOptimizationConfig and cannot be null");
            }
            else
            {
                this.ColsampleBytree = colsampleBytree;
            }

            // to ensure "regAlpha" is required (not null)
            if (regAlpha == null)
            {
                throw new InvalidDataException("regAlpha is a required property for XGBoostOptimizationConfig and cannot be null");
            }
            else
            {
                this.RegAlpha = regAlpha;
            }

            // to ensure "learningRate" is required (not null)
            if (learningRate == null)
            {
                throw new InvalidDataException("learningRate is a required property for XGBoostOptimizationConfig and cannot be null");
            }
            else
            {
                this.LearningRate = learningRate;
            }

            this.EngineConfig    = engineConfig;
            this.DatasetId       = datasetId;
            this.ValidationSetId = validationSetId;
            this.Inputs          = inputs;
            this.OutputRanges    = outputRanges;
            // use default value if no "validationSplit" provided
            if (validationSplit == null)
            {
                this.ValidationSplit = 0.2D;
            }
            else
            {
                this.ValidationSplit = validationSplit;
            }
            // use default value if no "randomSeed" provided
            if (randomSeed == null)
            {
                this.RandomSeed = 300;
            }
            else
            {
                this.RandomSeed = randomSeed;
            }
            this.ProblemType = problemType;
            this.BinaryOptimizationMetric     = binaryOptimizationMetric;
            this.RegressionOptimizationMetric = regressionOptimizationMetric;
            this.EngineConfig = engineConfig;
        }
        /// <summary>
        /// Initializes a new instance of the <see cref="RnnOptimizationConfig" /> class.
        /// </summary>
        /// <param name="dropout">dropout.</param>
        /// <param name="batchSize">batchSize (default to 512).</param>
        /// <param name="recurrentDropout">recurrentDropout.</param>
        /// <param name="recurrentOutputCount">recurrentOutputCount (default to 1).</param>
        /// <param name="datasetId">Data set id on which to train network.</param>
        /// <param name="validationSetId">Data set id on which to validate network.</param>
        /// <param name="inputs">Define min and max value for each output column(feature), and is input optional.</param>
        /// <param name="outputRanges">Define min and max value for each output column(feature).</param>
        /// <param name="hiddenLayerCountRange">Range in which to search number of hidden layers.</param>
        /// <param name="neuronsPerLayer">Range in which to search number of neurons per layer.</param>
        /// <param name="trainingAlgorithms">List of training algorithms to use.</param>
        /// <param name="activationFunctions">List of activation functions to use.</param>
        /// <param name="recurrentActivationFunctions">List of recurrent activation functions to use.</param>
        /// <param name="maxEpoch">Maximum number of epoch (required) (default to 3000).</param>
        /// <param name="validationSplit">Portion of data set to use for validation, must be between 0 and 1. (required) (default to 0.2D).</param>
        /// <param name="randomSeed">Random number generator seed, if the value is zero, the rows will not be randomly shuffled (default to 300).</param>
        /// <param name="recurrentInputCountRange">Range in which to search number of recurrent inputs.</param>
        /// <param name="engineConfig">Optimization engine config.</param>
        public RnnOptimizationConfig(Range dropout = default(Range), int batchSize = 512, Range recurrentDropout = default(Range), int recurrentOutputCount = 1, string datasetId = default(string), string validationSetId = default(string), List <InputConfig> inputs = default(List <InputConfig>), List <Range> outputRanges = default(List <Range>), RangeInt hiddenLayerCountRange = default(RangeInt), RangeInt neuronsPerLayer = default(RangeInt), List <NeuralNetworkTrainingAlgorithm> trainingAlgorithms = default(List <NeuralNetworkTrainingAlgorithm>), List <NeuralNetworkActivationFunction> activationFunctions = default(List <NeuralNetworkActivationFunction>), List <NeuralNetworkActivationFunction> recurrentActivationFunctions = default(List <NeuralNetworkActivationFunction>), int maxEpoch = 3000, double validationSplit = 0.2D, int?randomSeed = 300, RangeInt recurrentInputCountRange = default(RangeInt), OptimizationEngineConfig engineConfig = default(OptimizationEngineConfig))
        {
            this.Dropout                      = dropout;
            this.RecurrentDropout             = recurrentDropout;
            this.DatasetId                    = datasetId;
            this.ValidationSetId              = validationSetId;
            this.Inputs                       = inputs;
            this.OutputRanges                 = outputRanges;
            this.HiddenLayerCountRange        = hiddenLayerCountRange;
            this.NeuronsPerLayer              = neuronsPerLayer;
            this.TrainingAlgorithms           = trainingAlgorithms;
            this.ActivationFunctions          = activationFunctions;
            this.RecurrentActivationFunctions = recurrentActivationFunctions;
            // to ensure "maxEpoch" is required (not null)
            if (maxEpoch == null)
            {
                throw new InvalidDataException("maxEpoch is a required property for RnnOptimizationConfig and cannot be null");
            }
            else
            {
                this.MaxEpoch = maxEpoch;
            }

            // to ensure "validationSplit" is required (not null)
            if (validationSplit == null)
            {
                throw new InvalidDataException("validationSplit is a required property for RnnOptimizationConfig and cannot be null");
            }
            else
            {
                this.ValidationSplit = validationSplit;
            }

            this.RandomSeed = randomSeed;
            this.RecurrentInputCountRange = recurrentInputCountRange;
            this.EngineConfig             = engineConfig;
            this.Dropout = dropout;
            // use default value if no "batchSize" provided
            if (batchSize == null)
            {
                this.BatchSize = 512;
            }
            else
            {
                this.BatchSize = batchSize;
            }
            this.RecurrentDropout = recurrentDropout;
            // use default value if no "recurrentOutputCount" provided
            if (recurrentOutputCount == null)
            {
                this.RecurrentOutputCount = 1;
            }
            else
            {
                this.RecurrentOutputCount = recurrentOutputCount;
            }
            this.DatasetId                    = datasetId;
            this.ValidationSetId              = validationSetId;
            this.Inputs                       = inputs;
            this.OutputRanges                 = outputRanges;
            this.HiddenLayerCountRange        = hiddenLayerCountRange;
            this.NeuronsPerLayer              = neuronsPerLayer;
            this.TrainingAlgorithms           = trainingAlgorithms;
            this.ActivationFunctions          = activationFunctions;
            this.RecurrentActivationFunctions = recurrentActivationFunctions;
            // use default value if no "randomSeed" provided
            if (randomSeed == null)
            {
                this.RandomSeed = 300;
            }
            else
            {
                this.RandomSeed = randomSeed;
            }
            this.RecurrentInputCountRange = recurrentInputCountRange;
            this.EngineConfig             = engineConfig;
        }