code: def partial_by_order(*args, **kwargs):
      """
      >>> from operator import add, truediv
      >>> partial_by_order(5, function=add, other=[(1, 10)])
      15
      >>> partial_by_order(10, function=truediv, other=[(1, 5)])
      2.0
      >>> partial_by_order(10, function=truediv, other=[(0, 5)])
      0.5
      """
      function = kwargs.pop("function")
      other = kwargs.pop("other")
      args2 = list(args)
      for i, arg in other:
          args2.insert(i, arg)
      return function(*args2, **kwargs)
  
file_path: lightning-flash/src/flash/core/serve/dag/utils.py
imports: import functools
  import re
  from operator import methodcaller
  from flash.core.utilities.imports import _TOPIC_SERVE_AVAILABLE
label_desc: Use image node_id 4 for calling a global function with example usage: partial_by_order() and returns: function