def get_backend_instance(self, backend: BackendDefinitionType) -> BaseBackend:
if backend is NOT_SET:<EOL><INDENT>backend = self.get_setting("<STR_LIT>", "<STR_LIT>")<EOL><DEDENT>if isinstance(backend, str):<EOL><INDENT>backend = load_class(backend)<EOL><DEDENT>if callable(backend):<EOL><INDENT>backend = backend()<EOL><DEDENT>if not issubclass(type(backend), BaseBackend):<EOL><INDENT>raise ArcaMisconfigured(f"<STR_LIT>")<EOL><DEDENT>return backend<EOL>
Returns a backend instance, either from the argument or from the settings.

        :raise ArcaMisconfigured: If the instance is not a subclass of :class:`BaseBackend`