




import math
from datetime import datetime, timedelta







def  __UpperCamelCase    (						A							):
     UpperCamelCase__										=      year % 19
     UpperCamelCase__										=      year % 4
     UpperCamelCase__										=      year % 7
     UpperCamelCase__										=      math.floor(year / 100							)
     UpperCamelCase__										=      math.floor((13 + 8 * leap_day_inhibits) / 25							)
     UpperCamelCase__										=      leap_day_inhibits / 4
     UpperCamelCase__										=      (
         15 - lunar_orbit_correction + leap_day_inhibits - leap_day_reinstall_number
     ) % 30
     UpperCamelCase__										=      (4 + leap_day_inhibits - leap_day_reinstall_number) % 7

     # days to be added to March 21
     UpperCamelCase__										=      (19 * metonic_cycle + secular_moon_shift) % 30

     # PHM -> Paschal Full Moon
     UpperCamelCase__										=      (
         2 * julian_leap_year
         + 4 * non_leap_year
         + 6 * days_to_add
         + century_starting_point
     ) % 7

     if days_to_add == 29 and days_from_phm_to_sunday == 6:
          return datetime(A ,							4 ,							19							)
     elif days_to_add == 28 and days_from_phm_to_sunday == 6:
          return datetime(A ,							4 ,							18							)
     else:
          return datetime(A ,							3 ,							22							) + timedelta(
              days=int(days_to_add + days_from_phm_to_sunday							)							)


if __name__ == "__main__":
     for year in (1994, 2000, 2010, 2021, 2023):
          __magic_name__								='''will be''' if year > datetime.now().year else '''was'''
          print(f"""Easter in {year} {tense} {gauss_easter(year)}""")




import unittest

from transformers import is_torch_available
from transformers.testing_utils import require_torch


if is_torch_available():
     import torch

     from transformers.activations import gelu_new, gelu_python, get_activation



@require_torch
class     _A   (    unittest.TestCase							):






  def 		_a					(self	)		->      str:





       '''simple docstring'''





       UpperCamelCase__										=      torch.tensor([-100, -1, -0.1, 0, 0.1, 1.0, 100]	)
       UpperCamelCase__										=      get_activation('''gelu'''	)
       self.assertTrue(torch.allclose(gelu_python(SCREAMING_SNAKE_CASE_	)   ,				torch_builtin(SCREAMING_SNAKE_CASE_	)	)	)
       self.assertFalse(torch.allclose(gelu_python(SCREAMING_SNAKE_CASE_	)   ,				gelu_new(SCREAMING_SNAKE_CASE_	)	)	)






  def 		_a					(self	)		->      str:





       '''simple docstring'''





       UpperCamelCase__										=      torch.tensor([-100, -1, -0.1, 0, 0.1, 1.0, 100]	)
       UpperCamelCase__										=      get_activation('''gelu'''	)
       UpperCamelCase__										=      get_activation('''gelu_10'''	)

       UpperCamelCase__										=      torch_builtin(SCREAMING_SNAKE_CASE_	)
       UpperCamelCase__										=      geluaa(SCREAMING_SNAKE_CASE_	)

       UpperCamelCase__										=      torch.where(y_gelu_aa < 10.0   ,				1   ,				0	)

       self.assertTrue(torch.max(SCREAMING_SNAKE_CASE_	).item() == 10.0	)
       self.assertTrue(torch.allclose(y_gelu * clipped_mask   ,				y_gelu_aa * clipped_mask	)	)






  def 		_a					(self	)		->      Optional[Any]:





       '''simple docstring'''





       get_activation('''gelu'''	)
       get_activation('''gelu_10'''	)
       get_activation('''gelu_fast'''	)
       get_activation('''gelu_new'''	)
       get_activation('''gelu_python'''	)
       get_activation('''gelu_pytorch_tanh'''	)
       get_activation('''linear'''	)
       get_activation('''mish'''	)
       get_activation('''quick_gelu'''	)
       get_activation('''relu'''	)
       get_activation('''sigmoid'''	)
       get_activation('''silu'''	)
       get_activation('''swish'''	)
       get_activation('''tanh'''	)
       with self.assertRaises(SCREAMING_SNAKE_CASE_	):
            get_activation('''bogus'''	)
       with self.assertRaises(SCREAMING_SNAKE_CASE_	):
            get_activation(SCREAMING_SNAKE_CASE_	)






  def 		_a					(self	)		->      Optional[Any]:





       '''simple docstring'''





       UpperCamelCase__										=      get_activation('''gelu'''	)
       UpperCamelCase__										=      1
       UpperCamelCase__										=      get_activation('''gelu'''	)
       self.assertEqual(acta.a   ,				1	)
       with self.assertRaises(SCREAMING_SNAKE_CASE_	):
            UpperCamelCase__										=      acta.a



