class_docstr: A tokenizer that splits a string using a regular expression, which
  matches either the tokens or the separators between tokens.
  
      >>> tokenizer = RegexpTokenizer(r'\w+|\$[\d\.]+|\S+')
  
  :type pattern: str
  :param pattern: The pattern used to build this tokenizer.
      (This pattern must not contain capturing parentheses;
      Use non-capturing parentheses, e.g. (?:...), instead)
  :type gaps: bool
  :param gaps: True if this tokenizer's pattern should be used
      to find separators between tokens; False if this
      tokenizer's pattern should be used to find the tokens
      themselves.
  :type discard_empty: bool
  :param discard_empty: True if any empty tokens `''`
      generated by the tokenizer should be discarded.  Empty
      tokens can only be generated if `_gaps == True`.
  :type flags: int
  :param flags: The regexp flags used to compile this
      tokenizer's pattern.  By default, the following flags are
      used: `re.UNICODE | re.MULTILINE | re.DOTALL`.
class_docstr_tok: ["A","tokenizer","that","splits","a","string","using","a","regular","expression",",","which","matches","either","the","tokens","or","the","separators","between","tokens",".",">",">",">","tokenizer","=","RegexpTokenizer","(","r'\\w+|\\","$","[","\\d\\",".","]","+|\\S+","'",")",":","type","pattern",":","str",":","param","pattern",":","The","pattern","used","to","build","this","tokenizer",".","(","This","pattern","must","not","contain","capturing","parentheses",";","Use","non-capturing","parentheses",",","e.g",".","(","?",":","...",")",",","instead",")",":","type","gaps",":","bool",":","param","gaps",":","True","if","this","tokenizer","'s","pattern","should","be","used","to","find","separators","between","tokens",";","False","if","this","tokenizer","'s","pattern","should","be","used","to","find","the","tokens","themselves",".",":","type","discard_empty",":","bool",":","param","discard_empty",":","True","if","any","empty","tokens","`","``","`","generated","by","the","tokenizer","should","be","discarded",".","Empty","tokens","can","only","be","generated","if","`","_gaps","==","True","`",".",":","type","flags",":","int",":","param","flags",":","The","regexp","flags","used","to","compile","this","tokenizer","'s","pattern",".","By","default",",","the","following","flags","are","used",":","`","re.UNICODE","|","re.MULTILINE","|","re.DOTALL","`","."]
code: def _check_regexp(self):
      if self._regexp is None:
          self._regexp = re.compile(self._pattern, self._flags)
  
imports: import re
  from nltk.tokenize.api import TokenizerI
  from nltk.tokenize.util import regexp_span_tokenize
label_desc: Use image node_id 2 for calling the RegexpTokenizer obj's underlying member method code with example usage: obj._check_regexp() without return types