code: def test_ubersum_total(equation, plates):
      inputs, outputs, operands, sizes = make_example(
          equation, fill=1.0, sizes=(2,)
      )
      output = outputs[0]
  
      expected = naive_ubersum(equation, *operands, plates=plates)[0]
      actual = ubersum(
          equation, *operands, plates=plates, modulo_total=True
      )[0]
      expected = _normalize(expected, output, plates)
      actual = _normalize(actual, output, plates)
      assert_equal(
          expected,
          actual,
          msg="Expected:\n{}\nActual:\n{}".format(
              expected.detach().cpu(), actual.detach().cpu()
          ),
      )
  
imports: import itertools
  import numbers
  from collections import OrderedDict
  import opt_einsum
  import pytest
  import torch
  import pyro.ops.jit
  from pyro.distributions.util import logsumexp
  from pyro.ops.contract import _partition_terms, contract_tensor_tree, contract_to_tensor, einsum, naive_ubersum, ubersum
  from pyro.ops.einsum.adjoint import require_backward
  from pyro.ops.rings import LogRing
  from pyro.poutine.indep_messenger import CondIndepStackFrame
  from pyro.util import optional
  from tests.common import assert_equal
label_desc: Use image node_id 14 for calling a global function with example usage: test_ubersum_total(equation, plates) without return types