class_docstr: MLFlowHandler defines a set of Ignite Event-handlers for the MLFlow tracking logics.
  It can be used for any Ignite Engine(trainer, validator and evaluator).
  And it can track both epoch level and iteration level logging, then MLFlow can store
  the data and visualize.
  The expected data source is Ignite ``engine.state.output`` and ``engine.state.metrics``.
  
  Default behaviors:
      - When EPOCH_COMPLETED, track each dictionary item in
        ``engine.state.metrics`` in MLFlow.
      - When ITERATION_COMPLETED, track expected item in
        ``self.output_transform(engine.state.output)`` in MLFlow, default to `Loss`.
  
  Usage example is available in the tutorial:
  https://github.com/Project-MONAI/tutorials/blob/master/3d_segmentation/unet_segmentation_3d_ignite.ipynb.
  
  Args:
      tracking_uri: connects to a tracking URI. can also set the `MLFLOW_TRACKING_URI` environment
          variable to have MLflow find a URI from there. in both cases, the URI can either be
          an HTTP/HTTPS URI for a remote server, a database connection string, or a local path
          to log data to a directory. The URI defaults to path `mlruns`.
          for more details: https://mlflow.org/docs/latest/python_api/mlflow.html#mlflow.set_tracking_uri.
      iteration_log: whether to log data to MLFlow when iteration completed, default to `True`.
          ``iteration_log`` can be also a function and it will be interpreted as an event filter
          (see https://pytorch.org/ignite/generated/ignite.engine.events.Events.html for details).
          Event filter function accepts as input engine and event value (iteration) and should return True/False.
      epoch_log: whether to log data to MLFlow when epoch completed, default to `True`.
          ``epoch_log`` can be also a function and it will be interpreted as an event filter.
          See ``iteration_log`` argument for more details.
      epoch_logger: customized callable logger for epoch level logging with MLFlow.
          Must accept parameter "engine", use default logger if None.
      iteration_logger: customized callable logger for iteration level logging with MLFlow.
          Must accept parameter "engine", use default logger if None.
      dataset_logger: customized callable logger to log the dataset information with MLFlow.
          Must accept parameter "dataset_dict", use default logger if None.
      dataset_dict: a dictionary in which the key is the name of the dataset and the value is a PyTorch
          dataset, that needs to be recorded. This arg is only useful when MLFlow version >= 2.4.0.
          For more details about how to log data with MLFlow, please go to the website:
          https://mlflow.org/docs/latest/python_api/mlflow.data.html.
      dataset_keys: a key or a collection of keys to indicate contents in the dataset that
          need to be stored by MLFlow.
      output_transform: a callable that is used to transform the
          ``ignite.engine.state.output`` into a scalar to track, or a dictionary of {key: scalar}.
          By default this value logging happens when every iteration completed.
          The default behavior is to track loss from output[0] as output is a decollated list
          and we replicated loss value for every item of the decollated list.
          `engine.state` and `output_transform` inherit from the ignite concept:
          https://pytorch-ignite.ai/concepts/03-state/, explanation and usage example are in the tutorial:
          https://github.com/Project-MONAI/tutorials/blob/master/modules/batch_output_transform.ipynb.
      global_epoch_transform: a callable that is used to customize global epoch number.
          For example, in evaluation, the evaluator engine might want to track synced epoch number
          with the trainer engine.
      state_attributes: expected attributes from `engine.state`, if provided, will extract them
          when epoch completed.
      tag_name: when iteration output is a scalar, `tag_name` is used to track, defaults to `'Loss'`.
      experiment_name: the experiment name of MLflow, default to `'monai_experiment'`. An experiment can be
          used to record several runs.
      run_name: the run name in an experiment. A run can be used to record information about a workflow,
          like the loss, metrics and so on.
      experiment_param: a dict recording parameters which will not change through the whole workflow,
          like torch version, cuda version and so on.
      artifacts: paths to images that need to be recorded after running the workflow.
      optimizer_param_names: parameter names in the optimizer that need to be recorded during running the
          workflow, default to `'lr'`.
      close_on_complete: whether to close the mlflow run in `complete` phase in workflow, default to False.
  
  For more details of MLFlow usage, please refer to: https://mlflow.org/docs/latest/index.html.
docstr: Handler for train or validation/evaluation iteration completed Event.
  Track iteration level log.
  
  Args:
      engine: Ignite Engine, it can be a trainer, validator or evaluator.
docstr_tok: ["Handler","for","train","or","validation\/evaluation","iteration","completed","Event",".","Track","iteration","level","log",".","Args",":","engine",":","Ignite","Engine",",","it","can","be","a","trainer",",","validator","or","evaluator","."]
code: def iteration_completed(self, engine: Engine) -> None:
      """
      Handler for train or validation/evaluation iteration completed Event.
      Track iteration level log.
  
      Args:
          engine: Ignite Engine, it can be a trainer, validator or evaluator.
  
      """
      if self.iteration_logger is not None:
          self.iteration_logger(engine)
      else:
          self._default_iteration_log(engine)
  
imports: from __future__ import annotations
  import os
  import time
  import warnings
  from collections.abc import Callable, Mapping, Sequence
  from pathlib import Path
  from typing import TYPE_CHECKING, Any
  import torch
  from torch.utils.data import Dataset
  from monai.config import IgniteInfo
  from monai.utils import CommonKeys, ensure_tuple, min_version, optional_import
label_desc: Use image node_id 14 for calling the MLFlowHandler obj's underlying member method code with example usage: obj.iteration_completed(engine) without return types