code: def team_pursuit_simulation(x) -> float:
      if len(x) == 2:  # Let us concatenate the instrumentation.
          pacing = x[1]["pacing"]
          transition = x[1]["transition"]
      elif len(x) in (30, 22):
          transition = x
          pacing = [550 if len(x) == 30 else 400] * (len(x) + 1)
      elif len(x) in (31, 23):
          pacing = x
          transition = [True, False] * ((len(x) - 1) // 2)
      else:
          raise ValueError(f"len(x) == {len(x)}")
  
          # What is this ?
          # for i in range(0, len(pacing_strategy)):
          #    pacing_strategy[i] = 100 * pacing_strategy[i] + 200
  
      # Create a mensteampursuit oor womensteampursuit object.
      team_pursuit: tp.Any = (
          womensteampursuit()
          if len(pacing) == 23
          else mensteampursuit()
      )
      assert len(pacing) in (23, 31)
  
      # Simulate event with the default strategies
      result = team_pursuit.simulate(transition, pacing)
  
      if result.get_finish_time() > 10000:  # in case of inf
          return 10000
      else:
          return float(result.get_finish_time())
  
file_path: nevergrad/nevergrad/functions/cycling/cycling.py
imports: import numpy
  import typing
  from ..None import base
  from nevergrad.parametrization import parameter
  from .womensteampursuit import womensteampursuit
  from .mensteampursuit import mensteampursuit
label_desc: Use image node_id 1 for calling a global function with example usage: team_pursuit_simulation(x) and returns: int, float