



"""simple docstring"""






from typing import TYPE_CHECKING

from ...utils import (
    OptionalDependencyNotAvailable,
    _LazyModule,
    is_sentencepiece_available,
    is_tf_available,
    is_tokenizers_available,
    is_torch_available,
)


lowerCAmelCase__        =				{'''configuration_xlnet''': ['''XLNET_PRETRAINED_CONFIG_ARCHIVE_MAP''', '''XLNetConfig''']}

try:
   if not is_sentencepiece_available():
      raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
   pass
else:
   lowerCAmelCase__        =				['''XLNetTokenizer''']

try:
   if not is_tokenizers_available():
      raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
   pass
else:
   lowerCAmelCase__        =				['''XLNetTokenizerFast''']

try:
   if not is_torch_available():
      raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
   pass
else:
   lowerCAmelCase__        =				[
       '''XLNET_PRETRAINED_MODEL_ARCHIVE_LIST''',
       '''XLNetForMultipleChoice''',
       '''XLNetForQuestionAnswering''',
       '''XLNetForQuestionAnsweringSimple''',
       '''XLNetForSequenceClassification''',
       '''XLNetForTokenClassification''',
       '''XLNetLMHeadModel''',
       '''XLNetModel''',
       '''XLNetPreTrainedModel''',
       '''load_tf_weights_in_xlnet''',
   ]

try:
   if not is_tf_available():
      raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
   pass
else:
   lowerCAmelCase__        =				[
       '''TF_XLNET_PRETRAINED_MODEL_ARCHIVE_LIST''',
       '''TFXLNetForMultipleChoice''',
       '''TFXLNetForQuestionAnsweringSimple''',
       '''TFXLNetForSequenceClassification''',
       '''TFXLNetForTokenClassification''',
       '''TFXLNetLMHeadModel''',
       '''TFXLNetMainLayer''',
       '''TFXLNetModel''',
       '''TFXLNetPreTrainedModel''',
   ]


if TYPE_CHECKING:
   from .configuration_xlnet import XLNET_PRETRAINED_CONFIG_ARCHIVE_MAP, XLNetConfig

   try:
      if not is_sentencepiece_available():
         raise OptionalDependencyNotAvailable()
   except OptionalDependencyNotAvailable:
      pass
   else:
      from .tokenization_xlnet import XLNetTokenizer

   try:
      if not is_tokenizers_available():
         raise OptionalDependencyNotAvailable()
   except OptionalDependencyNotAvailable:
      pass
   else:
      from .tokenization_xlnet_fast import XLNetTokenizerFast

   try:
      if not is_torch_available():
         raise OptionalDependencyNotAvailable()
   except OptionalDependencyNotAvailable:
      pass
   else:
      from .modeling_xlnet import (
          XLNET_PRETRAINED_MODEL_ARCHIVE_LIST,
          XLNetForMultipleChoice,
          XLNetForQuestionAnswering,
          XLNetForQuestionAnsweringSimple,
          XLNetForSequenceClassification,
          XLNetForTokenClassification,
          XLNetLMHeadModel,
          XLNetModel,
          XLNetPreTrainedModel,
          load_tf_weights_in_xlnet,
      )

   try:
      if not is_tf_available():
         raise OptionalDependencyNotAvailable()
   except OptionalDependencyNotAvailable:
      pass
   else:
      from .modeling_tf_xlnet import (
          TF_XLNET_PRETRAINED_MODEL_ARCHIVE_LIST,
          TFXLNetForMultipleChoice,
          TFXLNetForQuestionAnsweringSimple,
          TFXLNetForSequenceClassification,
          TFXLNetForTokenClassification,
          TFXLNetLMHeadModel,
          TFXLNetMainLayer,
          TFXLNetModel,
          TFXLNetPreTrainedModel,
      )

else:
   import sys

   lowerCAmelCase__        =				_LazyModule(__name__, globals()['''__file__'''], _import_structure, module_spec=__spec__)






UpperCAmelCase__   	=							{
    '''A''': '''.-''', '''B''': '''-...''', '''C''': '''-.-.''', '''D''': '''-..''', '''E''': '''.''', '''F''': '''..-.''', '''G''': '''--.''',
    '''H''': '''....''', '''I''': '''..''', '''J''': '''.---''', '''K''': '''-.-''', '''L''': '''.-..''', '''M''': '''--''', '''N''': '''-.''',
    '''O''': '''---''', '''P''': '''.--.''', '''Q''': '''--.-''', '''R''': '''.-.''', '''S''': '''...''', '''T''': '''-''', '''U''': '''..-''',
    '''V''': '''...-''', '''W''': '''.--''', '''X''': '''-..-''', '''Y''': '''-.--''', '''Z''': '''--..''', '''1''': '''.----''',
    '''2''': '''..---''', '''3''': '''...--''', '''4''': '''....-''', '''5''': '''.....''', '''6''': '''-....''', '''7''': '''--...''',
    '''8''': '''---..''', '''9''': '''----.''', '''0''': '''-----''', '''&''': '''.-...''', '''@''': '''.--.-.''',
    ''':''': '''---...''', ''',''': '''--..--''', '''.''': '''.-.-.-''', '''\'''': '''.----.''', '''"''': '''.-..-.''',
    '''?''': '''..--..''', '''/''': '''-..-.''', '''=''': '''-...-''', '''+''': '''.-.-.''', '''-''': '''-....-''',
    '''(''': '''-.--.''', ''')''': '''-.--.-''', '''!''': '''-.-.--''', ''' ''': '''/'''
}  # Exclamation mark is not in ITU-R recommendation
# fmt: on
UpperCAmelCase__   	=							{value: key for key, value in MORSE_CODE_DICT.items()}
def 				UpperCAmelCase_					(							__snake_case						)     ->			str:







 """simple docstring"""


 return " ".join(MORSE_CODE_DICT[char] for char in message.upper()						)
def 				UpperCAmelCase_					(							__snake_case						)     ->			str:







 """simple docstring"""


 return "".join(REVERSE_DICT[char] for char in message.split()						)
def 				UpperCAmelCase_					(							)     ->			None:







 """simple docstring"""


 _lowercase							      ='''Morse code here!'''
 print(__snake_case						)
 _lowercase							      =encrypt(__snake_case						)
 print(__snake_case						)
 _lowercase							      =decrypt(__snake_case						)
 print(__snake_case						)


if __name__ == "__main__":
  main()

