






"""simple docstring"""






from ... import PretrainedConfig


SCREAMING_SNAKE_CASE						:						str					   =       {
    '''sijunhe/nezha-cn-base''': '''https://huggingface.co/sijunhe/nezha-cn-base/resolve/main/config.json''',
}





class       snake_case_       (    _lowerCamelCase       ):



	"""simple docstring"""

	SCREAMING_SNAKE_CASE_:							str   			=					NEZHA_PRETRAINED_CONFIG_ARCHIVE_MAP
	SCREAMING_SNAKE_CASE_:							List[str]   			=					"""nezha"""


	def __init__(      self  ,					__a=2_1128  ,					__a=768  ,					__a=12  ,					__a=12  ,					__a=3072  ,					__a="gelu"  ,					__a=0.1  ,					__a=0.1  ,					__a=512  ,					__a=64  ,					__a=2  ,					__a=0.02  ,					__a=1E-12  ,					__a=0.1  ,					__a=0  ,					__a=2  ,					__a=3  ,					__a=True  ,					**__a  ,					):


					"""simple docstring"""

					super().__init__(pad_token_id=__a  ,					bos_token_id=__a  ,					eos_token_id=__a  ,					**__a						)

					A__							 =       vocab_size
					A__							 =       hidden_size
					A__							 =       num_hidden_layers
					A__							 =       num_attention_heads
					A__							 =       hidden_act
					A__							 =       intermediate_size
					A__							 =       hidden_dropout_prob
					A__							 =       attention_probs_dropout_prob
					A__							 =       max_position_embeddings
					A__							 =       max_relative_position
					A__							 =       type_vocab_size
					A__							 =       initializer_range
					A__							 =       layer_norm_eps
					A__							 =       classifier_dropout
					A__							 =       use_cache










"""simple docstring"""






from ...processing_utils import ProcessorMixin





class       snake_case_       (    _lowerCamelCase       ):



	"""simple docstring"""

	SCREAMING_SNAKE_CASE_:							Union[str, Any]   			=					["""image_processor""", """feature_extractor"""]
	SCREAMING_SNAKE_CASE_:							Optional[int]   			=					"""TvltImageProcessor"""
	SCREAMING_SNAKE_CASE_:							Optional[int]   			=					"""TvltFeatureExtractor"""


	def __init__(      self  ,					__a  ,					__a						):


					"""simple docstring"""

					super().__init__(image_processor=__a  ,					feature_extractor=__a						)

					A__							 =       image_processor
					A__							 =       feature_extractor


	def __call__(      self  ,					__a=None  ,					__a=None  ,					__a=None  ,					__a=None  ,					__a=False  ,					__a=False  ,					*__a  ,					**__a  ,					):


					"""simple docstring"""

					if images is None and audio is None:
									raise ValueError('You need to specify either an `images` or `audio` input to process.'						)

					A__							 =       None
					if images is not None:
									A__							 =       self.image_processor(__a  ,					mask_pixel=__a  ,					*__a  ,					**__a						)
					if images_mixed is not None:
									A__							 =       self.image_processor(__a  ,					is_mixed=__a  ,					*__a  ,					**__a						)
					if audio is not None:
									A__							 =       self.feature_extractor(
									    __a  ,					*__a  ,					sampling_rate=__a  ,					mask_audio=__a  ,					**__a						)

					A__							 =       {}
					if audio is not None:
									output_dict.update(__a						)
					if images is not None:
									output_dict.update(__a						)
					if images_mixed_dict is not None:
									output_dict.update(__a						)
					return output_dict






	@property
	def       _UpperCAmelCase						(      self						):


					"""simple docstring"""

					A__							 =       self.image_processor.model_input_names
					A__							 =       self.feature_extractor.model_input_names
					return list(dict.fromkeys(image_processor_input_names + feature_extractor_input_names						)						)


