




from ..utils import DummyObject, requires_backends






class  _lowerCAmelCase     (  metaclass=_lowercase	):
      A__		     =		['torch', 'torchsde']

      def __init__(   self      ,				*__UpperCAmelCase      ,				**__UpperCAmelCase		):
        requires_backends(self      ,				['''torch''', '''torchsde''']		)

      @classmethod
      def 	__magic_name__(   cls      ,				*__UpperCAmelCase      ,				**__UpperCAmelCase		):
        requires_backends(cls      ,				['''torch''', '''torchsde''']		)







      @classmethod
      def 	__magic_name__(   cls      ,				*__UpperCAmelCase      ,				**__UpperCAmelCase		):
        requires_backends(cls      ,				['''torch''', '''torchsde''']		)







def      __lowerCAmelCase			(					UpperCamelCase      )     ->	bool:
  if not isinstance(UpperCamelCase	,      UpperCamelCase      ):
    raise ValueError('''Input series is not valid, valid series - [2, 4, 6]'''      )
  if len(UpperCamelCase      ) == 0:
    raise ValueError('''Input list must be a non empty list'''      )
  if len(UpperCamelCase      ) == 1:
    return True
  lowerCAmelCase__				:  Tuple		       =     series[1] - series[0]
  for index in range(len(UpperCamelCase      ) - 1      ):
    if series[index + 1] - series[index] != common_diff:
      return False
  return True



def      __lowerCAmelCase			(					UpperCamelCase      )     ->	float:
  if not isinstance(UpperCamelCase	,      UpperCamelCase      ):
    raise ValueError('''Input series is not valid, valid series - [2, 4, 6]'''      )
  if len(UpperCamelCase      ) == 0:
    raise ValueError('''Input list must be a non empty list'''      )
  lowerCAmelCase__				:  int		       =     0
  for val in series:
    answer += val
  return answer / len(UpperCamelCase      )


if __name__ == "__main__":
     import doctest

     doctest.testmod()

