ExperimentRun
One generation in one experiment, lifecycle-managed.
Use as a context manager. On clean exit, the generation + experiment are marked completed (with the best score / generation_id). On raised exception, both are marked failed with the exception message. All writes are mirrored locally and degrade gracefully if the backend is down.
Attributes
attributeclient= clientattributeexperiment_idstr | None= Noneattributerun_idstr | None= NoneFunctions
func__init__(self, client, *, experiment_name, hypothesis=None, hypothesis_reasoning=None, plan=None, tags=None, project_goal_id=None, group_id=None, dataset_id=None, seed=None, recipe_kind=None, run_config=None, wandb_run_url=None, tensorboard_path=None, experiment_id=None) -> NoneparamselfparamclientDashboardClientparamexperiment_namestrparamhypothesisstr | None= Noneparamhypothesis_reasoningstr | None= Noneparamplanstr | None= Noneparamtagslist[str] | None= Noneparamproject_goal_idstr | None= Noneparamgroup_idstr | None= Noneparamdataset_idstr | None= Noneparamseedint | None= Noneparamrecipe_kindstr | None= Noneparamrun_configdict | None= Noneparamwandb_run_urlstr | None= Noneparamtensorboard_pathstr | None= Noneparamexperiment_idstr | None= NoneReturns
Nonefunc__enter__(self) -> 'ExperimentRun'paramselfReturns
'ExperimentRun'func__exit__(self, exc_type, exc_val, exc_tb) -> Noneparamselfparamexc_typeparamexc_valparamexc_tbReturns
Nonefunclog_step(self, step, **metrics) -> NoneparamselfparamstepintparammetricsAny= {}Returns
Nonefunclog_eval(self, *, metrics, benchmark_id=None, checkpoint_id=None, model_ref=None, step=None) -> Noneparamselfparammetricsdict[str, float]parambenchmark_idstr | None= Noneparamcheckpoint_idstr | None= Noneparammodel_refstr | None= Noneparamstepint | None= NoneReturns
Nonefuncadd_checkpoint(self, *, uri, label=None, step=None, base_model=None, is_final=False) -> Noneparamselfparamuristrparamlabelstr | None= Noneparamstepint | None= Noneparambase_modelstr | None= Noneparamis_finalbool= FalseReturns
Nonefunclog_predictions(self, predictions) -> Noneparamselfparampredictionslist[dict]Returns
Nonefuncset_best_score(self, score) -> NoneparamselfparamscorefloatReturns
Nonefuncset_conclusion(self, text) -> NoneOne- or two-line takeaway from the run. Flushed on clean exit.
paramselfparamtextstrReturns
Nonefuncupdate_run(self, **patch) -> NoneparamselfparampatchAny= {}Returns
Nonefuncupdate_experiment(self, **patch) -> NoneparamselfparampatchAny= {}Returns
None