code: def mxnet_compare(fun, pre1, pre2, post1, post2):
      mxnet_pre1 = [mxnd.array(pre1.at(i)) for i in range(BATCH_SIZE)]
      mxnet_pre2 = [mxnd.array(pre2.at(i)) for i in range(BATCH_SIZE)]
      mxnet_post1, mxnet_post2 = fun(mxnet_pre1, mxnet_pre2)
      for i in range(BATCH_SIZE):
          assert numpy.array_equal(
              post1.at(i), mxnet_post1[i].asnumpy()
          )
          assert numpy.array_equal(
              post2.at(i), mxnet_post2[i].asnumpy()
          )
  
imports: import numpy
  import nvidia.dali.ops
  import nvidia.dali.types
  import os
  import random
  from functools import partial
  from nvidia.dali.pipeline import Pipeline
  from nvidia.dali import fn, pipeline_def
  from nvidia.dali.python_function_plugin import current_dali_stream
label_desc: Use image node_id 15 for calling a global function with example usage: mxnet_compare(fun, pre1, pre2, post1, post2) without return types