





"""simple docstring"""
import inspect
import unittest

from transformers import ViTHybridConfig
from transformers.testing_utils import require_accelerate, require_torch, require_vision, slow, torch_device
from transformers.utils import cached_property, is_torch_available, is_vision_available

from ...test_configuration_common import ConfigTester
from ...test_modeling_common import ModelTesterMixin, _config_zero_init, floats_tensor, ids_tensor
from ...test_pipeline_mixin import PipelineTesterMixin


if is_torch_available():
		import torch
		from torch import nn

		from transformers import ViTHybridForImageClassification, ViTHybridImageProcessor, ViTHybridModel
		from transformers.models.vit_hybrid.modeling_vit_hybrid import VIT_HYBRID_PRETRAINED_MODEL_ARCHIVE_LIST


if is_vision_available():
		from PIL import Image






class 					_UpperCAmelCase   :


					def __init__(					self			:Optional[int]     ,       __UpperCamelCase			:List[Any]     ,       __UpperCamelCase			:List[Any]=13     ,       __UpperCamelCase			:int=64     ,       __UpperCamelCase			:Optional[int]=2     ,       __UpperCamelCase			:str=3     ,       __UpperCamelCase			:Any=True     ,       __UpperCamelCase			:Optional[int]=True     ,       __UpperCamelCase			:Dict=32     ,       __UpperCamelCase			:List[Any]=5     ,       __UpperCamelCase			:str=4     ,       __UpperCamelCase			:str=37     ,       __UpperCamelCase			:Optional[int]="gelu"     ,       __UpperCamelCase			:List[str]=0.1     ,       __UpperCamelCase			:Any=0.1     ,       __UpperCamelCase			:Tuple=10     ,       __UpperCamelCase			:Dict=0.02     ,       __UpperCamelCase			:List[Any]=[1, 16, 4, 4]     ,       __UpperCamelCase			:List[str]=None     ,       ):
												A		=  parent
												A		=  batch_size
												A		=  image_size
												A		=  patch_size
												A		=  num_channels
												A		=  is_training
												A		=  use_labels
												A		=  hidden_size
												A		=  num_hidden_layers
												A		=  num_attention_heads
												A		=  intermediate_size
												A		=  hidden_act
												A		=  hidden_dropout_prob
												A		=  attention_probs_dropout_prob
												A		=  type_sequence_label_size
												A		=  initializer_range
												A		=  scope
												A		=  backbone_featmap_shape

												# in ViT hybrid, the seq length equals the number of patches + 1 (we add 1 for the [CLS] token)
												# the number of patches is based on the feature map of the backbone, which by default uses an output stride
												# of 32, which means that the feature map has a spatial resolution of 1/32 of the input image size
												A		=  (self.image_size // 32) ** 2
												A		=  num_patches + 1


					def 	lowerCamelCase       (					self			:Optional[int]		):
												A		=  floats_tensor([self.batch_size, self.num_channels, self.image_size, self.image_size]		)

												A		=  None
												if self.use_labels:
																			A		=  ids_tensor([self.batch_size]     ,       self.type_sequence_label_size		)

												A		=  self.get_config()

												return config, pixel_values, labels


					def 	lowerCamelCase       (					self			:List[str]		):
												A		=  {
												    "global_padding": "same",
												    "layer_type": "bottleneck",
												    "depths": [3, 4, 9],
												    "out_features": ["stage1", "stage2", "stage3"],
												    "embedding_dynamic_padding": True,
												    "hidden_sizes": [4, 8, 16, 32],
												    "num_groups": 2,
												}

												return ViTHybridConfig(
												    image_size=self.image_size     ,       patch_size=self.patch_size     ,       num_channels=self.num_channels     ,       hidden_size=self.hidden_size     ,       num_hidden_layers=self.num_hidden_layers     ,       num_attention_heads=self.num_attention_heads     ,       intermediate_size=self.intermediate_size     ,       hidden_act=self.hidden_act     ,       hidden_dropout_prob=self.hidden_dropout_prob     ,       attention_probs_dropout_prob=self.attention_probs_dropout_prob     ,       is_decoder=__UpperCamelCase     ,       initializer_range=self.initializer_range     ,       backbone_featmap_shape=self.backbone_featmap_shape     ,       backbone_config=__UpperCamelCase     ,       )


					def 	lowerCamelCase       (					self			:Tuple     ,       __UpperCamelCase			:Optional[int]     ,       __UpperCamelCase			:int     ,       __UpperCamelCase			:Union[str, Any]		):
												A		=  ViTHybridModel(config=__UpperCamelCase		)
												model.to(__UpperCamelCase		)
												model.eval()
												A		=  model(__UpperCamelCase		)
												self.parent.assertEqual(result.last_hidden_state.shape     ,       (self.batch_size, self.seq_length, self.hidden_size)		)


					def 	lowerCamelCase       (					self			:Union[str, Any]     ,       __UpperCamelCase			:Tuple     ,       __UpperCamelCase			:Optional[Any]     ,       __UpperCamelCase			:List[Any]		):
												A		=  self.type_sequence_label_size
												A		=  ViTHybridForImageClassification(__UpperCamelCase		)
												model.to(__UpperCamelCase		)
												model.eval()
												A		=  model(__UpperCamelCase     ,       labels=__UpperCamelCase		)
												self.parent.assertEqual(result.logits.shape     ,       (self.batch_size, self.type_sequence_label_size)		)


					def 	lowerCamelCase       (					self			:str		):
												A		=  self.prepare_config_and_inputs()
												A,	A,	A		=  config_and_inputs
												A		=  {"pixel_values": pixel_values}
												return config, inputs_dict







@require_torch
class 					_UpperCAmelCase   (	lowercase_     ,							lowercase_     ,							unittest.TestCase ):
					UpperCamelCase      =							(ViTHybridModel, ViTHybridForImageClassification) if is_torch_available() else ()
					UpperCamelCase      =							(
					    {'''feature-extraction''': ViTHybridModel, '''image-classification''': ViTHybridForImageClassification}
					    if is_torch_available()
					    else {}
					)
					UpperCamelCase      =							False
					UpperCamelCase      =							False
					UpperCamelCase      =							False


					def 	lowerCamelCase       (					self			:Dict		):
												A		=  ViTHybridModelTester(self		)
												A		=  ConfigTester(self     ,       config_class=__UpperCamelCase     ,       has_text_modality=__UpperCamelCase     ,       hidden_size=37		)


					def 	lowerCamelCase       (					self			:Any		):
												self.config_tester.run_common_tests()


					@unittest.skip(reason="ViT does not use inputs_embeds"		)
					def 	lowerCamelCase       (					self			:List[str]		):
												pass


					def 	lowerCamelCase       (					self			:Dict		):
												A,	A		=  self.model_tester.prepare_config_and_inputs_for_common()

												for model_class in self.all_model_classes:
																			A		=  model_class(__UpperCamelCase		)
																			self.assertIsInstance(model.get_input_embeddings()     ,       (nn.Module)		)
																			A		=  model.get_output_embeddings()
																			self.assertTrue(x is None or isinstance(__UpperCamelCase     ,       nn.Linear		)		)


					def 	lowerCamelCase       (					self			:Any		):
												A,	A		=  self.model_tester.prepare_config_and_inputs_for_common()

												for model_class in self.all_model_classes:
																			A		=  model_class(__UpperCamelCase		)
																			A		=  inspect.signature(model.forward		)
																			# signature.parameters is an OrderedDict => so arg_names order is deterministic
																			A		=  [*signature.parameters.keys()]

																			A		=  ["pixel_values"]
																			self.assertListEqual(arg_names[:1]     ,       __UpperCamelCase		)


					def 	lowerCamelCase       (					self			:Dict		):
												A		=  self.model_tester.prepare_config_and_inputs()
												self.model_tester.create_and_check_model(*__UpperCamelCase		)


					def 	lowerCamelCase       (					self			:Union[str, Any]		):
												A		=  self.model_tester.prepare_config_and_inputs()
												self.model_tester.create_and_check_for_image_classification(*__UpperCamelCase		)


					def 	lowerCamelCase       (					self			:List[str]		):
												A,	A		=  self.model_tester.prepare_config_and_inputs_for_common()

												A		=  _config_zero_init(__UpperCamelCase		)
												for model_class in self.all_model_classes:
																			A		=  model_class(config=__UpperCamelCase		)
																			# Skip the check for the backbone
																			for name, module in model.named_modules():
																										if module.__class__.__name__ == "ViTHybridPatchEmbeddings":
																																	A		=  [f"{name}.{key}" for key in module.state_dict().keys()]
																																	break

																			for name, param in model.named_parameters():
																										if param.requires_grad:
																																	if name in backbone_params:
																																								continue
																																	self.assertIn(
																																	    ((param.data.mean() * 1e9).round() / 1e9).item()     ,       [0.0, 1.0]     ,       msg=f"Parameter {name} of model {model_class} seems not properly initialized"     ,       )


					@slow
					def 	lowerCamelCase       (					self			:Tuple		):
												for model_name in VIT_HYBRID_PRETRAINED_MODEL_ARCHIVE_LIST[:1]:
																			A		=  ViTHybridModel.from_pretrained(__UpperCamelCase		)
																			self.assertIsNotNone(__UpperCamelCase		)







def 					A__				(			):
							A		=  Image.open("./tests/fixtures/tests_samples/COCO/000000039769.png"       )
							return image






@require_torch
@require_vision
class 					_UpperCAmelCase   (	unittest.TestCase ):


					@cached_property
					def 	lowerCamelCase       (					self			:Optional[int]		):
												return (
												    ViTHybridImageProcessor.from_pretrained(VIT_HYBRID_PRETRAINED_MODEL_ARCHIVE_LIST[0]		)
												    if is_vision_available()
												    else None
												)


					@slow
					def 	lowerCamelCase       (					self			:Optional[Any]		):
												A		=  ViTHybridForImageClassification.from_pretrained(VIT_HYBRID_PRETRAINED_MODEL_ARCHIVE_LIST[0]		).to(
												    __UpperCamelCase		)

												A		=  self.default_image_processor
												A		=  prepare_img()
												A		=  image_processor(images=__UpperCamelCase     ,       return_tensors="pt"		).to(__UpperCamelCase		)

												# forward pass
												with torch.no_grad():
																			A		=  model(**__UpperCamelCase		)

												# verify the logits
												A		=  torch.Size((1, 10_00)		)
												self.assertEqual(outputs.logits.shape     ,       __UpperCamelCase		)

												A		=  torch.tensor([-1.9_090, -0.4_993, -0.2_389]		).to(__UpperCamelCase		)

												self.assertTrue(torch.allclose(outputs.logits[0, :3]     ,       __UpperCamelCase     ,       atol=1e-4		)		)


					@slow
					@require_accelerate
					def 	lowerCamelCase       (					self			:Dict		):
												A		=  ViTHybridImageProcessor.from_pretrained("google/vit-hybrid-base-bit-384"		)
												A		=  ViTHybridForImageClassification.from_pretrained("google/vit-hybrid-base-bit-384"     ,       device_map="auto"		)

												A		=  prepare_img()

												A		=  image_processor(images=__UpperCamelCase     ,       return_tensors="pt"		)
												A		=  model(**__UpperCamelCase		)
												A		=  outputs.logits
												# model predicts one of the 1000 ImageNet classes
												A		=  logits.argmax(-1		).item()

												self.assertTrue(model.config.idalabel[predicted_class_idx]     ,       "tabby, tabby cat"		)









"""simple docstring"""
from collections import OrderedDict
from typing import Any, Mapping, Optional

from ... import PreTrainedTokenizer
from ...configuration_utils import PretrainedConfig
from ...onnx import OnnxConfig, OnnxConfigWithPast, OnnxSeqaSeqConfigWithPast
from ...onnx.utils import compute_effective_axis_dimension
from ...utils import TensorType, is_torch_available, logging


_snake_case     :		List[Any]       						= logging.get_logger(__name__)

_snake_case     :		int       						= {
    'Helsinki-NLP/opus-mt-en-de': 'https://huggingface.co/Helsinki-NLP/opus-mt-en-de/resolve/main/config.json',
    # See all Marian models at https://huggingface.co/models?filter=marian
}






class 					_UpperCAmelCase   (	lowercase_ ):
					UpperCamelCase      =							'''marian'''
					UpperCamelCase      =							['''past_key_values''']
					UpperCamelCase      =							{'''num_attention_heads''': '''encoder_attention_heads''', '''hidden_size''': '''d_model'''}


					def __init__(					self			:int     ,       __UpperCamelCase			:Any=5_81_01     ,       __UpperCamelCase			:int=None     ,       __UpperCamelCase			:Union[str, Any]=10_24     ,       __UpperCamelCase			:Union[str, Any]=12     ,       __UpperCamelCase			:str=40_96     ,       __UpperCamelCase			:int=16     ,       __UpperCamelCase			:int=12     ,       __UpperCamelCase			:Optional[Any]=40_96     ,       __UpperCamelCase			:Optional[Any]=16     ,       __UpperCamelCase			:Dict=0.0     ,       __UpperCamelCase			:Dict=0.0     ,       __UpperCamelCase			:str=True     ,       __UpperCamelCase			:Optional[int]=True     ,       __UpperCamelCase			:Any="gelu"     ,       __UpperCamelCase			:Any=10_24     ,       __UpperCamelCase			:List[Any]=0.1     ,       __UpperCamelCase			:Optional[Any]=0.0     ,       __UpperCamelCase			:Union[str, Any]=0.0     ,       __UpperCamelCase			:Tuple=0.02     ,       __UpperCamelCase			:List[str]=5_81_00     ,       __UpperCamelCase			:str=False     ,       __UpperCamelCase			:Optional[int]=5_81_00     ,       __UpperCamelCase			:List[Any]=0     ,       __UpperCamelCase			:List[str]=0     ,       __UpperCamelCase			:Dict=True     ,       **__UpperCamelCase			:Tuple     ,       ):
												A		=  vocab_size
												A		=  decoder_vocab_size or vocab_size
												A		=  max_position_embeddings
												A		=  d_model
												A		=  encoder_ffn_dim
												A		=  encoder_layers
												A		=  encoder_attention_heads
												A		=  decoder_ffn_dim
												A		=  decoder_layers
												A		=  decoder_attention_heads
												A		=  dropout
												A		=  attention_dropout
												A		=  activation_dropout
												A		=  activation_function
												A		=  init_std
												A		=  encoder_layerdrop
												A		=  decoder_layerdrop
												A		=  use_cache
												A		=  encoder_layers
												A		=  scale_embedding  # scale factor will be sqrt(d_model) if True
												A		=  share_encoder_decoder_embeddings
												super().__init__(
												    pad_token_id=__UpperCamelCase     ,       eos_token_id=__UpperCamelCase     ,       is_encoder_decoder=__UpperCamelCase     ,       decoder_start_token_id=__UpperCamelCase     ,       forced_eos_token_id=__UpperCamelCase     ,       **__UpperCamelCase     ,       )







class 					_UpperCAmelCase   (	lowercase_ ):


					@property
					# Copied from transformers.models.bart.configuration_bart.BartOnnxConfig.inputs
					def 	lowerCamelCase       (					self			:List[str]		):
												if self.task in ["default", "seq2seq-lm"]:
																			A		=  OrderedDict(
																			    [
																			        ("input_ids", {0: "batch", 1: "encoder_sequence"}),
																			        ("attention_mask", {0: "batch", 1: "encoder_sequence"}),
																			    ]		)

																			if self.use_past:
																										A		=  {0: "batch"}
																										A		=  {0: "batch", 1: "past_decoder_sequence + sequence"}
																			else:
																										A		=  {0: "batch", 1: "decoder_sequence"}
																										A		=  {0: "batch", 1: "decoder_sequence"}

																			if self.use_past:
																										self.fill_with_past_key_values_(__UpperCamelCase     ,       direction="inputs"		)
												elif self.task == "causal-lm":
																			# TODO: figure this case out.
																			A		=  OrderedDict(
																			    [
																			        ("input_ids", {0: "batch", 1: "encoder_sequence"}),
																			        ("attention_mask", {0: "batch", 1: "encoder_sequence"}),
																			    ]		)
																			if self.use_past:
																										A,	A		=  self.num_layers
																										for i in range(__UpperCamelCase		):
																																	A		=  {0: "batch", 2: "past_sequence + sequence"}
																																	A		=  {0: "batch", 2: "past_sequence + sequence"}
												else:
																			A		=  OrderedDict(
																			    [
																			        ("input_ids", {0: "batch", 1: "encoder_sequence"}),
																			        ("attention_mask", {0: "batch", 1: "encoder_sequence"}),
																			        ("decoder_input_ids", {0: "batch", 1: "decoder_sequence"}),
																			        ("decoder_attention_mask", {0: "batch", 1: "decoder_sequence"}),
																			    ]		)

												return common_inputs


					@property
					# Copied from transformers.models.bart.configuration_bart.BartOnnxConfig.outputs
					def 	lowerCamelCase       (					self			:List[str]		):
												if self.task in ["default", "seq2seq-lm"]:
																			A		=  super().outputs
												else:
																			A		=  super(__UpperCamelCase     ,       self		).outputs
																			if self.use_past:
																										A,	A		=  self.num_layers
																										for i in range(__UpperCamelCase		):
																																	A		=  {0: "batch", 2: "past_sequence + sequence"}
																																	A		=  {0: "batch", 2: "past_sequence + sequence"}
												return common_outputs


					def 	lowerCamelCase       (					self			:Optional[int]     ,       __UpperCamelCase			:PreTrainedTokenizer     ,       __UpperCamelCase			:int = -1     ,       __UpperCamelCase			:int = -1     ,       __UpperCamelCase			:bool = False     ,       __UpperCamelCase			:Optional[TensorType] = None     ,       ):
												A		=  self._generate_dummy_inputs_for_encoder_and_decoder(
												    __UpperCamelCase     ,       __UpperCamelCase     ,       __UpperCamelCase     ,       __UpperCamelCase     ,       __UpperCamelCase		)

												# Generate decoder inputs
												A		=  seq_length if not self.use_past else 1
												A		=  self._generate_dummy_inputs_for_encoder_and_decoder(
												    __UpperCamelCase     ,       __UpperCamelCase     ,       __UpperCamelCase     ,       __UpperCamelCase     ,       __UpperCamelCase		)
												A		=  {f"decoder_{name}": tensor for name, tensor in decoder_inputs.items()}
												A		=  dict(**__UpperCamelCase     ,       **__UpperCamelCase		)

												if self.use_past:
																			if not is_torch_available():
																										raise ValueError("Cannot generate dummy past_keys inputs without PyTorch installed."		)
																			else:
																										import torch
																			A,	A		=  common_inputs["input_ids"].shape
																			A		=  common_inputs["decoder_input_ids"].shape[1]
																			A,	A		=  self.num_attention_heads
																			A		=  (
																			    batch,
																			    num_encoder_attention_heads,
																			    encoder_seq_length,
																			    self._config.hidden_size // num_encoder_attention_heads,
																			)
																			A		=  decoder_seq_length + 3
																			A		=  (
																			    batch,
																			    num_decoder_attention_heads,
																			    decoder_past_length,
																			    self._config.hidden_size // num_decoder_attention_heads,
																			)

																			A		=  torch.cat(
																			    [common_inputs["decoder_attention_mask"], torch.ones(__UpperCamelCase     ,       __UpperCamelCase		)]     ,       dim=1		)

																			A		=  []
																			# If the number of encoder and decoder layers are present in the model configuration, both are considered
																			A,	A		=  self.num_layers
																			A		=  min(__UpperCamelCase     ,       __UpperCamelCase		)
																			A		=  max(__UpperCamelCase     ,       __UpperCamelCase		) - min_num_layers
																			A		=  "encoder" if num_encoder_layers > num_decoder_layers else "decoder"

																			for _ in range(__UpperCamelCase		):
																										common_inputs["past_key_values"].append(
																										    (
																										        torch.zeros(__UpperCamelCase		),
																										        torch.zeros(__UpperCamelCase		),
																										        torch.zeros(__UpperCamelCase		),
																										        torch.zeros(__UpperCamelCase		),
																										    )		)
																			# TODO: test this.
																			A		=  encoder_shape if remaining_side_name == "encoder" else decoder_shape
																			for _ in range(__UpperCamelCase     ,       __UpperCamelCase		):
																										common_inputs["past_key_values"].append((torch.zeros(__UpperCamelCase		), torch.zeros(__UpperCamelCase		))		)
												return common_inputs


					def 	lowerCamelCase       (					self			:Optional[int]     ,       __UpperCamelCase			:PreTrainedTokenizer     ,       __UpperCamelCase			:int = -1     ,       __UpperCamelCase			:int = -1     ,       __UpperCamelCase			:bool = False     ,       __UpperCamelCase			:Optional[TensorType] = None     ,       ):
												A		=  self._generate_dummy_inputs_for_encoder_and_decoder(
												    __UpperCamelCase     ,       __UpperCamelCase     ,       __UpperCamelCase     ,       __UpperCamelCase     ,       __UpperCamelCase		)

												if self.use_past:
																			if not is_torch_available():
																										raise ValueError("Cannot generate dummy past_keys inputs without PyTorch installed."		)
																			else:
																										import torch
																			A,	A		=  common_inputs["input_ids"].shape
																			# Not using the same length for past_key_values
																			A		=  seqlen + 2
																			A,	A		=  self.num_layers
																			A,	A		=  self.num_attention_heads
																			A		=  (
																			    batch,
																			    num_encoder_attention_heads,
																			    past_key_values_length,
																			    self._config.hidden_size // num_encoder_attention_heads,
																			)

																			A		=  common_inputs["attention_mask"].dtype
																			A		=  torch.cat(
																			    [common_inputs["attention_mask"], torch.ones(__UpperCamelCase     ,       __UpperCamelCase     ,       dtype=__UpperCamelCase		)]     ,       dim=1		)
																			A		=  [
																			    (torch.zeros(__UpperCamelCase		), torch.zeros(__UpperCamelCase		)) for _ in range(__UpperCamelCase		)
																			]
												return common_inputs


					def 	lowerCamelCase       (					self			:Tuple     ,       __UpperCamelCase			:PreTrainedTokenizer     ,       __UpperCamelCase			:int = -1     ,       __UpperCamelCase			:int = -1     ,       __UpperCamelCase			:bool = False     ,       __UpperCamelCase			:Optional[TensorType] = None     ,       ):
												# Copied from OnnxConfig.generate_dummy_inputs
												# Did not use super(OnnxConfigWithPast, self).generate_dummy_inputs for code clarity.
												# If dynamic axis (-1) we forward with a fixed dimension of 2 samples to avoid optimizations made by ONNX
												A		=  compute_effective_axis_dimension(
												    __UpperCamelCase     ,       fixed_dimension=OnnxConfig.default_fixed_batch     ,       num_token_to_add=0		)

												# If dynamic axis (-1) we forward with a fixed dimension of 8 tokens to avoid optimizations made by ONNX
												A		=  tokenizer.num_special_tokens_to_add(__UpperCamelCase		)
												A		=  compute_effective_axis_dimension(
												    __UpperCamelCase     ,       fixed_dimension=OnnxConfig.default_fixed_sequence     ,       num_token_to_add=__UpperCamelCase		)

												# Generate dummy inputs according to compute batch and sequence
												A		=  [" ".join([tokenizer.unk_token]		) * seq_length] * batch_size
												A		=  dict(tokenizer(__UpperCamelCase     ,       return_tensors=__UpperCamelCase		)		)
												return common_inputs


					def 	lowerCamelCase       (					self			:List[Any]     ,       __UpperCamelCase			:PreTrainedTokenizer     ,       __UpperCamelCase			:int = -1     ,       __UpperCamelCase			:int = -1     ,       __UpperCamelCase			:bool = False     ,       __UpperCamelCase			:Optional[TensorType] = None     ,       ):
												if self.task in ["default", "seq2seq-lm"]:
																			A		=  self._generate_dummy_inputs_for_default_and_seqaseq_lm(
																			    __UpperCamelCase     ,       batch_size=__UpperCamelCase     ,       seq_length=__UpperCamelCase     ,       is_pair=__UpperCamelCase     ,       framework=__UpperCamelCase		)

												else:
																			A		=  self._generate_dummy_inputs_for_causal_lm(
																			    __UpperCamelCase     ,       batch_size=__UpperCamelCase     ,       seq_length=__UpperCamelCase     ,       is_pair=__UpperCamelCase     ,       framework=__UpperCamelCase		)

												return common_inputs


					def 	lowerCamelCase       (					self			:List[Any]     ,       __UpperCamelCase			:Tuple     ,       __UpperCamelCase			:List[str]     ,       __UpperCamelCase			:str     ,       __UpperCamelCase			:str		):
												if self.task in ["default", "seq2seq-lm"]:
																			A		=  super()._flatten_past_key_values_(__UpperCamelCase     ,       __UpperCamelCase     ,       __UpperCamelCase     ,       __UpperCamelCase		)
												else:
																			A		=  super(__UpperCamelCase     ,       self		)._flatten_past_key_values_(
																			    __UpperCamelCase     ,       __UpperCamelCase     ,       __UpperCamelCase     ,       __UpperCamelCase		)


					@property
					def 	lowerCamelCase       (					self			:List[str]		):
												return 1e-4


