code: def test_count_vocab_items_uses_ner_tags(self):
      tokens = self.tokenizer.split_words(
          "Larry Page is CEO of Google."
      )
      tokens = [Token("<S>")] + [t for t in tokens] + [Token("</S>")]
      indexer = NerTagIndexer()
      counter = defaultdict(lambda: defaultdict(int))
      for token in tokens:
          indexer.count_vocab_items(token, counter)
      assert counter["ner_tags"] == {"PERSON": 2, "ORG": 1, "NONE": 6}
  
file_path: magnitude/pymagnitude/third_party/allennlp/tests/data/token_indexers/ner_tag_indexer_test.py
imports: from __future__ import absolute_import
  from collections import defaultdict
  from allennlp.common.testing import AllenNlpTestCase
  from allennlp.data import Token, Vocabulary
  from allennlp.data.token_indexers import NerTagIndexer
  from allennlp.data.tokenizers.word_splitter import SpacyWordSplitter
label_desc: Use image node_id 2 for calling the TestNerTagIndexer obj's underlying member method code with example usage: obj.test_count_vocab_items_uses_ner_tags() without return types