code: def evaluate(self, pred, target, seq_len):
      # for i in range(int(seq_len.shape[0])):
      for i in range(len(seq_len)):
          if self.tag_vocab:
              Pred = ["O"] * int(seq_len[i])
              Target = ["O"] * int(seq_len[i])
              for j, k in enumerate(pred[i]):
                  if k >= 0 and k < seq_len[i]:
                      Pred[j] = self.tag_vocab[int(k)]
              for j, k in enumerate(target[i]):
                  if k >= 0 and k < seq_len[i]:
                      Target[j] = self.tag_vocab[int(k)]
              Pred = self.tag_to_span_func(Pred)
              Target = self.tag_to_span_func(Target)
          else:
              Pred = self.tag_to_span_func(pred[i])
              Target = self.tag_to_span_func(target[i])
  
          self.all_word += len(Target)
          self.pred_word += len(Pred)
          for i, j in Pred:
              for n, m in Target:
                  if i == n and j == m:
                      self.pred_real_word += 1
                      break
  
file_path: textflint/textflint/input/model/metrics/nerspanmetric.py
imports: from abc import ABC
label_desc: Use image node_id 3 for calling the NERSpanMetric obj's underlying member method code with example usage: obj.evaluate(pred, target, seq_len) without return types