ó
    ‰Ž¡jN  ã                   óh   • S SK Jr  SSKJr  SSKJrJrJr  \" \" SSS9S	5       " S
 S\5      5       rg)é    )ÚAnyé   )Úadd_end_docstringsé   )ÚGenericTensorÚPipelineÚbuild_pipeline_init_argsTF)Úhas_tokenizerÚsupports_binary_outputa  
        tokenize_kwargs (`dict`, *optional*):
                Additional dictionary of keyword arguments passed along to the tokenizer.
        return_tensors (`bool`, *optional*):
            If `True`, returns a tensor according to the specified framework, otherwise returns a list.c                   ó–   ^ • \ rS rSrSrSrSrSrSrSS jr	S\
\\4   4S jrS rSS	 jrS
\\\   -  S\S\\\   -  4U 4S jjrSrU =r$ )ÚFeatureExtractionPipelineé   a�  
Feature extraction pipeline uses no model head. This pipeline extracts the hidden states from the base
transformer, which can be used as features in downstream tasks.

Example:

```python
>>> from transformers import pipeline

>>> extractor = pipeline(model="google-bert/bert-base-uncased", task="feature-extraction")
>>> result = extractor("This is a simple test.", return_tensors=True)
>>> result.shape  # This is a tensor of shape [1, sequence_length, hidden_dimension] representing the input string.
torch.Size([1, 8, 768])
```

Learn more about the basics of using a pipeline in the [pipeline tutorial](../pipeline_tutorial)

This feature extraction pipeline can currently be loaded from [`pipeline`] using the task identifier:
`"feature-extraction"`.

All models may be used for this pipeline. See a list of all models, including community-contributed models on
[huggingface.co/models](https://huggingface.co/models).
FTc                 ó\   • Uc  0 nUb  SU;   a  [        S5      eXS'   Un0 nUb  X6S'   U0 U4$ )NÚ
truncationz\truncation parameter defined twice (given as keyword argument as well as in tokenize_kwargs)Úreturn_tensors)Ú
ValueError)Úselfr   Útokenize_kwargsr   ÚkwargsÚpreprocess_paramsÚpostprocess_paramss          Ú·C:\Users\johnn\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.13_qbz5n2kfra8p0\LocalCache\local-packages\Python313\site-packages\transformers/pipelines/feature_extraction.pyÚ_sanitize_parametersÚ.FeatureExtractionPipeline._sanitize_parameters-   s^   € ØÑ"Ø ˆOàÑ!Ø˜Ó.Ü Øróð ð -7˜LÑ)à+ÐàÐØÑ%Ø3AÐ/Ñ0à  "Ð&8Ð8Ð8ó    Úreturnc                 ó0   • U R                   " U4SS0UD6nU$ )Nr   Úpt)Ú	tokenizer)r   Úinputsr   Úmodel_inputss       r   Ú
preprocessÚ$FeatureExtractionPipeline.preprocess@   s    € Ø—~’~ fÑU¸TÐUÀ_ÑUˆØÐr   c                 ó*   • U R                   " S0 UD6nU$ )N© )Úmodel)r   r!   Úmodel_outputss      r   Ú_forwardÚ"FeatureExtractionPipeline._forwardD   s   € ØŸ
š
Ñ2 \Ñ2ˆØÐr   c                 ó@   • U(       a  US   $ US   R                  5       $ )Nr   )Útolist)r   r'   r   s      r   ÚpostprocessÚ%FeatureExtractionPipeline.postprocessH   s$   € æØ  Ñ#Ð#Ø˜QÑ×&Ñ&Ó(Ð(r   Úargsr   c                 ó$   >• [         TU ]  " U0 UD6$ )zã
Extract the features of the input(s) text.

Args:
    args (`str` or `list[str]`): One or several texts (or one list of texts) to get the features of.

Return:
    A nested list of `float`: The features computed by the model.
)ÚsuperÚ__call__)r   r.   r   Ú	__class__s      €r   r1   Ú"FeatureExtractionPipeline.__call__N   s   ø€ ô ‰wÒ Ð0¨Ñ0Ð0r   r%   )NNN)F)Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__doc__Ú_load_processorÚ_load_image_processorÚ_load_feature_extractorÚ_load_tokenizerr   ÚdictÚstrr   r"   r(   r,   Úlistr   r1   Ú__static_attributes__Ú__classcell__)r2   s   @r   r   r      st   ø† ñð0 €OØ!ÐØ#ÐØ€Oô9ð&°t¸CÀÐ<NÑ7Oô òô)ð
1˜c D¨¡I™oð 
1¸ð 
1ÀÀtÈCÁyÁ÷ 
1õ 
1r   r   N)	Útypingr   Úutilsr   Úbaser   r   r	   r   r%   r   r   Ú<module>rE      sD   ðÝ å &ß CÑ Cñ Ù¨4ÈÑNðkóôI1 ó I1óñI1r   