class_docstr: ASR Task 
class_docstr_tok: ["ASR","Task"]
code: def dataset(
      self, mode, batch_size, epoch
  ):  # pylint: disable=arguments-differ
      if batch_size != self.batch_size:
          logging.warning(
              "dataset: batch_size not equal to config: {} {}".format(
                  batch_size, self.batch_size
              )
          )
  
      types, shapes, values = self.feature_spec(batch_size)
      logging.debug(
          "dtypes: {} shapes: {} values: {}".format(
              types, shapes, values
          )
      )
  
      if self.dummy:
          logging.info("Dummy data: dataset")
          dss = []
          for i in range(len(shapes)):
              dss.append(
                  utils.generate_synthetic_data(
                      input_shape=shapes[i],
                      input_value=values[i],
                      input_dtype=types[i],
                      nepoch=epoch,
                  )
              )
          ds = tf.data.Dataset.zip(tuple(dss))
      else:
          del values
          ds = tf.data.Dataset.from_generator(
              generator=lambda: self.generate_data(),  # pylint: disable=unnecessary-lambda
              output_types=types,
              output_shapes=shapes,
          )
  
          if mode == utils.TRAIN:
              if self._need_shuffle:
                  ds = ds.shuffle(self._shuffle_buffer_size, seed=None)
              ds = ds.repeat(count=epoch)
  
          if not self.batch_mode:
              ds = ds.padded_batch(
                  batch_size,
                  padded_shapes=shapes,
                  padding_values=None,
                  drop_remainder=True if mode == utils.TRAIN else False,
              )  # pylint: disable=simplifiable-if-expression
  
      ds = ds.map(_make_example)
      ds = ds.prefetch(tf.data.experimental.AUTOTUNE)
      return ds
  
imports: import numpy
  import delta.compat
  from absl import logging
  from delta import utils
  from delta.data.utils import espnet_utils
  from delta.utils.register import registers
  from delta.data.task.base_speech_task import SpeechTask
label_desc: Use image node_id 15 for calling the AsrSeqTask obj's underlying member method code with example usage: obj.dataset(mode, batch_size, epoch) and returns: ds