MCPcopy
hub / github.com/hyperopt/hyperopt / test_annotated_params_space

Function test_annotated_params_space

hyperopt/tests/unit/test_fmin.py:381–388  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

379
380
381def test_annotated_params_space():
382 def objective(x: hp.uniform("x", -10, 10), y: hp.uniform("y", -10, 10)):
383 return (x * y) ** 2
384
385 trials = Trials()
386 fmin(objective, space="annotated", algo=tpe.suggest, max_evals=10, trials=trials)
387
388 assert len(trials) == 10
389
390
391def test_invalid_annotated_params_space():

Callers

nothing calls this directly

Calls 2

TrialsClass · 0.90
fminFunction · 0.90

Tested by

no test coverage detected