code: def test_effective_complexity(
      model: ModelInterface,
      data: dict,
      params: dict,
      expected: Union[float, dict, bool],
  ):
      init_params = params.get("init", {})
      call_params = params.get("call", {})
  
      scores = EffectiveComplexity(**init_params)(
          model=model,
          x_batch=data["x_batch"],
          y_batch=data["y_batch"],
          a_batch=data.get("a_batch"),
          **call_params,
      )
      assert scores is not None, "Test failed."
  
file_path: Quantus/tests/metrics/test_complexity_metrics.py
imports: from typing import Union
  import pytest
  from pytest_lazyfixture import lazy_fixture
  import numpy
  from quantus.functions.explanation_func import explain
  from quantus.helpers.model.model_interface import ModelInterface
  from quantus.metrics.complexity import Complexity, EffectiveComplexity, Sparseness
label_desc: Use image node_id 4 for calling a global function with example usage: test_effective_complexity(model, data, params, expected) without return types