MLFlowResultTracker

class MLFlowResultTracker(tracking_uri=None, experiment_id=None, experiment_name=None, tags=None)[source]

Bases: pykeen.trackers.base.ResultTracker

A tracker for MLflow.

Initialize result tracking via MLFlow.

Parameters
  • tracking_uri (Optional[str]) – The tracking uri.

  • experiment_id (Optional[int]) – The experiment ID. If given, this has to be the ID of an existing experiment in MFLow. Has priority over experiment_name.

  • experiment_name (Optional[str]) – The experiment name. If this experiment name exists, add the current run to this experiment. Otherwise create an experiment of the given name.

  • tags (Optional[Dict[str, Any]]) – The additional run details which are presented as tags to be logged

Methods Summary

end_run()

End a run.

log_metrics(metrics[, step, prefix])

Log metrics to result store.

log_params(params[, prefix])

Log parameters to result store.

start_run([run_name])

Start a run with an optional name.

Methods Documentation

end_run()[source]

End a run.

HAS to be called after the experiment is finished.

Return type

None

log_metrics(metrics, step=None, prefix=None)[source]

Log metrics to result store.

Parameters
  • metrics (Dict[str, float]) – The metrics to log.

  • step (Optional[int]) – An optional step to attach the metrics to (e.g. the epoch).

  • prefix (Optional[str]) – An optional prefix to prepend to every key in metrics.

Return type

None

log_params(params, prefix=None)[source]

Log parameters to result store.

Return type

None

start_run(run_name=None)[source]

Start a run with an optional name.

Return type

None