docstr: Get precision, recall, f1 based on token overlap between generated and ground_truth sequence
docstr_tok: ["Get","precision",",","recall",",","f1","based","on","token","overlap","between","generated","and","ground_truth","sequence"]
code: def _get_one_f1(generated_field, ground_truth_field):
      """
      Get precision, recall, f1 based on token overlap between generated and ground_truth sequence
      """
      generated_tokens = generated_field.split()
      ground_truth_tokens = ground_truth_field.split()
  
      common = Counter(generated_tokens) & Counter(ground_truth_tokens)
      num_same = sum(common.values())
      if num_same == 0:
          return 0, 0, 0
      precision = 1.0 * num_same / len(generated_tokens)
      recall = 1.0 * num_same / len(ground_truth_tokens)
      f1 = (2 * precision * recall) / (precision + recall)
      return np.array([precision * 100, recall * 100, f1 * 100])
  
file_path: NeMo/nemo/collections/nlp/metrics/dialogue_metrics.py
imports: import json
  from collections import Counter
  import numpy
  from sacrebleu import corpus_bleu
label_desc: Use image node_id 2 for calling the DialogueGenerationMetrics obj's underlying member method code with example usage: obj._get_one_f1(generated_field, ground_truth_field) and returns: np, int,  int,  int