code: def test_get_dimension_is_correct(self):
      encoder = StackedSelfAttentionEncoder(
          input_dim=9,
          hidden_dim=12,
          projection_dim=6,
          feedforward_hidden_dim=5,
          num_layers=3,
          num_attention_heads=3,
      )
      assert encoder.get_input_dim() == 9
      # hidden_dim + projection_dim
      assert encoder.get_output_dim() == 12
  
file_path: magnitude/pymagnitude/third_party/allennlp/tests/modules/seq2seq_encoders/stacked_self_attention_test.py
imports: from __future__ import absolute_import
  import torch
  from allennlp.common.testing import AllenNlpTestCase
  from allennlp.modules.seq2seq_encoders import StackedSelfAttentionEncoder
label_desc: Use image node_id 1 for calling the TestStackedSelfAttention obj's underlying member method code with example usage: obj.test_get_dimension_is_correct() without return types