

from collections import OrderedDict
from typing import Mapping

from packaging import version

from ...configuration_utils import PretrainedConfig
from ...onnx import OnnxConfig
from ...utils import logging


lowerCAmelCase							:  Tuple            =						logging.get_logger(__name__)

lowerCAmelCase							:  str            =						{
    """google/mobilenet_v2_1.4_224""": """https://huggingface.co/google/mobilenet_v2_1.4_224/resolve/main/config.json""",
    """google/mobilenet_v2_1.0_224""": """https://huggingface.co/google/mobilenet_v2_1.0_224/resolve/main/config.json""",
    """google/mobilenet_v2_0.75_160""": """https://huggingface.co/google/mobilenet_v2_0.75_160/resolve/main/config.json""",
    """google/mobilenet_v2_0.35_96""": """https://huggingface.co/google/mobilenet_v2_0.35_96/resolve/main/config.json""",
    # See all MobileNetV2 models at https://huggingface.co/models?filter=mobilenet_v2
}



class   __lowercase    (			UpperCAmelCase_     ):




			"""simple docstring"""







			_UpperCAmelCase       :							Dict      							=					'''mobilenet_v2'''



			def __init__(			self  :					str       ,						lowerCAmelCase__  :					Tuple=3       ,						lowerCAmelCase__  :					Optional[int]=224       ,						lowerCAmelCase__  :					Optional[int]=1.0       ,						lowerCAmelCase__  :					Tuple=8       ,						lowerCAmelCase__  :					Optional[Any]=8       ,						lowerCAmelCase__  :					int=6       ,						lowerCAmelCase__  :					Tuple=32       ,						lowerCAmelCase__  :					List[str]=True       ,						lowerCAmelCase__  :					Tuple=True       ,						lowerCAmelCase__  :					Tuple="relu6"       ,						lowerCAmelCase__  :					List[str]=True       ,						lowerCAmelCase__  :					str=0.8       ,						lowerCAmelCase__  :					Optional[int]=0.02       ,						lowerCAmelCase__  :					List[Any]=0.001       ,						lowerCAmelCase__  :					Optional[Any]=255       ,						**lowerCAmelCase__  :					Optional[int]       ,						):
									super().__init__(**lowerCAmelCase__)

									if depth_multiplier <= 0:
															raise ValueError("depth_multiplier must be greater than zero.")

									SCREAMING_SNAKE_CASE_:			List[str]  		=	num_channels
									SCREAMING_SNAKE_CASE_:			List[str]  		=	image_size
									SCREAMING_SNAKE_CASE_:			Optional[Any]  		=	depth_multiplier
									SCREAMING_SNAKE_CASE_:			Union[str, Any]  		=	depth_divisible_by
									SCREAMING_SNAKE_CASE_:			Dict  		=	min_depth
									SCREAMING_SNAKE_CASE_:			List[str]  		=	expand_ratio
									SCREAMING_SNAKE_CASE_:			int  		=	output_stride
									SCREAMING_SNAKE_CASE_:			Dict  		=	first_layer_is_expansion
									SCREAMING_SNAKE_CASE_:			int  		=	finegrained_output
									SCREAMING_SNAKE_CASE_:			str  		=	hidden_act
									SCREAMING_SNAKE_CASE_:			Any  		=	tf_padding
									SCREAMING_SNAKE_CASE_:			Any  		=	classifier_dropout_prob
									SCREAMING_SNAKE_CASE_:			Union[str, Any]  		=	initializer_range
									SCREAMING_SNAKE_CASE_:			int  		=	layer_norm_eps
									SCREAMING_SNAKE_CASE_:			List[str]  		=	semantic_loss_ignore_index







class   __lowercase    (			UpperCAmelCase_     ):




			"""simple docstring"""







			_UpperCAmelCase       :							Any      							=					version.parse('''1.11'''     )



			@property
			def 	_SCREAMING_SNAKE_CASE      (			self  :					List[str]):
									return OrderedDict([("pixel_values", {0: "batch"})])



			@property
			def 	_SCREAMING_SNAKE_CASE      (			self  :					Any):
									if self.task == "image-classification":
															return OrderedDict([("logits", {0: "batch"})])
									else:
															return OrderedDict([("last_hidden_state", {0: "batch"}), ("pooler_output", {0: "batch"})])




			@property
			def 	_SCREAMING_SNAKE_CASE      (			self  :					Union[str, Any]):
									return 1E-4









import os

# Precomputes a list of the 100 first triangular numbers
lowerCAmelCase							:  Optional[int]            =						[int(0.5 * n * (n + 1)) for n in range(1, 101)]







def       A_				(   ):
						SCREAMING_SNAKE_CASE_:			List[str]  		=	os.path.dirname(os.path.realpath(_UpperCAmelCase   )   )
						SCREAMING_SNAKE_CASE_:			Union[str, Any]  		=	os.path.join(_UpperCAmelCase    ,     "words.txt"   )

						SCREAMING_SNAKE_CASE_:			Dict  		=	""
						with open(_UpperCAmelCase   ) as f:
												SCREAMING_SNAKE_CASE_:			int  		=	f.readline()

						SCREAMING_SNAKE_CASE_:			Optional[int]  		=	[word.strip("\""   ) for word in words.strip("\r\n"   ).split(","   )]
						SCREAMING_SNAKE_CASE_:			List[Any]  		=	[
						    word
						    for word in [sum(ord(_UpperCAmelCase   ) - 64 for x in word   ) for word in words]
						    if word in TRIANGULAR_NUMBERS
						]
						return len(_UpperCAmelCase   )


if __name__ == "__main__":
						print(solution())






