code: def safe_import(mod_name: str, min_version: str | None = None):
      """
      Parameters
      ----------
      mod_name : str
          Name of the module to be imported
      min_version : str, default None
          Minimum required version of the specified mod_name
  
      Returns
      -------
      object
          The imported module if successful, or False
      """
      try:
          mod = __import__(mod_name)
      except ImportError:
          return False
      except SystemError:
          # TODO: numba is incompatible with numpy 1.24+.
          # Once that's fixed, this block should be removed.
          if mod_name == "numba":
              return False
          else:
              raise
  
      if not min_version:
          return mod
      else:
          import sys
  
          try:
              version = getattr(sys.modules[mod_name], "__version__")
          except AttributeError:
              # xlrd uses a capitalized attribute name
              version = getattr(sys.modules[mod_name], "__VERSION__")
          if version and Version(version) >= Version(min_version):
              return mod
  
      return False
  
imports: from __future__ import annotations
  import locale
  from typing import Callable
  import numpy
  import pytest
  from pandas._config import get_option
  from pandas._typing import F
  from pandas.compat import IS64, is_platform_windows
  from pandas.compat._optional import import_optional_dependency
  from pandas.core.computation.expressions import NUMEXPR_INSTALLED, USE_NUMEXPR
  from pandas.util.version import Version
label_desc: Use image node_id 1 for calling a global function with example usage: safe_import(mod_name, min_version) and returns: False, mod, False, mod, False