code: def _get_game_loop(agent_obs):
      if isinstance(agent_obs, sc_pb.ResponseObservation):
          return agent_obs.observation.game_loop
      else:
          return agent_obs.game_loop[0]
  
imports: import collections
  import copy
  import random
  import time
  from absl import logging
  from pysc2 import maps
  from pysc2 import run_configs
  from pysc2.env import enums
  from pysc2.env import environment
  from pysc2.lib import actions
  from pysc2.lib import features
  from pysc2.lib import metrics
  from pysc2.lib import portspicker
  from pysc2.lib import renderer_human
  from pysc2.lib import run_parallel
  from pysc2.lib import stopwatch
  from s2clientprotocol import sc2api_pb2
label_desc: Use image node_id 4 for calling a global function with example usage: _get_game_loop(agent_obs) and returns: agent_obs, agent_obs