class_docstr: 评估parser的性能
class_docstr_tok: ["\u8bc4\u4f30parser\u7684\u6027\u80fd"]
code: def get_metric(self, reset=True):
      res = {
          "UAS": self.num_arc * 1.0 / self.num_sample,
          "LAS": self.num_label * 1.0 / self.num_sample,
      }
      if reset:
          self.num_sample = self.num_label = self.num_arc = 0
      return res
  
file_path: fastNLP/tests/models/torch/test_biaffine_parser.py
imports: import pytest
  from fastNLP.envs.imports import _NEED_IMPORT_TORCH
  from fastNLP import Metric, seq_len_to_mask
  from .model_runner import *
label_desc: Use image node_id 2 for calling the ParserMetric obj's underlying member method code with example usage: obj.get_metric(reset) and returns: res