

'''simple docstring'''




from ...processing_utils import ProcessorMixin



class 							lowercase_						(		a			):

  '''simple docstring'''





  __lowerCAmelCase       :			List[Any]     	= "WhisperFeatureExtractor"
  __lowerCAmelCase       :			int     	= "WhisperTokenizer"
  def __init__(  self ,			a_ ,			a_  )				->					List[str]:


    """simple docstring"""
    super().__init__(a_ ,			a_  )
    UpperCAmelCase    				=						self.feature_extractor
    UpperCAmelCase    				=						False
  def     snake_case_      (  self ,			a_=None ,			a_=None ,			a_=True  )				->					int:


    """simple docstring"""
    return self.tokenizer.get_decoder_prompt_ids(task=a_ ,			language=a_ ,			no_timestamps=a_  )
  def __call__(  self ,			*a_ ,			**a_  )				->					Union[str, Any]:


    """simple docstring"""
    # For backward compatibility
    if self._in_target_context_manager:
      return self.current_processor(*a_ ,			**a_  )

    UpperCAmelCase    				=						kwargs.pop('audio' ,			a_  )
    UpperCAmelCase    				=						kwargs.pop('sampling_rate' ,			a_  )
    UpperCAmelCase    				=						kwargs.pop('text' ,			a_  )
    if len(a_  ) > 0:
      UpperCAmelCase    				=						args[0]
      UpperCAmelCase    				=						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:
      UpperCAmelCase    				=						self.feature_extractor(a_ ,			*a_ ,			sampling_rate=a_ ,			**a_  )
    if text is not None:
      UpperCAmelCase    				=						self.tokenizer(a_ ,			**a_  )

    if text is None:
      return inputs

    elif audio is None:
      return encodings
    else:
      UpperCAmelCase    				=						encodings['input_ids']
      return inputs
  def     snake_case_      (  self ,			*a_ ,			**a_  )				->					List[Any]:


    """simple docstring"""
    return self.tokenizer.batch_decode(*a_ ,			**a_  )
  def     snake_case_      (  self ,			*a_ ,			**a_  )				->					Union[str, Any]:


    """simple docstring"""
    return self.tokenizer.decode(*a_ ,			**a_  )





  def     snake_case_      (  self ,			a_ ,			a_="np"  )				->					Tuple:


    """simple docstring"""
    return self.tokenizer.get_prompt_ids(a_ ,			return_tensors=a_  )





'''simple docstring'''




from __future__ import annotations


def    lowerCamelCase__		(    SCREAMING_SNAKE_CASE   : int | float | str							, SCREAMING_SNAKE_CASE   : int | float | str    ):
  if nth_term == "":
    return [""]
  UpperCAmelCase    				=						int(SCREAMING_SNAKE_CASE    )
  UpperCAmelCase    				=						int(SCREAMING_SNAKE_CASE    )
  UpperCAmelCase    				=						[]
  for temp in range(int(SCREAMING_SNAKE_CASE    )    ):
    series.append(f'''1 / {pow(temp + 1							, int(SCREAMING_SNAKE_CASE    )    )}''' if series else '1'    )
  return series


if __name__ == "__main__":
  import doctest

  doctest.testmod()

  _a					:			List[Any]							=    int(input('Enter the last number (nth term) of the P-Series'))
  _a					:			Tuple							=    int(input('Enter the power for  P-Series'))
  print('Formula of P-Series => 1+1/2^p+1/3^p ..... 1/n^p')
  print(p_series(nth_term, power))


