code: def iterate_function(outputs, side):
      funcs = []
  
      def visitor(f):
          if f.name != "Sink":
              funcs.append(f)
  
      if isinstance(outputs, nn.Variable):
          outputs.visit(visitor)
      else:
          y = F.sink(*outputs)
          y.visit(visitor)
  
      for f in funcs:
          yield f
  
imports: import os
  import io
  import pytest
  import numpy
  import nnabla
  import nnabla.functions
  from nnabla.testing import assert_allclose
  from contextlib import contextmanager
  from shutil import rmtree
  import tempfile
  import numpy
  import warnings
  from legacy_expander import NnpExpander
  from nnabla.utils import nnabla_pb2
  from legacy_load import _create_variable
  import google.protobuf.text_format
  from nnabla.utils.image_utils import imsave
  from nnabla.utils.get_file_handle import get_file_handle_save
  from nnabla.utils.nnp_format import nnp_version
label_desc: Use image node_id 3 for calling a global function with example usage: iterate_function(outputs, side) without return types