code: def _get_algorithm_class(alg: str) -> type:
      # This helps us get around a circular import (tune calls rllib._register_all when
      # checking if a rllib Trainable is registered)
      if alg in ALGORITHMS:
          return ALGORITHMS[alg]()[0]
      elif alg == "script":
          from ray.tune import script_runner
  
          return script_runner.ScriptRunner
      elif alg == "__fake":
          from ray.rllib.algorithms.mock import _MockTrainer
  
          return _MockTrainer
      elif alg == "__sigmoid_fake_data":
          from ray.rllib.algorithms.mock import _SigmoidFakeData
  
          return _SigmoidFakeData
      elif alg == "__parameter_tuning":
          from ray.rllib.algorithms.mock import _ParameterTuningTrainer
  
          return _ParameterTuningTrainer
      else:
          raise Exception("Unknown algorithm {}.".format(alg))
  
imports: import importlib
  import re
  from ray.rllib.utils.deprecation import Deprecated
label_desc: Use image node_id 36 for calling a global function with example usage: _get_algorithm_class(alg) and returns: ALGORITHMS, script_runner, _MockTrainer, _SigmoidFakeData, _ParameterTuningTrainer