code: def check(self, f, reference=None, verbose=False):
      tmp_dir = tempfile.mkdtemp()
      html_file = pt.join(tmp_dir, "index.html")
      if verbose:
          print(html_file)
      d3v.d3viz(f, html_file)
      assert pt.getsize(html_file) > 0
      if reference:
          assert filecmp.cmp(html_file, reference)
  
file_path: Theano/theano/d3viz/tests/test_d3viz.py
imports: from __future__ import absolute_import, print_function, division
  import numpy
  import os.path
  import tempfile
  import unittest
  import filecmp
  import theano
  import theano.d3viz
  from theano.d3viz.tests import models
  from nose.plugins.skip import SkipTest
  from theano.d3viz.formatting import pydot_imported, pydot_imported_msg
label_desc: Use image node_id 2 for calling the TestD3Viz obj's underlying member method code with example usage: obj.check(f, reference, verbose) without return types