o
    i.
                     @   s2   d Z ddlZddlmZ G dd deZdgZdS )z%
Image/Text processor class for CLIP
    N   )ProcessorMixinc                       sJ   e Zd ZdZddgZdZdZd fdd	Zed	d
 Z	edd Z
  ZS )CLIPProcessora  
    Constructs a CLIP processor which wraps a CLIP image processor and a CLIP tokenizer into a single processor.

    [`CLIPProcessor`] offers all the functionalities of [`CLIPImageProcessor`] and [`CLIPTokenizerFast`]. See the
    [`~CLIPProcessor.__call__`] and [`~CLIPProcessor.decode`] for more information.

    Args:
        image_processor ([`CLIPImageProcessor`], *optional*):
            The image processor is a required input.
        tokenizer ([`AutoTokenizer`], *optional*):
            The tokenizer is a required input.
    image_processor	tokenizer)CLIPImageProcessorCLIPImageProcessorFastAutoTokenizerNc                    sD   d }d|v rt dt |d}|d ur|n|}t || d S )Nfeature_extractorzhThe `feature_extractor` argument is deprecated and will be removed in v5, use `image_processor` instead.)warningswarnFutureWarningpopsuper__init__)selfr   r   kwargsr
   	__class__ e/home/ubuntu/veenaModal/venv/lib/python3.10/site-packages/transformers/models/clip/processing_clip.pyr   *   s   
zCLIPProcessor.__init__c                 C      t dt | jS )Nzg`feature_extractor_class` is deprecated and will be removed in v5. Use `image_processor_class` instead.)r   r   r   image_processor_classr   r   r   r   feature_extractor_class8   
   z%CLIPProcessor.feature_extractor_classc                 C   r   )Nz[`feature_extractor` is deprecated and will be removed in v5. Use `image_processor` instead.)r   r   r   r   r   r   r   r   r
   @   r   zCLIPProcessor.feature_extractor)NN)__name__
__module____qualname____doc__
attributesr   tokenizer_classr   propertyr   r
   __classcell__r   r   r   r   r      s    
r   )r   r   processing_utilsr   r   __all__r   r   r   r   <module>   s
   
1