@classmethod
def from_tokens(cls, tokens, **init_kwargs):
    """
        Create a new TMPreproc instance by loading `tokens` in the same format as they are returned by
        :attr:`~TMPreproc.tokens` or :attr:`~TMPreproc.tokens_with_metadata`, i.e. as dict with mapping: document
        label -> document tokens array or document data frame.

        :param tokens: dict of tokens as returned by :attr:`~TMPreproc.tokens` o
                       :attr:`~TMPreproc.tokens_with_metadata`
        :param init_kwargs: dict of arguments passed to :meth:`~TMPreproc.__init__`
        :return: new instance with passed tokens
        """
    if 'docs' in init_kwargs.keys():
        raise ValueError(
            '`docs` cannot be passed as argument when loading tokens')
    init_kwargs['docs'] = None
    return cls(**init_kwargs).load_tokens(tokens)
