





'''simple docstring'''




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


_A:					Union[str, Any]							=				logging.get_logger(__name__)

_A:					int							=				{
    """alibaba-damo/mgp-str-base""": """https://huggingface.co/alibaba-damo/mgp-str-base/resolve/main/config.json""",
}






class UpperCAmelCase							(		UpperCAmelCase_							):
    _A :			Optional[int]						   =       """mgp-str"""



    def __init__(  self     ,			__A=[32, 128]     ,			__A=4     ,			__A=3     ,			__A=27     ,			__A=38     ,			__A=50_257     ,			__A=30_522     ,			__A=768     ,			__A=12     ,			__A=12     ,			__A=4.0     ,			__A=True     ,			__A=False     ,			__A=1E-5     ,			__A=0.0     ,			__A=0.0     ,			__A=0.0     ,			__A=False     ,			__A=0.0_2     ,			**__A     ,			):
     super().__init__(**__A					)

     __UpperCAmelCase					=   image_size
     __UpperCAmelCase					=   patch_size
     __UpperCAmelCase					=   num_channels
     __UpperCAmelCase					=   max_token_length
     __UpperCAmelCase					=   num_character_labels
     __UpperCAmelCase					=   num_bpe_labels
     __UpperCAmelCase					=   num_wordpiece_labels
     __UpperCAmelCase					=   hidden_size
     __UpperCAmelCase					=   num_hidden_layers
     __UpperCAmelCase					=   num_attention_heads
     __UpperCAmelCase					=   mlp_ratio
     __UpperCAmelCase					=   distilled
     __UpperCAmelCase					=   layer_norm_eps
     __UpperCAmelCase					=   drop_rate
     __UpperCAmelCase					=   qkv_bias
     __UpperCAmelCase					=   attn_drop_rate
     __UpperCAmelCase					=   drop_path_rate
     __UpperCAmelCase					=   output_aa_attentions
     __UpperCAmelCase					=   initializer_range












'''simple docstring'''




from typing import TYPE_CHECKING

from ...utils import OptionalDependencyNotAvailable, _LazyModule, is_torch_available


_A:					List[str]							=				{
    """configuration_luke""": ["""LUKE_PRETRAINED_CONFIG_ARCHIVE_MAP""", """LukeConfig"""],
    """tokenization_luke""": ["""LukeTokenizer"""],
}

try:
    if not is_torch_available():
        raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
    pass
else:
    _A:					Union[str, Any]							=				[
        """LUKE_PRETRAINED_MODEL_ARCHIVE_LIST""",
        """LukeForEntityClassification""",
        """LukeForEntityPairClassification""",
        """LukeForEntitySpanClassification""",
        """LukeForMultipleChoice""",
        """LukeForQuestionAnswering""",
        """LukeForSequenceClassification""",
        """LukeForTokenClassification""",
        """LukeForMaskedLM""",
        """LukeModel""",
        """LukePreTrainedModel""",
    ]


if TYPE_CHECKING:
    from .configuration_luke import LUKE_PRETRAINED_CONFIG_ARCHIVE_MAP, LukeConfig
    from .tokenization_luke import LukeTokenizer

    try:
        if not is_torch_available():
            raise OptionalDependencyNotAvailable()
    except OptionalDependencyNotAvailable:
        pass
    else:
        from .modeling_luke import (
            LUKE_PRETRAINED_MODEL_ARCHIVE_LIST,
            LukeForEntityClassification,
            LukeForEntityPairClassification,
            LukeForEntitySpanClassification,
            LukeForMaskedLM,
            LukeForMultipleChoice,
            LukeForQuestionAnswering,
            LukeForSequenceClassification,
            LukeForTokenClassification,
            LukeModel,
            LukePreTrainedModel,
        )

else:
    import sys

    _A:					str							=				_LazyModule(__name__, globals()["""__file__"""], _import_structure, module_spec=__spec__)





