


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


__UpperCamelCase       :       str						       =				logging.get_logger(__name__)

class       __magic_name__	(     __lowerCAmelCase):
     A:		Optional[Any]			=      "timm_backbone"


     def __init__(      self							:     Optional[Any]							,	lowerCamelCase__							:     Optional[int]=None							,	lowerCamelCase__							:     str=3							,	lowerCamelCase__							:     List[str]=True							,	lowerCamelCase__							:     int=True							,	lowerCamelCase__							:     List[str]=None							,	**lowerCamelCase__							:     Union[str, Any]							,	)  ->      Dict:





      '''simple docstring'''






      super().__init__(**lowerCamelCase__			)
      UpperCamelCase__					:    str          =   backbone
      UpperCamelCase__					:    Union[str, Any]          =   num_channels
      UpperCamelCase__					:    List[str]          =   features_only
      UpperCamelCase__					:    Dict          =   use_pretrained_backbone
      UpperCamelCase__					:    Optional[Any]          =   True
      UpperCamelCase__					:    Any          =   out_indices if out_indices is not None else (-1,)






from typing import TYPE_CHECKING

from ...utils import (
    OptionalDependencyNotAvailable,
    _LazyModule,
    is_sentencepiece_available,
    is_speech_available,
    is_torch_available,
)


__UpperCamelCase       :       Dict						       =				{
    "configuration_trocr": ["TROCR_PRETRAINED_CONFIG_ARCHIVE_MAP", "TrOCRConfig"],
    "processing_trocr": ["TrOCRProcessor"],
}


try:
       if not is_torch_available():
              raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
       pass
else:
       __UpperCamelCase       :       Optional[int]						       =				[
           "TROCR_PRETRAINED_MODEL_ARCHIVE_LIST",
           "TrOCRForCausalLM",
           "TrOCRPreTrainedModel",
       ]


if TYPE_CHECKING:
       from .configuration_trocr import TROCR_PRETRAINED_CONFIG_ARCHIVE_MAP, TrOCRConfig
       from .processing_trocr import TrOCRProcessor

       try:
              if not is_torch_available():
                     raise OptionalDependencyNotAvailable()
       except OptionalDependencyNotAvailable:
              pass
       else:
              from .modeling_trocr import TROCR_PRETRAINED_MODEL_ARCHIVE_LIST, TrOCRForCausalLM, TrOCRPreTrainedModel

else:
       import sys

       __UpperCamelCase       :       Tuple						       =				_LazyModule(__name__, globals()["__file__"], _import_structure, module_spec=__spec__)


