code: def _int_to_enum(value, enum_klass):
      """Convert a numeric value to an IntEnum member.
      If it's not a known member, return the numeric value itself.
      """
      try:
          return enum_klass(value)
      except ValueError:
          return value
  
file_path: catboost/contrib/tools/python3/src/Lib/signal.py
imports: import _signal
  from _signal import *
  from enum import IntEnum
label_desc: Use image node_id 1 for calling a global function with example usage: _int_to_enum(value, enum_klass) and returns: enum_klass, value