docs: def recall_score(gold, pred, pos_label=1, ignore_in_gold=[], ignore_in_pred=[]):
      """
      Calculate recall for a single class.
      Args:
          gold: A 1d array-like of gold labels
          pred: A 1d array-like of predicted labels (assuming abstain = 0)
          ignore_in_gold: A list of labels for which elements having that gold
              label will be ignored.
          ignore_in_pred: A list of labels for which elements having that pred
              label will be ignored.
          pos_label: The class label to treat as positive for recall
  
      Returns:
          rec: The (float) recall score
      """
      gold, pred = _preprocess(gold, pred, ignore_in_gold, ignore_in_pred)
  
      positives = np.where(pred == pos_label, 1, 0).astype(bool)
      trues = np.where(gold == pos_label, 1, 0).astype(bool)
      TP = np.sum(positives * trues)
      FN = np.sum(np.logical_not(positives) * trues)
  
      if TP or FN:
          rec = TP / (TP + FN)
      else:
          rec = 0
  
      return rec