'Initialize a new :class:`.Inspector`.
:param bind: a :class:`~sqlalchemy.engine.Connectable`,
which is typically an instance of
:class:`~sqlalchemy.engine.Engine` or
:class:`~sqlalchemy.engine.Connection`.
For a dialect-specific instance of :class:`.Inspector`, see
:meth:`.Inspector.from_engine`'

def __init__(self, bind):

    self.bind = bind
    if hasattr(bind, 'engine'):
        self.engine = bind.engine
    else:
        self.engine = bind
    if (self.engine is bind):
        bind.connect().close()
    self.dialect = self.engine.dialect
    self.info_cache = {}
