Skip to content

comet_ml.ExperimentConfig ΒΆ

ExperimentConfig(
    disabled: Optional[bool] = None,
    log_code: Optional[bool] = None,
    log_graph: Optional[bool] = None,
    parse_args: Optional[bool] = None,
    display_summary_level: int = 1,
    log_git_metadata: Optional[bool] = None,
    log_git_patch: Optional[bool] = None,
    log_env_details: Optional[bool] = None,
    log_env_gpu: Optional[bool] = None,
    log_env_host: Optional[bool] = None,
    log_env_cpu: Optional[bool] = None,
    log_env_network: Optional[bool] = None,
    log_env_disk: Optional[bool] = None,
    auto_output_logging: str = "default",
    auto_param_logging: bool = True,
    auto_metric_logging: bool = True,
    auto_log_co2: bool = True,
    auto_metric_step_rate: int = 10,
    auto_histogram_epoch_rate: int = 1,
    auto_histogram_gradient_logging: bool = False,
    auto_histogram_activation_logging: bool = False,
    auto_histogram_tensorboard_logging: bool = False,
    auto_histogram_weight_logging: bool = False,
    offline_directory: Optional[str] = None,
    distributed_node_identifier: Optional[str] = None,
    name: Optional[str] = None,
    tags: Optional[List[str]] = None,
)

The Comet experiment configuration. All of the following attributes can also be configured through environment variables or configuration files.

Attributes:

  • disabled (boolean) –

    Allows you to disable all network communication with the Comet.com backend. It is useful when you want to test to make sure everything is working, without actually logging anything. If not configured, defaults to False.

  • log_code (boolean) –

    Allows you to enable and disable automatic code logging. Defaults to True when a new experiment is created and False when resuming an experiment.

  • log_graph (boolean) –

    Allows you to enable and disable automatic computation graph logging. Defaults to True when a new experiment is created and False when resuming an experiment.

  • parse_args (boolean) –

    Allows you to enable and disable automatic parsing of CLI arguments. Defaults to True when a new experiment is created and False when resuming an experiment.

  • display_summary_level (int) –

    Allows you to control the summary detail that is displayed on the console at the end of an experiment. If 0, the summary will not be displayed. Valid values are 0 to 2.

  • log_git_metadata (boolean) –

    Allows you to enable and disable automatic git metadata logging. Defaults to True when a new experiment is created and False when resuming an experiment.

  • log_git_patch (boolean) –

    Allows you to enable and disable automatic git patch logging. Defaults to True when a new experiment is created and False when resuming an experiment.

  • log_env_details (boolean) –

    Allows you to enable and disable automatic logging of various environment information in order to identify where the script ran. If log_env_details is False, GPU, CPU, network, disk and host information will not be logged. Defaults to True when a new experiment is created and False when resuming an experiment.

  • log_env_gpu (boolean) –

    Allows you to enable and disable automatic logging of GPU details and metrics (utilization, memory usage, etc...). Defaults to True when a new experiment is created and False when resuming an experiment.

  • log_env_host (boolean) –

    Allows you to enable and disable automatic logging of host information (ip, hostname, python version, user, etc...). Defaults to True when a new experiment is created and False when resuming an experiment.

  • log_env_cpu (boolean) –

    Allows you to enable and disable automatic logging of CPU details and metrics (utilization, memory usage, etc...). Defaults to True when a new experiment is created and False when resuming an experiment.

  • log_env_network (boolean) –

    Allows you to enable and disable automatic logging of network details and metrics (sent and received rates, etc...). Defaults to True when a new experiment is created and False when resuming an experiment.

  • log_env_disk (boolean) –

    Allows you to enable and disable automatic logging of disk utilization metrics (usage, IO rates, etc...). Defaults to True when a new experiment is created and False when resuming an experiment.

  • auto_output_logging ([default, native, simple, False]) –

    Allows you to select which output logging mode to use. You can pass "native" which will log all output even when it originated from a C native library. You can also pass "simple" which will work only for output made by Python code. If you want to disable automatic output logging, you can pass False. The default is "default" which will detect your environment and deactivate the output logging for IPython and Jupyter environment, sets "simple" for MacOS and sets "native" in the other cases.

  • auto_param_logging (boolean) –

    Allows you to enable and disable automatic hyperparameter logging.

  • auto_metric_logging (boolean) –

    Allows you to enable and disable automatic metric logging.

  • auto_log_co2 (boolean, optional, defaults to True) –

    Allows you to enable and disable automatic tracking of the CO2 emission of this experiment if codecarbon package is installed in the environment.

  • auto_metric_step_rate (int, optional, defaults to 10) –

    Allows you to control how often in-batch metrics are logged.

  • auto_histogram_epoch_rate (int, optional, defaults to 1) –

    Allows you to control how often histograms are logged.

  • auto_histogram_gradient_logging (boolean, optional, defaults to False) –

    Allows you to enable and disable automatic histogram logging of gradients.

  • auto_histogram_activation_logging (boolean, optional, defaults to False) –

    Allows you to enable and disable automatic histogram logging of activations.

  • auto_histogram_tensorboard_logging (boolean, optional, defaults to False) –

    Allows you to enable and disable automatic tensorboard histogram logging.

  • offline_directory (string) –

    Allows you to set the directory used to save the offline archive for the experiment. If not configured, defaults to None.

  • distributed_node_identifier (string) –

    Allows you to set a prefix as node identifier. If not configured, defaults to None.

  • name (string) –

    Allows you to set the name of the experiment. If not configured, a default random Experiment Name will be generated.

  • tags (List[str]) –

    Allows you to set tags to be associated with the experiment. If not configured, no tags will be added to the Experiment.

Nov. 18, 2024