
'''simple docstring'''


from collections import OrderedDict
from typing import Mapping

from packaging import version

from ...configuration_utils import PretrainedConfig
from ...onnx import OnnxConfig
from ...utils import logging
from ...utils.backbone_utils import BackboneConfigMixin, get_aligned_output_features_output_indices


__lowercase							:				Tuple					=       logging.get_logger(__name__)

__lowercase							:				str					=       {
    '''facebook/convnext-tiny-224''': '''https://huggingface.co/facebook/convnext-tiny-224/resolve/main/config.json''',
    # See all ConvNeXT models at https://huggingface.co/models?filter=convnext
}

class 		__lowercase			(					_lowercase ,       _lowercase      ):
			lowerCamelCase     :						Dict		 =     "convnext"

			def __init__(self     ,				A=3     ,				A=4     ,				A=4     ,				A=None     ,				A=None     ,				A="gelu"     ,				A=0.02     ,				A=1E-12     ,				A=1E-6     ,				A=0.0     ,				A=2_2_4     ,				A=None     ,				A=None     ,				**A     ,				):
								super().__init__(**A )

								lowerCamelCase_   : Any       =						num_channels
								lowerCamelCase_   : Any       =						patch_size
								lowerCamelCase_   : Union[str, Any]       =						num_stages
								lowerCamelCase_   : List[str]       =						[9_6, 1_9_2, 3_8_4, 7_6_8] if hidden_sizes is None else hidden_sizes
								lowerCamelCase_   : Union[str, Any]       =						[3, 3, 9, 3] if depths is None else depths
								lowerCamelCase_   : Optional[Any]       =						hidden_act
								lowerCamelCase_   : Optional[int]       =						initializer_range
								lowerCamelCase_   : Optional[int]       =						layer_norm_eps
								lowerCamelCase_   : List[Any]       =						layer_scale_init_value
								lowerCamelCase_   : int       =						drop_path_rate
								lowerCamelCase_   : Optional[Any]       =						image_size
								lowerCamelCase_   : str       =						['''stem'''] + [F"""stage{idx}""" for idx in range(1     ,				len(self.depths ) + 1 )]
								lowerCamelCase_   : List[Any]       =						get_aligned_output_features_output_indices(
								    out_features=A     ,				out_indices=A     ,				stage_names=self.stage_names )




class 		__lowercase			(					_lowercase      ):
			lowerCamelCase     :						List[str]		 =     version.parse("1.11"      )

			@property
			def     UpperCAmelCase__	(self ):
								return OrderedDict(
								    [
								        ('''pixel_values''', {0: '''batch''', 1: '''num_channels''', 2: '''height''', 3: '''width'''}),
								    ] )






			@property
			def     UpperCAmelCase__	(self ):
								return 1E-5




'''simple docstring'''


def lowercase_		(				_lowercase			)       ->							int:
					'''simple docstring'''

					if not isinstance(_lowercase     ,    _lowercase			):
										raise TypeError('''recursive_lucas_number accepts only integer arguments.'''			)
					if n_th_number == 0:
										return 2
					if n_th_number == 1:
										return 1

					return recursive_lucas_number(n_th_number - 1			) + recursive_lucas_number(
					    n_th_number - 2			)




def lowercase_		(				_lowercase			)       ->							int:
					'''simple docstring'''

					if not isinstance(_lowercase     ,    _lowercase			):
										raise TypeError('''dynamic_lucas_number accepts only integer arguments.'''			)
					lowerCamelCase_, lowerCamelCase_   : List[Any]       =						2, 1
					for _ in range(_lowercase			):
										lowerCamelCase_, lowerCamelCase_   : Dict       =						b, a + b
					return a


if __name__ == "__main__":
					from doctest import testmod

					testmod()
					__lowercase							:				Any					=       int(input('''Enter the number of terms in lucas series:\n''').strip())
					print('''Using recursive function to calculate lucas series:''')
					print(''' '''.join(str(recursive_lucas_number(i)) for i in range(n)))
					print('''\nUsing dynamic function to calculate lucas series:''')
					print(''' '''.join(str(dynamic_lucas_number(i)) for i in range(n)))


