

_a			=       {hex(i)[2:]: i for i in range(1_6)}  # Use [:2] to strip off the leading '0x'







def _a			(	SCREAMING_SNAKE_CASE		:      str		)   ->   int:

 """simple docstring"""






 __lowerCAmelCase:       int            =				hex_string.strip().lower()
 if not hex_string:
  raise ValueError('Empty string was passed to the function'		)
 __lowerCAmelCase:       List[str]            =				hex_string[0] == '-'
 if is_negative:
  __lowerCAmelCase:       Optional[Any]            =				hex_string[1:]
 if not all(char in hex_table for char in hex_string		):
  raise ValueError('Non-hexadecimal value was passed to the function'		)
 __lowerCAmelCase:       Dict            =				0
 for char in hex_string:
  __lowerCAmelCase:       int            =				16 * decimal_number + hex_table[char]
 return -decimal_number if is_negative else decimal_number


if __name__ == "__main__":
  from doctest import testmod

  testmod()








import torch

from transformers import PreTrainedModel

from .custom_configuration import CustomConfig, NoSuperInitConfig






class 							A_			(		snake_case__ ):
     _lowercase      :					Any       =     CustomConfig


     def __init__(							self      :		List[Any]      ,  UpperCAmelCase      :		Optional[Any] )							->     int:
      super().__init__(UpperCAmelCase )
      __lowerCAmelCase:       Tuple            =				torch.nn.Linear(config.hidden_size      ,  config.hidden_size )


     def   UpperCAmelCase  (							self      :		Optional[int]      ,  UpperCAmelCase      :		Tuple )							->     Union[str, Any]:
      return self.linear(UpperCAmelCase )


     def   UpperCAmelCase  (							self      :		str      ,  UpperCAmelCase      :		str )							->     Optional[int]:
      pass







class 							A_			(		snake_case__ ):
     _lowercase      :					str       =     NoSuperInitConfig


     def __init__(							self      :		List[Any]      ,  UpperCAmelCase      :		Union[str, Any] )							->     int:
      super().__init__(UpperCAmelCase )
      __lowerCAmelCase:       int            =				torch.nn.Linear(config.attribute      ,  config.attribute )


     def   UpperCAmelCase  (							self      :		Tuple      ,  UpperCAmelCase      :		Tuple )							->     Tuple:
      return self.linear(UpperCAmelCase )


     def   UpperCAmelCase  (							self      :		Optional[Any]      ,  UpperCAmelCase      :		Any )							->     str:
      pass





