code: def instance_ctc_greedy_decoder(
      gather_info, logits_map, keep_blank_in_idxs=True
  ):
      """
      gather_info: [[x, y], [x, y] ...]
      logits_map: H x W X (n_chars + 1)
      """
      _, _, C = logits_map.shape
      ys, xs = zip(*gather_info)
      logits_seq = logits_map[list(ys), list(xs)]  # n x 96
      probs_seq = softmax(logits_seq)
      dst_str, keep_idx_list = ctc_greedy_decoder(
          probs_seq, blank=C - 1, keep_blank_in_idxs=keep_blank_in_idxs
      )
      keep_gather_list = [gather_info[idx] for idx in keep_idx_list]
      return dst_str, keep_gather_list
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import cv2
  import math
  import numpy
  from itertools import groupby
  from skimage.morphology._skeletonize import thin
label_desc: Use image node_id 10 for calling a global function with example usage: instance_ctc_greedy_decoder(gather_info, logits_map, keep_blank_in_idxs) and returns: dst_str,  keep_gather_list