

'''simple docstring'''





from argparse import ArgumentParser

from . import BaseTransformersCLICommand






def 					__lowercase      (     _A			)     ->						Tuple:
      return DownloadCommand(args.model						,    args.cache_dir						,    args.force						,    args.trust_remote_code			)







class        a__       (   __a       ):







  """simple docstring"""




  @staticmethod
  def  _lowercase      (			UpperCAmelCase__    : ArgumentParser		)					->Any:
        """simple docstring"""







        SCREAMING_SNAKE_CASE :      Union[str, Any]       =   parser.add_parser("""download"""		)
        download_parser.add_argument(
            """--cache-dir"""				,				type=snake_case__				,				default=snake_case__				,				help="""Path to location to store the models"""		)
        download_parser.add_argument(
            """--force"""				,				action="""store_true"""				,				help="""Force the model to be download even if already in cache-dir"""		)
        download_parser.add_argument(
            """--trust-remote-code"""				,				action="""store_true"""				,				help="""Whether or not to allow for custom models defined on the Hub in their own modeling files. Use only if you've reviewed the code as it will execute on your local machine"""				,				)
        download_parser.add_argument("""model"""				,				type=snake_case__				,				help="""Name of the model to download"""		)
        download_parser.set_defaults(func=snake_case__		)


  def __init__(			self    : Tuple				,				UpperCAmelCase__    : str				,				UpperCAmelCase__    : str				,				UpperCAmelCase__    : bool				,				UpperCAmelCase__    : bool		)					->Optional[int]:
        """simple docstring"""







        SCREAMING_SNAKE_CASE :      Optional[Any]       =   model
        SCREAMING_SNAKE_CASE :      Optional[Any]       =   cache
        SCREAMING_SNAKE_CASE :      List[Any]       =   force
        SCREAMING_SNAKE_CASE :      Dict       =   trust_remote_code




  def  _lowercase      (			self    : List[Any]		)					->str:
        """simple docstring"""







        from ..models.auto import AutoModel, AutoTokenizer

        AutoModel.from_pretrained(
            self._model				,				cache_dir=self._cache				,				force_download=self._force				,				trust_remote_code=self._trust_remote_code		)
        AutoTokenizer.from_pretrained(
            self._model				,				cache_dir=self._cache				,				force_download=self._force				,				trust_remote_code=self._trust_remote_code		)







from __future__ import annotations






def 					__lowercase      (     _A						,    _A			)     ->						list[str]:
      if nth_term == "":
            return [""]
      SCREAMING_SNAKE_CASE :      Optional[Any]       =   int(_A			)
      SCREAMING_SNAKE_CASE :      Optional[int]       =   int(_A			)
      SCREAMING_SNAKE_CASE :      list[str]       =   []
      for temp in range(int(_A			)			):
            series.append(F"1 / {pow(temp + 1						,    int(_A			)			)}" if series else """1"""			)
      return series


if __name__ == "__main__":
  import doctest

  doctest.testmod()

  UpperCAmelCase__ :     Dict				    =    int(input("""Enter the last number (nth term) of the P-Series"""))
  UpperCAmelCase__ :     Optional[int]				    =    int(input("""Enter the power for  P-Series"""))
  print("""Formula of P-Series => 1+1/2^p+1/3^p ..... 1/n^p""")
  print(p_series(nth_term, power))




