code: def test_feat_label_dataset(self):
      with tempfile.TemporaryDirectory() as tmpdir:
          manifest_path = os.path.join(tmpdir, "manifest_input.json")
          with open(manifest_path, "w", encoding="utf-8") as fp:
              for i in range(2):
                  feat_file = os.path.join(tmpdir, f"feat_{i}.pt")
                  torch.save(torch.randn(80, 5), feat_file)
                  entry = {
                      "feature_file": feat_file,
                      "duration": 100000,
                      "label": "0",
                  }
                  fp.write(json.dumps(entry) + "\n")
  
          dataset = FeatureToLabelDataset(
              manifest_filepath=manifest_path,
              labels=self.unique_labels_in_seq,
          )
  
          correct_label = torch.tensor(
              self.unique_labels_in_seq.index("0")
          )
          correct_label_length = torch.tensor(1)
  
          assert dataset[0][0].shape == (80, 5)
          assert torch.equal(dataset[0][2], correct_label)
          assert torch.equal(dataset[0][3], correct_label_length)
  
          count = 0
          for _ in dataset:
              count += 1
          assert count == 2
  
file_path: NeMo/tests/collections/asr/test_label_datasets.py
imports: import json
  import os
  import tempfile
  import numpy
  import pytest
  import soundfile
  import torch
  from nemo.collections.asr.data.audio_to_label import AudioToMultiLabelDataset, TarredAudioToClassificationLabelDataset
  from nemo.collections.asr.data.feature_to_label import FeatureToLabelDataset, FeatureToSeqSpeakerLabelDataset
  from nemo.collections.asr.parts.preprocessing.feature_loader import ExternalFeatureLoader
  from nemo.collections.asr.parts.preprocessing.features import WaveformFeaturizer
label_desc: Use image node_id 4 for calling the TestASRDatasets obj's underlying member method code with example usage: obj.test_feat_label_dataset() without return types