code: def test_ensembler(aggregator, normalizer):
      """Test the Ensembler for each combination of aggregator and normalizer
  
      - Test the ensembler correctly aggregates and normalizes the scores
      - Test the ensembler can be torch scripted
      """
      aggregator = getattr(ensemble, aggregator)()
      normalizer = getattr(ensemble, normalizer)()
      ensembler = ensemble.Ensembler(
          aggregator=aggregator, normalizer=normalizer
      )
  
      x = torch.randn(3, 10)
      x_ref = torch.randn(64, 10)
  
      # test the ensembler correctly aggregates and normalizes the scores
      ensembler.fit(x_ref)
      x_norm = ensembler(x)
  
      # test the scriptability of the ensembler
      ensembler = torch.jit.script(ensembler)
      x_norm_2 = ensembler(x)
      assert torch.all(x_norm_2 == x_norm)
  
file_path: alibi-detect/alibi_detect/od/tests/test_ensemble.py
imports: import pytest
  import torch
  from alibi_detect.od.pytorch import ensemble
  from alibi_detect.exceptions import NotFittedError
label_desc: Use image node_id 8 for calling a global function with example usage: test_ensembler(aggregator, normalizer) without return types