parameters: (image_size: Union[Text, int, Tuple[int, int]], max_level: int)
return_statement: return feat_sizes
docstring: Get feat widths and heights for all levels.
  
      Args:
        image_size: A integer, a tuple (H, W), or a string with HxW format.
        max_level: maximum feature level.
  
      Returns:
        feat_sizes: a list of tuples (height, width) for each level.
docstring_summary: Get feat widths and heights for all levels.
docstring_tokens: Get feat widths and heights for all levels .
function: def get_feat_sizes(image_size: Union[Text, int, Tuple[int, int]], max_level: int):
      """Get feat widths and heights for all levels.
  
      Args:
        image_size: A integer, a tuple (H, W), or a string with HxW format.
        max_level: maximum feature level.
  
      Returns:
        feat_sizes: a list of tuples (height, width) for each level.
      """
      image_size = parse_image_size(image_size)
      feat_sizes = [{"height": image_size[0], "width": image_size[1]}]
      feat_size = image_size
      for _ in range(1, max_level + 1):
          feat_size = ((feat_size[0] - 1) // 2 + 1, (feat_size[1] - 1) // 2 + 1)
          feat_sizes.append({"height": feat_size[0], "width": feat_size[1]})
      return feat_sizes
function_tokens: def get_feat_sizes ( image_size : Union [ Text , int , Tuple [ int , int ] ] , max_level : int ) : image_size = parse_image_size ( image_size ) feat_sizes = [ { "height" : image_size [ 0 ] , "width" : image_size [ 1 ] } ] feat_size = image_size for _ in range ( 1 , max_level + 1 ) : feat_size = ( ( feat_size [ 0 ] - 1 ) // 2 + 1 , ( feat_size [ 1 ] - 1 ) // 2 + 1 ) feat_sizes . append ( { "height" : feat_size [ 0 ] , "width" : feat_size [ 1 ] } ) return feat_sizes