



import torch

from transformers import PreTrainedModel

from .custom_configuration import CustomConfig, NoSuperInitConfig



class        lowerCAmelCase_	(						lowerCAmelCase__							):
							UpperCAmelCase__       :      int       =						CustomConfig
							def __init__(    self,    SCREAMING_SNAKE_CASE_ )  ->	str:
										super().__init__(lowerCAmelCase_ )
										UpperCamelCase					:						str					=			torch.nn.Linear(config.hidden_size,    config.hidden_size )
							def       snake_case_ (    self,    SCREAMING_SNAKE_CASE_ )  ->	int:
										return self.linear(lowerCAmelCase_ )






							def       snake_case_ (    self,    SCREAMING_SNAKE_CASE_ )  ->	Optional[Any]:
										pass






class        lowerCAmelCase_	(						lowerCAmelCase__							):
							UpperCAmelCase__       :      Tuple       =						NoSuperInitConfig
							def __init__(    self,    SCREAMING_SNAKE_CASE_ )  ->	Any:
										super().__init__(lowerCAmelCase_ )
										UpperCamelCase					:						Optional[Any]					=			torch.nn.Linear(config.attribute,    config.attribute )
							def       snake_case_ (    self,    SCREAMING_SNAKE_CASE_ )  ->	Optional[Any]:
										return self.linear(lowerCAmelCase_ )






							def       snake_case_ (    self,    SCREAMING_SNAKE_CASE_ )  ->	str:
										pass








from typing import TYPE_CHECKING

from ...utils import OptionalDependencyNotAvailable, _LazyModule, is_torch_available, is_vision_available


__UpperCAmelCase      = {
    '''configuration_deta''': ['''DETA_PRETRAINED_CONFIG_ARCHIVE_MAP''', '''DetaConfig'''],
}

try:
    if not is_vision_available():
        raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
    pass
else:
    __UpperCAmelCase      = ['''DetaImageProcessor''']

try:
    if not is_torch_available():
        raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
    pass
else:
    __UpperCAmelCase      = [
        '''DETA_PRETRAINED_MODEL_ARCHIVE_LIST''',
        '''DetaForObjectDetection''',
        '''DetaModel''',
        '''DetaPreTrainedModel''',
    ]


if TYPE_CHECKING:
    from .configuration_deta import DETA_PRETRAINED_CONFIG_ARCHIVE_MAP, DetaConfig

    try:
        if not is_vision_available():
            raise OptionalDependencyNotAvailable()
    except OptionalDependencyNotAvailable:
        pass
    else:
        from .image_processing_deta import DetaImageProcessor

    try:
        if not is_torch_available():
            raise OptionalDependencyNotAvailable()
    except OptionalDependencyNotAvailable:
        pass
    else:
        from .modeling_deta import (
            DETA_PRETRAINED_MODEL_ARCHIVE_LIST,
            DetaForObjectDetection,
            DetaModel,
            DetaPreTrainedModel,
        )

else:
    import sys

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



