






import copy
from dataclasses import dataclass, field
from typing import ClassVar, Dict

from ..features import Audio, Features, Value
from .base import TaskTemplate





@dataclass(frozen=A__	)
class       __a  (   A__	):
 _lowerCAmelCase	:	str				=			field(default='''automatic-speech-recognition'''	,       metadata={'''include_in_asdict_even_if_is_default''': True}	)
 _lowerCAmelCase	:	ClassVar[Features]				=			Features({'''audio''': Audio()}	)
 _lowerCAmelCase	:	ClassVar[Features]				=			Features({'''transcription''': Value('''string'''	)}	)
 _lowerCAmelCase	:	str				=			"audio"
 _lowerCAmelCase	:	str				=			"transcription"







 def  __lowercase (		self :       str							,       SCREAMING_SNAKE_CASE :       str						):


      '''simple docstring'''






      if self.audio_column not in features:
           raise ValueError(F'Column {self.audio_column} is not present in features.'						)
      if not isinstance(features[self.audio_column]							,       SCREAMING_SNAKE_CASE						):
           raise ValueError(F'Column {self.audio_column} is not an Audio type.'						)
      UpperCamelCase__      :       List[Any]	    =  copy.deepcopy(self						)
      UpperCamelCase__      :       Any	    =  self.input_schema.copy()
      UpperCamelCase__      :       List[str]	    =  features[self.audio_column]
      UpperCamelCase__      :       int	    =  input_schema
      return task_template







 @property
 def  __lowercase (		self :       List[str]						):


      '''simple docstring'''






      return {self.audio_column: "audio", self.transcription_column: "transcription"}







from __future__ import annotations







def 		SCREAMING_SNAKE_CASE							( __lowerCAmelCase ,   __lowerCAmelCase = None ,   __lowerCAmelCase = None      )			->     None:
     if start is None:
          UpperCamelCase__      :       Union[str, Any]	    =  0

     if end is None:
          UpperCamelCase__      :       List[Any]	    =  len(__lowerCAmelCase      ) - 1

     if start >= end:
          return

     UpperCamelCase__      :       Union[str, Any]	    =  (start + end) // 2

     slowsort(__lowerCAmelCase ,   __lowerCAmelCase ,   __lowerCAmelCase      )
     slowsort(__lowerCAmelCase ,   mid + 1 ,   __lowerCAmelCase      )

     if sequence[end] < sequence[mid]:
          UpperCamelCase__    ,					UpperCamelCase__      :       Optional[int]	    =  sequence[mid], sequence[end]

     slowsort(__lowerCAmelCase ,   __lowerCAmelCase ,   end - 1      )


if __name__ == "__main__":
 from doctest import testmod

 testmod()