Artificial Intelligence

What is Hyperparameter?

Quick answer

A setting chosen before training a machine learning model, such as learning rate or number of layers, that shapes how the model learns.

Hyperparameter, explained

Machine learning models learn parameters, such as the weights in a neural network, from data. Hyperparameters are different: they are decisions made by the practitioner that control the training process itself. Examples include the learning rate, batch size, number of training epochs, tree depth in a decision tree, and the number of layers in a network.

Picking good hyperparameters can make a large difference in accuracy and training time. Too high a learning rate may cause training to fail, while too low makes it painfully slow. Practitioners use techniques such as grid search, random search, and Bayesian optimization, evaluating each combination on a validation dataset. Careless tuning on test data can lead to overfitting and overly optimistic results.

Related terms

Guides that mention Hyperparameter