def actionIndexInt2Tuple(actionIdx, numActionList):
  """Transforms an action index to tuple of action indices.

  Args:
      actionIdx (int): action index of the discrete action set.
      numActionList (list): consists of the number of actions in evader and
          pursuer's action sets.

  Returns:
      tuple of int: indices of the Q-matrix.
  """
  numJoinAction = int(numActionList[0] * numActionList[1])
  assert (actionIdx < numJoinAction), (
      "The size of joint action set is "
      "{:d} but get index {:d}".format(numJoinAction, actionIdx)
  )
  rowIdx = actionIdx // numActionList[1]
  colIdx = actionIdx % numActionList[1]
  return (rowIdx, colIdx)