code: def setUp(self):
      super(TestBasicTextFieldEmbedder, self).setUp()
      self.vocab = Vocabulary()
      self.vocab.add_token_to_namespace("1")
      self.vocab.add_token_to_namespace("2")
      self.vocab.add_token_to_namespace("3")
      self.vocab.add_token_to_namespace("4")
      params = Params(
          {
              "words1": {"type": "embedding", "embedding_dim": 2},
              "words2": {"type": "embedding", "embedding_dim": 5},
              "words3": {"type": "embedding", "embedding_dim": 3},
          }
      )
      self.token_embedder = BasicTextFieldEmbedder.from_params(
          vocab=self.vocab, params=params
      )
      self.inputs = {
          "words1": torch.LongTensor([[0, 2, 3, 5]]),
          "words2": torch.LongTensor([[1, 4, 3, 2]]),
          "words3": torch.LongTensor([[1, 5, 1, 2]]),
      }
  
file_path: magnitude/pymagnitude/third_party/allennlp/tests/modules/text_field_embedders/basic_text_field_embedder_test.py
imports: from __future__ import division
  from __future__ import with_statement
  from __future__ import absolute_import
  import pytest
  import torch
  from allennlp.common import Params
  from allennlp.common.checks import ConfigurationError
  from allennlp.data import Vocabulary
  from allennlp.modules.text_field_embedders import BasicTextFieldEmbedder
  from allennlp.common.testing import AllenNlpTestCase
label_desc: Use image node_id 1 for calling the TestBasicTextFieldEmbedder obj's underlying member method code with example usage: obj.setUp() without return types