class_docstr: Compute CTC label sequence scores
  
  which is based on Algorithm 2 in WATANABE et al.
  "HYBRID CTC/ATTENTION ARCHITECTURE FOR END-TO-END SPEECH RECOGNITION,"
  but extended to efficiently compute the probablities of multiple labels
  simultaneously
class_docstr_tok: ["Compute","CTC","label","sequence","scores","which","is","based","on","Algorithm","2","in","WATANABE","et","al",".","``","HYBRID","CTC\/ATTENTION","ARCHITECTURE","FOR","END-TO-END","SPEECH","RECOGNITION",",","''","but","extended","to","efficiently","compute","the","probablities","of","multiple","labels","simultaneously"]
docstr: Obtain an initial CTC state
  
  :return: CTC state
docstr_tok: ["Obtain","an","initial","CTC","state",":","return",":","CTC","state"]
code: def initial_state(self):
      """Obtain an initial CTC state
  
      :return: CTC state
      """
      # initial CTC state is made of a frame x 2 tensor that corresponds to
      # r_t^n(<sos>) and r_t^b(<sos>), where 0 and 1 of axis=1 represent
      # superscripts n and b (non-blank and blank), respectively.
      r = self.xp.full(
          (self.input_length, 2), self.logzero, dtype=np.float32
      )
      r[0, 1] = self.x[0, self.blank]
      for i in range(1, self.input_length):
          r[i, 1] = r[i - 1, 1] + self.x[i, self.blank]
      return r
  
file_path: espnet/espnet/nets/ctc_prefix_score.py
imports: import numpy
  import torch
label_desc: Use image node_id 2 for calling the CTCPrefixScore obj's underlying member method code with example usage: obj.initial_state() and returns: r