





import json
import os
import tempfile

from transformers.testing_utils import check_json_file_has_correct_format


class       __lowerCAmelCase					:


	'''simple docstring'''





	_A													=				None

	def    snake_case__(						self:						Optional[Any]			):
			lowercase__					:      Any      =		self.feature_extraction_class(**self.feat_extract_dict			)
			lowercase__					:      List[str]      =		json.loads(feat_extract.to_json_string()			)
			for key, value in self.feat_extract_dict.items():
					self.assertEqual(obj[key],					lowerCamelCase_			)

	def    snake_case__(						self:						int			):
			lowercase__					:      Tuple      =		self.feature_extraction_class(**self.feat_extract_dict			)

			with tempfile.TemporaryDirectory() as tmpdirname:
					lowercase__					:      Union[str, Any]      =		os.path.join(lowerCamelCase_,					'feat_extract.json'			)
					feat_extract_first.to_json_file(lowerCamelCase_			)
					lowercase__					:      Optional[int]      =		self.feature_extraction_class.from_json_file(lowerCamelCase_			)

			self.assertEqual(feat_extract_second.to_dict(),					feat_extract_first.to_dict()			)

	def    snake_case__(						self:						List[Any]			):
			lowercase__					:      Optional[int]      =		self.feature_extraction_class(**self.feat_extract_dict			)

			with tempfile.TemporaryDirectory() as tmpdirname:
					lowercase__					:      int      =		feat_extract_first.save_pretrained(lowerCamelCase_			)[0]
					check_json_file_has_correct_format(lowerCamelCase_			)
					lowercase__					:      Optional[Any]      =		self.feature_extraction_class.from_pretrained(lowerCamelCase_			)

			self.assertEqual(feat_extract_second.to_dict(),					feat_extract_first.to_dict()			)





	def    snake_case__(						self:						int			):
			lowercase__					:      str      =		self.feature_extraction_class()
			self.assertIsNotNone(lowerCamelCase_			)









def       SCREAMING_SNAKE_CASE__  (       _lowercase     : int   ,    _lowercase     : int			)   ->							Optional[int]:




		'''simple docstring'''
		if b == 0:
				return 1
		if (b % 2) == 0:
				return actual_power(_lowercase   ,    int(b / 2			)			) * actual_power(_lowercase   ,    int(b / 2			)			)
		else:
				return a * actual_power(_lowercase   ,    int(b / 2			)			) * actual_power(_lowercase   ,    int(b / 2			)			)


def       SCREAMING_SNAKE_CASE__  (       _lowercase     : int   ,    _lowercase     : int			)   ->							float:




		'''simple docstring'''
		if b < 0:
				return 1 / actual_power(_lowercase   ,    _lowercase			)
		return actual_power(_lowercase   ,    _lowercase			)


if __name__ == "__main__":
			print(power(-2, -3))


