INNER CODE UNIT · Python

_load_backends

vacancy/SceneGraphParser · sng_parser/parser.py:15

def _load_backends():
    from . import backends


class Parser(object):
    """
    The scene graph parser. To instantiate a scene graph parser,
    you need to specify a backend (default: spacy) and the initialization
    keyword arguments for the backend (optional).

    Once the backend has been specified, you can call parser.parse(sentence)
    to parse a sentence in natural language into a scene graph.
    Note that, the function `parse` also supports extra keyword arguments
    which will be passed to the backend for the parsing.
    To use this feature, you may refer to the implementation of your parser
    backend.

    Example::

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…