what-is","metadata":{}},{"id":"GLOBAL#tech-category#ai","name":"Artificial Intelligence","namespaceId":"GLOBAL#tech-category","description":"

Artificial Intelligence","metadata":{}}]}}]},"metadata":{"auth":{},"testAttributes":{}},"context":{"page":{"pageUrl":"https://aws.amazon.com/what-is/hyperparameter-tuning/"},"environment":{"stage":"prod","region":"us-east-1"},"sdkVersion":"1.0.129"},"refMap":{"manifest.js":"289765ed09","what-is-header.js":"2e0d22c000","what-is-header.rtl.css":"ccf4035484","what-is-header.css":"ce47058367","what-is-header.css.js":"004a4704e8","what-is-header.rtl.css.js":"f687973e4f"},"settings":{"templateMappings":{"category":"category","headline":"headline","primaryCTA":"primaryCTA","primaryCTAText":"primaryCTAText","primaryBreadcrumbText":"primaryBreadcrumbText","primaryBreadcrumbURL":"primaryBreadcrumbURL"}}}

hyperparameter tuning","metadata":{}}]}},{"fields":{"faqQuestion":"What are hyperparameters?","faqAnswer":"

Hyperparameters are external configuration variables that data scientists use to manage machine learning model training. Sometimes called model hyperparameters, the hyperparameters are manually set before training a model. They're different from parameters, which are internal parameters automatically derived during the learning process and not set by data scientists. \n

Examples of hyperparameters include the number of nodes and layers in a neural network and the number of branches in a decision tree. Hyperparameters determine key features such as model architecture, learning rate, and model complexity.","id":"seo-faq-pairs#what-are-hyperparameters","customSort":"2"},"metadata":{"tags":[{"id":"seo-faq-pairs#faq-collections#hyperparameter-tuning","name":"hyperparameter-tuning ","namespaceId":"seo-faq-pairs#faq-collections","description":"

hyperparameter tuning","metadata":{}}]}},{"fields":{"faqQuestion":"How do you identify hyperparameters?","faqAnswer":"

Selecting the right set of hyperparameters is important in terms of model performance and accuracy. Unfortunately, there are no set rules on which hyperparameters work best nor their optimal or default values. You need to experiment to find the optimum hyperparameter set. This activity is known as hyperparameter tuning or hyperparameter optimization.","id":"seo-faq-pairs#how-do-you-identify-hyperparameters","customSort":"3"},"metadata":{"tags":[{"id":"seo-faq-pairs#faq-collections#hyperparameter-tuning","name":"hyperparameter-tuning ","namespaceId":"seo-faq-pairs#faq-collections","description":"

hyperparameter tuning","metadata":{}}]}},{"fields":{"faqQuestion":"Why is hyperparameter tuning important?","faqAnswer":"

Hyperparameters directly control model structure, function, and performance. Hyperparameter tuning allows data scientists to tweak model performance for optimal results. This process is an essential part of machine learning, and choosing appropriate hyperparameter values is crucial for success. \n

For example, assume you're using the learning rate of the model as a hyperparameter. If the value is too high, the model may converge too quickly with suboptimal results. Whereas if the rate is too low, training takes too long and results may not converge. A good and balanced choice of hyperparameters results in accurate models and excellent model performance.","id":"seo-faq-pairs#why-is-hyperparameter-tuning-important","customSort":"4"},"metadata":{"tags":[{"id":"seo-faq-pairs#faq-collections#hyperparameter-tuning","name":"hyperparameter-tuning ","namespaceId":"seo-faq-pairs#faq-collections","description":"

hyperparameter tuning","metadata":{}}]}},{"fields":{"faqQuestion":"How does hyperparameter tuning work?","faqAnswer":"

As previously stated, hyperparameter tuning can be manual or automated. While manual tuning is slow and tedious, a benefit is that you better understand how hyperparameter weightings affect the model. But in most instances, you would normally use one of the well-known hyperparameter learning algorithms. \n

The process of hyperparameter tuning is iterative, and you try out different combinations of parameters and values. You generally start by defining a target variable such as accuracy as the primary metric, and you intend to maximize or minimize this variable. It’s a good idea to use cross-validation techniques, so your model isn't centered on a single portion of your data.","id":"seo-faq-pairs#how-does-hyperparameter-tuning-work","customSort":"5"},"metadata":{"tags":[{"id":"seo-faq-pairs#faq-collections#hyperparameter-tuning","name":"hyperparameter-tuning ","namespaceId":"seo-faq-pairs#faq-collections","description":"

hyperparameter tuning","metadata":{}}]}},{"fields":{"faqQuestion":"What are the hyperparameter tuning techniques?","faqAnswer":"

Numerous hyperparameter tuning algorithms exist, although the most commonly used types are Bayesian optimization, grid search and randomized search. \n

Bayesian optimization \n

Bayesian optimization is a technique based on Bayes’ theorem, which describes the probability of an event occurring related to current knowledge. When this is applied to hyperparameter optimization, the algorithm builds a probabilistic model from a set of hyperparameters that optimizes a specific metric. It uses regression analysis to iteratively choose the best set of hyperparameters. \n

Grid search \n

With grid search, you specify a list of hyperparameters and a performance metric, and the algorithm works through all possible combinations to determine the best fit. Grid search works well, but it’s relatively tedious and computationally intensive, especially with large numbers of hyperparameters. \n

Random search \n

Although based on similar principles as grid search, random search selects groups of hyperparameters randomly on each iteration. It works well when a relatively small number of the hyperparameters primarily determine the model outcome.","id":"seo-faq-pairs#what-are-the-hyperparameter-tuning-techniques","customSort":"6"},"metadata":{"tags":[{"id":"seo-faq-pairs#faq-collections#hyperparameter-tuning","name":"hyperparameter-tuning ","namespaceId":"seo-faq-pairs#faq-collections","description":"

hyperparameter tuning","metadata":{}}]}},{"fields":{"faqQuestion":"What are examples of hyperparameters?","faqAnswer":"

While some hyperparameters are common, in practice you'll find that algorithms use specific sets of hyperparameters. For example, you can read how Amazon SageMaker uses image classification hyperparameters and read how SageMaker uses XGBoost algorithm hyperparameters. \n

Here are some examples of common hyperparameters: \n

Next Steps with AWS

Check out additional product-related resources
Check out AWS AI Services 
Sign up for a free account

Instant get access to the AWS Free Tier.

Sign up 
Start building in the console

Get started building in the AWS management console.

Sign in