code: def _validate_database(db):
      from hypothesis.database import ExampleDatabase
  
      if db is None or isinstance(db, ExampleDatabase):
          return db
      raise InvalidArgument(
          "Arguments to the database setting must be None or an instance of "
          "ExampleDatabase.  Try passing database=ExampleDatabase(%r), or "
          "construct and use one of the specific subclasses in "
          "hypothesis.database" % (db,)
      )
  
imports: from __future__ import absolute_import, division, print_function
  import contextlib
  import datetime
  import inspect
  import threading
  import warnings
  from enum import Enum, IntEnum, unique
  import attr
  from hypothesis.errors import HypothesisDeprecationWarning, InvalidArgument, InvalidState
  from hypothesis.internal.compat import integer_types, quiet_raise, string_types
  from hypothesis.internal.reflection import get_pretty_function_description
  from hypothesis.internal.validation import check_type, try_convert
  from hypothesis.utils.conventions import UniqueIdentifier, not_set
  from hypothesis.utils.dynamicvariables import DynamicVariable
label_desc: Use image node_id 5 for calling a global function with example usage: _validate_database(db) and returns: db