class_docstr: Speech2Text class
  
  Examples:
      >>> import soundfile
      >>> speech2text = Speech2Text("st_config.yml", "st.pth")
      >>> audio, rate = soundfile.read("speech.wav")
      >>> speech2text(audio)
      [(text, token, token_int, hypothesis object), ...]
class_docstr_tok: ["Speech2Text","class","Examples",":",">",">",">","import","soundfile",">",">",">","speech2text","=","Speech2Text","(","``","st_config.yml","''",",","``","st.pth","''",")",">",">",">","audio",",","rate","=","soundfile.read","(","``","speech.wav","''",")",">",">",">","speech2text","(","audio",")","[","(","text",",","token",",","token_int",",","hypothesis","object",")",",","...","]"]
docstr: Build Speech2Text instance from the pretrained model.
  
  Args:
      model_tag (Optional[str]): Model tag of the pretrained models.
          Currently, the tags of espnet_model_zoo are supported.
  Returns:
      Speech2Text: Speech2Text instance.
docstr_tok: ["Build","Speech2Text","instance","from","the","pretrained","model",".","Args",":","model_tag","(","Optional","[","str","]",")",":","Model","tag","of","the","pretrained","models",".","Currently",",","the","tags","of","espnet_model_zoo","are","supported",".","Returns",":","Speech2Text",":","Speech2Text","instance","."]
code: def from_pretrained(
      model_tag: Optional[str] = None,
      **kwargs: Optional[Any],
  ):
      """Build Speech2Text instance from the pretrained model.
  
      Args:
          model_tag (Optional[str]): Model tag of the pretrained models.
              Currently, the tags of espnet_model_zoo are supported.
      Returns:
          Speech2Text: Speech2Text instance.
  
      """
      if model_tag is not None:
          try:
              from espnet_model_zoo.downloader import ModelDownloader
  
          except ImportError:
              logging.error(
                  "`espnet_model_zoo` is not installed. "
                  "Please install via `pip install -U espnet_model_zoo`."
              )
              raise
          d = ModelDownloader()
          kwargs.update(**d.download_and_unpack(model_tag))
  
      return Speech2Text(**kwargs)
  
imports: import argparse
  import logging
  import sys
  from pathlib import Path
  from typing import Any, List, Optional, Sequence, Tuple, Union
  import numpy
  import torch
  from typeguard import check_argument_types, check_return_type
  from espnet2.asr.transducer.beam_search_transducer import BeamSearchTransducer
  from espnet2.asr.transducer.beam_search_transducer import Hypothesis
  from espnet2.fileio.datadir_writer import DatadirWriter
  from espnet2.tasks.enh_s2t import EnhS2TTask
  from espnet2.tasks.lm import LMTask
  from espnet2.tasks.st import STTask
  from espnet2.text.build_tokenizer import build_tokenizer
  from espnet2.text.token_id_converter import TokenIDConverter
  from espnet2.text.whisper_token_id_converter import OpenAIWhisperTokenIDConverter
  from espnet2.torch_utils.device_funcs import to_device
  from espnet2.torch_utils.set_all_random_seed import set_all_random_seed
  from espnet2.utils import config_argparse
  from espnet2.utils.types import str2bool, str2triple_str, str_or_none
  from espnet.nets.batch_beam_search import BatchBeamSearch
  from espnet.nets.beam_search import BeamSearch, Hypothesis
  from espnet.nets.pytorch_backend.transformer.subsampling import TooShortUttError
  from espnet.nets.scorer_interface import BatchScorerInterface
  from espnet.nets.scorers.ctc import CTCPrefixScorer
  from espnet.nets.scorers.length_bonus import LengthBonus
  from espnet.utils.cli_utils import get_commandline_args
label_desc: Use image node_id 3 for calling the Speech2Text obj's underlying member method code with example usage: obj.from_pretrained(model_tag) and returns: Speech2Text