(team_size,
         time_limit=45.,
         random_state=None,
         disable_walker_contacts=False,
         enable_field_box=False,
         keep_aspect_ratio=False,
         terminate_on_goal=True,
         walker_type=WalkerType.BOXHEAD)
return composer.Environment(
      task=task_factory(
          players=_make_players(team_size, walker_type),
          arena=RandomizedPitch(
              min_size=min_size,
              max_size=max_size,
              keep_aspect_ratio=keep_aspect_ratio,
              field_box=enable_field_box,
              goal_size=goal_size),
          ball=ball,
          disable_walker_contacts=disable_walker_contacts),
      time_limit=time_limit,
      random_state=random_state)
Construct `team_size`-vs-`team_size` soccer environment.

  Args:
    team_size: Integer, the number of players per team. Must be between 1 and
      11.
    time_limit: Float, the maximum duration of each episode in seconds.
    random_state: (optional) an int seed or `np.random.RandomState` instance.
    disable_walker_contacts: (optional) if `True`, disable physical contacts
      between walkers.
    enable_field_box: (optional) if `True`, enable physical bounding box for
      the soccer ball (but not the players).
    keep_aspect_ratio: (optional) if `True`, maintain constant pitch aspect
      ratio.
    terminate_on_goal: (optional) if `False`, continuous game play across
      scoring events.
    walker_type: the type of walker to instantiate in the environment.

  Returns:
    A `composer.Environment` instance.

  Raises:
    ValueError: If `team_size` is not between 1 and 11.
    ValueError: If `walker_type` is not recognized.
Construct `team_size`-vs-`team_size` soccer environment.
Construct team_size - vs - team_size soccer environment .
def load(team_size,
         time_limit=45.,
         random_state=None,
         disable_walker_contacts=False,
         enable_field_box=False,
         keep_aspect_ratio=False,
         terminate_on_goal=True,
         walker_type=WalkerType.BOXHEAD):
  """Construct `team_size`-vs-`team_size` soccer environment.

  Args:
    team_size: Integer, the number of players per team. Must be between 1 and
      11.
    time_limit: Float, the maximum duration of each episode in seconds.
    random_state: (optional) an int seed or `np.random.RandomState` instance.
    disable_walker_contacts: (optional) if `True`, disable physical contacts
      between walkers.
    enable_field_box: (optional) if `True`, enable physical bounding box for
      the soccer ball (but not the players).
    keep_aspect_ratio: (optional) if `True`, maintain constant pitch aspect
      ratio.
    terminate_on_goal: (optional) if `False`, continuous game play across
      scoring events.
    walker_type: the type of walker to instantiate in the environment.

  Returns:
    A `composer.Environment` instance.

  Raises:
    ValueError: If `team_size` is not between 1 and 11.
    ValueError: If `walker_type` is not recognized.
  """
  goal_size = None
  min_size = (32, 24)
  max_size = (48, 36)
  ball = SoccerBall()

  if walker_type == WalkerType.HUMANOID:
    goal_size = MINI_FOOTBALL_GOAL_SIZE
    num_walkers = team_size * 2
    min_size = _area_to_size(MINI_FOOTBALL_MIN_AREA_PER_HUMANOID * num_walkers)
    max_size = _area_to_size(MINI_FOOTBALL_MAX_AREA_PER_HUMANOID * num_walkers)
    ball = regulation_soccer_ball()

  task_factory = Task
  if not terminate_on_goal:
    task_factory = MultiturnTask

  return composer.Environment(
      task=task_factory(
          players=_make_players(team_size, walker_type),
          arena=RandomizedPitch(
              min_size=min_size,
              max_size=max_size,
              keep_aspect_ratio=keep_aspect_ratio,
              field_box=enable_field_box,
              goal_size=goal_size),
          ball=ball,
          disable_walker_contacts=disable_walker_contacts),
      time_limit=time_limit,
      random_state=random_state)
def load ( team_size , time_limit = 45. , random_state = None , disable_walker_contacts = False , enable_field_box = False , keep_aspect_ratio = False , terminate_on_goal = True , walker_type = WalkerType . BOXHEAD ) : goal_size = None min_size = ( 32 , 24 ) max_size = ( 48 , 36 ) ball = SoccerBall ( ) if walker_type == WalkerType . HUMANOID : goal_size = MINI_FOOTBALL_GOAL_SIZE num_walkers = team_size * 2 min_size = _area_to_size ( MINI_FOOTBALL_MIN_AREA_PER_HUMANOID * num_walkers ) max_size = _area_to_size ( MINI_FOOTBALL_MAX_AREA_PER_HUMANOID * num_walkers ) ball = regulation_soccer_ball ( ) task_factory = Task if not terminate_on_goal : task_factory = MultiturnTask return composer . Environment ( task = task_factory ( players = _make_players ( team_size , walker_type ) , arena = RandomizedPitch ( min_size = min_size , max_size = max_size , keep_aspect_ratio = keep_aspect_ratio , field_box = enable_field_box , goal_size = goal_size ) , ball = ball , disable_walker_contacts = disable_walker_contacts ) , time_limit = time_limit , random_state = random_state )