


'''simple docstring'''







from dataclasses import asdict, dataclass
from typing import Optional

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


SCREAMING_SNAKE_CASE_      =			logging.get_logger(__name__)

# TODO Update this
SCREAMING_SNAKE_CASE_      =			{
    '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  lowerCAmelCase_						(       snake_case__      ):





  """simple docstring"""



  a_       :List[str]												="""esm"""

  def __init__(					self     :							int				,							SCREAMING_SNAKE_CASE__     :							int=None				,							SCREAMING_SNAKE_CASE__     :							str=None				,							SCREAMING_SNAKE_CASE__     :							Tuple=None				,							SCREAMING_SNAKE_CASE__     :							Union[str, Any]=7_6_8				,							SCREAMING_SNAKE_CASE__     :							Optional[Any]=1_2				,							SCREAMING_SNAKE_CASE__     :							Any=1_2				,							SCREAMING_SNAKE_CASE__     :							Union[str, Any]=3_0_7_2				,							SCREAMING_SNAKE_CASE__     :							Optional[int]=0.1				,							SCREAMING_SNAKE_CASE__     :							str=0.1				,							SCREAMING_SNAKE_CASE__     :							str=1_0_2_6				,							SCREAMING_SNAKE_CASE__     :							str=0.0_2				,							SCREAMING_SNAKE_CASE__     :							Tuple=1E-12				,							SCREAMING_SNAKE_CASE__     :							Union[str, Any]="absolute"				,							SCREAMING_SNAKE_CASE__     :							int=True				,							SCREAMING_SNAKE_CASE__     :							Tuple=None				,							SCREAMING_SNAKE_CASE__     :							List[str]=False				,							SCREAMING_SNAKE_CASE__     :							Optional[int]=False				,							SCREAMING_SNAKE_CASE__     :							str=None				,							SCREAMING_SNAKE_CASE__     :							Tuple=None				,							**SCREAMING_SNAKE_CASE__     :							Dict				,							):





       '''simple docstring'''

       super().__init__(pad_token_id=SCREAMING_SNAKE_CASE__				,							mask_token_id=SCREAMING_SNAKE_CASE__				,							**SCREAMING_SNAKE_CASE__						)

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


  def __a						(					self     :							Dict						):





       '''simple docstring'''

       __a       =   super().to_dict()
       if isinstance(self.esmfold_config				,							SCREAMING_SNAKE_CASE__						):
            __a       =   self.esmfold_config.to_dict()
       return output


@dataclass
class  lowerCAmelCase_						:





  """simple docstring"""



  a_       :str												=None
  a_       :bool												=True
  a_       :bool												=False
  a_       :bool												=False
  a_       :bool												=False
  a_       :float												=0

  a_       :bool												=True
  a_       :bool												=False

  a_       :int												=128
  a_       :"TrunkConfig"												=None

  def __a						(					self     :							List[str]						):





       '''simple docstring'''

       if self.trunk is None:
            __a       =   TrunkConfig()
       elif isinstance(self.trunk				,							SCREAMING_SNAKE_CASE__						):
            __a       =   TrunkConfig(**self.trunk						)


  def __a						(					self     :							List[Any]						):





       '''simple docstring'''

       __a       =   asdict(self						)
       __a       =   self.trunk.to_dict()
       return output


@dataclass
class  lowerCAmelCase_						:





  """simple docstring"""



  a_       :int												=48
  a_       :int												=1024
  a_       :int												=128
  a_       :int												=32
  a_       :int												=32
  a_       :int												=32
  a_       :float												=0
  a_       :float												=0
  a_       :bool												=False
  a_       :int												=4
  a_       :Optional[int]												=128
  a_       :"StructureModuleConfig"												=None

  def __a						(					self     :							str						):





       '''simple docstring'''

       if self.structure_module is None:
            __a       =   StructureModuleConfig()
       elif isinstance(self.structure_module				,							SCREAMING_SNAKE_CASE__						):
            __a       =   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}.'''						)

       __a       =   self.sequence_state_dim // self.sequence_head_width
       __a       =   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 __a						(					self     :							int						):





       '''simple docstring'''

       __a       =   asdict(self						)
       __a       =   self.structure_module.to_dict()
       return output


@dataclass
class  lowerCAmelCase_						:





  """simple docstring"""



  a_       :int												=384
  a_       :int												=128
  a_       :int												=16
  a_       :int												=128
  a_       :int												=12
  a_       :int												=4
  a_       :int												=8
  a_       :float												=0.1
  a_       :int												=8
  a_       :int												=1
  a_       :int												=2
  a_       :int												=7
  a_       :int												=10
  a_       :float												=1E-8
  a_       :float												=1E5

  def __a						(					self     :							Optional[int]						):





       '''simple docstring'''

       return asdict(self						)




def        __lowercase						(      )				->					Tuple:
     """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'''







def        __lowercase						(      __SCREAMING_SNAKE_CASE		)				->					bool:
     """simple docstring"""




     __a       =   [int(__SCREAMING_SNAKE_CASE		) for i in ip_va_address.split("""."""		) if i.isdigit()]
     return len(__SCREAMING_SNAKE_CASE		) == 4 and all(0 <= int(__SCREAMING_SNAKE_CASE		) <= 254 for octet in octets		)


if __name__ == "__main__":
 SCREAMING_SNAKE_CASE_      =			input().strip()
 SCREAMING_SNAKE_CASE_      =			'valid' if is_ip_va_address_valid(ip) else 'invalid'
 print(f"""{ip} is a {valid_or_invalid} IP v4 address.""")






