class_docstr: TestCase for analyzers execution
  
  TestCase that applies two method to several networks and
  runs the analyzer with random data and checks for equality
  of the results.
  
  :param method1: A function that returns an Analyzer class.
  :param method2: A function that returns an Analyzer class.
code: def _apply_test(self, model: Model) -> None:
      # Generate random training input
      input_shape = model.input_shape[1:]
      x = np.random.rand(1, *input_shape).astype(np.float32)
      # Call model with test input
      model.predict(x)
      # Get analyzer.
      analyzer1 = self._method1(model)
      analyzer2 = self._method2(model)
      # Dryrun.
      analysis1 = analyzer1.analyze(x)
      analysis2 = analyzer2.analyze(x)
  
      assert tuple(analysis1.shape) == (1,) + input_shape
      assert not np.any(np.isinf(analysis1.ravel()))
      assert not np.any(np.isnan(analysis1.ravel()))
  
      assert tuple(analysis2.shape) == (1,) + input_shape
      assert not np.any(np.isinf(analysis2.ravel()))
      assert not np.any(np.isnan(analysis2.ravel()))
      assert np.allclose(analysis1, analysis2)
  
imports: from __future__ import annotations
  from typing import Callable
  import numpy
  import tensorflow
  import tensorflow.keras.backend
  from innvestigate.analyzer import Random
  from innvestigate.analyzer.base import AnalyzerBase
  from innvestigate.backend.types import Model
  from tests import networks
label_desc: Use image node_id 4 for calling the EqualAnalyzerTestCase obj's underlying member method code with example usage: obj._apply_test(model) without return types