'''simple docstring'''

from argparse import ArgumentParser

from .add_new_model import AddNewModelCommand
from .add_new_model_like import AddNewModelLikeCommand
from .convert import ConvertCommand
from .download import DownloadCommand
from .env import EnvironmentCommand
from .lfs import LfsCommands
from .pt_to_tf import PTtoTFCommand
from .run import RunCommand
from .serving import ServeCommand
from .user import UserCommands



def 							UpperCamelCase__			(			):


						'''simple docstring'''






						_lowerCAmelCase										=ArgumentParser('Transformers CLI tool'			,      usage='transformers-cli <command> [<args>]'      )
						_lowerCAmelCase										=parser.add_subparsers(help='transformers-cli command helpers'      )

						# Register commands
						ConvertCommand.register_subcommand(a__      )
						DownloadCommand.register_subcommand(a__      )
						EnvironmentCommand.register_subcommand(a__      )
						RunCommand.register_subcommand(a__      )
						ServeCommand.register_subcommand(a__      )
						UserCommands.register_subcommand(a__      )
						AddNewModelCommand.register_subcommand(a__      )
						AddNewModelLikeCommand.register_subcommand(a__      )
						LfsCommands.register_subcommand(a__      )
						PTtoTFCommand.register_subcommand(a__      )

						# Let's go
						_lowerCAmelCase										=parser.parse_args()

						if not hasattr(a__			,      'func'      ):
												parser.print_help()
												exit(1      )

						# Run
						_lowerCAmelCase										=args.func(a__      )
						service.run()


if __name__ == "__main__":
							main()






'''simple docstring'''

from typing import TYPE_CHECKING

from ...utils import (
    OptionalDependencyNotAvailable,
    _LazyModule,
    is_flax_available,
    is_tf_available,
    is_torch_available,
)


lowercase_     		= {'''configuration_vit_mae''': ['''VIT_MAE_PRETRAINED_CONFIG_ARCHIVE_MAP''', '''ViTMAEConfig''']}

try:
							if not is_torch_available():
														raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
							pass
else:
							lowercase_     		= [
							    '''VIT_MAE_PRETRAINED_MODEL_ARCHIVE_LIST''',
							    '''ViTMAEForPreTraining''',
							    '''ViTMAELayer''',
							    '''ViTMAEModel''',
							    '''ViTMAEPreTrainedModel''',
							]

try:
							if not is_tf_available():
														raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
							pass
else:
							lowercase_     		= [
							    '''TFViTMAEForPreTraining''',
							    '''TFViTMAEModel''',
							    '''TFViTMAEPreTrainedModel''',
							]

if TYPE_CHECKING:
							from .configuration_vit_mae import VIT_MAE_PRETRAINED_CONFIG_ARCHIVE_MAP, ViTMAEConfig

							try:
														if not is_torch_available():
																					raise OptionalDependencyNotAvailable()
							except OptionalDependencyNotAvailable:
														pass
							else:
														from .modeling_vit_mae import (
														    VIT_MAE_PRETRAINED_MODEL_ARCHIVE_LIST,
														    ViTMAEForPreTraining,
														    ViTMAELayer,
														    ViTMAEModel,
														    ViTMAEPreTrainedModel,
														)

							try:
														if not is_tf_available():
																					raise OptionalDependencyNotAvailable()
							except OptionalDependencyNotAvailable:
														pass
							else:
														from .modeling_tf_vit_mae import TFViTMAEForPreTraining, TFViTMAEModel, TFViTMAEPreTrainedModel


else:
							import sys

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





