code: def safe_import(mod_name, min_version=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
  
      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:
              from distutils.version import LooseVersion
  
              if LooseVersion(version) >= LooseVersion(min_version):
                  return mod
  
      return False
  
file_path: catboost/contrib/python/pandas/py2/pandas/util/_test_decorators.py
imports: from distutils.version import LooseVersion
  import locale
  import pytest
  from pandas.compat import PY3, import_lzma, is_platform_32bit, is_platform_windows
  from pandas.compat.numpy import _np_version_under1p15
  from pandas.core.computation.expressions import _NUMEXPR_INSTALLED, _USE_NUMEXPR
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