code: def test_word_embeddings(self) -> None:
      embedding_list = configure_model_integ_grads_embeddings(
          self.model
      )
      integrated_gradients_embedding = embedding_list[0]
      input = torch.arange(0, 300).unsqueeze(0).unsqueeze(0)
      self.assertEqual(
          integrated_gradients_embedding.embedding_dim, 300
      )
      self.assertEqual(embedding_list.embedding_dim[0], 300)
      self.assertEqual(embedding_list(input).shape[2], input.shape[2])
      self.assertTrue(
          torch.allclose(
              integrated_gradients_embedding.get_attribution_map(input)[
                  "word"
              ],
              input,
          )
      )
  
file_path: captum/tests/attr/models/test_pytext.py
imports: from __future__ import print_function
  import os
  import tempfile
  import unittest
  from typing import Dict, List
  import torch
label_desc: Use image node_id 3 for calling the TestWordEmbeddings obj's underlying member method code with example usage: obj.test_word_embeddings() without return types