import os
import tempfile
import unittest

from transformers import FlaubertConfig, is_torch_available
from transformers.testing_utils import require_torch, require_torch_gpu, slow, torch_device

from ...test_configuration_common import ConfigTester
from ...test_modeling_common import ModelTesterMixin, ids_tensor, random_attention_mask
from ...test_pipeline_mixin import PipelineTesterMixin


if is_torch_available():
				import torch

				from transformers import (
				    FlaubertForMultipleChoice,
				    FlaubertForQuestionAnswering,
				    FlaubertForQuestionAnsweringSimple,
				    FlaubertForSequenceClassification,
				    FlaubertForTokenClassification,
				    FlaubertModel,
				    FlaubertWithLMHeadModel,
				)
				from transformers.models.flaubert.modeling_flaubert import FLAUBERT_PRETRAINED_MODEL_ARCHIVE_LIST





class     lowerCAmelCase__     (				__snake_case			):


		'''simple docstring'''






		def __init__(       self     :     Any     ,  snake_case__     :     List[Any]     ,  snake_case__     :     Dict=1_3     ,  snake_case__     :     str=7     ,  snake_case__     :     Union[str, Any]=True     ,  snake_case__     :     Union[str, Any]=True     ,  snake_case__     :     Optional[Any]=True     ,  snake_case__     :     int=True     ,  snake_case__     :     List[str]=True     ,  snake_case__     :     int=False     ,  snake_case__     :     Any=False     ,  snake_case__     :     int=False     ,  snake_case__     :     Any=2     ,  snake_case__     :     Tuple=9_9     ,  snake_case__     :     Optional[Any]=0     ,  snake_case__     :     Optional[Any]=3_2     ,  snake_case__     :     int=5     ,  snake_case__     :     Optional[Any]=4     ,  snake_case__     :     Union[str, Any]=0.1     ,  snake_case__     :     Union[str, Any]=0.1     ,  snake_case__     :     int=5_1_2     ,  snake_case__     :     int=1_2     ,  snake_case__     :     List[str]=2     ,  snake_case__     :     List[Any]=0.02     ,  snake_case__     :     int=3     ,  snake_case__     :     str=4     ,  snake_case__     :     Tuple="last"     ,  snake_case__     :     Optional[Any]=None     ,  snake_case__     :     Any=None     ,  )      ->	Tuple:
				_lowerCamelCase				   =  parent
				_lowerCamelCase				   =  batch_size
				_lowerCamelCase				   =  seq_length
				_lowerCamelCase				   =  is_training
				_lowerCamelCase				   =  use_input_lengths
				_lowerCamelCase				   =  use_token_type_ids
				_lowerCamelCase				   =  use_labels
				_lowerCamelCase				   =  gelu_activation
				_lowerCamelCase				   =  sinusoidal_embeddings
				_lowerCamelCase				   =  causal
				_lowerCamelCase				   =  asm
				_lowerCamelCase				   =  n_langs
				_lowerCamelCase				   =  vocab_size
				_lowerCamelCase				   =  n_special
				_lowerCamelCase				   =  hidden_size
				_lowerCamelCase				   =  num_hidden_layers
				_lowerCamelCase				   =  num_attention_heads
				_lowerCamelCase				   =  hidden_dropout_prob
				_lowerCamelCase				   =  attention_probs_dropout_prob
				_lowerCamelCase				   =  max_position_embeddings
				_lowerCamelCase				   =  type_vocab_size
				_lowerCamelCase				   =  type_sequence_label_size
				_lowerCamelCase				   =  initializer_range
				_lowerCamelCase				   =  num_labels
				_lowerCamelCase				   =  num_choices
				_lowerCamelCase				   =  summary_type
				_lowerCamelCase				   =  use_proj
				_lowerCamelCase				   =  scope
		def   _snake_case       (       self     :     str		)      ->	Dict:
				_lowerCamelCase				   =  ids_tensor([self.batch_size, self.seq_length]     ,  self.vocab_size		)
				_lowerCamelCase				   =  random_attention_mask([self.batch_size, self.seq_length]		)

				_lowerCamelCase				   =  None
				if self.use_input_lengths:
						_lowerCamelCase				   =  (
						    ids_tensor([self.batch_size]     ,  vocab_size=2		) + self.seq_length - 2
						)  # small variation of seq_length

				_lowerCamelCase				   =  None
				if self.use_token_type_ids:
						_lowerCamelCase				   =  ids_tensor([self.batch_size, self.seq_length]     ,  self.n_langs		)

				_lowerCamelCase				   =  None
				_lowerCamelCase				   =  None
				_lowerCamelCase				   =  None
				if self.use_labels:
						_lowerCamelCase				   =  ids_tensor([self.batch_size]     ,  self.type_sequence_label_size		)
						_lowerCamelCase				   =  ids_tensor([self.batch_size, self.seq_length]     ,  self.num_labels		)
						_lowerCamelCase				   =  ids_tensor([self.batch_size]     ,  2		).float()
						_lowerCamelCase				   =  ids_tensor([self.batch_size]     ,  self.num_choices		)

				_lowerCamelCase				   =  self.get_config()

				return (
				    config,
				    input_ids,
				    token_type_ids,
				    input_lengths,
				    sequence_labels,
				    token_labels,
				    is_impossible_labels,
				    choice_labels,
				    input_mask,
				)
		def   _snake_case       (       self     :     Any		)      ->	Optional[Any]:
				return FlaubertConfig(
				    vocab_size=self.vocab_size     ,  n_special=self.n_special     ,  emb_dim=self.hidden_size     ,  n_layers=self.num_hidden_layers     ,  n_heads=self.num_attention_heads     ,  dropout=self.hidden_dropout_prob     ,  attention_dropout=self.attention_probs_dropout_prob     ,  gelu_activation=self.gelu_activation     ,  sinusoidal_embeddings=self.sinusoidal_embeddings     ,  asm=self.asm     ,  causal=self.causal     ,  n_langs=self.n_langs     ,  max_position_embeddings=self.max_position_embeddings     ,  initializer_range=self.initializer_range     ,  summary_type=self.summary_type     ,  use_proj=self.use_proj     ,  )
		def   _snake_case       (       self     :     List[str]     ,  snake_case__     :     Dict     ,  snake_case__     :     Any     ,  snake_case__     :     Union[str, Any]     ,  snake_case__     :     str     ,  snake_case__     :     Any     ,  snake_case__     :     Dict     ,  snake_case__     :     Optional[Any]     ,  snake_case__     :     List[str]     ,  snake_case__     :     Union[str, Any]     ,  )      ->	List[str]:
				_lowerCamelCase				   =  FlaubertModel(config=_SCREAMING_SNAKE_CASE		)
				model.to(_SCREAMING_SNAKE_CASE		)
				model.eval()
				_lowerCamelCase				   =  model(_SCREAMING_SNAKE_CASE     ,  lengths=_SCREAMING_SNAKE_CASE     ,  langs=_SCREAMING_SNAKE_CASE		)
				_lowerCamelCase				   =  model(_SCREAMING_SNAKE_CASE     ,  langs=_SCREAMING_SNAKE_CASE		)
				_lowerCamelCase				   =  model(_SCREAMING_SNAKE_CASE		)
				self.parent.assertEqual(result.last_hidden_state.shape     ,  (self.batch_size, self.seq_length, self.hidden_size)		)
		def   _snake_case       (       self     :     Union[str, Any]     ,  snake_case__     :     List[str]     ,  snake_case__     :     List[str]     ,  snake_case__     :     Optional[Any]     ,  snake_case__     :     Optional[int]     ,  snake_case__     :     List[Any]     ,  snake_case__     :     Union[str, Any]     ,  snake_case__     :     Optional[int]     ,  snake_case__     :     Dict     ,  snake_case__     :     Optional[int]     ,  )      ->	Tuple:
				_lowerCamelCase				   =  FlaubertWithLMHeadModel(_SCREAMING_SNAKE_CASE		)
				model.to(_SCREAMING_SNAKE_CASE		)
				model.eval()

				_lowerCamelCase				   =  model(_SCREAMING_SNAKE_CASE     ,  token_type_ids=_SCREAMING_SNAKE_CASE     ,  labels=_SCREAMING_SNAKE_CASE		)
				self.parent.assertEqual(result.loss.shape     ,  ()		)
				self.parent.assertEqual(result.logits.shape     ,  (self.batch_size, self.seq_length, self.vocab_size)		)
		def   _snake_case       (       self     :     int     ,  snake_case__     :     Optional[Any]     ,  snake_case__     :     List[str]     ,  snake_case__     :     Union[str, Any]     ,  snake_case__     :     Optional[int]     ,  snake_case__     :     Optional[Any]     ,  snake_case__     :     int     ,  snake_case__     :     Union[str, Any]     ,  snake_case__     :     Optional[Any]     ,  snake_case__     :     List[Any]     ,  )      ->	Optional[Any]:
				_lowerCamelCase				   =  FlaubertForQuestionAnsweringSimple(_SCREAMING_SNAKE_CASE		)
				model.to(_SCREAMING_SNAKE_CASE		)
				model.eval()

				_lowerCamelCase				   =  model(_SCREAMING_SNAKE_CASE		)

				_lowerCamelCase				   =  model(_SCREAMING_SNAKE_CASE     ,  start_positions=_SCREAMING_SNAKE_CASE     ,  end_positions=_SCREAMING_SNAKE_CASE		)
				self.parent.assertEqual(result.start_logits.shape     ,  (self.batch_size, self.seq_length)		)
				self.parent.assertEqual(result.end_logits.shape     ,  (self.batch_size, self.seq_length)		)
		def   _snake_case       (       self     :     int     ,  snake_case__     :     Dict     ,  snake_case__     :     Optional[int]     ,  snake_case__     :     Dict     ,  snake_case__     :     str     ,  snake_case__     :     Tuple     ,  snake_case__     :     Union[str, Any]     ,  snake_case__     :     str     ,  snake_case__     :     List[str]     ,  snake_case__     :     str     ,  )      ->	Tuple:
				_lowerCamelCase				   =  FlaubertForQuestionAnswering(_SCREAMING_SNAKE_CASE		)
				model.to(_SCREAMING_SNAKE_CASE		)
				model.eval()

				_lowerCamelCase				   =  model(_SCREAMING_SNAKE_CASE		)

				_lowerCamelCase				   =  model(
				    _SCREAMING_SNAKE_CASE     ,  start_positions=_SCREAMING_SNAKE_CASE     ,  end_positions=_SCREAMING_SNAKE_CASE     ,  cls_index=_SCREAMING_SNAKE_CASE     ,  is_impossible=_SCREAMING_SNAKE_CASE     ,  p_mask=_SCREAMING_SNAKE_CASE     ,  )

				_lowerCamelCase				   =  model(
				    _SCREAMING_SNAKE_CASE     ,  start_positions=_SCREAMING_SNAKE_CASE     ,  end_positions=_SCREAMING_SNAKE_CASE     ,  cls_index=_SCREAMING_SNAKE_CASE     ,  is_impossible=_SCREAMING_SNAKE_CASE     ,  )

				((_lowerCamelCase  )   ,							  )				   =  result_with_labels.to_tuple()

				_lowerCamelCase				   =  model(_SCREAMING_SNAKE_CASE     ,  start_positions=_SCREAMING_SNAKE_CASE     ,  end_positions=_SCREAMING_SNAKE_CASE		)

				((_lowerCamelCase  )   ,							  )				   =  result_with_labels.to_tuple()

				self.parent.assertEqual(result_with_labels.loss.shape     ,  ()		)
				self.parent.assertEqual(result.start_top_log_probs.shape     ,  (self.batch_size, model.config.start_n_top)		)
				self.parent.assertEqual(result.start_top_index.shape     ,  (self.batch_size, model.config.start_n_top)		)
				self.parent.assertEqual(
				    result.end_top_log_probs.shape     ,  (self.batch_size, model.config.start_n_top * model.config.end_n_top)		)
				self.parent.assertEqual(
				    result.end_top_index.shape     ,  (self.batch_size, model.config.start_n_top * model.config.end_n_top)		)
				self.parent.assertEqual(result.cls_logits.shape     ,  (self.batch_size,)		)
		def   _snake_case       (       self     :     Dict     ,  snake_case__     :     Optional[int]     ,  snake_case__     :     Tuple     ,  snake_case__     :     Optional[int]     ,  snake_case__     :     Optional[int]     ,  snake_case__     :     str     ,  snake_case__     :     List[str]     ,  snake_case__     :     Optional[int]     ,  snake_case__     :     str     ,  snake_case__     :     List[str]     ,  )      ->	Union[str, Any]:
				_lowerCamelCase				   =  FlaubertForSequenceClassification(_SCREAMING_SNAKE_CASE		)
				model.to(_SCREAMING_SNAKE_CASE		)
				model.eval()

				_lowerCamelCase				   =  model(_SCREAMING_SNAKE_CASE		)
				_lowerCamelCase				   =  model(_SCREAMING_SNAKE_CASE     ,  labels=_SCREAMING_SNAKE_CASE		)

				self.parent.assertEqual(result.loss.shape     ,  ()		)
				self.parent.assertEqual(result.logits.shape     ,  (self.batch_size, self.type_sequence_label_size)		)
		def   _snake_case       (       self     :     List[Any]     ,  snake_case__     :     Union[str, Any]     ,  snake_case__     :     List[str]     ,  snake_case__     :     Dict     ,  snake_case__     :     int     ,  snake_case__     :     List[str]     ,  snake_case__     :     Tuple     ,  snake_case__     :     str     ,  snake_case__     :     Union[str, Any]     ,  snake_case__     :     Optional[int]     ,  )      ->	str:
				_lowerCamelCase				   =  self.num_labels
				_lowerCamelCase				   =  FlaubertForTokenClassification(_SCREAMING_SNAKE_CASE		)
				model.to(_SCREAMING_SNAKE_CASE		)
				model.eval()

				_lowerCamelCase				   =  model(_SCREAMING_SNAKE_CASE     ,  attention_mask=_SCREAMING_SNAKE_CASE     ,  labels=_SCREAMING_SNAKE_CASE		)
				self.parent.assertEqual(result.logits.shape     ,  (self.batch_size, self.seq_length, self.num_labels)		)
		def   _snake_case       (       self     :     int     ,  snake_case__     :     int     ,  snake_case__     :     Optional[int]     ,  snake_case__     :     Dict     ,  snake_case__     :     Tuple     ,  snake_case__     :     Any     ,  snake_case__     :     Optional[int]     ,  snake_case__     :     Any     ,  snake_case__     :     int     ,  snake_case__     :     Optional[Any]     ,  )      ->	Tuple:
				_lowerCamelCase				   =  self.num_choices
				_lowerCamelCase				   =  FlaubertForMultipleChoice(config=_SCREAMING_SNAKE_CASE		)
				model.to(_SCREAMING_SNAKE_CASE		)
				model.eval()
				_lowerCamelCase				   =  input_ids.unsqueeze(1		).expand(-1     ,  self.num_choices     ,  -1		).contiguous()
				_lowerCamelCase				   =  token_type_ids.unsqueeze(1		).expand(-1     ,  self.num_choices     ,  -1		).contiguous()
				_lowerCamelCase				   =  input_mask.unsqueeze(1		).expand(-1     ,  self.num_choices     ,  -1		).contiguous()
				_lowerCamelCase				   =  model(
				    _SCREAMING_SNAKE_CASE     ,  attention_mask=_SCREAMING_SNAKE_CASE     ,  token_type_ids=_SCREAMING_SNAKE_CASE     ,  labels=_SCREAMING_SNAKE_CASE     ,  )
				self.parent.assertEqual(result.logits.shape     ,  (self.batch_size, self.num_choices)		)



		def   _snake_case       (       self     :     int		)      ->	Dict:
				_lowerCamelCase				   =  self.prepare_config_and_inputs()
				(
				    (
				    _lowerCamelCase  
				)   ,							(
				    _lowerCamelCase  
				)   ,							(
				    _lowerCamelCase  
				)   ,							(
				    _lowerCamelCase  
				)   ,							(
				    _lowerCamelCase  
				)   ,							(
				    _lowerCamelCase  
				)   ,							(
				    _lowerCamelCase  
				)   ,							(
				    _lowerCamelCase  
				)   ,							(
				    _lowerCamelCase  
				)   ,							  
				)				   =  config_and_inputs
				_lowerCamelCase				   =  {
				    'input_ids': input_ids,
				    'token_type_ids': token_type_ids,
				    'lengths': input_lengths,
				    'attention_mask': input_mask,
				}
				return config, inputs_dict





@require_torch
class     lowerCAmelCase__     (				__snake_case     ,__snake_case     ,unittest.TestCase			):


		'''simple docstring'''






		lowerCAmelCase_     =   (
		    (
		        FlaubertModel,
		        FlaubertWithLMHeadModel,
		        FlaubertForQuestionAnswering,
		        FlaubertForQuestionAnsweringSimple,
		        FlaubertForSequenceClassification,
		        FlaubertForTokenClassification,
		        FlaubertForMultipleChoice,
		    )
		    if is_torch_available()
		    else ()
		)
		lowerCAmelCase_     =   (
		    {
		        'feature-extraction': FlaubertModel,
		        'fill-mask': FlaubertWithLMHeadModel,
		        'question-answering': FlaubertForQuestionAnsweringSimple,
		        'text-classification': FlaubertForSequenceClassification,
		        'token-classification': FlaubertForTokenClassification,
		        'zero-shot': FlaubertForSequenceClassification,
		    }
		    if is_torch_available()
		    else {}
		)
		def   _snake_case       (       self     :     str     ,  snake_case__     :     Union[str, Any]     ,  snake_case__     :     Optional[Any]     ,  snake_case__     :     List[str]     ,  snake_case__     :     Union[str, Any]     ,  snake_case__     :     int		)      ->	List[str]:




				if (
				    pipeline_test_casse_name == "QAPipelineTests"
				    and tokenizer_name is not None
				    and not tokenizer_name.endswith('Fast'		)
				):
						# `QAPipelineTests` fails for a few models when the slower tokenizer are used.
						# (The slower tokenizers were never used for pipeline tests before the pipeline testing rework)
						# TODO: check (and possibly fix) the `QAPipelineTests` with slower tokenizer
						return True

				return False
		def   _snake_case       (       self     :     Union[str, Any]     ,  snake_case__     :     str     ,  snake_case__     :     Union[str, Any]     ,  snake_case__     :     Tuple=False		)      ->	Optional[Any]:
				_lowerCamelCase				   =  super()._prepare_for_class(_SCREAMING_SNAKE_CASE     ,  _SCREAMING_SNAKE_CASE     ,  return_labels=_SCREAMING_SNAKE_CASE		)

				if return_labels:
						if model_class.__name__ == "FlaubertForQuestionAnswering":
								_lowerCamelCase				   =  torch.zeros(
								    self.model_tester.batch_size     ,  dtype=torch.long     ,  device=_SCREAMING_SNAKE_CASE		)
								_lowerCamelCase				   =  torch.zeros(
								    self.model_tester.batch_size     ,  dtype=torch.long     ,  device=_SCREAMING_SNAKE_CASE		)

				return inputs_dict
		def   _snake_case       (       self     :     str		)      ->	List[str]:
				_lowerCamelCase				   =  FlaubertModelTester(self		)
				_lowerCamelCase				   =  ConfigTester(self     ,  config_class=_SCREAMING_SNAKE_CASE     ,  emb_dim=3_7		)
		def   _snake_case       (       self     :     Optional[int]		)      ->	Union[str, Any]:
				self.config_tester.run_common_tests()
		def   _snake_case       (       self     :     Optional[Any]		)      ->	int:
				_lowerCamelCase				   =  self.model_tester.prepare_config_and_inputs()
				self.model_tester.create_and_check_flaubert_model(*_SCREAMING_SNAKE_CASE		)
		def   _snake_case       (       self     :     Optional[Any]		)      ->	Union[str, Any]:
				_lowerCamelCase				   =  self.model_tester.prepare_config_and_inputs()
				self.model_tester.create_and_check_flaubert_lm_head(*_SCREAMING_SNAKE_CASE		)
		def   _snake_case       (       self     :     Union[str, Any]		)      ->	Optional[Any]:
				_lowerCamelCase				   =  self.model_tester.prepare_config_and_inputs()
				self.model_tester.create_and_check_flaubert_simple_qa(*_SCREAMING_SNAKE_CASE		)
		def   _snake_case       (       self     :     List[Any]		)      ->	Union[str, Any]:
				_lowerCamelCase				   =  self.model_tester.prepare_config_and_inputs()
				self.model_tester.create_and_check_flaubert_qa(*_SCREAMING_SNAKE_CASE		)
		def   _snake_case       (       self     :     int		)      ->	Optional[int]:
				_lowerCamelCase				   =  self.model_tester.prepare_config_and_inputs()
				self.model_tester.create_and_check_flaubert_sequence_classif(*_SCREAMING_SNAKE_CASE		)
		def   _snake_case       (       self     :     str		)      ->	List[Any]:
				_lowerCamelCase				   =  self.model_tester.prepare_config_and_inputs()
				self.model_tester.create_and_check_flaubert_token_classif(*_SCREAMING_SNAKE_CASE		)
		def   _snake_case       (       self     :     Any		)      ->	List[str]:
				_lowerCamelCase				   =  self.model_tester.prepare_config_and_inputs()
				self.model_tester.create_and_check_flaubert_multiple_choice(*_SCREAMING_SNAKE_CASE		)
		@slow
		def   _snake_case       (       self     :     Optional[Any]		)      ->	Union[str, Any]:




				for model_name in FLAUBERT_PRETRAINED_MODEL_ARCHIVE_LIST[:1]:
						_lowerCamelCase				   =  FlaubertModel.from_pretrained(_SCREAMING_SNAKE_CASE		)
						self.assertIsNotNone(_SCREAMING_SNAKE_CASE		)



		@slow
		@require_torch_gpu
		def   _snake_case       (       self     :     Dict		)      ->	int:
				_lowerCamelCase   ,							_lowerCamelCase				   =  self.model_tester.prepare_config_and_inputs_for_common()
				for model_class in self.all_model_classes:
						# FlauBertForMultipleChoice behaves incorrectly in JIT environments.
						if model_class == FlaubertForMultipleChoice:
								return

						_lowerCamelCase				   =  True
						_lowerCamelCase				   =  model_class(config=_SCREAMING_SNAKE_CASE		)

						_lowerCamelCase				   =  self._prepare_for_class(_SCREAMING_SNAKE_CASE     ,  _SCREAMING_SNAKE_CASE		)
						_lowerCamelCase				   =  torch.jit.trace(
						    _SCREAMING_SNAKE_CASE     ,  (inputs_dict['input_ids'].to('cpu'		), inputs_dict['attention_mask'].to('cpu'		))		)

						with tempfile.TemporaryDirectory() as tmp:
								torch.jit.save(_SCREAMING_SNAKE_CASE     ,  os.path.join(_SCREAMING_SNAKE_CASE     ,  'traced_model.pt'		)		)
								_lowerCamelCase				   =  torch.jit.load(os.path.join(_SCREAMING_SNAKE_CASE     ,  'traced_model.pt'		)     ,  map_location=_SCREAMING_SNAKE_CASE		)
								loaded(inputs_dict['input_ids'].to(_SCREAMING_SNAKE_CASE		)     ,  inputs_dict['attention_mask'].to(_SCREAMING_SNAKE_CASE		)		)





@require_torch
class     lowerCAmelCase__     (				unittest.TestCase			):


		'''simple docstring'''






		@slow
		def   _snake_case       (       self     :     Union[str, Any]		)      ->	Any:
				_lowerCamelCase				   =  FlaubertModel.from_pretrained('flaubert/flaubert_base_cased'		)
				_lowerCamelCase				   =  torch.tensor([[0, 3_4_5, 2_3_2, 3_2_8, 7_4_0, 1_4_0, 1_6_9_5, 6_9, 6_0_7_8, 1_5_8_8, 2]]		)
				with torch.no_grad():
						_lowerCamelCase				   =  model(_SCREAMING_SNAKE_CASE		)[0]
				_lowerCamelCase				   =  torch.Size((1, 1_1, 7_6_8)		)
				self.assertEqual(output.shape     ,  _SCREAMING_SNAKE_CASE		)
				_lowerCamelCase				   =  torch.tensor(
				    [[[-2.6251, -1.4298, -0.0227], [-2.8510, -1.6387, 0.2258], [-2.8114, -1.1832, -0.3066]]]		)

				self.assertTrue(torch.allclose(output[:, :3, :3]     ,  _SCREAMING_SNAKE_CASE     ,  atol=1e-4		)		)







import unittest

from transformers import DebertaVaTokenizer, DebertaVaTokenizerFast
from transformers.testing_utils import get_tests_dir, require_sentencepiece, require_tokenizers, slow

from ...test_tokenization_common import TokenizerTesterMixin


__magic_name__   :  Optional[int]        =							get_tests_dir('''fixtures/spiece.model''')





@require_sentencepiece
@require_tokenizers
class 					A__     (     __snake_case   ,    unittest.TestCase ):

     '''simple docstring'''






     snake_case__					=					DebertaVaTokenizer
     snake_case__					=					DebertaVaTokenizerFast
     snake_case__					=					True
     snake_case__					=					True







     def   _SCREAMING_SNAKE_CASE     ( self      :    Tuple ):






           """simple docstring"""




           super().setUp()

           # We have a SentencePiece fixture for testing
           UpperCamelCase					       =  DebertaVaTokenizer(_SCREAMING_SNAKE_CASE   ,						unk_token='<unk>' )
           tokenizer.save_pretrained(self.tmpdirname )







     def   _SCREAMING_SNAKE_CASE     ( self      :    List[Any]   ,						_SCREAMING_SNAKE_CASE      :    Optional[Any] ):






           """simple docstring"""




           UpperCamelCase					       =  'this is a test'
           UpperCamelCase					       =  'this is a test'
           return input_text, output_text







     def   _SCREAMING_SNAKE_CASE     ( self      :    Optional[Any] ):






           """simple docstring"""




           UpperCamelCase					       =  '<pad>'
           UpperCamelCase					       =  0

           self.assertEqual(self.get_tokenizer()._convert_token_to_id(_SCREAMING_SNAKE_CASE )   ,						_SCREAMING_SNAKE_CASE )
           self.assertEqual(self.get_tokenizer()._convert_id_to_token(_SCREAMING_SNAKE_CASE )   ,						_SCREAMING_SNAKE_CASE )







     def   _SCREAMING_SNAKE_CASE     ( self      :    Dict ):






           """simple docstring"""




           UpperCamelCase					       =  list(self.get_tokenizer().get_vocab().keys() )
           self.assertEqual(vocab_keys[0]   ,						'<pad>' )
           self.assertEqual(vocab_keys[1]   ,						'<unk>' )
           self.assertEqual(vocab_keys[-1]   ,						'[PAD]' )
           self.assertEqual(len(_SCREAMING_SNAKE_CASE )   ,						3_0001 )







     def   _SCREAMING_SNAKE_CASE     ( self      :    str ):






           """simple docstring"""




           self.assertEqual(self.get_tokenizer().vocab_size   ,						3_0000 )







     def   _SCREAMING_SNAKE_CASE     ( self      :    int ):






           """simple docstring"""




           UpperCamelCase					       =  ' \tHeLLo!how  \n Are yoU?  '
           UpperCamelCase					       =  ['▁hello', '!', 'how', '▁are', '▁you', '?']
           # fmt: on

           UpperCamelCase					       =  DebertaVaTokenizer(_SCREAMING_SNAKE_CASE   ,						do_lower_case=_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  tokenizer.convert_ids_to_tokens(tokenizer.encode(_SCREAMING_SNAKE_CASE   ,						add_special_tokens=_SCREAMING_SNAKE_CASE ) )

           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )

           UpperCamelCase					       =  DebertaVaTokenizerFast(_SCREAMING_SNAKE_CASE   ,						do_lower_case=_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  rust_tokenizer.convert_ids_to_tokens(rust_tokenizer.encode(_SCREAMING_SNAKE_CASE   ,						add_special_tokens=_SCREAMING_SNAKE_CASE ) )

           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )







     @unittest.skip('There is an inconsistency between slow and fast tokenizer due to a bug in the fast one.' )
     def   _SCREAMING_SNAKE_CASE     ( self      :    int ):






           """simple docstring"""




           pass







     @unittest.skip('There is an inconsistency between slow and fast tokenizer due to a bug in the fast one.' )
     def   _SCREAMING_SNAKE_CASE     ( self      :    Any ):






           """simple docstring"""




           pass







     def   _SCREAMING_SNAKE_CASE     ( self      :    int ):






           """simple docstring"""




           UpperCamelCase					       =  'I was born in 92000, and this is falsé.'
           UpperCamelCase					       =  ['▁', '<unk>', '▁was', '▁born', '▁in', '▁9', '2000', '▁', ',', '▁and', '▁this', '▁is', '▁fal', 's', '<unk>', '▁', '.', ]
           # fmt: on

           UpperCamelCase					       =  DebertaVaTokenizer(_SCREAMING_SNAKE_CASE   ,						split_by_punct=_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  tokenizer.convert_ids_to_tokens(tokenizer.encode(_SCREAMING_SNAKE_CASE   ,						add_special_tokens=_SCREAMING_SNAKE_CASE ) )

           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )

           UpperCamelCase					       =  DebertaVaTokenizerFast(_SCREAMING_SNAKE_CASE   ,						split_by_punct=_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  rust_tokenizer.convert_ids_to_tokens(rust_tokenizer.encode(_SCREAMING_SNAKE_CASE   ,						add_special_tokens=_SCREAMING_SNAKE_CASE ) )

           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )







     def   _SCREAMING_SNAKE_CASE     ( self      :    str ):






           """simple docstring"""




           UpperCamelCase					       =  'I was born in 92000, and this is falsé.'
           UpperCamelCase					       =  ['▁i', '▁was', '▁born', '▁in', '▁9', '2000', '▁', ',', '▁and', '▁this', '▁is', '▁fal', 's', '<unk>', '▁', '.', ]
           # fmt: on

           UpperCamelCase					       =  DebertaVaTokenizer(_SCREAMING_SNAKE_CASE   ,						do_lower_case=_SCREAMING_SNAKE_CASE   ,						split_by_punct=_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  tokenizer.convert_ids_to_tokens(tokenizer.encode(_SCREAMING_SNAKE_CASE   ,						add_special_tokens=_SCREAMING_SNAKE_CASE ) )
           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )

           UpperCamelCase					       =  DebertaVaTokenizerFast(_SCREAMING_SNAKE_CASE   ,						do_lower_case=_SCREAMING_SNAKE_CASE   ,						split_by_punct=_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  rust_tokenizer.convert_ids_to_tokens(rust_tokenizer.encode(_SCREAMING_SNAKE_CASE   ,						add_special_tokens=_SCREAMING_SNAKE_CASE ) )
           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )







     def   _SCREAMING_SNAKE_CASE     ( self      :    Tuple ):






           """simple docstring"""




           UpperCamelCase					       =  'I was born in 92000, and this is falsé.'
           UpperCamelCase					       =  ['▁i', '▁was', '▁born', '▁in', '▁9', '2000', ',', '▁and', '▁this', '▁is', '▁fal', 's', '<unk>', '.', ]
           # fmt: on

           UpperCamelCase					       =  DebertaVaTokenizer(_SCREAMING_SNAKE_CASE   ,						do_lower_case=_SCREAMING_SNAKE_CASE   ,						split_by_punct=_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  tokenizer.convert_ids_to_tokens(tokenizer.encode(_SCREAMING_SNAKE_CASE   ,						add_special_tokens=_SCREAMING_SNAKE_CASE ) )

           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )

           UpperCamelCase					       =  DebertaVaTokenizerFast(_SCREAMING_SNAKE_CASE   ,						do_lower_case=_SCREAMING_SNAKE_CASE   ,						split_by_punct=_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  rust_tokenizer.convert_ids_to_tokens(rust_tokenizer.encode(_SCREAMING_SNAKE_CASE   ,						add_special_tokens=_SCREAMING_SNAKE_CASE ) )

           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )







     def   _SCREAMING_SNAKE_CASE     ( self      :    List[Any] ):






           """simple docstring"""




           UpperCamelCase					       =  'I was born in 92000, and this is falsé.'
           UpperCamelCase					       =  ['▁', '<unk>', '▁was', '▁born', '▁in', '▁9', '2000', '▁', ',', '▁and', '▁this', '▁is', '▁fal', 's', '<unk>', '▁', '.', ]
           # fmt: on

           UpperCamelCase					       =  DebertaVaTokenizer(_SCREAMING_SNAKE_CASE   ,						do_lower_case=_SCREAMING_SNAKE_CASE   ,						split_by_punct=_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  tokenizer.convert_ids_to_tokens(tokenizer.encode(_SCREAMING_SNAKE_CASE   ,						add_special_tokens=_SCREAMING_SNAKE_CASE ) )

           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )

           UpperCamelCase					       =  DebertaVaTokenizerFast(_SCREAMING_SNAKE_CASE   ,						do_lower_case=_SCREAMING_SNAKE_CASE   ,						split_by_punct=_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  rust_tokenizer.convert_ids_to_tokens(rust_tokenizer.encode(_SCREAMING_SNAKE_CASE   ,						add_special_tokens=_SCREAMING_SNAKE_CASE ) )

           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )







     def   _SCREAMING_SNAKE_CASE     ( self      :    Tuple ):






           """simple docstring"""




           UpperCamelCase					       =  ' \tHeLLo!how  \n Are yoU?  '
           UpperCamelCase					       =  ['▁', '<unk>', 'e', '<unk>', 'o', '!', 'how', '▁', '<unk>', 're', '▁yo', '<unk>', '?']
           # fmt: on

           UpperCamelCase					       =  DebertaVaTokenizer(_SCREAMING_SNAKE_CASE   ,						do_lower_case=_SCREAMING_SNAKE_CASE   ,						split_by_punct=_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  tokenizer.convert_ids_to_tokens(tokenizer.encode(_SCREAMING_SNAKE_CASE   ,						add_special_tokens=_SCREAMING_SNAKE_CASE ) )

           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )

           UpperCamelCase					       =  DebertaVaTokenizerFast(_SCREAMING_SNAKE_CASE   ,						do_lower_case=_SCREAMING_SNAKE_CASE   ,						split_by_punct=_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  rust_tokenizer.convert_ids_to_tokens(rust_tokenizer.encode(_SCREAMING_SNAKE_CASE   ,						add_special_tokens=_SCREAMING_SNAKE_CASE ) )

           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )







     def   _SCREAMING_SNAKE_CASE     ( self      :    Optional[int] ):






           """simple docstring"""




           UpperCamelCase					       =  self.get_tokenizer()
           UpperCamelCase					       =  self.get_rust_tokenizer()

           UpperCamelCase					       =  'I was born in 92000, and this is falsé.'

           UpperCamelCase					       =  tokenizer.convert_ids_to_tokens(tokenizer.encode(_SCREAMING_SNAKE_CASE   ,						add_special_tokens=_SCREAMING_SNAKE_CASE ) )
           UpperCamelCase					       =  rust_tokenizer.convert_ids_to_tokens(rust_tokenizer.encode(_SCREAMING_SNAKE_CASE   ,						add_special_tokens=_SCREAMING_SNAKE_CASE ) )
           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )

           UpperCamelCase					       =  tokenizer.encode(_SCREAMING_SNAKE_CASE   ,						add_special_tokens=_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  rust_tokenizer.encode(_SCREAMING_SNAKE_CASE   ,						add_special_tokens=_SCREAMING_SNAKE_CASE )
           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )

           UpperCamelCase					       =  self.get_rust_tokenizer()
           UpperCamelCase					       =  tokenizer.encode(_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  rust_tokenizer.encode(_SCREAMING_SNAKE_CASE )
           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )







     def   _SCREAMING_SNAKE_CASE     ( self      :    Optional[int] ):






           """simple docstring"""




           UpperCamelCase					       =  'This is a test'
           UpperCamelCase					       =  [13, 1, 4398, 25, 21, 1289]
           UpperCamelCase					       =  ['▁', 'T', 'his', '▁is', '▁a', '▁test']
           UpperCamelCase					       =  ['▁', '<unk>', 'his', '▁is', '▁a', '▁test']

           UpperCamelCase					       =  DebertaVaTokenizer(_SCREAMING_SNAKE_CASE   ,						keep_accents=_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  DebertaVaTokenizerFast(_SCREAMING_SNAKE_CASE   ,						keep_accents=_SCREAMING_SNAKE_CASE )

           UpperCamelCase					       =  tokenizer.encode(_SCREAMING_SNAKE_CASE   ,						add_special_tokens=_SCREAMING_SNAKE_CASE )
           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  tokenizer.tokenize(_SCREAMING_SNAKE_CASE )
           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  tokenizer.convert_ids_to_tokens(_SCREAMING_SNAKE_CASE )
           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )

           UpperCamelCase					       =  rust_tokenizer.encode(_SCREAMING_SNAKE_CASE   ,						add_special_tokens=_SCREAMING_SNAKE_CASE )
           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  rust_tokenizer.tokenize(_SCREAMING_SNAKE_CASE )
           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  rust_tokenizer.convert_ids_to_tokens(_SCREAMING_SNAKE_CASE )
           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )

           # fmt: off
           UpperCamelCase					       =  'I was born in 92000, and this is falsé.'
           UpperCamelCase					       =  [13, 1, 23, 386, 19, 561, 3050, 15, 17, 48, 25, 8256, 18, 1, 9]
           UpperCamelCase					       =  ['▁', 'I', '▁was', '▁born', '▁in', '▁9', '2000', ',', '▁and', '▁this', '▁is', '▁fal', 's', 'é', '.', ]
           UpperCamelCase					       =  ['▁', '<unk>', '▁was', '▁born', '▁in', '▁9', '2000', ',', '▁and', '▁this', '▁is', '▁fal', 's', '<unk>', '.', ]
           # fmt: on

           UpperCamelCase					       =  tokenizer.encode(_SCREAMING_SNAKE_CASE   ,						add_special_tokens=_SCREAMING_SNAKE_CASE )
           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  tokenizer.tokenize(_SCREAMING_SNAKE_CASE )
           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  tokenizer.convert_ids_to_tokens(_SCREAMING_SNAKE_CASE )
           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )

           UpperCamelCase					       =  rust_tokenizer.encode(_SCREAMING_SNAKE_CASE   ,						add_special_tokens=_SCREAMING_SNAKE_CASE )
           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  rust_tokenizer.tokenize(_SCREAMING_SNAKE_CASE )
           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  rust_tokenizer.convert_ids_to_tokens(_SCREAMING_SNAKE_CASE )
           self.assertListEqual(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )







     def   _SCREAMING_SNAKE_CASE     ( self      :    Any ):






           """simple docstring"""




           UpperCamelCase					       =  DebertaVaTokenizer(_SCREAMING_SNAKE_CASE )

           UpperCamelCase					       =  tokenizer.encode('sequence builders' )
           UpperCamelCase					       =  tokenizer.encode('multi-sequence build' )

           UpperCamelCase					       =  tokenizer.build_inputs_with_special_tokens(_SCREAMING_SNAKE_CASE )
           UpperCamelCase					       =  tokenizer.build_inputs_with_special_tokens(_SCREAMING_SNAKE_CASE   ,						_SCREAMING_SNAKE_CASE )

           self.assertEqual([tokenizer.cls_token_id] + text + [tokenizer.sep_token_id]   ,						_SCREAMING_SNAKE_CASE )
           self.assertEqual(
               [tokenizer.cls_token_id] + text + [tokenizer.sep_token_id] + text_a + [tokenizer.sep_token_id]   ,						_SCREAMING_SNAKE_CASE   ,						)







     @slow
     def   _SCREAMING_SNAKE_CASE     ( self      :    List[Any] ):






           """simple docstring"""




           UpperCamelCase					       =  {'input_ids': [[1, 3_9867, 36, 1_9390, 486, 27, 3_5052, 8_1436, 18, 6_0685, 1225, 7, 3_5052, 8_1436, 18, 9367, 1_6899, 18, 1_5937, 53, 594, 773, 18, 1_6287, 3_0465, 36, 1_5937, 6, 4_1139, 38, 3_6979, 6_0763, 191, 6, 3_4132, 99, 6, 5_0538, 390, 4_3230, 6, 3_4132, 2779, 2_0850, 14, 699, 1072, 1194, 36, 382, 1_0901, 53, 7, 699, 1072, 2084, 36, 2_0422, 630, 53, 19, 105, 3049, 1896, 1053, 1_6899, 1506, 11, 3_7978, 4243, 7, 1237, 3_1869, 200, 1_6566, 654, 6, 3_5052, 8_1436, 7, 5_5630, 1_3593, 4, 2], [1, 26, 1_5011, 13, 667, 8, 1053, 18, 2_3611, 1237, 7_2356, 1_2820, 34, 10_4134, 1209, 35, 1_3313, 6627, 21, 202, 347, 7, 164, 2399, 11, 46, 4485, 4, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [1, 5, 1232, 2864, 1_5785, 1_4951, 105, 5, 8581, 1250, 4, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]], 'token_type_ids': [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]], 'attention_mask': [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]]}  # noqa: E501
           # fmt: on

           self.tokenizer_integration_test_util(
               expected_encoding=_SCREAMING_SNAKE_CASE   ,						model_name='microsoft/deberta-v2-xlarge'   ,						revision='ad6e42c1532ddf3a15c39246b63f5559d558b670'   ,						)



