code: def get_sample_small(cls) -> "RnntLossSampleData":
      activations = np.array(
          [
              [
                  [
                      [0.1, 0.6, 0.1, 0.1, 0.1],
                      [0.1, 0.1, 0.6, 0.1, 0.1],
                      [0.1, 0.1, 0.2, 0.8, 0.1],
                  ],
                  [
                      [0.1, 0.6, 0.1, 0.1, 0.1],
                      [0.1, 0.1, 0.2, 0.1, 0.1],
                      [0.7, 0.1, 0.2, 0.1, 0.1],
                  ],
              ]
          ]
      )
      labels = np.asarray([[1, 2]])
  
      expected_cost = [4.495666]
      expected_grads = np.array(
          [
              [
                  [
                      [
                          -0.13116688,
                          -0.3999269,
                          0.17703125,
                          0.17703125,
                          0.17703125,
                      ],
                      [
                          -0.18572757,
                          0.12247056,
                          -0.18168412,
                          0.12247056,
                          0.12247056,
                      ],
                      [
                          -0.32091254,
                          0.06269141,
                          0.06928472,
                          0.12624499,
                          0.06269141,
                      ],
                  ],
                  [
                      [
                          0.05456069,
                          -0.21824276,
                          0.05456069,
                          0.05456069,
                          0.05456069,
                      ],
                      [
                          0.12073959,
                          0.12073959,
                          -0.48295835,
                          0.12073959,
                          0.12073959,
                      ],
                      [
                          -0.6925882,
                          0.16871116,
                          0.18645467,
                          0.16871116,
                          0.16871116,
                      ],
                  ],
              ]
          ]
      )
      return RnntLossSampleData(
          vocab_size=3,
          blank_id=0,
          logits=torch.from_numpy(activations).to(torch.float32),
          targets=torch.from_numpy(labels),
          input_lengths=torch.tensor([2]),
          target_lengths=torch.tensor([2]),
          expected_cost=torch.tensor(expected_cost).to(torch.float32),
          expected_grads=torch.from_numpy(expected_grads),
      )
  
file_path: NeMo/tests/collections/asr/conftest.py
imports: from dataclasses import dataclass
  from typing import Optional, Type
  import numpy
  import pytest
  import torch
label_desc: Use image node_id 1 for calling the RnntLossSampleData obj's underlying member method code with example usage: obj.get_sample_small(cls) and returns: RnntLossSampleData