class_docstr: An abstract class for extracting subset of examples.
class_docstr_tok: ["An","abstract","class","for","extracting","subset","of","examples","."]
docstr: Normalize the bound of slice
  
  :param str|float|int limit: left_bound or right_bound for intervals
      can be percentile like 10%, 20%
      can be float between 0 and 1 like 0.3
      can be int index like 50
  :param size: the size of samples
  :return int : bound
docstr_tok: ["Normalize","the","bound","of","slice",":","param","str|float|int","limit",":","left_bound","or","right_bound","for","intervals","can","be","percentile","like","10","%",",","20","%","can","be","float","between","0","and","1","like","0.3","can","be","int","index","like","50",":","param","size",":","the","size","of","samples",":","return","int",":","bound"]
code: def normalize_bound(limit, size):
      r"""
      Normalize the bound of slice
  
      :param str|float|int limit: left_bound or right_bound for intervals
          can be percentile like 10%, 20%
          can be float between 0 and 1 like 0.3
          can be int index like 50
      :param size: the size of samples
      :return int : bound
  
      """
      if isinstance(limit, str) and limit.endswith("%"):
          limit = float(limit.replace("%", "")) / 100
          return math.floor(limit * size)
      elif isinstance(limit, float):
          return math.floor(limit * size)
      elif isinstance(limit, int):
          return limit
      else:
          raise NotImplementedError
  
file_path: textflint/textflint/generation/subpopulation/subpopulation.py
imports: import math
  from tqdm import tqdm
  from abc import ABC, abstractmethod
  from ...common.preprocess import EnProcessor
label_desc: Use image node_id 7 for calling the SubPopulation obj's underlying member method code with example usage: obj.normalize_bound(limit, size) and returns: math, math, limit