






from collections.abc import Sequence




def 				A		(					lowercase__  :  Sequence[int] | None = None  )		-> int:
	if nums is None or not nums:
		raise ValueError("""Input sequence should not be empty"""  )

	UpperCamelCase__ :int						=      nums[0]
	for i in range(1 ,		len(lowercase__  )  ):
		UpperCamelCase__ :str						=      nums[i]
		UpperCamelCase__ :List[str]						=      max(lowercase__ ,		ans + num ,		lowercase__  )

	return ans


if __name__ == "__main__":
							import doctest

							doctest.testmod()

							# Try on a sample input from the user
							UpperCamelCase        =				int(input("Enter number of elements : ").strip())
							UpperCamelCase        =				list(map(int, input("\nEnter the numbers : ").strip().split()))[:n]
							print(max_subsequence_sum(array))







'''simple docstring'''
import argparse
import os

import torch

from transformers.utils import WEIGHTS_NAME


UpperCamelCase__			=      ['small', 'medium', 'large']

UpperCamelCase__			=      'lm_head.decoder.weight'
UpperCamelCase__			=      'lm_head.weight'




def 		__SCREAMING_SNAKE_CASE       (	_UpperCamelCase    ,		_UpperCamelCase				):


   """simple docstring"""




   lowercase_						:     Optional[Any]							     =  torch.load(_UpperCamelCase				)
   lowercase_						:     List[Any]							     =  d.pop(_UpperCamelCase				)
   os.makedirs(_UpperCamelCase    ,		exist_ok=_UpperCamelCase				)
   torch.save(_UpperCamelCase    ,		os.path.join(_UpperCamelCase    ,		_UpperCamelCase				)				)


if __name__ == "__main__":
 UpperCamelCase__			=      argparse.ArgumentParser()
 parser.add_argument('--dialogpt_path', default='.', type=str)
 UpperCamelCase__			=      parser.parse_args()
 for MODEL in DIALOGPT_MODELS:
  UpperCamelCase__			=      os.path.join(args.dialogpt_path, f"""{MODEL}_ft.pkl""")
  UpperCamelCase__			=      f"""./DialoGPT-{MODEL}"""
  convert_dialogpt_checkpoint(
      checkpoint_path,
      pytorch_dump_folder_path,
  )




