code: def setup_experiment(env, experiment, clean=True):
      if not isinstance(experiment, str):
          key = experiment.key
          artifacts = experiment.artifacts
      else:
          key = experiment
          artifacts = {}
  
      env[STUDIOML_EXPERIMENT] = key
      _setup_model_directory(key, clean)
  
      artifact_mapping_path = _get_artifact_mapping_path(key)
      env[STUDIOML_ARTIFACT_MAPPING] = artifact_mapping_path
  
      amapping = {}
      for tag, art in artifacts.items():
          # art is of type Artifact:
          if art.local_path is not None:
              amapping[tag] = art.local_path
  
          with open(artifact_mapping_path, "w") as f_in:
              json.dump(amapping, f_in)
  
file_path: studio/studio/artifacts/artifacts_tracker.py
imports: import os
  import uuid
  import json
  import re
  import shutil
  from studio.util import util
label_desc: Use image node_id 4 for calling a global function with example usage: setup_experiment(env, experiment, clean) without return types