parameters: (rank_id)
docstring: A function that check if a collection communication rank id is legal.If not raise error.
  
      Returns:
          None
docstring_summary: A function that check if a collection communication rank id is legal.If not raise error.
docstring_tokens: A function that check if a collection communication rank id is legal . If not raise error .
function: def check_rank_id(rank_id):
      """
      A function that check if a collection communication rank id is legal.If not raise error.
  
      Returns:
          None
      """
      if isinstance(rank_id, (int)):
          if rank_id >= MAX_RANK_NUM or rank_id < 0:
              raise ValueError("The rand id in the communication group must be greater or equal 0 and "
                               "less than {}, but got type value : {}.".format(MAX_RANK_NUM, rank_id))
      else:
          raise TypeError("The rand id in the communication group must be must be type of int, "
                          "but got type value : {}.".format(type(rank_id)))
function_tokens: def check_rank_id ( rank_id ) : if isinstance ( rank_id , ( int ) ) : if rank_id >= MAX_RANK_NUM or rank_id < 0 : raise ValueError ( "The rand id in the communication group must be greater or equal 0 and " "less than {}, but got type value : {}." . format ( MAX_RANK_NUM , rank_id ) ) else : raise TypeError ( "The rand id in the communication group must be must be type of int, " "but got type value : {}." . format ( type ( rank_id ) ) )