docstr: Check that method `forward` produces correctly-shaped outputs.
docstr_tok: ["Check","that","method","`","forward","`","produces","correctly-shaped","outputs","."]
code: def test_output_shape_forward(self):
      r"""Check that method `forward` produces correctly-shaped outputs."""
      input_dim = 128
      batch_size = 10
      num_frames = 123
      right_context_length = 9
  
      emformer = self.gen_model(input_dim, right_context_length)
      input, lengths = self.gen_inputs(
          input_dim, batch_size, num_frames, right_context_length
      )
  
      output, output_lengths = emformer(input, lengths)
  
      self.assertEqual(
          (batch_size, num_frames - right_context_length, input_dim),
          output.shape,
      )
      self.assertEqual((batch_size,), output_lengths.shape)
  
file_path: audio/test/torchaudio_unittest/models/emformer/emformer_test_impl.py
imports: from abc import ABC, abstractmethod
  import torch
  from torchaudio.models import Emformer
  from torchaudio_unittest.common_utils import TestBaseMixin, torch_script
label_desc: Use image node_id 6 for calling the EmformerTestMixin obj's underlying member method code with example usage: obj.test_output_shape_forward() without return types