
'''simple docstring'''




import operator as op


lowercase			:				List[Any]    		=			'scaler.pt'
lowercase			:				Dict    		=			'pytorch_model'
lowercase			:				int    		=			'random_states'
lowercase			:				List[str]    		=			'optimizer'
lowercase			:				List[Any]    		=			'scheduler'
lowercase			:				int    		=			'pytorch_model.bin'
lowercase			:				Optional[int]    		=			'pytorch_model.bin.index.json'
lowercase			:				str    		=			'model.safetensors'
lowercase			:				List[str]    		=			'model.safetensors.index.json'
lowercase			:				Optional[int]    		=			'1.10.2'
lowercase			:				Optional[Any]    		=			'py38'
lowercase			:				List[Any]    		=			'4.17.0'
lowercase			:				Tuple    		=			['ml.p3.16xlarge', 'ml.p3dn.24xlarge', 'ml.p4dn.24xlarge']
lowercase			:				Optional[Any]    		=			['FULL_SHARD', 'SHARD_GRAD_OP', 'NO_SHARD', 'HYBRID_SHARD', 'HYBRID_SHARD_ZERO2']
lowercase			:				Dict    		=			['TRANSFORMER_BASED_WRAP', 'SIZE_BASED_WRAP', 'NO_WRAP']
lowercase			:				int    		=			['BACKWARD_PRE', 'BACKWARD_POST', 'NO_PREFETCH']
lowercase			:				str    		=			['FULL_STATE_DICT', 'LOCAL_STATE_DICT', 'SHARDED_STATE_DICT']
lowercase			:				int    		=			'2.0.1'
lowercase			:				int    		=			['pdsh', 'standard', 'openmpi', 'mvapich']
lowercase			:				Union[str, Any]    		=			['default', 'reduce-overhead', 'max-autotune']

lowercase			:				str    		=			{'>': op.gt, '>=': op.ge, '==': op.eq, '!=': op.ne, '<=': op.le, '<': op.lt}

# These are the args for `torch.distributed.launch` for pytorch < 1.9
lowercase			:				int    		=			[
    'nnodes',
    'nproc_per_node',
    'rdzv_backend',
    'rdzv_endpoint',
    'rdzv_id',
    'rdzv_conf',
    'standalone',
    'max_restarts',
    'monitor_interval',
    'start_method',
    'role',
    'module',
    'm',
    'no_python',
    'run_path',
    'log_dir',
    'r',
    'redirects',
    't',
    'tee',
    'node_rank',
    'master_addr',
    'master_port',
]

lowercase			:				List[Any]    		=			['DEEPSPEED', 'MULTI_GPU', 'FSDP', 'MEGATRON_LM']
lowercase			:				Optional[Any]    		=			['DEEPSPEED', 'MULTI_XPU', 'FSDP']






'''simple docstring'''




from typing import TYPE_CHECKING

from ...utils import (
    OptionalDependencyNotAvailable,
    _LazyModule,
    is_sentencepiece_available,
    is_speech_available,
    is_tf_available,
    is_torch_available,
)


lowercase			:				Dict    		=			{
    'configuration_speech_to_text': ['SPEECH_TO_TEXT_PRETRAINED_CONFIG_ARCHIVE_MAP', 'Speech2TextConfig'],
    'processing_speech_to_text': ['Speech2TextProcessor'],
}

try:
      if not is_sentencepiece_available():
            raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
      pass
else:
      lowercase			:				List[Any]    		=			['Speech2TextTokenizer']

try:
      if not is_speech_available():
            raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
      pass
else:
      lowercase			:				List[str]    		=			['Speech2TextFeatureExtractor']

try:
      if not is_tf_available():
            raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
      pass
else:
      lowercase			:				Dict    		=			[
          'TF_SPEECH_TO_TEXT_PRETRAINED_MODEL_ARCHIVE_LIST',
          'TFSpeech2TextForConditionalGeneration',
          'TFSpeech2TextModel',
          'TFSpeech2TextPreTrainedModel',
      ]

try:
      if not is_torch_available():
            raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
      pass
else:
      lowercase			:				Any    		=			[
          'SPEECH_TO_TEXT_PRETRAINED_MODEL_ARCHIVE_LIST',
          'Speech2TextForConditionalGeneration',
          'Speech2TextModel',
          'Speech2TextPreTrainedModel',
      ]


if TYPE_CHECKING:
      from .configuration_speech_to_text import SPEECH_TO_TEXT_PRETRAINED_CONFIG_ARCHIVE_MAP, SpeechaTextConfig
      from .processing_speech_to_text import SpeechaTextProcessor

      try:
            if not is_sentencepiece_available():
                  raise OptionalDependencyNotAvailable()
      except OptionalDependencyNotAvailable:
            pass
      else:
            from .tokenization_speech_to_text import SpeechaTextTokenizer

      try:
            if not is_speech_available():
                  raise OptionalDependencyNotAvailable()
      except OptionalDependencyNotAvailable:
            pass
      else:
            from .feature_extraction_speech_to_text import SpeechaTextFeatureExtractor

      try:
            if not is_tf_available():
                  raise OptionalDependencyNotAvailable()
      except OptionalDependencyNotAvailable:
            pass
      else:
            from .modeling_tf_speech_to_text import (
                TF_SPEECH_TO_TEXT_PRETRAINED_MODEL_ARCHIVE_LIST,
                TFSpeechaTextForConditionalGeneration,
                TFSpeechaTextModel,
                TFSpeechaTextPreTrainedModel,
            )

      try:
            if not is_torch_available():
                  raise OptionalDependencyNotAvailable()
      except OptionalDependencyNotAvailable:
            pass
      else:
            from .modeling_speech_to_text import (
                SPEECH_TO_TEXT_PRETRAINED_MODEL_ARCHIVE_LIST,
                SpeechaTextForConditionalGeneration,
                SpeechaTextModel,
                SpeechaTextPreTrainedModel,
            )

else:
      import sys

      lowercase			:				List[Any]    		=			_LazyModule(__name__, globals()['__file__'], _import_structure, module_spec=__spec__)




