liveBook · Manning

Hyperparameter optimization trial loop

As explained in Designing Deep Learning Systems: A guide for software engineers

A repeated execution cycle that proposes hyperparameters, runs a training trial, records its results, and requests another proposal.

A hyperparameter optimization trial loop repeatedly searches for effective hyperparameter values by training and evaluating one model trial after another. It stops when the trial budget is exhausted or a trial reaches the training objective, then returns the best-performing values. section 5.2.1 section 5.3.2

A service-oriented trial loop separates search decisions from trial execution:

  • An API request supplies training code, such as a Docker image, hyperparameters and their search space, the training objective, and an HPO algorithm. section 5.3.2
  • The HPO job manager starts the loop and asks a suggestion maker for the next hyperparameter values. section 5.3.2
  • The manager creates a trial to launch model training, configure distributed execution, recover failures, and collect progress, metrics, accuracy, and tried values. section 5.3.2
  • After evaluation, the loop either returns the best values or requests another proposal; using the same dataset supports fair comparison across trials. section 5.2.1

Service execution

A customer submits training code, a search space, an objective, and an algorithm. The manager obtains a proposal, launches a trial, records its result, and repeats until the budget runs out or the target is met. section 5.3.2

Figure 5.9 A general system design of an HPO service

Use the system-design figure to trace the API, job manager, suggestion maker, and trial execution responsibilities. section 5.3.2

How Designing Deep Learning Systems: A guide for software engineers covers it

How deep it goes
Explains trial sequencing, evaluation, stopping, proposal generation, service components, result collection, distributed setup, and failure recovery.
Examples
Uses API requests, Docker images, search spaces, trial objects, training metrics, and service architecture diagrams as concrete artifacts.
What it assumes
Assumes familiarity with model training and hyperparameters while defining the trial sequence and stopping logic explicitly.
What you can do after
Operate/configure an HPO service by defining a search space, selecting an algorithm, launching trials, and returning the best hyperparameters.
How it connects
Connects hyperparameter optimization with model training, model evaluation, HPO algorithms, distributed training, and failure recovery.

This explainer was generated by Manning's knowledge graph from the text of Designing Deep Learning Systems: A guide for software engineers. The section links point to the parts of the book it draws on.