Optional TD_GLM Syntax Elements - Analytics Database

Database Analytic Functions

Deployment
VantageCloud
VantageCore
Edition
Enterprise
IntelliFlex
VMware
Product
Analytics Database
Release Number
17.20
Published
June 2022
Language
English (United States)
Last Update
2024-04-06
dita:mapPath
gjn1627595495337.ditamap
dita:ditavalPath
ayr1485454803741.ditaval
dita:id
jmh1512506877710
Product Category
Teradata Vantageā„¢
PartitionColumn
Name of the InputTable columns on which to partition the input. The name must be consistent with the partition_by_column in the ON clause. If the partition_by_column is unicode with foreign language characters, then it is necessary to specify PartitionColumn argument.
Family
Specify the distribution exponential family. Options are Gaussian and Binomial. Default value is Gaussian.
BatchSize
Specify the number of observations (training samples) processed in a single minibatch per AMP. A value of 0 or higher than the number of rows on an AMP processes all rows on the AMP, such that the entire dataset is processed in a single iteration, and the algorithm becomes Gradient Descent. Specify a non-negative integer value. The default value is 10.
MaxIterNum
Specify the maximum number of iterations (minibatches) over the training data batches. Value is a positive integer less than 10,000,000. Default value is 300.
RegularizationLambda
Specify the regularization amount. The higher the value, stronger the regularization. It is also used to compute learning rate when learning rate is set to optimal. Must be a non-negative float value. A value of 0 means no regularization. Default value is 0.02.
Alpha
Specify the Elasticnet parameter for penalty computation. It is only effective when RegularizationLambda is greater than 0. The value represents the contribution ratio of L1 in the penalty. A value of 1.0 indicates L1 (LASSO) only, a value of 0 indicates L2 (Ridge) only, and a value between is a combination of L1 and L2. Value is a float value between 0 and 1. The default value is 0.15 (15% L1, 85% L2).
IterNumNoChange
Specify the number of iterations (minibatches) with no improvement in loss including the tolerance to stop training. A value of 0 indicates no early stopping and the algorithm continues until MaxIterNum iterations are reached. Specify a non-negative integer value. The default value is 50.
Tolerance
Specify the stopping criteria in terms of loss function improvement. Applicable when IterNumNoChange is greater than 0. Specify a positive integer value. The default value is 0.001.
Intercept
Specify whether to estimate intercept based on whether the data is already centered. The default value is true.
ClassWeights
Specify weights associated with classes. Only applicable for Binomial Family. The format is 0:weight,1:weight. For example, 0:1.0,1:0.5 gives twice the weight to each observation in class 0. If the weight of a class is omitted, it is assumed to be 1.0. The default value is 0:1.0,1:1.0.
LearningRate
Specify one of the learning rate algorithms:
  • Constant
  • InvTime
  • Optimal
  • Adaptive

The default value is invtime for Gaussian, and optimal for Binomial.

InitialEta
Specify the initial learning rate eta value. If you specify the learning rate as constant, the eta value is applicable for all iterations. The default value is 0.05.
DecayRate
Specify the decay rate for the learning rate. Only applicable for invtime and adaptive learning rates. The default value is 0.25.
DecaySteps
Specify the number of iterations without decay for the adaptive learning rate. The learning rate changes by decay rate after the specified number of iterations are completed. The default value is 5.
Momentum
Specify the value to use for momentum learning rate optimizer. A larger value indicates higher momentum contribution. A value of 0 means momentum optimizer is disabled. For a good momentum contribution, a value between 0.6-0.95 is recommended. Value is a non-negative float between 0 and 1. The default value is 0.
Nesterov
Specify whether to use Nesterov optimization for the Momentum optimizer. Only applicable when the Momentum optimizer value is greater than 0. The default value is True.
LocalSGDIterations
Specify the number of local iterations for the Local SGD algorithm. A value of 0 implies that the algorithm is disabled. A value greater than 0 enables the algorithm and specifies the number of iterations for the algorithm. The recommended values for the arguments are as follows:
  • LocalSGDIterations: 10
  • MaxIterNum: 100
  • BatchSize: 50
  • IterNumNoChange: 5

The default value is 0.

StepwiseDirection
Specify the type of algorithm to be used. The algorithm stops when the addition or deletion of variables in the model does not improve the score. The following arguments are available:
  • forward

    Forward selection starts with an empty model and adds features one at a time, keeping the variable that provides the best model. Once a feature has been added to the model it cannot be removed.

  • backward

    Backward elimination starts with a full model with all the features to be tested. In each step, a single feature is removed from the model keeping only those that improve the selected criterion. Once a feature has been removed it cannot be added to the model.

  • both or bidirectional

    Both and bidirectional behave the same way. The function starts from a given model, which can be full, empty, or any combination of variables. The features inside the model are deleted and those outside the model are added one at a time, selecting in each step the combination that improves the most the score of the selected criterion.

MaxStepsNum
Specify the maximum number of steps to be used for the StepwiseDirection algorithm. If the value is set to zero, then the algorithm runs until convergence. Default is 5.
InitialStepwiseColumns
Specify the names of the initial state model columns that need to be used as starting point for the stepwise regression algorithm, such as predictors, features or independent variables.
IterationMode
The iteration mode. Values are Batch and Epoch. Default is Batch.
  • Batch: One iteration per batch. After processing rows in a batch, update the weight of the parameters and proceed to the next iteration.
  • Epoch: One iteration per epoch. After processing all rows in a partition (with one or more batches), update the weight of the parameters and proceed to the next epoch. See BatchSize argument for batch size.