class_docstr: An abstract class representing a metric which accumulates TPs, FPs, and FNs.
  
  :param average: This determines the type of averaging performed            on the data: 'micro' (calculate metrics globally by
  counting the total true positives, false negatives and false positives)            , 'macro' (calculate metrics for each label,
  and find their unweighted mean).
class_docstr_tok: ["An","abstract","class","representing","a","metric","which","accumulates","TPs",",","FPs",",","and","FNs",".",":","param","average",":","This","determines","the","type","of","averaging","performed","on","the","data",":","'micro","'","(","calculate","metrics","globally","by","counting","the","total","true","positives",",","false","negatives","and","false","positives",")",",","'macro","'","(","calculate","metrics","for","each","label",",","and","find","their","unweighted","mean",")","."]
code: def __init__(self, average: str = "micro"):
      # These will hold per span label counts.
      self._true_positives: Dict[str, float] = defaultdict(float)
      self._false_positives: Dict[str, float] = defaultdict(float)
      self._false_negatives: Dict[str, float] = defaultdict(float)
      self._average = average
  
imports: from collections import defaultdict
  from copy import copy
  from typing import Dict, List, Set, Tuple
  from .distance import Distance
label_desc: Use image node_id 1 to create a new ErrorMetric object  with example: obj = ErrorMetric(average)