code: def test_pos_metric(self):
      pred = np.array([[1, 2, 1], [2, 1, 1]])
      gold = np.array([[1, 2, 0], [1, 1, 0]])
      pos_metric = POSMetric()
      score = pos_metric(pred, gold, ignore_label_id=0)
      self.assertEqual(0.75, score["precision"])
  
imports: import unittest
  from textflint.input.model.metrics.metrics import *
  import numpy
label_desc: Use image node_id 2 for calling the TestMetrics obj's underlying member method code with example usage: obj.test_pos_metric() without return types