RandomSearch algorithm performs random sampling on hyperparameter space to identify optimal hyperparameters. It works for teradataml analytic functions from Database Engine 20, BYOM, VAL, and UAF features.
teradataml RandomSearch allows user to perform hyperparameter tuning for all model trainer and non-model trainer functions.
- When used for model trainer functions:
- Based on evaluation metrics, search determines best model.
- All methods and properties can be used.
- When used for non-model trainer functions:
- You can choose the best output as you see fit to use this.
- Only fit method is supported.
teradataml RandomSearch also allows you to use input data as the hyperparameter. This option can be suitable when you want to identify the best models for a set of input data. When you pass set of data as hyperparameter for model trainer function, the search determines the best data along with the best model based on the evaluation metrics.
configure.temp_object_type="VT" follows sequential execution.
Required Parameters
- func
- Specifies a teradataml analytic function from Database Engine 20, BYOM, VAL, and UAF.
Use the display_analytic_functions() function for list of functions.
- params
- Specifies the parameters of a teradataml analytic function. The parameters must be in dictionary type:
- Keys refer to the argument names;
- Values refer to argument values for corresponding arguments.
- You can specify the argument value in a tuple to run hyperparameter tunning with different arguments.
- Model trainer function arguments id_column, input_columns, and target_columns must be passed in fit() method.
- All required arguments of non-model trainer function must be passed during RandomSearch object creation.
Optional Argument
- n_iter
- Specifies the number of iterations random search need to be performed.
Default value is 10.
The value of this argument must be less than the size of parameter populations.