class_docstr: A class designed for extracting word timestamps while the ASR decoding process.
  This class contains a few setups for a slew of NeMo ASR models such as QuartzNet, CitriNet and ConformerCTC models.
class_docstr_tok: ["A","class","designed","for","extracting","word","timestamps","while","the","ASR","decoding","process",".","This","class","contains","a","few","setups","for","a","slew","of","NeMo","ASR","models","such","as","QuartzNet",",","CitriNet","and","ConformerCTC","models","."]
docstr: Collect the space symbols with a list of words.
  
  Args:
      trans (list):
          List containing the character output (str).
      char_ts (list):
          List containing the timestamps of the characters.
      time_stride (float):
          The size of stride of the model in second.
  
  Returns:
      spaces_in_sec (list):
          List containing the ranges of spaces
      word_list (list):
          List containing the words from ASR inference.
docstr_tok: ["Collect","the","space","symbols","with","a","list","of","words",".","Args",":","trans","(","list",")",":","List","containing","the","character","output","(","str",")",".","char_ts","(","list",")",":","List","containing","the","timestamps","of","the","characters",".","time_stride","(","float",")",":","The","size","of","stride","of","the","model","in","second",".","Returns",":","spaces_in_sec","(","list",")",":","List","containing","the","ranges","of","spaces","word_list","(","list",")",":","List","containing","the","words","from","ASR","inference","."]
code: def _get_spaces(
      self, trans: str, char_ts: List[str], time_stride: float
  ) -> Tuple[float, List[str]]:
      """
      Collect the space symbols with a list of words.
  
      Args:
          trans (list):
              List containing the character output (str).
          char_ts (list):
              List containing the timestamps of the characters.
          time_stride (float):
              The size of stride of the model in second.
  
      Returns:
          spaces_in_sec (list):
              List containing the ranges of spaces
          word_list (list):
              List containing the words from ASR inference.
      """
      blank = " "
      spaces_in_sec, word_list = [], []
      stt_idx = 0
      assert (len(trans) > 0) and (
          len(char_ts) > 0
      ), "Transcript and char_ts length should not be 0."
      assert len(trans) == len(
          char_ts
      ), "Transcript and timestamp lengths do not match."
  
      # If there is a blank, update the time stamps of the space and the word.
      for k, s in enumerate(trans):
          if s == blank:
              spaces_in_sec.append(
                  [
                      round(char_ts[k] * time_stride, 2),
                      round((char_ts[k + 1] - 1) * time_stride, 2),
                  ]
              )
              word_list.append(trans[stt_idx:k])
              stt_idx = k + 1
  
      # Add the last word
      if len(trans) > stt_idx and trans[stt_idx] != blank:
          word_list.append(trans[stt_idx:])
      return spaces_in_sec, word_list
  
imports: import copy
  import math
  from typing import Dict, List, Tuple, Type, Union
  import numpy
  import torch
  from omegaconf import OmegaConf
  import nemo.collections.asr
  from nemo.collections.asr.metrics.wer import WER
  from nemo.collections.asr.models import EncDecCTCModel, EncDecCTCModelBPE
  from nemo.collections.asr.parts.submodules.ctc_decoding import CTCBPEDecoding, CTCBPEDecodingConfig, CTCDecoding, CTCDecodingConfig
  from nemo.collections.asr.parts.utils.audio_utils import get_samples
  from nemo.collections.asr.parts.utils.speaker_utils import audio_rttm_map, get_uniqname_from_filepath
  from nemo.collections.asr.parts.utils.streaming_utils import AudioFeatureIterator, FrameBatchASR
  from nemo.collections.common.tokenizers.tokenizer_spec import TokenizerSpec
  from nemo.utils import logging
label_desc: Use image node_id 6 for calling the ASRDecoderTimeStamps obj's underlying member method code with example usage: obj._get_spaces(trans, char_ts, time_stride) and returns: spaces_in_sec,  word_list