code: def convert_mp(mp):
      if hasattr(mp, "mp"):
          mp_left = mp.mp(0)
          mp_right = mp.mp(1)
      else:
          mp_left = mp.mp_nofunc(0)
          mp_right = mp.mp_nofunc(1)
  
      if mp.MUL() or mp.CMD_TIMES() or mp.CMD_CDOT():
          lh = convert_mp(mp_left)
          rh = convert_mp(mp_right)
          return sympy.Mul(lh, rh, evaluate=False)
      elif mp.DIV() or mp.CMD_DIV() or mp.COLON():
          lh = convert_mp(mp_left)
          rh = convert_mp(mp_right)
          return sympy.Mul(
              lh, sympy.Pow(rh, -1, evaluate=False), evaluate=False
          )
      else:
          if hasattr(mp, "unary"):
              return convert_unary(mp.unary())
          else:
              return convert_unary(mp.unary_nofunc())
  
imports: from importlib.metadata import version
  import sympy
  from sympy.external import import_module
  from sympy.printing.str import StrPrinter
  from sympy.physics.quantum.state import Bra, Ket
  from .errors import LaTeXParsingError
label_desc: Use image node_id 5 for calling a global function with example usage: convert_mp(mp) and returns: sympy, sympy, convert_unary, convert_unary