allennlp.modules.token_embedders.empty_embedder#

EmptyEmbedder#

EmptyEmbedder(self) -> None

Assumes you want to completely ignore the output of a TokenIndexer for some reason, and does not return anything when asked to embed it.

You should almost never need to use this; normally you would just not use a particular TokenIndexer. It's only in very rare cases, like simplicity in data processing for language modeling (where we use just one TextField to handle input embedding and computing target ids), where you might want to use this.

Registered as a TokenEmbedder with name "empty".