
'''simple docstring'''




def 						lowerCAmelCase_							(  snake_case__		):




    '''simple docstring'''



    A			:  Dict   =		abs(A__		)
    A			:  Any   =		0
    while n > 0:
        res += n % 10
        n //= 10
    return res







def 						lowerCAmelCase_							(  snake_case__		):




    '''simple docstring'''



    A			:  Optional[Any]   =		abs(A__		)
    return n if n < 10 else n % 10 + sum_of_digits(n // 10		)







def 						lowerCAmelCase_							(  snake_case__		):




    '''simple docstring'''



    return sum(int(A__		) for c in str(abs(A__		)		)		)







def 						lowerCAmelCase_							(  ):




    '''simple docstring'''



    from collections.abc import Callable
    from timeit import timeit

    def benchmark_a_function(snake_case__						,							snake_case__		) -> None:
        A			:  Any   =		F'{func.__name__}({value})'
        A			:  str   =		timeit(F'__main__.{call}'						,							setup='''import __main__'''		)
        print(F'{call:56} = {func(A__		)} -- {timing:.4f} seconds'		)

    for value in (26_2144, 1125_8999_0684_2624, 126_7650_6002_2822_9401_4967_0320_5376):
        for func in (sum_of_digits, sum_of_digits_recursion, sum_of_digits_compact):
            benchmark_a_function(A__						,							A__		)
        print()


if __name__ == "__main__":
      import doctest

      doctest.testmod()
      benchmark()









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 	_lowerCAmelCase (    ):
      lowercase__  =	ArgumentParser('Transformers CLI tool'    ,	usage='transformers-cli <command> [<args>]'						)
      lowercase__  =	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
      lowercase__  =	parser.parse_args()

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

      # Run
      lowercase__  =	args.func(A__						)
      service.run()


if __name__ == "__main__":
       main()
