






import json
from typing import List, Optional, Tuple

from tokenizers import normalizers

from ...tokenization_utils_fast import PreTrainedTokenizerFast
from .tokenization_lxmert import LxmertTokenizer


A_       :Dict       =						{'''vocab_file''': '''vocab.txt''', '''tokenizer_file''': '''tokenizer.json'''}

A_       :Dict       =						{
    '''vocab_file''': {
        '''unc-nlp/lxmert-base-uncased''': '''https://huggingface.co/unc-nlp/lxmert-base-uncased/resolve/main/vocab.txt''',
    },
    '''tokenizer_file''': {
        '''unc-nlp/lxmert-base-uncased''': (
            '''https://huggingface.co/unc-nlp/lxmert-base-uncased/resolve/main/tokenizer.json'''
        ),
    },
}

A_       :str       =						{
    '''unc-nlp/lxmert-base-uncased''': 512,
}

A_       :Dict       =						{
    '''unc-nlp/lxmert-base-uncased''': {'''do_lower_case''': True},
}




class 				__A     (			a ):





				"""simple docstring"""







				UpperCamelCase__ :      Optional[Any]			 =VOCAB_FILES_NAMES
				UpperCamelCase__ :      List[str]			 =PRETRAINED_VOCAB_FILES_MAP
				UpperCamelCase__ :      Union[str, Any]			 =PRETRAINED_INIT_CONFIGURATION
				UpperCamelCase__ :      int			 =PRETRAINED_POSITIONAL_EMBEDDINGS_SIZES
				UpperCamelCase__ :      str			 =LxmertTokenizer


				def __init__( self							,  lowerCamelCase__=None							,  lowerCamelCase__=None							,  lowerCamelCase__=True							,  lowerCamelCase__="[UNK]"							,  lowerCamelCase__="[SEP]"							,  lowerCamelCase__="[PAD]"							,  lowerCamelCase__="[CLS]"							,  lowerCamelCase__="[MASK]"							,  lowerCamelCase__=True							,  lowerCamelCase__=None							,  **lowerCamelCase__							,  ):




									"""simple docstring"""

									super().__init__(
									    lowerCamelCase__							,  tokenizer_file=lowerCamelCase__							,  do_lower_case=lowerCamelCase__							,  unk_token=lowerCamelCase__							,  sep_token=lowerCamelCase__							,  pad_token=lowerCamelCase__							,  cls_token=lowerCamelCase__							,  mask_token=lowerCamelCase__							,  tokenize_chinese_chars=lowerCamelCase__							,  strip_accents=lowerCamelCase__							,  **lowerCamelCase__							,  )

									__UpperCamelCase      :					Dict       		=json.loads(self.backend_tokenizer.normalizer.__getstate__()    )
									if (
									    normalizer_state.get('lowercase'							,  lowerCamelCase__    ) != do_lower_case
									    or normalizer_state.get('strip_accents'							,  lowerCamelCase__    ) != strip_accents
									    or normalizer_state.get('handle_chinese_chars'							,  lowerCamelCase__    ) != tokenize_chinese_chars
									):
														__UpperCamelCase      :					str       		=getattr(lowerCamelCase__							,  normalizer_state.pop('type'    )    )
														__UpperCamelCase      :					Any       		=do_lower_case
														__UpperCamelCase      :					Dict       		=strip_accents
														__UpperCamelCase      :					List[str]       		=tokenize_chinese_chars
														__UpperCamelCase      :					Union[str, Any]       		=normalizer_class(**lowerCamelCase__    )

									__UpperCamelCase      :					Union[str, Any]       		=do_lower_case


				def       __lowercase							( self							,  lowerCamelCase__							,  lowerCamelCase__=None    ):




									"""simple docstring"""

									__UpperCamelCase      :					List[str]       		=[self.cls_token_id] + token_ids_a + [self.sep_token_id]

									if token_ids_a:
														output += token_ids_a + [self.sep_token_id]

									return output


				def       __lowercase							( self							,  lowerCamelCase__							,  lowerCamelCase__ = None    ):




									"""simple docstring"""

									__UpperCamelCase      :					str       		=[self.sep_token_id]
									__UpperCamelCase      :					Union[str, Any]       		=[self.cls_token_id]
									if token_ids_a is None:
														return len(cls + token_ids_a + sep    ) * [0]
									return len(cls + token_ids_a + sep    ) * [0] + len(token_ids_a + sep    ) * [1]







				def       __lowercase							( self							,  lowerCamelCase__							,  lowerCamelCase__ = None    ):




									"""simple docstring"""

									__UpperCamelCase      :					int       		=self._tokenizer.model.save(lowerCamelCase__							,  name=lowerCamelCase__    )
									return tuple(lowerCamelCase__    )



'''simple docstring'''







from collections import defaultdict
from math import gcd







def 				SCREAMING_SNAKE_CASE__	(   __A = 1_500_000	)       ->	int:
	_snake_case   						=		defaultdict(__A	)
	_snake_case   						=		2
	while 2 * euclid_m * (euclid_m + 1) <= limit:
		for euclid_n in range((euclid_m % 2) + 1			,				__A			,				2	):
			if gcd(__A			,				__A	) > 1:
				continue
			_snake_case   						=		2 * euclid_m * (euclid_m + euclid_n)
			for perimeter in range(__A			,				limit + 1			,				__A	):
				frequencies[perimeter] += 1
		euclid_m += 1
	return sum(1 for frequency in frequencies.values() if frequency == 1	)


if __name__ == "__main__":
					print(F'''{solution() = }''')

