





'''simple docstring'''






from dataclasses import asdict, dataclass
from typing import Optional

from ...configuration_utils import PretrainedConfig
from ...utils import logging


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

# TODO Update this
__lowerCamelCase						: List[Any]		=   {
    'facebook/esm-1b': 'https://huggingface.co/facebook/esm-1b/resolve/main/config.json',
    # See all ESM models at https://huggingface.co/models?filter=esm
}







class 		UpperCAmelCase   (				_UpperCamelCase):


		"""simple docstring"""







		lowerCAmelCase_					=				"""esm"""


		def __init__(				self    :					Any							,	UpperCamelCase__    :					str=None							,	UpperCamelCase__    :					Dict=None							,	UpperCamelCase__    :					Dict=None							,	UpperCamelCase__    :					Tuple=768							,	UpperCamelCase__    :					Any=12							,	UpperCamelCase__    :					Any=12							,	UpperCamelCase__    :					Optional[int]=3072							,	UpperCamelCase__    :					Optional[int]=0.1							,	UpperCamelCase__    :					Union[str, Any]=0.1							,	UpperCamelCase__    :					Union[str, Any]=1026							,	UpperCamelCase__    :					Tuple=0.02							,	UpperCamelCase__    :					str=1E-12							,	UpperCamelCase__    :					List[str]="absolute"							,	UpperCamelCase__    :					Union[str, Any]=True							,	UpperCamelCase__    :					Union[str, Any]=None							,	UpperCamelCase__    :					Dict=False							,	UpperCamelCase__    :					Optional[int]=False							,	UpperCamelCase__    :					Any=None							,	UpperCamelCase__    :					Union[str, Any]=None							,	**UpperCamelCase__    :					Union[str, Any]							,	)     ->						Dict:
				super().__init__(pad_token_id=UpperCamelCase__							,	mask_token_id=UpperCamelCase__							,	**UpperCamelCase__  )

				_UpperCamelCase       			=vocab_size
				_UpperCamelCase       			=hidden_size
				_UpperCamelCase       			=num_hidden_layers
				_UpperCamelCase       			=num_attention_heads
				_UpperCamelCase       			=intermediate_size
				_UpperCamelCase       			=hidden_dropout_prob
				_UpperCamelCase       			=attention_probs_dropout_prob
				_UpperCamelCase       			=max_position_embeddings
				_UpperCamelCase       			=initializer_range
				_UpperCamelCase       			=layer_norm_eps
				_UpperCamelCase       			=position_embedding_type
				_UpperCamelCase       			=use_cache
				_UpperCamelCase       			=emb_layer_norm_before
				_UpperCamelCase       			=token_dropout
				_UpperCamelCase       			=is_folding_model
				if is_folding_model:
						if esmfold_config is None:
								logger.info('''No esmfold_config supplied for folding model, using default values.'''  )
								_UpperCamelCase       			=EsmFoldConfig()
						elif isinstance(UpperCamelCase__							,	UpperCamelCase__  ):
								_UpperCamelCase       			=EsmFoldConfig(**UpperCamelCase__  )
						_UpperCamelCase       			=esmfold_config
						if vocab_list is None:
								logger.warning('''No vocab_list supplied for folding model, assuming the ESM-2 vocabulary!'''  )
								_UpperCamelCase       			=get_default_vocab_list()
						else:
								_UpperCamelCase       			=vocab_list
				else:
						_UpperCamelCase       			=None
						_UpperCamelCase       			=None
				if self.esmfold_config is not None and getattr(self.esmfold_config							,	'''use_esm_attn_map'''							,	UpperCamelCase__  ):
						raise ValueError('''The HuggingFace port of ESMFold does not support use_esm_attn_map at this time!'''  )




		def   UpperCamelCase__      (				self    :					List[str]  )     ->						List[Any]:
				_UpperCamelCase       			=super().to_dict()
				if isinstance(self.esmfold_config							,	UpperCamelCase__  ):
						_UpperCamelCase       			=self.esmfold_config.to_dict()
				return output







@dataclass
class 		UpperCAmelCase   :


		"""simple docstring"""







		lowerCAmelCase_					=				None
		lowerCAmelCase_					=				True
		lowerCAmelCase_					=				False
		lowerCAmelCase_					=				False
		lowerCAmelCase_					=				False
		lowerCAmelCase_					=				0

		lowerCAmelCase_					=				True
		lowerCAmelCase_					=				False

		lowerCAmelCase_					=				128
		lowerCAmelCase_					=				None


		def   UpperCamelCase__      (				self    :					Optional[int]  )     ->						int:
				if self.trunk is None:
						_UpperCamelCase       			=TrunkConfig()
				elif isinstance(self.trunk							,	UpperCamelCase__  ):
						_UpperCamelCase       			=TrunkConfig(**self.trunk  )




		def   UpperCamelCase__      (				self    :					Union[str, Any]  )     ->						Optional[Any]:
				_UpperCamelCase       			=asdict(self  )
				_UpperCamelCase       			=self.trunk.to_dict()
				return output







@dataclass
class 		UpperCAmelCase   :


		"""simple docstring"""







		lowerCAmelCase_					=				48
		lowerCAmelCase_					=				1_024
		lowerCAmelCase_					=				128
		lowerCAmelCase_					=				32
		lowerCAmelCase_					=				32
		lowerCAmelCase_					=				32
		lowerCAmelCase_					=				0
		lowerCAmelCase_					=				0
		lowerCAmelCase_					=				False
		lowerCAmelCase_					=				4
		lowerCAmelCase_					=				128
		lowerCAmelCase_					=				None


		def   UpperCamelCase__      (				self    :					Dict  )     ->						int:
				if self.structure_module is None:
						_UpperCamelCase       			=StructureModuleConfig()
				elif isinstance(self.structure_module							,	UpperCamelCase__  ):
						_UpperCamelCase       			=StructureModuleConfig(**self.structure_module  )

				if self.max_recycles <= 0:
						raise ValueError(F'''`max_recycles` should be positive, got {self.max_recycles}.'''  )
				if self.sequence_state_dim % self.sequence_state_dim != 0:
						raise ValueError(
						    '''`sequence_state_dim` should be a round multiple of `sequence_state_dim`, got'''
						    F''' {self.sequence_state_dim} and {self.sequence_state_dim}.'''  )
				if self.pairwise_state_dim % self.pairwise_state_dim != 0:
						raise ValueError(
						    '''`pairwise_state_dim` should be a round multiple of `pairwise_state_dim`, got'''
						    F''' {self.pairwise_state_dim} and {self.pairwise_state_dim}.'''  )

				_UpperCamelCase       			=self.sequence_state_dim // self.sequence_head_width
				_UpperCamelCase       			=self.pairwise_state_dim // self.pairwise_head_width

				if self.sequence_state_dim != sequence_num_heads * self.sequence_head_width:
						raise ValueError(
						    '''`sequence_state_dim` should be equal to `sequence_num_heads * sequence_head_width, got'''
						    F''' {self.sequence_state_dim} != {sequence_num_heads} * {self.sequence_head_width}.'''  )
				if self.pairwise_state_dim != pairwise_num_heads * self.pairwise_head_width:
						raise ValueError(
						    '''`pairwise_state_dim` should be equal to `pairwise_num_heads * pairwise_head_width, got'''
						    F''' {self.pairwise_state_dim} != {pairwise_num_heads} * {self.pairwise_head_width}.'''  )
				if self.pairwise_state_dim % 2 != 0:
						raise ValueError(F'''`pairwise_state_dim` should be even, got {self.pairwise_state_dim}.'''  )

				if self.dropout >= 0.4:
						raise ValueError(F'''`dropout` should not be greater than 0.4, got {self.dropout}.'''  )




		def   UpperCamelCase__      (				self    :					Optional[Any]  )     ->						int:
				_UpperCamelCase       			=asdict(self  )
				_UpperCamelCase       			=self.structure_module.to_dict()
				return output







@dataclass
class 		UpperCAmelCase   :


		"""simple docstring"""







		lowerCAmelCase_					=				384
		lowerCAmelCase_					=				128
		lowerCAmelCase_					=				16
		lowerCAmelCase_					=				128
		lowerCAmelCase_					=				12
		lowerCAmelCase_					=				4
		lowerCAmelCase_					=				8
		lowerCAmelCase_					=				0.1
		lowerCAmelCase_					=				8
		lowerCAmelCase_					=				1
		lowerCAmelCase_					=				2
		lowerCAmelCase_					=				7
		lowerCAmelCase_					=				10
		lowerCAmelCase_					=				1e-8
		lowerCAmelCase_					=				1e5


		def   UpperCamelCase__      (				self    :					Dict  )     ->						List[str]:
				return asdict(self  )




def 					_a   ():


		"""simple docstring"""

		return (
		    "<cls>",
		    "<pad>",
		    "<eos>",
		    "<unk>",
		    "L",
		    "A",
		    "G",
		    "V",
		    "S",
		    "E",
		    "R",
		    "T",
		    "I",
		    "D",
		    "P",
		    "K",
		    "Q",
		    "N",
		    "F",
		    "Y",
		    "M",
		    "H",
		    "W",
		    "C",
		    "X",
		    "B",
		    "U",
		    "Z",
		    "O",
		    ".",
		    "-",
		    "<null_1>",
		    "<mask>",
		)













'''simple docstring'''






import argparse
import datetime


def 					_a   (__SCREAMING_SNAKE_CASE   ):


  """simple docstring"""

  _UpperCamelCase       			={
      '''0''': '''Sunday''',
      '''1''': '''Monday''',
      '''2''': '''Tuesday''',
      '''3''': '''Wednesday''',
      '''4''': '''Thursday''',
      '''5''': '''Friday''',
      '''6''': '''Saturday''',
  }

  _UpperCamelCase       			={0: 1, 1: 2, 2: 3, 3: 4, 4: 5, 5: 6, 6: 0}

  # Validate
  if not 0 < len(__SCREAMING_SNAKE_CASE   ) < 11:
    raise ValueError('''Must be 10 characters long'''   )

  # Get month
  _UpperCamelCase       			=int(date_input[0] + date_input[1]   )
  # Validate
  if not 0 < m < 13:
    raise ValueError('''Month must be between 1 - 12'''   )

  _UpperCamelCase       			=date_input[2]
  # Validate
  if sep_a not in ["-", "/"]:
    raise ValueError('''Date separator must be \'-\' or \'/\''''   )

  # Get day
  _UpperCamelCase       			=int(date_input[3] + date_input[4]   )
  # Validate
  if not 0 < d < 32:
    raise ValueError('''Date must be between 1 - 31'''   )

  # Get second separator
  _UpperCamelCase       			=date_input[5]
  # Validate
  if sep_a not in ["-", "/"]:
    raise ValueError('''Date separator must be \'-\' or \'/\''''   )

  # Get year
  _UpperCamelCase       			=int(date_input[6] + date_input[7] + date_input[8] + date_input[9]   )
  # Arbitrary year range
  if not 45 < y < 8500:
    raise ValueError(
        '''Year out of range. There has to be some sort of limit...right?'''   )

  # Get datetime obj for validation
  _UpperCamelCase       			=datetime.date(int(__SCREAMING_SNAKE_CASE   )  ,      int(__SCREAMING_SNAKE_CASE   )  ,      int(__SCREAMING_SNAKE_CASE   )   )

  # Start math
  if m <= 2:
    _UpperCamelCase       			=y - 1
    _UpperCamelCase       			=m + 12
  # maths var
  _UpperCamelCase       			=int(str(__SCREAMING_SNAKE_CASE   )[:2]   )
  _UpperCamelCase       			=int(str(__SCREAMING_SNAKE_CASE   )[2:]   )
  _UpperCamelCase       			=int(2.6 * m - 5.3_9   )
  _UpperCamelCase       			=int(c / 4   )
  _UpperCamelCase       			=int(k / 4   )
  _UpperCamelCase       			=int(d + k   )
  _UpperCamelCase       			=int(t + u + v + x   )
  _UpperCamelCase       			=int(z - (2 * c)   )
  _UpperCamelCase       			=round(w % 7   )
  # End math

  # Validate math
  if f != convert_datetime_days[dt_ck.weekday()]:
    raise AssertionError('''The date was evaluated incorrectly. Contact developer.'''   )

  # Response
  _UpperCamelCase       			=f'''Your date {date_input}, is a {days[str(__SCREAMING_SNAKE_CASE   )]}!'''
  return response


if __name__ == "__main__":
      import doctest

      doctest.testmod()
      __lowerCamelCase						: List[Any]		=   argparse.ArgumentParser(
          description=(
              'Find out what day of the week nearly any date is or was. Enter '
              'date as a string in the mm-dd-yyyy or mm/dd/yyyy format'
          )
      )
      parser.add_argument(
          'date_input', type=str, help='Date as a string (mm-dd-yyyy or mm/dd/yyyy)'
      )
      __lowerCamelCase						: Union[str, Any]		=   parser.parse_args()
      zeller(args.date_input)






