code: def _resolve_experiment_id(experiment_name=None, experiment_id=None):
      """
      Resolve experiment.
  
      Verifies either one or other is specified - cannot be both selected.
  
      If ``experiment_name`` is provided and does not exist, an experiment
      of that name is created and its id is returned.
  
      :param experiment_name: Name of experiment under which to launch the run.
      :param experiment_id: ID of experiment under which to launch the run.
      :return: str
      """
  
      if experiment_name and experiment_id:
          raise MlflowException(
              "Specify only one of 'experiment_name' or 'experiment_id'."
          )
  
      if experiment_id:
          return str(experiment_id)
  
      if experiment_name:
          client = tracking.MlflowClient()
          exp = client.get_experiment_by_name(experiment_name)
          if exp:
              return exp.experiment_id
          else:
              _logger.info(
                  "'%s' does not exist. Creating a new experiment",
                  experiment_name,
              )
              return client.create_experiment(experiment_name)
  
      return _get_experiment_id()
  
imports: import json
  import logging
  import os
  import yaml
  import mlflow.projects.databricks
  import mlflow.utils.uri
  from mlflow import tracking
  from mlflow.entities import RunStatus
  from mlflow.exceptions import ExecutionException, MlflowException
  from mlflow.projects.backend import loader
  from mlflow.projects.submitted_run import SubmittedRun
  from mlflow.projects.utils import MLFLOW_LOCAL_BACKEND_RUN_ID_CONFIG, PROJECT_BUILD_IMAGE, PROJECT_DOCKER_ARGS, PROJECT_DOCKER_AUTH, PROJECT_ENV_MANAGER, PROJECT_STORAGE_DIR, PROJECT_SYNCHRONOUS, fetch_and_validate_project, get_entry_point_command, get_or_create_run, get_run_env_vars, load_project
  from mlflow.tracking.fluent import _get_experiment_id
  from mlflow.utils import env_manager
  from mlflow.utils.mlflow_tags import MLFLOW_DOCKER_IMAGE_ID, MLFLOW_PROJECT_BACKEND, MLFLOW_PROJECT_ENV, MLFLOW_RUN_NAME
label_desc: Use image node_id 1 for calling a global function with example usage: _resolve_experiment_id(experiment_name, experiment_id) and returns: _get_experiment_id, str, exp, client