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       _snake_case	(   ):
		"""simple docstring"""







		SCREAMING_SNAKE_CASE_  :		Union[str, Any]				      =    ArgumentParser("Transformers CLI tool"   , usage="transformers-cli <command> [<args>]"	)
		SCREAMING_SNAKE_CASE_  :		Union[str, Any]				      =    parser.add_subparsers(help="transformers-cli command helpers"	)

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

		# Let's go
		SCREAMING_SNAKE_CASE_  :		Any				      =    parser.parse_args()

		if not hasattr(lowerCAmelCase   , "func"	):
				parser.print_help()
				exit(1	)

		# Run
		SCREAMING_SNAKE_CASE_  :		int				      =    args.func(lowerCAmelCase	)
		service.run()


if __name__ == "__main__":
		main()

def       _snake_case	(   lowerCAmelCase							:   int	):
		"""simple docstring"""







		SCREAMING_SNAKE_CASE_  :		Tuple				      =    int(lowerCAmelCase	)
		if decimal in (0, 1):  # Exit cases for the recursion
				return str(lowerCAmelCase	)
		SCREAMING_SNAKE_CASE_      ,    SCREAMING_SNAKE_CASE_  :		Dict				      =    divmod(lowerCAmelCase   , 2	)
		return binary_recursive(lowerCAmelCase	) + str(lowerCAmelCase	)




def       _snake_case	(   lowerCAmelCase							:   str	):
		"""simple docstring"""







		SCREAMING_SNAKE_CASE_  :		str				      =    str(lowerCAmelCase	).strip()
		if not number:
				raise ValueError("No input value was provided"	)
		SCREAMING_SNAKE_CASE_  :		List[str]				      =    "-" if number.startswith("-"	) else ""
		SCREAMING_SNAKE_CASE_  :		Optional[Any]				      =    number.lstrip("-"	)
		if not number.isnumeric():
				raise ValueError("Input value is not an integer"	)
		return f'{negative}0b{binary_recursive(int(lowerCAmelCase	)	)}'


if __name__ == "__main__":
		from doctest import testmod

		testmod()
