+
    œ°³j®  ã                   óh   € R t ^RIHt ^RIHtHtHtHtHt ^RI	H
t
Ht ] ! R R]4      4       tR.tR# )z 
Processor class for LayoutXLM.
)ÚProcessorMixin)ÚBatchEncodingÚPaddingStrategyÚPreTokenizedInputÚ	TextInputÚTruncationStrategy)Ú
TensorTypeÚauto_docstringc                   ól   a a€ ] tR t^t oRV 3R llt]RV3R lR ll4       tR t]R 4       t	Rt
VtV ;t# )	ÚLayoutXLMProcessorc                ó&   <€ \         SV `  W4       R # )N)ÚsuperÚ__init__)ÚselfÚimage_processorÚ	tokenizerÚkwargsÚ	__class__s   &&&,€Ús/home/luca/screen-checking/.venv/lib/python3.14/site-packages/transformers/models/layoutxlm/processing_layoutxlm.pyr   ÚLayoutXLMProcessor.__init__   s   ø€ Ü‰Ñ˜Ö4ó    c          &      ó\  <€ V ^8„  d   QhRS[ S[,          S[S[ ,          ,          S[S[,          ,          RS[S[S[,          ,          R,          RS[S[S[,          ,          S[S[S[S[,          ,          ,          ,          R,          RS[S[,          S[S[S[,          ,          ,          R,          RS[RS[S[,          S[,          RS[S[,          S[,          R	S[R,          R
S[RS[R,          RS[R,          RS[R,          RS[RS[RS[RS[RS[RS[S[,          R,          RS[	/# )é   ÚtextÚ	text_pairNÚboxesÚword_labelsÚadd_special_tokensÚpaddingÚ
truncationÚ
max_lengthÚstrideÚpad_to_multiple_ofÚreturn_token_type_idsÚreturn_attention_maskÚreturn_overflowing_tokensÚreturn_special_tokens_maskÚreturn_offsets_mappingÚreturn_lengthÚverboseÚreturn_tensorsÚreturn)
r   r   ÚlistÚintÚboolÚstrr   r   r   r   )ÚformatÚ__classdict__s   "€r   Ú__annotate__ÚLayoutXLMProcessor.__annotate__   sl  ø€ ÷ Jñ Jñ Ñ+Õ+©d±9­oÕ=ÁÑEVÕ@WÕWðJñ %¡tÑ,=Õ'>Õ>ÀÕEð	Jñ
 ‘D™•I�¡¡d©4±­9¥oÕ!6Õ6¸Õ=ðJñ ™#•Y¡¡d©3¥i¥Õ0°4Õ7ðJñ !ðJñ ™•™oÕ-ðJñ ™3•JÑ!3Õ3ðJñ ˜$•JðJñ ðJñ   $�JðJñ  $ d�{ðJñ  $ d�{ðJñ $(ðJñ  %)ð!Jñ" !%ð#Jñ$ ð%Jñ& ð'Jñ( ™jÕ(¨4Õ/ð)Jñ, 
ñ-Jr   c                óÌ  € V P                   P                  '       d   Ve   \        R4      hV P                   P                  '       d   Ve   \        R4      hVRJ d   VRJ d   \        R4      hV P                  VVR7      pVeC   V P                   P                  '       d'   Vf#   \        V\        4      '       d   V.pVR,          pV P
                  ! R/ RVe   TMVR,          bR	Ve   TMR bR
Ve   TMVR
,          bRVbRVbRVbRVbRV	bRV
bRVbRVbRVbRVbRVbRVbRVbRVbRVbVB pVP                  R4      pVRJ d   V P                  VVR,          4      pVVR&   V# )NzdYou cannot provide bounding boxes if you initialized the image processor with apply_ocr set to True.zaYou cannot provide word labels if you initialized the image processor with apply_ocr set to True.TFzKYou cannot return overflowing tokens without returning the offsets mapping.)Úimagesr*   Úwordsr   r   r   r   r   r   r   r    r!   r"   r#   r$   r%   r&   r'   r(   r)   r*   Úpixel_valuesÚoverflow_to_sample_mappingÚimage© )r   Ú	apply_ocrÚ
ValueErrorÚ
isinstancer/   r   ÚpopÚget_overflowing_images)r   r5   r   r   r   r   r   r   r   r    r!   r"   r#   r$   r%   r&   r'   r(   r)   r*   r   ÚfeaturesÚencoded_inputss   &&&&&&&&&&&&&&&&&&&&,  r   Ú__call__ÚLayoutXLMProcessor.__call__   sê  € ð2 ×Ñ×)×)Ð)¨uÒ/@ÜØvóð ð ×Ñ×)×)Ð)¨{Ò/FÜØsóð ð %¨Ó,Ð1GÈ5Ó1PÜÐjÓkÐkð ×'Ñ'¨vÀnÐ'ÓUˆð Ò × 4Ñ 4× >× >Ð >À9ÒCTÜ˜$¤×$Ò$Ø�v�Ø  Õ)ˆIàŸšò 
ØÒ)‘¨x¸Õ/@øð
à#,Ò#8‘i¸døð
ð !Ò,‘%°(¸7Õ2Cøð
ñ $ð	
ñ
  2ð
ñ ð
ñ "ð
ñ "ð
ñ ð
ñ  2ð
ñ #8ð
ñ #8ð
ñ '@ð
ñ (Bð
ñ $:ð
ñ  (ð!
ñ" ð#
ñ$ *Øñ'
ˆð. —‘˜nÓ-ˆØ$¨Ó,Ø×0Ñ0°¸ÐHdÕ9eÓfˆFØ"(ˆ�wÑàÐr   c                óÂ   € . pV F  pVP                  W,          4       K  	  \        V4      \        V4      8w  d$   \        R \        V4       R\        V4       24      hV# )z`Expected length of images to be the same as the length of `overflow_to_sample_mapping`, but got z and )ÚappendÚlenr<   )r   r5   r8   Úimages_with_overflowÚ
sample_idxs   &&&  r   r?   Ú)LayoutXLMProcessor.get_overflowing_imagesi   sr   € à!ÐÛ4ˆJØ ×'Ñ'¨Õ(:Ö;ñ 5ô Ð#Ó$¬Ð,FÓ(GÔGÜðÜÐ,Ó-Ð.¨e´CÐ8RÓ4SÐ3TðVóð ð
 $Ð#r   c                ó
   € . RO# )Ú	input_ids)rK   ÚbboxÚattention_maskr9   r:   )r   s   &r   Úmodel_input_namesÚ$LayoutXLMProcessor.model_input_namesw   s   € â?Ð?r   r:   )NN)NNNNTFNNé    NNNFFFFTN)Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__r   r	   rB   r?   ÚpropertyrN   Ú__static_attributes__Ú__classdictcell__Ú__classcell__)r   r1   s   @@r   r   r      sH   ù‡ € ÷5ð ÷Jñ Jó ðJòX$ð ñ@ó ÷@ð @r   r   N)Ú__doc__Úprocessing_utilsr   Útokenization_utils_baser   r   r   r   r   Úutilsr   r	   r   Ú__all__r:   r   r   Ú<module>r^      sD   ðñõ /ß wÕ wß /ð ôa@˜ó a@ó ða@ðH  Ð
 ‚r   