Skip to content

get_running_experiment

comet_ml.get_running_experiment

get_running_experiment()

Returns a currently running experiment or None if there is no such.

Returns: None or "BaseExperiment"

Examples:

1
2
3
4
5
6
7
8
9
import comet_ml

comet_ml.init()
exp = comet_ml.Experiment()
print(exp.get_key())

# Get the running experiment
experiment_obj = comet_ml.get_running_experiment()
print(experiment_obj.get_key())
May. 17, 2024