code: def main():
      args = parse_args()
      root_path = args.root_path
      print("Processing training set...")
      num_train_imgs = convert_cocotext(
          root_path=root_path,
          split="train",
          preserve_vertical=args.preserve_vertical,
          nproc=args.nproc,
      )
      print("Processing validation set...")
      convert_cocotext(
          root_path=root_path,
          split="val",
          preserve_vertical=args.preserve_vertical,
          nproc=args.nproc,
          img_start_idx=num_train_imgs,
      )
      print("Finish")
  
file_path: mmocr/tools/dataset_converters/textrecog/cocotext_converter.py
imports: import argparse
  import math
  import os.path
  from functools import partial
  import mmcv
  import mmengine
  from mmocr.utils import dump_ocr_data
label_desc: Use image node_id 4 for calling a global function with example usage: main() without return types