code: def remove_punctuation(
      text: str,
      remove_spaces: bool = False,
      do_lower: bool = False,
      exclude: List[str] = None,
  ):
      """
      Remove punctuation marks form text
  
      Args:
          text: input text
          remove_spaces: set to True to remove spaces
          do_lower: set to True to lower case the text
          exclude: specify list of punctuation marks keep in the output, e.g., exclude=["'", "."]
  
      Return:
          processed text with punctuation marks removed
      """
      all_punct_marks = string.punctuation
  
      if exclude is not None:
          for p in exclude:
              all_punct_marks = all_punct_marks.replace(p, "")
  
      text = re.sub("[" + all_punct_marks + "]", " ", text)
  
      text = re.sub(r" +", " ", text)
      if remove_spaces:
          text = text.replace(" ", "").replace("\u00A0", "").strip()
  
      if do_lower:
          text = text.lower()
      return text.strip()
  
file_path: NeMo/nemo/collections/tts/g2p/utils.py
imports: import csv
  import os
  import re
  import string
  from typing import Dict, List, Union
label_desc: Use image node_id 3 for calling a global function with example usage: remove_punctuation(text, remove_spaces, do_lower, exclude) and returns: text