code: def generate_ref_data_tflite(model):
      """
      This method generates reference data by running the specified model on tflite with random input data.
      The random input data and generated output data are returned.
      """
      expected_output_data = {}
  
      interpreter = tf.lite.Interpreter(
          model_content=model,
          experimental_op_resolver_type=tf.lite.experimental.OpResolverType.BUILTIN_REF,
      )
  
      interpreter.allocate_tensors()
  
      input_details = interpreter.get_input_details()
      output_details = interpreter.get_output_details()
  
      # Initialize random generators with a fixed seed to get deterministic results
      seed = 0
      random_state = np.random.RandomState(seed)
  
      inputgen = InputGenerator(random_state)
  
      # Generate input data
      input_data = {
          input_detail["name"]: inputgen.generate(
              input_detail["shape"],
              input_detail["dtype"],
          )
          for input_detail in input_details
      }
      input_index = {
          input_detail["name"]: input_detail["index"]
          for input_detail in input_details
      }
  
      for input_name in input_data.keys():
          data = input_data[input_name]
          index = input_index[input_name]
          interpreter.set_tensor(index, data)
      interpreter.invoke()
  
      expected_output_data = {
          output_detail["name"]: interpreter.get_tensor(
              output_detail["index"]
          )
          for output_detail in output_details
      }
  
      return input_data, expected_output_data
  
imports: from typing import List
  import os
  import struct
  import numpy
  import math
  from enum import IntEnum
  import tensorflow
  from ethosu.vela.register_command_stream_generator import CmdMode
  from ethosu.vela.register_command_stream_generator import cmd0
  from ethosu.vela.register_command_stream_generator import cmd1
  import tvm
  from tvm import relay
  import tvm.relay.backend.contrib.ethosu.op
  from tvm.topi.nn.utils import get_pad_tuple
  from tvm.relay.expr_functor import ExprMutator
  from tvm.relay.op.annotation import compiler_begin, compiler_end
  from tvm.relay.backend.contrib.ethosu import preprocess
  import tvm.relay.testing.tf
  from tvm import WorkspaceMemoryPools, WorkspacePoolInfo, PoolInfoProperties
  from tvm.relay.op.contrib.ethosu import partition_for_ethosu
  from tvm.testing.aot import AOTCompiledTestModel, AOTDataLinkage, AOTTestModel, AOTTestRunner, compile_models, run_and_check
label_desc: Use image node_id 8 for calling a global function with example usage: generate_ref_data_tflite(model) and returns: input_data,  expected_output_data