class_docstr: SynthText Text Detection Annotation Parser.
  
  Args:
      split (str): The split of the dataset. It is usually set automatically
          and users do not need to set it manually in config file in most
          cases.
      nproc (int): Number of processes to process the data. Defaults to 1.
          It is usually set automatically and users do not need to set it
          manually in config file in most cases.
      separator (str): The separator between each element in a line. Defaults
          to ','.
      ignore (str): The text to be ignored. Defaults to '###'.
      format (str): The format of the annotation. Defaults to
          'x1,y1,x2,y2,x3,y3,x4,trans'.
      encoding (str): The encoding of the annotation file. Defaults to
          'utf-8-sig'.
      remove_strs (List[str], Optional): Used to remove redundant strings in
          the transcription. Defaults to None.
      mode (str, optional): The mode of the box converter. Supported modes
          are 'xywh' and 'xyxy'. Defaults to None.
class_docstr_tok: ["SynthText","Text","Detection","Annotation","Parser",".","Args",":","split","(","str",")",":","The","split","of","the","dataset",".","It","is","usually","set","automatically","and","users","do","not","need","to","set","it","manually","in","config","file","in","most","cases",".","nproc","(","int",")",":","Number","of","processes","to","process","the","data",".","Defaults","to","1",".","It","is","usually","set","automatically","and","users","do","not","need","to","set","it","manually","in","config","file","in","most","cases",".","separator","(","str",")",":","The","separator","between","each","element","in","a","line",".","Defaults","to","'",",","'",".","ignore","(","str",")",":","The","text","to","be","ignored",".","Defaults","to","'","#","#","#","'",".","format","(","str",")",":","The","format","of","the","annotation",".","Defaults","to","'x1",",","y1",",","x2",",","y2",",","x3",",","y3",",","x4",",","trans","'",".","encoding","(","str",")",":","The","encoding","of","the","annotation","file",".","Defaults","to","'utf-8-sig","'",".","remove_strs","(","List","[","str","]",",","Optional",")",":","Used","to","remove","redundant","strings","in","the","transcription",".","Defaults","to","None",".","mode","(","str",",","optional",")",":","The","mode","of","the","box","converter",".","Supported","modes","are","'xywh","'","and","'xyxy","'",".","Defaults","to","None","."]
code: def __init__(
      self,
      split: str,
      nproc: int,
      separator: str = ",",
      ignore: str = "###",
      format: str = "x1,y1,x2,y2,x3,y3,x4,y4,trans",
      encoding: str = "utf-8",
      remove_strs: Optional[List[str]] = None,
      mode: str = None,
  ) -> None:
      self.sep = separator
      self.format = format
      self.encoding = encoding
      self.ignore = ignore
      self.mode = mode
      self.remove_strs = remove_strs
      super().__init__(split=split, nproc=nproc)
  
file_path: mmocr/mmocr/datasets/preparers/parsers/synthtext_parser.py
imports: import os.path
  from typing import List, Optional, Tuple, Union
  import numpy
  from mmengine import track_parallel_progress
  from scipy.io import loadmat
  from mmocr.utils import is_type_list
  from ..data_preparer import DATA_PARSERS
  from .base import BaseParser
label_desc: Use image node_id 1 to create a new SynthTextAnnParser object from inherited base classes: BaseParser with example: obj = SynthTextAnnParser(split, nproc, separator, ignore, format, encoding, remove_strs, mode)