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


lowerCamelCase_  :	Optional[Any] 				=					logging.get_logger(__name__)

lowerCamelCase_  :	List[str] 				=					{
    """facebook/convnextv2-tiny-1k-224""": """https://huggingface.co/facebook/convnextv2-tiny-1k-224/resolve/main/config.json""",
}

class     _UpperCamelCase			(   _A       ,    _A					):






			'''simple docstring'''

			__UpperCamelCase :  List[str]    =	"""convnextv2"""

			def __init__(    self	:    Tuple  ,		snake_case_	:    List[str]=3  ,		snake_case_	:    List[str]=4  ,		snake_case_	:    int=4  ,		snake_case_	:    Tuple=None  ,		snake_case_	:    int=None  ,		snake_case_	:    List[Any]="gelu"  ,		snake_case_	:    Tuple=0.02  ,		snake_case_	:    Optional[int]=1e-12  ,		snake_case_	:    Optional[int]=0.0  ,		snake_case_	:    List[Any]=224  ,		snake_case_	:    Dict=None  ,		snake_case_	:    Tuple=None  ,		**snake_case_	:    Any  ,		):
							super().__init__(**snake_case_ )

							UpperCamelCase_:							int		=  num_channels
							UpperCamelCase_:							Any		=  patch_size
							UpperCamelCase_:							List[str]		=  num_stages
							UpperCamelCase_:							Optional[int]		=  [96, 192, 384, 768] if hidden_sizes is None else hidden_sizes
							UpperCamelCase_:							Union[str, Any]		=  [3, 3, 9, 3] if depths is None else depths
							UpperCamelCase_:							Union[str, Any]		=  hidden_act
							UpperCamelCase_:							List[Any]		=  initializer_range
							UpperCamelCase_:							int		=  layer_norm_eps
							UpperCamelCase_:							Dict		=  drop_path_rate
							UpperCamelCase_:							Dict		=  image_size
							UpperCamelCase_:							Tuple		=  ["""stem"""] + [f'''stage{idx}''' for idx in range(1  ,		len(self.depths ) + 1 )]
							UpperCamelCase_,				UpperCamelCase_:							Union[str, Any]		=  get_aligned_output_features_output_indices(
							    out_features=snake_case_  ,		out_indices=snake_case_  ,		stage_names=self.stage_names )








def     A__   (  lowerCamelCase       ,      lowerCamelCase  )					->		float:
				if mass < 0:
								raise ValueError("""The mass of a body cannot be negative"""  )
				return 0.5 * mass * abs(lowerCamelCase  ) * abs(lowerCamelCase  )


if __name__ == "__main__":
							import doctest

							doctest.testmod(verbose=True)






