
"""simple docstring"""


import json
from typing import List, Optional, Tuple

from tokenizers import normalizers

from ...tokenization_utils_fast import PreTrainedTokenizerFast
from ...utils import logging
from .tokenization_distilbert import DistilBertTokenizer


_lowercase							   =				logging.get_logger(__name__)

_lowercase							   =				{"vocab_file": "vocab.txt", "tokenizer_file": "tokenizer.json"}

_lowercase							   =				{
    "vocab_file": {
        "distilbert-base-uncased": "https://huggingface.co/distilbert-base-uncased/resolve/main/vocab.txt",
        "distilbert-base-uncased-distilled-squad": (
            "https://huggingface.co/distilbert-base-uncased-distilled-squad/resolve/main/vocab.txt"
        ),
        "distilbert-base-cased": "https://huggingface.co/distilbert-base-cased/resolve/main/vocab.txt",
        "distilbert-base-cased-distilled-squad": (
            "https://huggingface.co/distilbert-base-cased-distilled-squad/resolve/main/vocab.txt"
        ),
        "distilbert-base-german-cased": "https://huggingface.co/distilbert-base-german-cased/resolve/main/vocab.txt",
        "distilbert-base-multilingual-cased": (
            "https://huggingface.co/distilbert-base-multilingual-cased/resolve/main/vocab.txt"
        ),
    },
    "tokenizer_file": {
        "distilbert-base-uncased": "https://huggingface.co/distilbert-base-uncased/resolve/main/tokenizer.json",
        "distilbert-base-uncased-distilled-squad": (
            "https://huggingface.co/distilbert-base-uncased-distilled-squad/resolve/main/tokenizer.json"
        ),
        "distilbert-base-cased": "https://huggingface.co/distilbert-base-cased/resolve/main/tokenizer.json",
        "distilbert-base-cased-distilled-squad": (
            "https://huggingface.co/distilbert-base-cased-distilled-squad/resolve/main/tokenizer.json"
        ),
        "distilbert-base-german-cased": (
            "https://huggingface.co/distilbert-base-german-cased/resolve/main/tokenizer.json"
        ),
        "distilbert-base-multilingual-cased": (
            "https://huggingface.co/distilbert-base-multilingual-cased/resolve/main/tokenizer.json"
        ),
    },
}

_lowercase							   =				{
    "distilbert-base-uncased": 5_12,
    "distilbert-base-uncased-distilled-squad": 5_12,
    "distilbert-base-cased": 5_12,
    "distilbert-base-cased-distilled-squad": 5_12,
    "distilbert-base-german-cased": 5_12,
    "distilbert-base-multilingual-cased": 5_12,
}


_lowercase							   =				{
    "distilbert-base-uncased": {"do_lower_case": True},
    "distilbert-base-uncased-distilled-squad": {"do_lower_case": True},
    "distilbert-base-cased": {"do_lower_case": False},
    "distilbert-base-cased-distilled-squad": {"do_lower_case": False},
    "distilbert-base-german-cased": {"do_lower_case": False},
    "distilbert-base-multilingual-cased": {"do_lower_case": False},
}







class 				lowerCAmelCase_				(    UpperCamelCase_    ):



						'''simple docstring'''


						_lowerCamelCase:    str      =    VOCAB_FILES_NAMES
						_lowerCamelCase:    List[str]      =    PRETRAINED_VOCAB_FILES_MAP
						_lowerCamelCase:    List[str]      =    PRETRAINED_POSITIONAL_EMBEDDINGS_SIZES
						_lowerCamelCase:    List[Any]      =    PRETRAINED_INIT_CONFIGURATION
						_lowerCamelCase:    List[str]      =    ["""input_ids""", """attention_mask"""]
						_lowerCamelCase:    List[Any]      =    DistilBertTokenizer


						def __init__( self     :      str  ,A_     :      List[Any]=None  ,A_     :      Dict=None  ,A_     :      str=True  ,A_     :      int="[UNK]"  ,A_     :      Union[str, Any]="[SEP]"  ,A_     :      Tuple="[PAD]"  ,A_     :      Any="[CLS]"  ,A_     :      Dict="[MASK]"  ,A_     :      str=True  ,A_     :      int=None  ,**A_     :      Tuple  ,)     ->   Optional[int]:
							super().__init__(
							    _a  ,tokenizer_file=_a  ,do_lower_case=_a  ,unk_token=_a  ,sep_token=_a  ,pad_token=_a  ,cls_token=_a  ,mask_token=_a  ,tokenize_chinese_chars=_a  ,strip_accents=_a  ,**_a  ,)

							A						   =   json.loads(self.backend_tokenizer.normalizer.__getstate__()      )
							if (
							    normalizer_state.get('lowercase'  ,_a      ) != do_lower_case
							    or normalizer_state.get('strip_accents'  ,_a      ) != strip_accents
							    or normalizer_state.get('handle_chinese_chars'  ,_a      ) != tokenize_chinese_chars
							):
								A						   =   getattr(_a  ,normalizer_state.pop('type'      )      )
								A						   =   do_lower_case
								A						   =   strip_accents
								A						   =   tokenize_chinese_chars
								A						   =   normalizer_class(**_a      )

							A						   =   do_lower_case


						def 						_SCREAMING_SNAKE_CASE      ( self     :      List[Any]  ,A_     :      int  ,A_     :      Tuple=None      )     ->   Union[str, Any]:
							A						   =   [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 						_SCREAMING_SNAKE_CASE      ( self     :      str  ,A_     :      Any  ,A_     :      Optional[int] = None      )     ->   List[int]:
							A						   =   [self.sep_token_id]
							A						   =   [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 						_SCREAMING_SNAKE_CASE      ( self     :      Union[str, Any]  ,A_     :      Any  ,A_     :      Optional[Any] = None      )     ->   Tuple[str]:
							A						   =   self._tokenizer.model.save(_a  ,name=_a      )
							return tuple(_a      )

"""simple docstring"""


def       _snake_case				(		snake_case__   :     list	,      snake_case__   :     list	,      snake_case__   :     int     ):
	A						   =   len(snake_case__     )
	A						   =   [[0] * n for i in range(snake_case__     )]
	for i in range(snake_case__     ):
		A						   =   y_points[i]

	for i in range(2	,      snake_case__     ):
		for j in range(snake_case__	,      snake_case__     ):
			A						   =   (
			    (xa - x_points[j - i + 1]) * q[j][i - 1]
			    - (xa - x_points[j]) * q[j - 1][i - 1]
			) / (x_points[j] - x_points[j - i + 1])

	return [q[n - 1][n - 1], q]


if __name__ == "__main__":
		import doctest

		doctest.testmod()