gatelfdata.vocabs module

Module for the Voabs class

class gatelfdata.vocabs.Vocabs(remove_counts=True, remove_embs=True)[source]

Bases: object

A class for managing all the vocab instances that are needed by features

finish()[source]

Once all the counts have been gathered, create the final instances

get_vocab(attrinfo_or_embid)[source]

Return a vocab instance for the given attribute name or embedding id.

setup_vocab(attrinfo, featurestats)[source]

Create or update the temporary Vocab instances so that the counts from different attributes get merged