code: def test_combine_heuristics(heuristic1, heuristic2, weights):
      np.random.seed(1337)
      predictions = [distributions_3d, distributions_5d]
  
      with pytest.raises(ValueError) as excinfo:
          heuristic1(predictions)
      assert "CombineHeuristics" in str(excinfo.value)
  
      if isinstance(heuristic1, Certainty) and not isinstance(
          heuristic2, Certainty
      ):
          with pytest.raises(Exception) as e_info:
              heuristics = CombineHeuristics(
                  [heuristic1, heuristic2],
                  weights=weights,
                  reduction="mean",
              )
              assert (
                  "heuristics should have the same value for `revesed` parameter"
                  in str(e_info.value)
              )
      else:
          heuristics = CombineHeuristics(
              [heuristic1, heuristic2],
              weights=weights,
              reduction="mean",
          )
          if isinstance(heuristic1, Certainty) and isinstance(
              heuristic2, Certainty
          ):
              assert not heuristics.reversed
          else:
              assert heuristics.reversed
          ranks = heuristics(predictions)
          assert np.all(
              ranks == [1, 2, 0]
          ), "Combine Heuristics is not right {}".format(ranks)
  
imports: import warnings
  import numpy
  import pytest
  from hypothesis import given
  from torch_hypothesis import class_logits
  from baal.active import get_heuristic
  from baal.active.heuristics import Random, BALD, Margin, Entropy, Certainty, Variance, BatchBALD, AbstractHeuristic, requireprobs, Precomputed, CombineHeuristics
  from tests.test_utils import make_fake_dist, make_3d_fake_dist, make_5d_fake_dist
label_desc: Use image node_id 13 for calling a global function with example usage: test_combine_heuristics(heuristic1, heuristic2, weights) without return types