
from collections import OrderedDict
from typing import Mapping

from ...configuration_utils import PretrainedConfig
from ...onnx import OnnxConfig
from ...utils import logging


__magic_name__  							=	logging.get_logger(__name__)

__magic_name__  							=	{
    '''distilbert-base-uncased''': '''https://huggingface.co/distilbert-base-uncased/resolve/main/config.json''',
    '''distilbert-base-uncased-distilled-squad''': (
        '''https://huggingface.co/distilbert-base-uncased-distilled-squad/resolve/main/config.json'''
    ),
    '''distilbert-base-cased''': '''https://huggingface.co/distilbert-base-cased/resolve/main/config.json''',
    '''distilbert-base-cased-distilled-squad''': (
        '''https://huggingface.co/distilbert-base-cased-distilled-squad/resolve/main/config.json'''
    ),
    '''distilbert-base-german-cased''': '''https://huggingface.co/distilbert-base-german-cased/resolve/main/config.json''',
    '''distilbert-base-multilingual-cased''': (
        '''https://huggingface.co/distilbert-base-multilingual-cased/resolve/main/config.json'''
    ),
    '''distilbert-base-uncased-finetuned-sst-2-english''': (
        '''https://huggingface.co/distilbert-base-uncased-finetuned-sst-2-english/resolve/main/config.json'''
    ),
}




class        _SCREAMING_SNAKE_CASE	(   __UpperCamelCase			):
      _A    :		Dict     						=  'distilbert'
      _A    :		Optional[int]     						=  {
          'hidden_size': 'dim',
          'num_attention_heads': 'n_heads',
          'num_hidden_layers': 'n_layers',
      }
      def __init__(      self		,						lowerCamelCase=3_05_22		,						lowerCamelCase=5_12		,						lowerCamelCase=False		,						lowerCamelCase=6		,						lowerCamelCase=12		,						lowerCamelCase=7_68		,						lowerCamelCase=4 * 7_68		,						lowerCamelCase=0.1		,						lowerCamelCase=0.1		,						lowerCamelCase="gelu"		,						lowerCamelCase=0.0_2		,						lowerCamelCase=0.1		,						lowerCamelCase=0.2		,						lowerCamelCase=0		,						**lowerCamelCase		,						):
          snake_case__    =					vocab_size
          snake_case__    =					max_position_embeddings
          snake_case__    =					sinusoidal_pos_embds
          snake_case__    =					n_layers
          snake_case__    =					n_heads
          snake_case__    =					dim
          snake_case__    =					hidden_dim
          snake_case__    =					dropout
          snake_case__    =					attention_dropout
          snake_case__    =					activation
          snake_case__    =					initializer_range
          snake_case__    =					qa_dropout
          snake_case__    =					seq_classif_dropout
          super().__init__(**lowerCamelCase		,						pad_token_id=lowerCamelCase			)





class        _SCREAMING_SNAKE_CASE	(   __UpperCamelCase			):
      @property
      def A_      (      self			):
          if self.task == "multiple-choice":
              snake_case__    =					{0: "batch", 1: "choice", 2: "sequence"}
          else:
              snake_case__    =					{0: "batch", 1: "sequence"}
          return OrderedDict(
              [
                  ("input_ids", dynamic_axis),
                  ("attention_mask", dynamic_axis),
              ]			)





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


__magic_name__  							=	logging.get_logger(__name__)

__magic_name__  							=	{
    '''microsoft/biogpt''': '''https://huggingface.co/microsoft/biogpt/resolve/main/config.json''',
    # See all BioGPT models at https://huggingface.co/models?filter=biogpt
}




class        _SCREAMING_SNAKE_CASE	(   __UpperCamelCase			):
      _A    :		Dict     						=  'biogpt'
      def __init__(      self		,						lowerCamelCase=4_23_84		,						lowerCamelCase=10_24		,						lowerCamelCase=24		,						lowerCamelCase=16		,						lowerCamelCase=40_96		,						lowerCamelCase="gelu"		,						lowerCamelCase=0.1		,						lowerCamelCase=0.1		,						lowerCamelCase=10_24		,						lowerCamelCase=0.0_2		,						lowerCamelCase=1e-12		,						lowerCamelCase=True		,						lowerCamelCase=True		,						lowerCamelCase=0.0		,						lowerCamelCase=0.0		,						lowerCamelCase=1		,						lowerCamelCase=0		,						lowerCamelCase=2		,						**lowerCamelCase		,						):
          snake_case__    =					vocab_size
          snake_case__    =					max_position_embeddings
          snake_case__    =					hidden_size
          snake_case__    =					num_hidden_layers
          snake_case__    =					num_attention_heads
          snake_case__    =					intermediate_size
          snake_case__    =					hidden_act
          snake_case__    =					hidden_dropout_prob
          snake_case__    =					attention_probs_dropout_prob
          snake_case__    =					initializer_range
          snake_case__    =					layer_norm_eps
          snake_case__    =					scale_embedding
          snake_case__    =					use_cache
          snake_case__    =					layerdrop
          snake_case__    =					activation_dropout
          super().__init__(pad_token_id=lowerCamelCase		,						bos_token_id=lowerCamelCase		,						eos_token_id=lowerCamelCase		,						**lowerCamelCase			)



