code: def is_open_mpi_installed():
      command = "mpirun --version"
      try:
          output_msg = str(
              subprocess.check_output(
                  shlex.split(command), universal_newlines=True
              )
          )
      except Exception:  # pylint disable=broad-except
          print(
              "Was not able to run %s:\n%s" % (command, output_msg),
              file=sys.stderr,
          )
          print(traceback.format_exc(), file=sys.stderr)
          return False
  
      if "Open MPI" not in output_msg:
          print(
              "Open MPI not found in output of mpirun --version.",
              file=sys.stderr,
          )
          return False
      return True
  
file_path: bluefog/bluefog/run/env_util.py
imports: import re
  import shlex
  import subprocess
  import sys
  import traceback
label_desc: Use image node_id 2 for calling a global function with example usage: is_open_mpi_installed() and returns: True, False, False