def fields_to_vocabs(fields):
    """
    Extract Vocab Dictionary from Fields Dictionary.
       Args:
          fields: A dict mapping field names to Field objects
       Returns:
          vocab: A dict mapping field names to Vocabularies
    """
    vocabs = {}
    for name, field in fields.items():
        if field is not None and 'vocab' in field.__dict__:
            vocabs[name] = field.vocab
    return vocabs
