
from __future__ import annotations


def 						UpperCAmelCase      (     a_		,       a_		,       a_						)		->     float:







				"""simple docstring"""



				if days_between_payments <= 0:
								raise ValueError("days_between_payments must be > 0"						)
				if daily_interest_rate < 0:
								raise ValueError("daily_interest_rate must be >= 0"						)
				if principal <= 0:
								raise ValueError("principal must be > 0"						)
				return principal * daily_interest_rate * days_between_payments


def 						UpperCAmelCase      (     a_		,       a_		,       a_		,       )		->     float:







				"""simple docstring"""



				if number_of_compounding_periods <= 0:
								raise ValueError("number_of_compounding_periods must be > 0"						)
				if nominal_annual_interest_rate_percentage < 0:
								raise ValueError("nominal_annual_interest_rate_percentage must be >= 0"						)
				if principal <= 0:
								raise ValueError("principal must be > 0"						)

				return principal * (
				    (1 + nominal_annual_interest_rate_percentage) ** number_of_compounding_periods
				    - 1
				)


def 						UpperCAmelCase      (     a_		,       a_		,       a_		,       )		->     float:







				"""simple docstring"""



				if number_of_years <= 0:
								raise ValueError("number_of_years must be > 0"						)
				if nominal_annual_percentage_rate < 0:
								raise ValueError("nominal_annual_percentage_rate must be >= 0"						)
				if principal <= 0:
								raise ValueError("principal must be > 0"						)

				return compound_interest(
				    a_		,       nominal_annual_percentage_rate / 3_6_5		,       number_of_years * 3_6_5						)


if __name__ == "__main__":
					import doctest

					doctest.testmod()


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

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





@dataclass(frozen=__SCREAMING_SNAKE_CASE  )
class 							UpperCAmelCase				(  __SCREAMING_SNAKE_CASE  ):




	'''simple docstring'''





	snake_case_    =					field(default="automatic-speech-recognition"      ,      metadata={"include_in_asdict_even_if_is_default": True}  )
	snake_case_    =					Features({"audio": Audio()}  )
	snake_case_    =					Features({"transcription": Value("string"  )}  )
	snake_case_    =					"audio"
	snake_case_    =					"transcription"






	def     UpperCamelCase_  (	self :			Optional[int]							,A :			Union[str, Any]			):
					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]							,A			):
									raise ValueError(f'''Column {self.audio_column} is not an Audio type.'''			)
					__A             =			copy.deepcopy(self			)
					__A             =			self.input_schema.copy()
					__A             =			features[self.audio_column]
					__A             =			input_schema
					return task_template







	@property
	def     UpperCamelCase_  (	self :			int			):
					return {self.audio_column: "audio", self.transcription_column: "transcription"}
