code: def _get_expected_codegen(
      shape, weight_shape, units, dtype, has_bias=False, has_gelu=False
  ):
      output_shape = (shape[0], units)
      name = "nn.dense"
      if has_bias is True:
          name = "bnns.dense_bias"
      if has_bias is True and has_gelu is True:
          name = "bnns.dense_bias_gelu"
  
      node = {
          "op": "kernel",
          "name": name,
          "inputs": [],
          "attrs": {
              "num_outputs": "1",
              "out_dtype": [["float32"]],
              "shape": [[list(output_shape)]],
              "dtype": [[dtype]],
              "units": [[str(units)]],
          },
      }
  
      inputs = [
          {
              "op": "input",
              "name": "",
              "attrs": {
                  "shape": [[list(shape)]],
                  "dtype": [[str(dtype)]],
              },
          },
          {
              "op": "const",
              "name": "",
              "attrs": {
                  "shape": [[list(weight_shape)]],
                  "dtype": [[str(dtype)]],
              },
          },
      ]
  
      if has_bias:
          inputs.append(
              {
                  "op": "const",
                  "name": "",
                  "attrs": {
                      "shape": [[[weight_shape[0]]]],
                      "dtype": [["float32"]],
                  },
              }
          )
  
      input_idx = 0
      for _ in range(len(inputs)):
          node["inputs"].append([input_idx, 0, 0])
          input_idx += 1
      node["attrs"]["num_inputs"] = str(len(inputs))
      inputs.append(node)
      return inputs
  
file_path: tvm/tests/python/contrib/test_bnns/test_dense.py
imports: import numpy
  import math
  import pytest
  import tvm
  from tvm import relay
  from .infrastructure import Device, skip_runtime_test, skip_codegen_test, build_and_run, verify, verify_codegen, generate_trials
label_desc: Use image node_id 2 for calling a global function with example usage: _get_expected_codegen(shape, weight_shape, units, dtype, has_bias, has_gelu) and returns: inputs