


def _A						(						lowercase		):







    """simple docstring"""

    if not isinstance(lowercase	,   lowercase		):
        raise TypeError('''only integers accepted as input'''		)
    else:
        a					=str(abs(lowercase		)		)
        a					=[list(lowercase		) for char in range(len(lowercase		)		)]
        for index in range(len(lowercase		)		):
            num_transpositions[index].pop(lowercase		)
        return max(
            int(''''''.join(list(lowercase		)		)		) for transposition in num_transpositions		)


if __name__ == "__main__":
       __import__("""doctest""").testmod()



"""simple docstring"""







from ...processing_utils import ProcessorMixin






class 				__A    (	_SCREAMING_SNAKE_CASE      ):






 """simple docstring"""




 __lowerCAmelCase			 =  "WhisperFeatureExtractor"
 __lowerCAmelCase			 =  "WhisperTokenizer"


 def __init__(		self			,   __A			,   __A						) ->					Dict:
     super().__init__(__A			,   __A						)
     a					=self.feature_extractor
     a					=False


 def 				SCREAMING_SNAKE_CASE							(		self			,   __A=None			,   __A=None			,   __A=True						) ->					int:
     return self.tokenizer.get_decoder_prompt_ids(task=__A			,   language=__A			,   no_timestamps=__A						)


 def __call__(		self			,   *__A			,   **__A						) ->					Tuple:
     # For backward compatibility
     if self._in_target_context_manager:
         return self.current_processor(*__A			,   **__A						)

     a					=kwargs.pop('''audio'''			,   __A						)
     a					=kwargs.pop('''sampling_rate'''			,   __A						)
     a					=kwargs.pop('''text'''			,   __A						)
     if len(__A						) > 0:
         a					=args[0]
         a					=args[1:]

     if audio is None and text is None:
         raise ValueError('''You need to specify either an `audio` or `text` input to process.'''						)

     if audio is not None:
         a					=self.feature_extractor(__A			,   *__A			,   sampling_rate=__A			,   **__A						)
     if text is not None:
         a					=self.tokenizer(__A			,   **__A						)

     if text is None:
         return inputs

     elif audio is None:
         return encodings
     else:
         a					=encodings['''input_ids''']
         return inputs


 def 				SCREAMING_SNAKE_CASE							(		self			,   *__A			,   **__A						) ->					Optional[Any]:
     return self.tokenizer.batch_decode(*__A			,   **__A						)


 def 				SCREAMING_SNAKE_CASE							(		self			,   *__A			,   **__A						) ->					Union[str, Any]:
     return self.tokenizer.decode(*__A			,   **__A						)





 def 				SCREAMING_SNAKE_CASE							(		self			,   __A			,   __A="np"						) ->					Optional[Any]:
     return self.tokenizer.get_prompt_ids(__A			,   return_tensors=__A						)