code: def garnet_stack_models():
      x = Input(shape=(vmax, feat))
      n = Input(shape=(1,), dtype="uint16")
      inputs = [x, n]
      outputs = GarNetStack(
          ([4, 4, 8]),
          ([4, 4, 8]),
          ([8, 8, 16]),
          simplified=True,
          collapse="mean",
          input_format="xn",
          output_activation=None,  # added output_activation_transform back in contrib.garnet.py
          name="gar_1",
          quantize_transforms=None,  # this should be false, not None...fix in contrib.garnet.py
      )(inputs)
      model = Model(inputs=inputs, outputs=outputs)
      model.summary()
  
      config = hls4ml.utils.config_from_keras_model(
          model, granularity="name"
      )
      config["Model"] = {}
      config["Model"]["ReuseFactor"] = 1
      config["Model"]["Strategy"] = "Latency"
      config["Model"]["Precision"] = "ap_fixed<32,6>"
      # config should now have precisions specified for ['LayerName']['gar_1']['Precision']['norm', 'aggr', etc.]
      cfg = hls4ml.converters.create_config(
          output_dir=str(test_root_path / "hls4mlprj_garnet"),
          part="xc7z020clg400-1",
      )
      cfg["HLSConfig"] = config
      cfg["KerasModel"] = model
  
      hls_model = hls4ml.converters.keras_to_hls(cfg)
      hls_model.compile()
      return model, hls_model
  
file_path: hls4ml/test/pytest/test_garnet.py
imports: from pathlib import Path
  import numpy
  import pytest
  from tensorflow.keras.layers import Input
  from tensorflow.keras.models import Model
  import hls4ml
  from contrib.garnet import GarNet, GarNetStack
label_desc: Use image node_id 2 for calling a global function with example usage: garnet_stack_models() and returns: model,  hls_model