






def 				snake_case  (     lowerCamelCase					):




	'''simple docstring'''







	try:
		__lowercase             =  float(lowerCAmelCase__					)
	except ValueError:
		raise ValueError("""Please enter a valid number"""					)
	__lowercase             =  decimal - int(lowerCAmelCase__					)
	if fractional_part == 0:
		return int(lowerCAmelCase__					), 1
	else:
		__lowercase             =  len(str(lowerCAmelCase__					).split("""."""					)[1]					)
		__lowercase             =  int(decimal * (10**number_of_frac_digits)					)
		__lowercase             =  10**number_of_frac_digits
		__lowercase       ,						__lowercase             =  denominator, numerator
		while True:
			__lowercase             =  dividend % divisor
			if remainder == 0:
				break
			__lowercase       ,						__lowercase             =  divisor, remainder
		__lowercase       ,						__lowercase             =  numerator / divisor, denominator / divisor
		return int(lowerCAmelCase__					), int(lowerCAmelCase__					)


if __name__ == "__main__":
					print(F'''{decimal_to_fraction(2) = }''')
					print(F'''{decimal_to_fraction(8_9.0) = }''')
					print(F'''{decimal_to_fraction("67") = }''')
					print(F'''{decimal_to_fraction("45.0") = }''')
					print(F'''{decimal_to_fraction(1.5) = }''')
					print(F'''{decimal_to_fraction("6.25") = }''')
					print(F'''{decimal_to_fraction("78td") = }''')









from typing import TYPE_CHECKING

from ...utils import (
    OptionalDependencyNotAvailable,
    _LazyModule,
    is_torch_available,
)


__UpperCamelCase      :      Tuple     						=						{
    """configuration_swiftformer""": [
        """SWIFTFORMER_PRETRAINED_CONFIG_ARCHIVE_MAP""",
        """SwiftFormerConfig""",
        """SwiftFormerOnnxConfig""",
    ]
}

try:
						if not is_torch_available():
												raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
						pass
else:
						__UpperCamelCase      :      Optional[Any]     						=						[
						    """SWIFTFORMER_PRETRAINED_MODEL_ARCHIVE_LIST""",
						    """SwiftFormerForImageClassification""",
						    """SwiftFormerModel""",
						    """SwiftFormerPreTrainedModel""",
						]

if TYPE_CHECKING:
						from .configuration_swiftformer import (
						    SWIFTFORMER_PRETRAINED_CONFIG_ARCHIVE_MAP,
						    SwiftFormerConfig,
						    SwiftFormerOnnxConfig,
						)

						try:
												if not is_torch_available():
																		raise OptionalDependencyNotAvailable()
						except OptionalDependencyNotAvailable:
												pass
						else:
												from .modeling_swiftformer import (
												    SWIFTFORMER_PRETRAINED_MODEL_ARCHIVE_LIST,
												    SwiftFormerForImageClassification,
												    SwiftFormerModel,
												    SwiftFormerPreTrainedModel,
												)

else:
						import sys

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

