class_docstr: Offer a similar interface as WorkloadResponseInterceptor, except let send() yield a whole
  progression of RUN_STEP and COMPUTE_VALIDATION_METRICS, and let result() return the accumulated
  metrics from each.
class_docstr_tok: ["Offer","a","similar","interface","as","WorkloadResponseInterceptor",",","except","let","send","(",")","yield","a","whole","progression","of","RUN_STEP","and","COMPUTE_VALIDATION_METRICS",",","and","let","result","(",")","return","the","accumulated","metrics","from","each","."]
code: def result(self) -> Tuple[List[Dict[str, Any]], List[Dict[str, Any]]]:
      assert self._training_metrics is not None
      assert self._validation_metrics is not None
      return self._training_metrics, self._validation_metrics
  
imports: import importlib
  import os
  import pathlib
  import re
  import unittest.mock
  from typing import Any, Callable, Dict, List, Optional, Sequence, Tuple, Type
  import numpy
  import pytest
  from mypy_extensions import DefaultNamedArg
  import determined
  from determined import core, gpu, workload
  from determined.common import util
label_desc: Use image node_id 3 for calling the TrainAndValidate obj's underlying member method code with example usage: obj.result() and returns: self,  self