class_docstr: Benchmark class for Flax examples.
  
  This class overrides the behaviour of `self.assert*` methods to be
  deferred instead of failing immediately. This allows for using absltest
  assert methods for checking benchmark target metrics. This is also
  necessary for correctly reporting benchmark results and determining its
  success.
class_docstr_tok: ["Benchmark","class","for","Flax","examples",".","This","class","overrides","the","behaviour","of","`","self.assert","*","`","methods","to","be","deferred","instead","of","failing","immediately",".","This","allows","for","using","absltest","assert","methods","for","checking","benchmark","target","metrics",".","This","is","also","necessary","for","correctly","reporting","benchmark","results","and","determining","its","success","."]
docstr: Setup ran before each test.
docstr_tok: ["Setup","ran","before","each","test","."]
code: def setUp(self):
      """Setup ran before each test."""
      super().setUp()
      self._reported_name = None
      self._reported_wall_time = None
      self._reported_metrics = {}
      self._reported_extras = {}
      self._outstanding_fails = []
  
imports: import functools
  import inspect
  import itertools
  import json
  import os
  import tempfile
  from typing import Dict
  from absl import flags, logging
  from absl.testing import absltest
  from tensorboard.backend.event_processing import directory_watcher, event_file_loader, io_wrapper
  from tensorboard.summary import v1
  from tensorboard.util import tensor_util
  from flax import io
label_desc: Use image node_id 3 for calling the Benchmark obj's underlying member method code with example usage: obj.setUp() without return types