code: def test_tflite_split_legalize(ifm_shape, num_or_size_splits, axis):
      dtype = "int8"
  
      def create_tflite_graph():
          class Model(tf.Module):
              @tf.function
              def tf_function(self, x, num_or_size_splits, axis):
                  op = tf.split(x, num_or_size_splits, axis=axis)
                  return op
  
          model = Model()
          concrete_func = model.tf_function.get_concrete_function(
              tf.TensorSpec(ifm_shape, tf.float32),
              num_or_size_splits,
              axis,
          )
  
          def representative_dataset():
              for _ in range(100):
                  data = np.random.rand(*tuple(ifm_shape))
                  yield [data.astype(np.float32)]
  
          converter = tf.lite.TFLiteConverter.from_concrete_functions(
              [concrete_func]
          )
          converter.optimizations = [tf.lite.Optimize.DEFAULT]
          converter.representative_dataset = representative_dataset
          converter.target_spec.supported_ops = [
              tf.lite.OpsSet.TFLITE_BUILTINS_INT8
          ]
          converter.inference_input_type = tf.int8
          converter.inference_output_type = tf.int8
          tflite_model = converter.convert()
  
          return tflite_model
  
      def verify(ext_func):
          # dig out the split
          single_output_split = num_or_size_splits == 1
          split = (
              ext_func.body.tuple_value
              if single_output_split
              else ext_func.body.args[0][0].args[0].tuple_value
          )
          assert split.op.name == "split"
  
          # Split is specified by number of equal chunks
          assert split.attrs.indices_or_sections == num_or_size_splits
  
          assert split.attrs.axis == axis
  
      tflite_graph = create_tflite_graph()
      tflite_model = tflite.Model.Model.GetRootAsModel(tflite_graph, 0)
  
      mod, _ = relay.frontend.from_tflite(
          tflite_model,
          shape_dict={"input": ifm_shape},
          dtype_dict={"input": dtype},
      )
      mod = ethosu.partition_for_ethosu(mod)
  
      mod["tvmgen_default_ethos_u_main_0"] = dataflow_pattern.rewrite(
          legalize.PartitionedSplitRewriter(),
          mod["tvmgen_default_ethos_u_main_0"],
      )
  
      mod[
          "tvmgen_default_ethos_u_main_0"
      ] = relay.transform.InferType()(mod)[
          "tvmgen_default_ethos_u_main_0"
      ]
  
      verify(mod["tvmgen_default_ethos_u_main_0"])
  
imports: import pytest
  import math
  import numpy
  import tensorflow
  import tflite.Model
  import tvm
  from tvm import relay
  from tvm.relay.backend.contrib.ethosu import legalize, preprocess
  from tvm.relay import dataflow_pattern
  from tvm.relay.op.contrib import ethosu
  from tvm.relay.backend.contrib.ethosu import util, codegen
  from tvm.relay.build_module import bind_params_by_name
  from tvm.relay.frontend.tflite import get_pad_value
  from tvm.relay.expr_functor import ExprVisitor
  from .None import infra
label_desc: Use image node_id 27 for calling a global function with example usage: test_tflite_split_legalize(ifm_shape, num_or_size_splits, axis) and returns: tflite_model, op