def __init__(
      self,
      start: datetime.datetime | None = None,
      step_sizes: Sequence[datetime.timedelta] = (_DEFAULT_STEP_SIZE,),
  ):
    """Initializes the clock.

    Args:
      start: The start time of the clock. If None, the current time is used.
      step_sizes: The step sizes of the clock.

    Raises:
      RuntimeError: If step_sizes are not sorted from lowest to highest.
    """
    if start is None:
      self._start = datetime.datetime.now()
    else:
      self._start = start

    # the default makes it a fixed interval clock
    if step_sizes != sorted(step_sizes, reverse=True):
      raise RuntimeError('Step sizes have to be sorted from lowest to highest.')

    self._step_sizes = step_sizes
    self._steps = [0] * len(step_sizes)
    self._current_gear = 0

    self._step_lock = threading.RLock()
    self._control_lock = threading.RLock()
Initializes the clock.

    Args:
      start: The start time of the clock. If None, the current time is used.
      step_sizes: The step sizes of the clock.

    Raises:
      RuntimeError: If step_sizes are not sorted from lowest to highest.
    
concordia/clocks/game_clock.py