User Guide#
Master Hyperactive’s optimization toolkit. This guide covers core concepts, algorithm selection, and integration with popular ML frameworks.
Tip
New to Hyperactive? Start with Introduction for the fundamentals, then explore Optimizers to choose your algorithm.
How Hyperactive Works#
Hyperactive separates what you optimize from how you optimize it. This design lets you swap algorithms without changing your experiment code.
Core Concepts#
Every optimization in Hyperactive involves three components:
What to optimize
Your objective function that takes parameters and returns a score. Can be a simple function or a built-in ML experiment class.
How to optimize
The algorithm that explores your search space. Choose from 31 algorithms across local search, global search, population methods, and Bayesian approaches.
Where to search
Parameter ranges defined as Python dictionaries. Supports categorical, integer, and continuous parameters.
Quick Example#
from hyperactive.opt import HillClimbing
# 1. Define what to optimize
def objective(params):
x, y = params["x"], params["y"]
return -(x**2 + y**2) # Minimize x² + y²
# 2. Define where to search
search_space = {
"x": list(range(-10, 11)),
"y": list(range(-10, 11)),
}
# 3. Choose how to optimize & run
optimizer = HillClimbing(search_space, n_iter=100, experiment=objective)
best = optimizer.solve() # Returns {"x": 0, "y": 0}
Guide Sections#
Core concepts and architecture. Start here if you’re new.
Best practices for parameter ranges, scaling, and granularity.
Algorithm selection guide. 31 algorithms across 5 categories.
Custom functions and built-in ML experiment classes.
sklearn, sktime, skpro, and PyTorch Lightning support.
Upgrade guide with API changes and new patterns.