code: def _on_missing(on_missing, msg, name="on_missing", error_klass=None):
      _check_on_missing(on_missing, name)
      error_klass = ValueError if error_klass is None else error_klass
      on_missing = "raise" if on_missing == "error" else on_missing
      on_missing = "warn" if on_missing == "warning" else on_missing
      if on_missing == "raise":
          raise error_klass(msg)
      elif on_missing == "warn":
          warn(msg)
      else:  # Ignore
          assert on_missing == "ignore"
  
imports: import numbers
  import operator
  import os
  import re
  from builtins import input
  from difflib import get_close_matches
  from importlib import import_module
  from pathlib import Path
  import numpy
  from ..defaults import HEAD_SIZE_DEFAULT, _handle_default
  from ..fixes import _compare_version, _median_complex
  from ._logging import _record_warnings, _verbose_safe_false, logger, verbose, warn
label_desc: Use image node_id 48 for calling a global function with example usage: _on_missing(on_missing, msg, name, error_klass) without return types