
import warnings

from ...processing_utils import ProcessorMixin
from ...tokenization_utils_base import BatchEncoding


class 	UpperCamelCase__       (  UpperCAmelCase__):

						'''simple docstring'''



						__a     :    Dict												=			["""image_processor""", """tokenizer"""]
						__a     :    Any												=			"""VideoMAEImageProcessor"""
						__a     :    List[str]												=			("""CLIPTokenizer""", """CLIPTokenizerFast""")


						def __init__(  self  , A=None  , A=None  , **A	)  ->Any:
									UpperCAmelCase__		:Optional[Any] 		=    None
									if "feature_extractor" in kwargs:
												warnings.warn(
												    'The `feature_extractor` argument is deprecated and will be removed in v5, use `image_processor`'
												    ' instead.'  , lowerCamelCase_  , )
												UpperCAmelCase__		:Any 		=    kwargs.pop('feature_extractor'	)

									UpperCAmelCase__		:Union[str, Any] 		=    image_processor if image_processor is not None else feature_extractor
									if image_processor is None:
												raise ValueError('You need to specify an `image_processor`.'	)
									if tokenizer is None:
												raise ValueError('You need to specify a `tokenizer`.'	)

									super().__init__(lowerCamelCase_  , lowerCamelCase_	)
									UpperCAmelCase__		:Dict 		=    self.image_processor


						def __call__(  self  , A=None  , A=None  , A=None  , **A	)  ->Union[str, Any]:

									if text is None and videos is None:
												raise ValueError('You have to specify either text or videos. Both cannot be none.'	)

									if text is not None:
												UpperCAmelCase__		:int 		=    self.tokenizer(lowerCamelCase_  , return_tensors=lowerCamelCase_  , **lowerCamelCase_	)

									if videos is not None:
												UpperCAmelCase__		:str 		=    self.image_processor(lowerCamelCase_  , return_tensors=lowerCamelCase_  , **lowerCamelCase_	)

									if text is not None and videos is not None:
												UpperCAmelCase__		:int 		=    image_features.pixel_values
												return encoding
									elif text is not None:
												return encoding
									else:
												return BatchEncoding(data=dict(**lowerCamelCase_	)  , tensor_type=lowerCamelCase_	)


						def    A__       (  self  , *A  , **A	)  ->Dict:
									return self.tokenizer.batch_decode(*lowerCamelCase_  , **lowerCamelCase_	)


						def    A__       (  self  , *A  , **A	)  ->Tuple:
									return self.tokenizer.decode(*lowerCamelCase_  , **lowerCamelCase_	)


						@property
						def    A__       (  self	)  ->int:
									return ["input_ids", "attention_mask", "position_ids", "pixel_values"]


						@property
						def    A__       (  self	)  ->List[str]:
									warnings.warn(
									    '`feature_extractor_class` is deprecated and will be removed in v5. Use `image_processor_class` instead.'  , lowerCamelCase_  , )
									return self.image_processor_class


						@property
						def    A__       (  self	)  ->Union[str, Any]:
									warnings.warn(
									    '`feature_extractor` is deprecated and will be removed in v5. Use `image_processor` instead.'  , lowerCamelCase_  , )
									return self.image_processor










from .pipeline_kandinskya_a import KandinskyVaaPipeline
from .pipeline_kandinsky2_2_controlnet import KandinskyVaaControlnetPipeline
from .pipeline_kandinsky2_2_controlnet_img2img import KandinskyVaaControlnetImgaImgPipeline
from .pipeline_kandinsky2_2_img2img import KandinskyVaaImgaImgPipeline
from .pipeline_kandinsky2_2_inpainting import KandinskyVaaInpaintPipeline
from .pipeline_kandinsky2_2_prior import KandinskyVaaPriorPipeline
from .pipeline_kandinsky2_2_prior_emb2emb import KandinskyVaaPriorEmbaEmbPipeline
