code: def run_experiment(experiment, use_cache=True, cache_dir="/tmp"):
      dataset_name, model_name, method_name, metric_name = experiment
  
      # see if we have a cached version
      cache_id = __gen_cache_id(experiment)
      cache_file = os.path.join(cache_dir, cache_id + ".pickle")
      if use_cache and os.path.isfile(cache_file):
          with open(cache_file, "rb") as f:
              # print(cache_id.replace("__", " ") + " ...loaded from cache.")
              return pickle.load(f)
  
      # compute the scores
      print(cache_id.replace("__", " ", 4) + " ...")
      sys.stdout.flush()
      start = time.time()
      X, y = getattr(datasets, dataset_name)()
      score = getattr(metrics, metric_name)(
          X,
          y,
          getattr(models, dataset_name + "__" + model_name),
          method_name,
      )
      print("...took %f seconds.\n" % (time.time() - start))
  
      # cache the scores
      with open(cache_file, "wb") as f:
          pickle.dump(score, f)
  
      return score
  
imports: import copy
  import itertools
  import os
  import pickle
  import random
  import subprocess
  import sys
  import time
  from multiprocessing import Pool
  from ..None import __version__, datasets
  from .None import metrics, models
  from threading import Lock, Thread
label_desc: Use image node_id 2 for calling a global function with example usage: run_experiment(experiment, use_cache, cache_dir) and returns: score, pickle