code: def get_scores(self):
      tag_set = self.get_tag_set()
  
      corpus_scores = {s: {} for s in self.metrics}
      group_scores = {s: {t: {} for t in tag_set} for s in self.metrics}
      sent_scores = {s: {} for s in self.metrics}
      for s in self.metrics:
          for i, m in enumerate(self.models):
              cur = _get_scores(self.dir_path, s, m)
              cur = [
                  cur.corpus_score,
                  cur.group_scores,
                  cur.sent_scores,
              ]
              corpus_scores[s][m] = cur[0]
              for t in tag_set:
                  group_scores[s][t][m] = cur[1][t]
              sent_scores[s][m] = cur[2]
  
      scores = {
          "corpus_scores": corpus_scores,
          "group_scores": group_scores,
          "sent_scores": sent_scores,
          "corpus_group_scores_latex": self.latex_corpus_group_scores(
              corpus_scores, group_scores
          ),
          "corpus_group_scores_csv": self.csv_corpus_group_scores(
              corpus_scores, group_scores
          ),
      }
      return json.dumps(scores)
  
imports: from typing import List, Tuple, Iterable
  import math
  import os
  import os.path
  from glob import glob
  import json
  from vizseq._data import VizSeqTaskConfigManager, VizSeqGlobalConfigManager, VizSeqStats, set_g_cred_path, VizSeqTableExporter, VizSeqNGrams, VizSeqTokenization
  from vizseq.scorers import get_scorer_name, get_scorer_ids_and_names
  from .data_view import VizSeqDataPageView, VizSeqPageData
  from .mem_cached_data_getters import _get_src, _get_ref, _get_tag, _get_hypo, _get_scores
label_desc: Use image node_id 9 for calling the VizSeqWebView obj's underlying member method code with example usage: obj.get_scores() and returns: json