Ë
    S^(h”$ ã                   óÂ  — d Z ddlZddlZddlmZ ddlmZmZmZm	Z	 ddl
Z
ddlZ
ddl
mZ ddlmZmZmZ ddlmZmZ dd	lmZ dd
lmZmZmZmZmZmZmZmZ ddlm Z m!Z! ddl"m#Z#m$Z$m%Z% ddl&m'Z'm(Z(m)Z)m*Z*m+Z+m,Z, ddl-m.Z.  e+j^                  e0«      Z1dZ2dZ3dId„Z4 G d„ dejj                  «      Z6 G d„ dejj                  «      Z7 G d„ dejj                  «      Z8de7iZ9 G d„ dejj                  «      Z: G d„ dejj                  «      Z; G d„ dejj                  «      Z< G d „ d!ejj                  «      Z= G d"„ d#ejj                  «      Z> G d$„ d%ejj                  «      Z? G d&„ d'ejj                  «      Z@ G d(„ d)e «      ZAe G d*„ d+e'«      «       ZBd,ZCd-ZD e)d.eC«       G d/„ d0eA«      «       ZE G d1„ d2ejj                  «      ZF e)d3eC«       G d4„ d5eA«      «       ZG e)d6eC«       G d7„ d8eA«      «       ZH e)d9eC«       G d:„ d;eA«      «       ZI e)d<eC«       G d=„ d>eA«      «       ZJ e)d?eC«       G d@„ dAeA«      «       ZK e)dBeC«       G dC„ dDeA«      «       ZL e)dEeC«       G dF„ dGeAe«      «       ZMg dH¢ZNy)JzPyTorch ELECTRA model.é    N)Ú	dataclass)ÚListÚOptionalÚTupleÚUnion)Únn)ÚBCEWithLogitsLossÚCrossEntropyLossÚMSELossé   )ÚACT2FNÚget_activation)ÚGenerationMixin)Ú"BaseModelOutputWithCrossAttentionsÚ)BaseModelOutputWithPastAndCrossAttentionsÚ!CausalLMOutputWithCrossAttentionsÚMaskedLMOutputÚMultipleChoiceModelOutputÚQuestionAnsweringModelOutputÚSequenceClassifierOutputÚTokenClassifierOutput)ÚPreTrainedModelÚSequenceSummary)Úapply_chunking_to_forwardÚ find_pruneable_heads_and_indicesÚprune_linear_layer)ÚModelOutputÚadd_code_sample_docstringsÚadd_start_docstringsÚ%add_start_docstrings_to_model_forwardÚloggingÚreplace_return_docstringsé   )ÚElectraConfigz"google/electra-small-discriminatorr$   c                 óð  — 	 ddl }ddl}ddl}t        j                  j                  |«      }t        j                  d|› �«       |j                  j                  |«      }g }	g }
|D ]^  \  }}t        j                  d|› d|› �«       |j                  j                  ||«      }|	j                  |«       |
j                  |«       Œ` t        |	|
«      D �]  \  }}|}	 t        | t         «      r|j#                  dd«      }|d	k(  r$|j#                  d
d«      }|j#                  dd
«      }|j#                  dd«      }|j#                  dd«      }|j%                  d«      }t'        d„ |D «       «      rt        j                  d|› �«       Œµ| }|D ]¿  }|j)                  d|«      r|j%                  d|«      }n|g}|d   dk(  s|d   dk(  rt+        |d«      }nV|d   dk(  s|d   dk(  rt+        |d«      }n9|d   dk(  rt+        |d«      }n$|d   dk(  rt+        |d«      }nt+        ||d   «      }t-        |«      dk\  sŒ­t/        |d    «      }||   }ŒÁ j1                  d!«      rt+        |d«      }n|dk(  r|j3                  |«      }	 |j4                  |j4                  k7  r&t7        d"|j4                  › d#|j4                  › d$�«      ‚	 t;        d%|› �|«       t=        j>                  |«      |_         �Œ | S # t        $ r t        j                  d«       ‚ w xY w# t6        $ r1}|xj8                  |j4                  |j4                  fz  c_        ‚ d}~ww xY w# tB        $ r}t;        d|› �||«       Y d}~�Œ�d}~ww xY w)&z'Load tf checkpoints in a pytorch model.r   Nz™Loading a TensorFlow model in PyTorch, requires TensorFlow to be installed. Please see https://www.tensorflow.org/install/ for installation instructions.z&Converting TensorFlow checkpoint from zLoading TF weight z with shape zelectra/embeddings/zgenerator/embeddings/Ú	generatorzelectra/zdiscriminator/z
generator/Údense_1Údense_predictionz!generator_predictions/output_biaszgenerator_lm_head/biasú/c              3   ó$   K  — | ]  }|d v –— Œ
 y­w))Úglobal_stepÚtemperatureN© )Ú.0Úns     új/var/www/skyplay_api_hub/venv/lib/python3.12/site-packages/transformers/models/electra/modeling_electra.pyú	<genexpr>z-load_tf_weights_in_electra.<locals>.<genexpr>d   s   è ø€ ÒE¸1�1Ð6Ô6ÑEùó   ‚z	Skipping z[A-Za-z]+_\d+z_(\d+)ÚkernelÚgammaÚweightÚoutput_biasÚbetaÚbiasÚoutput_weightsÚsquadÚ
classifieré   r#   Ú_embeddingszPointer shape z and array shape z mismatchedzInitialize PyTorch weight )"ÚreÚnumpyÚ
tensorflowÚImportErrorÚloggerÚerrorÚosÚpathÚabspathÚinfoÚtrainÚlist_variablesÚload_variableÚappendÚzipÚ
isinstanceÚElectraForMaskedLMÚreplaceÚsplitÚanyÚ	fullmatchÚgetattrÚlenÚintÚendswithÚ	transposeÚshapeÚ
ValueErrorÚargsÚprintÚtorchÚ
from_numpyÚdataÚAttributeError)ÚmodelÚconfigÚtf_checkpoint_pathÚdiscriminator_or_generatorr>   ÚnpÚtfÚtf_pathÚ	init_varsÚnamesÚarraysÚnamerX   ÚarrayÚoriginal_nameÚpointerÚm_nameÚscope_namesÚnumÚes                       r0   Úload_tf_weights_in_electrarr   :   sz  € ð
ÛãÛô �g‰g�o‰oÐ0Ó1€GÜ
‡K�KÐ8¸¸	ÐBÔCà—‘×'Ñ'¨Ó0€IØ€EØ€FØ ò ‰ˆˆeÜ�‰Ð(¨¨¨l¸5¸'ÐBÔCØ—‘×&Ñ& w°Ó5ˆØ�‰�TÔØ�‰�eÕð	ô
 ˜5 &Ó)ó 6‰ˆˆeØ!ˆð3	Ü˜%Ô!3Ô4Ø—|‘|Ð$9Ð;RÓS�à)¨[Ò8Ø—|‘| JÐ0@ÓA�Ø—|‘| L°*Ó=�à—<‘< 	Ð+=Ó>ˆDØ—<‘<Ð CÐE]Ó^ˆDà—:‘:˜c“?ˆDô ÑEÀÔEÔEÜ—‘˜i¨ Ð7Ô8ØØˆGØò +�Ø—<‘<Ð 0°&Ô9Ø"$§(¡(¨9°fÓ"=‘Kà#) (�KØ˜q‘> XÒ-°¸Q±À7Ò1JÜ% g¨xÓ8‘GØ  ‘^ }Ò4¸ÀA¹È&Ò8PÜ% g¨vÓ6‘GØ  ‘^Ð'7Ò7Ü% g¨xÓ8‘GØ  ‘^ wÒ.Ü% g¨|Ó<‘Gä% g¨{¸1©~Ó>�GÜ�{Ó# qÓ(Ü˜k¨!™nÓ-�CØ% c™l‘Gð#+ð$ �‰˜}Ô-Ü! '¨8Ó4‘Ø˜8Ò#ØŸ™ UÓ+�ðØ—=‘= E§K¡KÒ/Ü$ ~°g·m±m°_ÐDUÐV[×VaÑVaÐUbÐbmÐ%nÓoÐoð 0ô
 Ð.¨t¨fÐ5°}ÔEÜ ×+Ñ+¨EÓ2ˆGŽLðg6ðn €LøôQ ò Ü�‰ðQô	
ð 	ðûô@ ò Ø—’˜7Ÿ=™=¨%¯+©+Ð6Ñ6•Øûðûô
 ò 	Ü�I˜m˜_Ð-¨t°QÔ7Ýûð	úsV   ‚K1 ÃB*MÆB0MÈ9A	MÊ?LË*MË1 LÌ	MÌ,M	Í	MÍMÍ	M5ÍM0Í0M5c                   óÊ   ‡ — e Zd ZdZˆ fd„Z	 	 	 	 	 d
deej                     deej                     deej                     deej                     de	dej                  fd	„Zˆ xZS )ÚElectraEmbeddingszGConstruct the embeddings from word, position and token_type embeddings.c                 ó>  •— t         ‰| �  «        t        j                  |j                  |j
                  |j                  ¬«      | _        t        j                  |j                  |j
                  «      | _	        t        j                  |j                  |j
                  «      | _        t        j                  |j
                  |j                  ¬«      | _        t        j                  |j                  «      | _        | j#                  dt%        j&                  |j                  «      j)                  d«      d¬«       t+        |dd«      | _        | j#                  d	t%        j.                  | j0                  j3                  «       t$        j4                  ¬
«      d¬«       y )N)Úpadding_idx©ÚepsÚposition_ids)r#   éÿÿÿÿF)Ú
persistentÚposition_embedding_typeÚabsoluteÚtoken_type_ids©Údtype)ÚsuperÚ__init__r   Ú	EmbeddingÚ
vocab_sizeÚembedding_sizeÚpad_token_idÚword_embeddingsÚmax_position_embeddingsÚposition_embeddingsÚtype_vocab_sizeÚtoken_type_embeddingsÚ	LayerNormÚlayer_norm_epsÚDropoutÚhidden_dropout_probÚdropoutÚregister_bufferr\   ÚarangeÚexpandrS   r|   Úzerosry   ÚsizeÚlong©Úselfra   Ú	__class__s     €r0   r‚   zElectraEmbeddings.__init__�   s1  ø€ Ü‰ÑÔÜ!Ÿ|™|¨F×,=Ñ,=¸v×?TÑ?TÐbh×buÑbuÔvˆÔÜ#%§<¡<°×0NÑ0NÐPV×PeÑPeÓ#fˆÔ Ü%'§\¡\°&×2HÑ2HÈ&×J_ÑJ_Ó%`ˆÔ"ô Ÿ™ f×&;Ñ&;À×AVÑAVÔWˆŒÜ—z‘z &×"<Ñ"<Ó=ˆŒð 	×ÑØœEŸL™L¨×)GÑ)GÓH×OÑOÐPWÓXÐejð 	ô 	
ô (/¨vÐ7PÐR\Ó']ˆÔ$Ø×ÑØœeŸk™k¨$×*;Ñ*;×*@Ñ*@Ó*BÌ%Ï*É*ÔUÐbgð 	õ 	
ó    Ú	input_idsr~   ry   Úinputs_embedsÚpast_key_values_lengthÚreturnc                 óZ  — |�|j                  «       }n|j                  «       d d }|d   }|€| j                  d d …|||z   …f   }|€st        | d«      r-| j                  d d …d |…f   }|j	                  |d   |«      }	|	}n:t        j                  |t
        j                  | j                  j                  ¬«      }|€| j                  |«      }| j                  |«      }
||
z   }| j                  dk(  r| j                  |«      }||z  }| j                  |«      }| j                  |«      }|S )Nrz   r#   r~   r   ©r€   Údevicer}   )r•   ry   Úhasattrr~   r“   r\   r”   r–   r¡   r‡   r‹   r|   r‰   rŒ   r�   )r˜   r›   r~   ry   rœ   r�   Úinput_shapeÚ
seq_lengthÚbuffered_token_type_idsÚ buffered_token_type_ids_expandedr‹   Ú
embeddingsr‰   s                r0   ÚforwardzElectraEmbeddings.forward¤   sH  € ð Ð Ø#Ÿ.™.Ó*‰Kà'×,Ñ,Ó.¨s°Ð3ˆKà  ‘^ˆ
àÐØ×,Ñ,ªQÐ0FÈÐVlÑIlÐ0lÐ-lÑmˆLð
 Ð!Ü�tÐ-Ô.Ø*.×*=Ñ*=ºaÀÀ*À¸nÑ*MÐ'Ø3J×3QÑ3QÐR]Ð^_ÑR`ÐblÓ3mÐ0Ø!A‘ä!&§¡¨[ÄÇ
Á
ÐSW×SdÑSd×SkÑSkÔ!l�àÐ Ø ×0Ñ0°Ó;ˆMØ $× :Ñ :¸>Ó JÐà"Ð%:Ñ:ˆ
Ø×'Ñ'¨:Ò5Ø"&×":Ñ":¸<Ó"HÐØÐ-Ñ-ˆJØ—^‘^ JÓ/ˆ
Ø—\‘\ *Ó-ˆ
ØÐrš   )NNNNr   )Ú__name__Ú
__module__Ú__qualname__Ú__doc__r‚   r   r\   Ú
LongTensorÚFloatTensorrU   ÚTensorr¨   Ú__classcell__©r™   s   @r0   rt   rt   Œ   s‹   ø„ ÙQô
ð. 15Ø59Ø37Ø59Ø&'ñ'à˜E×,Ñ,Ñ-ð'ð ! ×!1Ñ!1Ñ2ð'ð ˜u×/Ñ/Ñ0ð	'ð
   × 1Ñ 1Ñ2ð'ð !$ð'ð 
�‰÷'rš   rt   c                   óP  ‡ — e Zd Zdˆ fd„	Zdej
                  dej
                  fd„Z	 	 	 	 	 	 ddej
                  deej                     deej                     deej                     d	eej                     d
ee	e	ej                           dee
   de	ej
                     fd„Zˆ xZS )ÚElectraSelfAttentionc                 óâ  •— t         ‰| �  «        |j                  |j                  z  dk7  r2t	        |d«      s&t        d|j                  › d|j                  › d�«      ‚|j                  | _        t        |j                  |j                  z  «      | _        | j                  | j                  z  | _        t        j                  |j                  | j                  «      | _        t        j                  |j                  | j                  «      | _        t        j                  |j                  | j                  «      | _        t        j                  |j                  «      | _        |xs t#        |dd«      | _        | j$                  dk(  s| j$                  d	k(  rF|j&                  | _        t        j(                  d
|j&                  z  dz
  | j                  «      | _        |j,                  | _        y )Nr   r…   zThe hidden size (z6) is not a multiple of the number of attention heads (ú)r|   r}   Úrelative_keyÚrelative_key_queryr<   r#   )r�   r‚   Úhidden_sizeÚnum_attention_headsr¢   rY   rU   Úattention_head_sizeÚall_head_sizer   ÚLinearÚqueryÚkeyÚvaluerŽ   Úattention_probs_dropout_probr�   rS   r|   rˆ   rƒ   Údistance_embeddingÚ
is_decoder©r˜   ra   r|   r™   s      €r0   r‚   zElectraSelfAttention.__init__Ð   s�  ø€ Ü‰ÑÔØ×Ñ × :Ñ :Ñ:¸aÒ?ÌÐPVÐXhÔHiÜØ# F×$6Ñ$6Ð#7ð 8Ø ×4Ñ4Ð5°Qð8óð ð
 $*×#=Ñ#=ˆÔ Ü#& v×'9Ñ'9¸F×<VÑ<VÑ'VÓ#WˆÔ Ø!×5Ñ5¸×8PÑ8PÑPˆÔä—Y‘Y˜v×1Ñ1°4×3EÑ3EÓFˆŒ
Ü—9‘9˜V×/Ñ/°×1CÑ1CÓDˆŒÜ—Y‘Y˜v×1Ñ1°4×3EÑ3EÓFˆŒ
ä—z‘z &×"EÑ"EÓFˆŒØ'>ò (
Ä'ØÐ-¨zóC
ˆÔ$ð ×'Ñ'¨>Ò9¸T×=YÑ=YÐ]qÒ=qØ+1×+IÑ+IˆDÔ(Ü&(§l¡l°1°v×7UÑ7UÑ3UÐXYÑ3YÐ[_×[sÑ[sÓ&tˆDÔ#à ×+Ñ+ˆ�rš   Úxrž   c                 ó¤   — |j                  «       d d | j                  | j                  fz   }|j                  |«      }|j	                  dddd«      S )Nrz   r   r<   r#   r   )r•   r¹   rº   ÚviewÚpermute)r˜   rÄ   Únew_x_shapes      r0   Útranspose_for_scoresz)ElectraSelfAttention.transpose_for_scoresê   sL   € Ø—f‘f“h˜s �m t×'?Ñ'?À×AYÑAYÐ&ZÑZˆØ�F‰F�;ÓˆØ�y‰y˜˜A˜q !Ó$Ð$rš   Úhidden_statesÚattention_maskÚ	head_maskÚencoder_hidden_statesÚencoder_attention_maskÚpast_key_valueÚoutput_attentionsc                 ó$  — | j                  |«      }|d u}	|	r|�|d   }
|d   }|}�n |	rC| j                  | j                  |«      «      }
| j                  | j                  |«      «      }|}n»|�y| j                  | j                  |«      «      }
| j                  | j                  |«      «      }t	        j
                  |d   |
gd¬«      }
t	        j
                  |d   |gd¬«      }n@| j                  | j                  |«      «      }
| j                  | j                  |«      «      }| j                  |«      }|d u}| j                  r|
|f}t	        j                  ||
j                  dd«      «      }| j                  dk(  s| j                  dk(  �r—|j                  d   |
j                  d   }}|rDt	        j                  |dz
  t        j                  |j                  ¬	«      j                  dd«      }n@t	        j                  |t        j                  |j                  ¬	«      j                  dd«      }t	        j                  |t        j                  |j                  ¬	«      j                  dd«      }||z
  }| j!                  || j"                  z   dz
  «      }|j%                  |j&                  ¬
«      }| j                  dk(  rt	        j(                  d||«      }||z   }nE| j                  dk(  r6t	        j(                  d||«      }t	        j(                  d|
|«      }||z   |z   }|t+        j,                  | j.                  «      z  }|�||z   }t0        j2                  j5                  |d¬«      }| j7                  |«      }|�||z  }t	        j                  ||«      }|j9                  dddd«      j;                  «       }|j=                  «       d d | j>                  fz   }|j                  |«      }|r||fn|f}| j                  r||fz   }|S )Nr   r#   r<   ©Údimrz   éþÿÿÿr¶   r·   r    r   zbhld,lrd->bhlrzbhrd,lrd->bhlrr   ) r½   rÉ   r¾   r¿   r\   ÚcatrÂ   ÚmatmulrW   r|   rX   Útensorr–   r¡   rÆ   r’   rÁ   rˆ   Útor€   ÚeinsumÚmathÚsqrtrº   r   Ú
functionalÚsoftmaxr�   rÇ   Ú
contiguousr•   r»   )r˜   rÊ   rË   rÌ   rÍ   rÎ   rÏ   rÐ   Úmixed_query_layerÚis_cross_attentionÚ	key_layerÚvalue_layerÚquery_layerÚ	use_cacheÚattention_scoresÚquery_lengthÚ
key_lengthÚposition_ids_lÚposition_ids_rÚdistanceÚpositional_embeddingÚrelative_position_scoresÚrelative_position_scores_queryÚrelative_position_scores_keyÚattention_probsÚcontext_layerÚnew_context_layer_shapeÚoutputss                               r0   r¨   zElectraSelfAttention.forwardï   sç  € ð !ŸJ™J }Ó5Ðð
 3¸$Ð>Ðá .Ð"<à& qÑ)ˆIØ(¨Ñ+ˆKØ3ŠNÙØ×1Ñ1°$·(±(Ð;PÓ2QÓRˆIØ×3Ñ3°D·J±JÐ?TÓ4UÓVˆKØ3‰NØÐ'Ø×1Ñ1°$·(±(¸=Ó2IÓJˆIØ×3Ñ3°D·J±J¸}Ó4MÓNˆKÜŸ	™	 >°!Ñ#4°iÐ"@ÀaÔHˆIÜŸ)™) ^°AÑ%6¸Ð$DÈ!ÔL‰Kà×1Ñ1°$·(±(¸=Ó2IÓJˆIØ×3Ñ3°D·J±J¸}Ó4MÓNˆKà×/Ñ/Ð0AÓBˆà"¨$Ð.ˆ	Ø�?Š?ð (¨Ð5ˆNô !Ÿ<™<¨°Y×5HÑ5HÈÈRÓ5PÓQÐà×'Ñ'¨>Ò9¸T×=YÑ=YÐ]qÓ=qØ'2×'8Ñ'8¸Ñ';¸Y¿_¹_ÈQÑ=O˜*ˆLÙÜ!&§¡¨j¸1©nÄEÇJÁJÐWd×WkÑWkÔ!l×!qÑ!qØ˜ó"‘ô "'§¡¨lÄ%Ç*Á*ÐUb×UiÑUiÔ!j×!oÑ!oÐprÐtuÓ!v�Ü"Ÿ\™\¨*¼E¿J¹JÈ}×OcÑOcÔd×iÑiÐjkÐmoÓpˆNØ%¨Ñ6ˆHà#'×#:Ñ#:¸8Àd×FbÑFbÑ;bÐefÑ;fÓ#gÐ Ø#7×#:Ñ#:À×ARÑARÐ#:Ó#SÐ à×+Ñ+¨~Ò=Ü+0¯<©<Ð8HÈ+ÐWkÓ+lÐ(Ø#3Ð6NÑ#NÑ Ø×-Ñ-Ð1EÒEÜ16·±Ð>NÐP[Ð]qÓ1rÐ.Ü/4¯|©|Ð<LÈiÐYmÓ/nÐ,Ø#3Ð6TÑ#TÐWsÑ#sÐ à+¬d¯i©i¸×8PÑ8PÓ.QÑQÐØÐ%à/°.Ñ@Ðô Ÿ-™-×/Ñ/Ð0@ÀbÐ/ÓIˆð Ÿ,™, Ó7ˆð Ð Ø-°	Ñ9ˆOäŸ™ _°kÓBˆà%×-Ñ-¨a°°A°qÓ9×DÑDÓFˆØ"/×"4Ñ"4Ó"6°s¸Ð";¸t×?QÑ?QÐ>SÑ"SÐØ%×*Ñ*Ð+BÓCˆá6G�= /Ñ2ÈmÐM]ˆà�?Š?Ø Ð 1Ñ1ˆGØˆrš   ©N©NNNNNF)r©   rª   r«   r‚   r\   r¯   rÉ   r   r®   r   Úboolr¨   r°   r±   s   @r0   r³   r³   Ï   så   ø„ õ,ð4% e§l¡lð %°u·|±|ó %ð 7;Ø15Ø=AØ>BØDHØ,1ñcà—|‘|ðcð ! ×!2Ñ!2Ñ3ðcð ˜E×-Ñ-Ñ.ð	cð
  (¨×(9Ñ(9Ñ:ðcð !)¨×):Ñ):Ñ ;ðcð !  u¨U×->Ñ->Ñ'?Ñ!@ÑAðcð $ D™>ðcð 
ˆu�|‰|Ñ	÷crš   r³   c                   ón   ‡ — e Zd Zˆ fd„Zdej
                  dej
                  dej
                  fd„Zˆ xZS )ÚElectraSelfOutputc                 ó(  •— t         ‰| �  «        t        j                  |j                  |j                  «      | _        t        j                  |j                  |j                  ¬«      | _        t        j                  |j                  «      | _
        y ©Nrw   )r�   r‚   r   r¼   r¸   ÚdenserŒ   r�   rŽ   r�   r�   r—   s     €r0   r‚   zElectraSelfOutput.__init__W  s`   ø€ Ü‰ÑÔÜ—Y‘Y˜v×1Ñ1°6×3EÑ3EÓFˆŒ
ÜŸ™ f×&8Ñ&8¸f×>SÑ>SÔTˆŒÜ—z‘z &×"<Ñ"<Ó=ˆ�rš   rÊ   Úinput_tensorrž   c                 ór   — | j                  |«      }| j                  |«      }| j                  ||z   «      }|S ró   ©rú   r�   rŒ   ©r˜   rÊ   rû   s      r0   r¨   zElectraSelfOutput.forward]  ó7   € ØŸ
™
 =Ó1ˆØŸ™ ]Ó3ˆØŸ™ }°|Ñ'CÓDˆØÐrš   ©r©   rª   r«   r‚   r\   r¯   r¨   r°   r±   s   @r0   r÷   r÷   V  ó1   ø„ ô>ð U§\¡\ð ÀÇÁð ÐRW×R^ÑR^÷ rš   r÷   Úeagerc                   ó  ‡ — e Zd Zdˆ fd„	Zd„ Z	 	 	 	 	 	 ddej                  deej                     deej                     deej                     deej                     dee	e	ej                           d	ee
   d
e	ej                     fd„Zˆ xZS )ÚElectraAttentionc                 óž   •— t         ‰| �  «        t        |j                     ||¬«      | _        t        |«      | _        t        «       | _        y )N©r|   )	r�   r‚   ÚELECTRA_SELF_ATTENTION_CLASSESÚ_attn_implementationr˜   r÷   ÚoutputÚsetÚpruned_headsrÃ   s      €r0   r‚   zElectraAttention.__init__k  sC   ø€ Ü‰ÑÔÜ2°6×3NÑ3NÑOØÐ,Cô
ˆŒ	ô (¨Ó/ˆŒÜ›EˆÕrš   c                 ó>  — t        |«      dk(  ry t        || j                  j                  | j                  j                  | j
                  «      \  }}t        | j                  j                  |«      | j                  _        t        | j                  j                  |«      | j                  _        t        | j                  j                  |«      | j                  _	        t        | j                  j                  |d¬«      | j                  _        | j                  j                  t        |«      z
  | j                  _        | j                  j                  | j                  j                  z  | j                  _        | j
                  j                  |«      | _        y )Nr   r#   rÒ   )rT   r   r˜   r¹   rº   r  r   r½   r¾   r¿   r	  rú   r»   Úunion)r˜   ÚheadsÚindexs      r0   Úprune_headszElectraAttention.prune_headss  s  € Üˆu‹:˜Š?ØÜ7Ø�4—9‘9×0Ñ0°$·)±)×2OÑ2OÐQU×QbÑQbó
‰ˆˆuô
 -¨T¯Y©Y¯_©_¸eÓDˆ�	‰	ŒÜ*¨4¯9©9¯=©=¸%Ó@ˆ�	‰	ŒÜ,¨T¯Y©Y¯_©_¸eÓDˆ�	‰	ŒÜ.¨t¯{©{×/@Ñ/@À%ÈQÔOˆ�‰Ôð )-¯	©	×(EÑ(EÌÈEË
Ñ(Rˆ�	‰	Ô%Ø"&§)¡)×"?Ñ"?À$Ç)Á)×B_ÑB_Ñ"_ˆ�	‰	ÔØ ×-Ñ-×3Ñ3°EÓ:ˆÕrš   rÊ   rË   rÌ   rÍ   rÎ   rÏ   rÐ   rž   c           	      óp   — | j                  |||||||«      }| j                  |d   |«      }	|	f|dd  z   }
|
S )Nr   r#   )r˜   r	  )r˜   rÊ   rË   rÌ   rÍ   rÎ   rÏ   rÐ   Úself_outputsÚattention_outputrò   s              r0   r¨   zElectraAttention.forward…  sW   € ð —y‘yØØØØ!Ø"ØØó
ˆð  Ÿ;™; |°A¡¸ÓFÐØ#Ð%¨°Q°RÐ(8Ñ8ˆØˆrš   ró   rô   )r©   rª   r«   r‚   r  r\   r¯   r   r®   r   rõ   r¨   r°   r±   s   @r0   r  r  j  sÆ   ø„ õ"ò;ð* 7;Ø15Ø=AØ>BØDHØ,1ñà—|‘|ðð ! ×!2Ñ!2Ñ3ðð ˜E×-Ñ-Ñ.ð	ð
  (¨×(9Ñ(9Ñ:ðð !)¨×):Ñ):Ñ ;ðð !  u¨U×->Ñ->Ñ'?Ñ!@ÑAðð $ D™>ðð 
ˆu�|‰|Ñ	÷rš   r  c                   óV   ‡ — e Zd Zˆ fd„Zdej
                  dej
                  fd„Zˆ xZS )ÚElectraIntermediatec                 ó  •— t         ‰| �  «        t        j                  |j                  |j
                  «      | _        t        |j                  t        «      rt        |j                     | _        y |j                  | _        y ró   )r�   r‚   r   r¼   r¸   Úintermediate_sizerú   rM   Ú
hidden_actÚstrr   Úintermediate_act_fnr—   s     €r0   r‚   zElectraIntermediate.__init__Ÿ  s]   ø€ Ü‰ÑÔÜ—Y‘Y˜v×1Ñ1°6×3KÑ3KÓLˆŒ
Ü�f×'Ñ'¬Ô-Ü'-¨f×.?Ñ.?Ñ'@ˆDÕ$à'-×'8Ñ'8ˆDÕ$rš   rÊ   rž   c                 óJ   — | j                  |«      }| j                  |«      }|S ró   )rú   r  )r˜   rÊ   s     r0   r¨   zElectraIntermediate.forward§  s&   € ØŸ
™
 =Ó1ˆØ×0Ñ0°Ó?ˆØÐrš   r   r±   s   @r0   r  r  ž  s#   ø„ ô9ð U§\¡\ð °e·l±l÷ rš   r  c                   ón   ‡ — e Zd Zˆ fd„Zdej
                  dej
                  dej
                  fd„Zˆ xZS )ÚElectraOutputc                 ó(  •— t         ‰| �  «        t        j                  |j                  |j
                  «      | _        t        j                  |j
                  |j                  ¬«      | _        t        j                  |j                  «      | _        y rù   )r�   r‚   r   r¼   r  r¸   rú   rŒ   r�   rŽ   r�   r�   r—   s     €r0   r‚   zElectraOutput.__init__¯  s`   ø€ Ü‰ÑÔÜ—Y‘Y˜v×7Ñ7¸×9KÑ9KÓLˆŒ
ÜŸ™ f×&8Ñ&8¸f×>SÑ>SÔTˆŒÜ—z‘z &×"<Ñ"<Ó=ˆ�rš   rÊ   rû   rž   c                 ór   — | j                  |«      }| j                  |«      }| j                  ||z   «      }|S ró   rý   rþ   s      r0   r¨   zElectraOutput.forwardµ  rÿ   rš   r   r±   s   @r0   r  r  ®  r  rš   r  c                   ó  ‡ — e Zd Zˆ fd„Z	 	 	 	 	 	 ddej
                  deej                     deej                     deej                     deej                     deeeej                           dee	   d	eej
                     fd
„Z
d„ Zˆ xZS )ÚElectraLayerc                 óf  •— t         ‰| �  «        |j                  | _        d| _        t	        |«      | _        |j                  | _        |j                  | _        | j                  r,| j                  st        | › d�«      ‚t	        |d¬«      | _	        t        |«      | _        t        |«      | _        y )Nr#   z> should be used as a decoder model if cross attention is addedr}   r  )r�   r‚   Úchunk_size_feed_forwardÚseq_len_dimr  Ú	attentionrÂ   Úadd_cross_attentionrY   Úcrossattentionr  Úintermediater  r	  r—   s     €r0   r‚   zElectraLayer.__init__¾  s—   ø€ Ü‰ÑÔØ'-×'EÑ'EˆÔ$ØˆÔÜ)¨&Ó1ˆŒØ ×+Ñ+ˆŒØ#)×#=Ñ#=ˆÔ Ø×#Ò#Ø—?’?Ü  D 6Ð)gÐ!hÓiÐiÜ"2°6ÐS]Ô"^ˆDÔÜ/°Ó7ˆÔÜ# FÓ+ˆ�rš   rÊ   rË   rÌ   rÍ   rÎ   rÏ   rÐ   rž   c           	      óÒ  — |�|d d nd }| j                  |||||¬«      }	|	d   }
| j                  r|	dd }|	d   }n|	dd  }d }| j                  rT|�Rt        | d«      st        d| › d�«      ‚|�|d	d  nd }| j	                  |
||||||«      }|d   }
||dd z   }|d   }|z   }t        | j                  | j                  | j                  |
«      }|f|z   }| j                  r|fz   }|S )
Nr<   )rÐ   rÏ   r   r#   rz   r'  z'If `encoder_hidden_states` are passed, z` has to be instantiated with cross-attention layers by setting `config.add_cross_attention=True`rÔ   )	r%  rÂ   r¢   rY   r'  r   Úfeed_forward_chunkr#  r$  )r˜   rÊ   rË   rÌ   rÍ   rÎ   rÏ   rÐ   Úself_attn_past_key_valueÚself_attention_outputsr  rò   Úpresent_key_valueÚcross_attn_present_key_valueÚcross_attn_past_key_valueÚcross_attention_outputsÚlayer_outputs                    r0   r¨   zElectraLayer.forwardÌ  s}  € ð :HÐ9S >°"°1Ñ#5ÐY]Ð Ø!%§¡ØØØØ/Ø3ð "0ó "
Ðð 2°!Ñ4Ðð �?Š?Ø,¨Q¨rÐ2ˆGØ 6°rÑ :Ñà,¨Q¨RÐ0ˆGà'+Ð$Ø�?Š?Ð4Ð@Ü˜4Ð!1Ô2Ü Ø=¸d¸Vð DDð Dóð ð @NÐ?Y¨°r°sÑ(;Ð_cÐ%Ø&*×&9Ñ&9Ø ØØØ%Ø&Ø)Ø!ó'Ð#ð  7°qÑ9ÐØÐ 7¸¸"Ð =Ñ=ˆGð ,CÀ2Ñ+FÐ(Ø 1Ð4PÑ PÐä0Ø×#Ñ# T×%AÑ%AÀ4×CSÑCSÐUeó
ˆð  �/ GÑ+ˆð �?Š?ØÐ!2Ð 4Ñ4ˆGàˆrš   c                 óL   — | j                  |«      }| j                  ||«      }|S ró   )r(  r	  )r˜   r  Úintermediate_outputr1  s       r0   r*  zElectraLayer.feed_forward_chunk  s,   € Ø"×/Ñ/Ð0@ÓAÐØ—{‘{Ð#6Ð8HÓIˆØÐrš   rô   )r©   rª   r«   r‚   r\   r¯   r   r®   r   rõ   r¨   r*  r°   r±   s   @r0   r!  r!  ½  sÇ   ø„ ô,ð" 7;Ø15Ø=AØ>BØDHØ,1ñ?à—|‘|ð?ð ! ×!2Ñ!2Ñ3ð?ð ˜E×-Ñ-Ñ.ð	?ð
  (¨×(9Ñ(9Ñ:ð?ð !)¨×):Ñ):Ñ ;ð?ð !  u¨U×->Ñ->Ñ'?Ñ!@ÑAð?ð $ D™>ð?ð 
ˆu�|‰|Ñ	ó?öBrš   r!  c                   óD  ‡ — e Zd Zˆ fd„Z	 	 	 	 	 	 	 	 	 ddej
                  deej                     deej                     deej                     deej                     deeeej                           dee	   d	ee	   d
ee	   dee	   de
eej
                     ef   fd„Zˆ xZS )ÚElectraEncoderc                 óÐ   •— t         ‰| �  «        || _        t        j                  t        |j                  «      D �cg c]  }t        |«      ‘Œ c}«      | _        d| _	        y c c}w )NF)
r�   r‚   ra   r   Ú
ModuleListÚrangeÚnum_hidden_layersr!  ÚlayerÚgradient_checkpointing)r˜   ra   Ú_r™   s      €r0   r‚   zElectraEncoder.__init__  sN   ø€ Ü‰ÑÔØˆŒÜ—]‘]Ä%È×H`ÑH`ÓBaÖ#b¸Q¤L°Õ$8Ò#bÓcˆŒ
Ø&+ˆÕ#ùò $cs   ½A#rÊ   rË   rÌ   rÍ   rÎ   Úpast_key_valuesrä   rÐ   Úoutput_hidden_statesÚreturn_dictrž   c                 óš  — |	rdnd }|rdnd }|r| j                   j                  rdnd }| j                  r%| j                  r|rt        j                  d«       d}|rdnd }t        | j                  «      D ]¤  \  }}|	r||fz   }|�||   nd }|�||   nd }| j                  r/| j                  r#| j                  |j                  |||||||«      }n ||||||||«      }|d   }|r	||d   fz  }|sŒ|||d   fz   }| j                   j                  sŒœ||d   fz   }Œ¦ |	r||fz   }|
st        d„ |||||fD «       «      S t        |||||¬	«      S )
Nr-   zZ`use_cache=True` is incompatible with gradient checkpointing. Setting `use_cache=False`...Fr   rz   r#   r<   c              3   ó$   K  — | ]  }|�|–— Œ
 y ­wró   r-   )r.   Úvs     r0   r1   z)ElectraEncoder.forward.<locals>.<genexpr>]  s   è ø€ ò 
àð �=ô ñ
ùr2   )Úlast_hidden_stater=  rÊ   Ú
attentionsÚcross_attentions)ra   r&  r;  ÚtrainingrB   Úwarning_onceÚ	enumerater:  Ú_gradient_checkpointing_funcÚ__call__Útupler   )r˜   rÊ   rË   rÌ   rÍ   rÎ   r=  rä   rÐ   r>  r?  Úall_hidden_statesÚall_self_attentionsÚall_cross_attentionsÚnext_decoder_cacheÚiÚlayer_moduleÚlayer_head_maskrÏ   Úlayer_outputss                       r0   r¨   zElectraEncoder.forward  sÎ  € ñ #7™B¸DÐÙ$5™b¸4ÐÙ%6¸4¿;¹;×;ZÒ;Z™rÐ`dÐà×&Ò&¨4¯=ª=ÙÜ×#Ñ#Øpôð "�	á#,™R°$ÐÜ(¨¯©Ó4ò #	V‰OˆAˆ|Ù#Ø$5¸Ð8HÑ$HÐ!à.7Ð.C˜i¨šlÈˆOØ3BÐ3N˜_¨QÒ/ÐTXˆNà×*Ò*¨t¯}ª}Ø $× AÑ AØ ×)Ñ)Ø!Ø"Ø#Ø)Ø*Ø"Ø%ó	!‘ñ !-Ø!Ø"Ø#Ø)Ø*Ø"Ø%ó!�ð *¨!Ñ,ˆMÙØ" }°RÑ'8Ð&:Ñ:Ð"Ú Ø&9¸]È1Ñ=MÐ<OÑ&OÐ#Ø—;‘;×2Ó2Ø+?À=ÐQRÑCSÐBUÑ+UÑ(ðG#	VñJ  Ø 1°]Ð4DÑ DÐáÜñ 
ð "Ø&Ø%Ø'Ø(ðô
ó 
ð 
ô 9Ø+Ø.Ø+Ø*Ø1ô
ð 	
rš   )	NNNNNNFFT)r©   rª   r«   r‚   r\   r¯   r   r®   r   rõ   r   r   r¨   r°   r±   s   @r0   r5  r5    s  ø„ ô,ð 7;Ø15Ø=AØ>BØEIØ$(Ø,1Ø/4Ø&*ñS
à—|‘|ðS
ð ! ×!2Ñ!2Ñ3ðS
ð ˜E×-Ñ-Ñ.ð	S
ð
  (¨×(9Ñ(9Ñ:ðS
ð !)¨×):Ñ):Ñ ;ðS
ð " %¨¨e×.?Ñ.?Ñ(@Ñ"AÑBðS
ð ˜D‘>ðS
ð $ D™>ðS
ð ' t™nðS
ð ˜d‘^ðS
ð 
ˆu�U—\‘\Ñ"Ð$MÐMÑ	N÷S
rš   r5  c                   ó(   ‡ — e Zd ZdZˆ fd„Zd„ Zˆ xZS )ÚElectraDiscriminatorPredictionszEPrediction module for the discriminator, made up of two dense layers.c                 ó  •— t         ‰| �  «        t        j                  |j                  |j                  «      | _        t        |j                  «      | _        t        j                  |j                  d«      | _	        || _
        y ©Nr#   )r�   r‚   r   r¼   r¸   rú   r   r  Ú
activationr(   ra   r—   s     €r0   r‚   z(ElectraDiscriminatorPredictions.__init__t  s^   ø€ Ü‰ÑÔä—Y‘Y˜v×1Ñ1°6×3EÑ3EÓFˆŒ
Ü(¨×):Ñ):Ó;ˆŒÜ "§	¡	¨&×*<Ñ*<¸aÓ @ˆÔØˆ�rš   c                 óŠ   — | j                  |«      }| j                  |«      }| j                  |«      j                  d«      }|S )Nrz   )rú   rX  r(   Úsqueeze)r˜   Údiscriminator_hidden_statesrÊ   Úlogitss       r0   r¨   z'ElectraDiscriminatorPredictions.forward|  s?   € ØŸ
™
Ð#>Ó?ˆØŸ™¨Ó6ˆØ×&Ñ& }Ó5×=Ñ=¸bÓAˆàˆrš   ©r©   rª   r«   r¬   r‚   r¨   r°   r±   s   @r0   rU  rU  q  s   ø„ ÙOôörš   rU  c                   ó(   ‡ — e Zd ZdZˆ fd„Zd„ Zˆ xZS )ÚElectraGeneratorPredictionszAPrediction module for the generator, made up of two dense layers.c                 ó   •— t         ‰| �  «        t        d«      | _        t	        j
                  |j                  |j                  ¬«      | _        t	        j                  |j                  |j                  «      | _
        y )NÚgelurw   )r�   r‚   r   rX  r   rŒ   r…   r�   r¼   r¸   rú   r—   s     €r0   r‚   z$ElectraGeneratorPredictions.__init__‡  sV   ø€ Ü‰ÑÔä(¨Ó0ˆŒÜŸ™ f×&;Ñ&;À×AVÑAVÔWˆŒÜ—Y‘Y˜v×1Ñ1°6×3HÑ3HÓIˆ�
rš   c                 ól   — | j                  |«      }| j                  |«      }| j                  |«      }|S ró   )rú   rX  rŒ   )r˜   Úgenerator_hidden_statesrÊ   s      r0   r¨   z#ElectraGeneratorPredictions.forwardŽ  s3   € ØŸ
™
Ð#:Ó;ˆØŸ™¨Ó6ˆØŸ™ }Ó5ˆàÐrš   r]  r±   s   @r0   r_  r_  „  s   ø„ ÙKôJörš   r_  c                   ó&   — e Zd ZdZeZeZdZdZ	d„ Z
y)ÚElectraPreTrainedModelz†
    An abstract class to handle weights initialization and a simple interface for downloading and loading pretrained
    models.
    ÚelectraTc                 ó  — t        |t        j                  «      rm|j                  j                  j                  d| j                  j                  ¬«       |j                  �%|j                  j                  j                  «        yyt        |t        j                  «      rz|j                  j                  j                  d| j                  j                  ¬«       |j                  �2|j                  j                  |j                     j                  «        yyt        |t        j                  «      rJ|j                  j                  j                  «        |j                  j                  j                  d«       yy)zInitialize the weightsg        )ÚmeanÚstdNg      ð?)rM   r   r¼   r5   r^   Únormal_ra   Úinitializer_ranger8   Úzero_rƒ   rv   rŒ   Úfill_)r˜   Úmodules     r0   Ú_init_weightsz$ElectraPreTrainedModel._init_weights¡  s  € ä�fœbŸi™iÔ(ð �M‰M×Ñ×&Ñ&¨C°T·[±[×5RÑ5RÐ&ÔSØ�{‰{Ð&Ø—‘× Ñ ×&Ñ&Õ(ð 'ä˜¤§¡Ô-Ø�M‰M×Ñ×&Ñ&¨C°T·[±[×5RÑ5RÐ&ÔSØ×!Ñ!Ð-Ø—‘×"Ñ" 6×#5Ñ#5Ñ6×<Ñ<Õ>ð .ä˜¤§¡Ô-Ø�K‰K×Ñ×"Ñ"Ô$Ø�M‰M×Ñ×$Ñ$ SÕ)ð .rš   N)r©   rª   r«   r¬   r$   Úconfig_classrr   Úload_tf_weightsÚbase_model_prefixÚsupports_gradient_checkpointingro  r-   rš   r0   re  re  –  s$   „ ñð
 !€LØ0€OØ!ÐØ&*Ð#ó*rš   re  c                   ó¾   — e Zd ZU dZdZeej                     ed<   dZ	eej                     ed<   dZ
eeej                        ed<   dZeeej                        ed<   y)ÚElectraForPreTrainingOutputaä  
    Output type of [`ElectraForPreTraining`].

    Args:
        loss (*optional*, returned when `labels` is provided, `torch.FloatTensor` of shape `(1,)`):
            Total loss of the ELECTRA objective.
        logits (`torch.FloatTensor` of shape `(batch_size, sequence_length)`):
            Prediction scores of the head (scores for each token before SoftMax).
        hidden_states (`tuple(torch.FloatTensor)`, *optional*, returned when `output_hidden_states=True` is passed or when `config.output_hidden_states=True`):
            Tuple of `torch.FloatTensor` (one for the output of the embeddings + one for the output of each layer) of
            shape `(batch_size, sequence_length, hidden_size)`.

            Hidden-states of the model at the output of each layer plus the initial embedding outputs.
        attentions (`tuple(torch.FloatTensor)`, *optional*, returned when `output_attentions=True` is passed or when `config.output_attentions=True`):
            Tuple of `torch.FloatTensor` (one for each layer) of shape `(batch_size, num_heads, sequence_length,
            sequence_length)`.

            Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
            heads.
    NÚlossr\  rÊ   rD  )r©   rª   r«   r¬   rv  r   r\   r®   Ú__annotations__r\  rÊ   r   rD  r-   rš   r0   ru  ru  ²  sg   … ñð* )-€Dˆ(�5×$Ñ$Ñ
%Ó,Ø*.€FˆH�U×&Ñ&Ñ'Ó.Ø8<€M�8˜E %×"3Ñ"3Ñ4Ñ5Ó<Ø59€J�˜˜u×0Ñ0Ñ1Ñ2Ô9rš   ru  aA  

    This model inherits from [`PreTrainedModel`]. Check the superclass documentation for the generic methods the
    library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
    etc.)

    This model is also a PyTorch [torch.nn.Module](https://pytorch.org/docs/stable/nn.html#torch.nn.Module) subclass.
    Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
    and behavior.

    Parameters:
        config ([`ElectraConfig`]): Model configuration class with all the parameters of the model.
            Initializing with a config file does not load the weights associated with the model, only the
            configuration. Check out the [`~PreTrainedModel.from_pretrained`] method to load the model weights.
aÛ  
    Args:
        input_ids (`torch.LongTensor` of shape `({0})`):
            Indices of input sequence tokens in the vocabulary.

            Indices can be obtained using [`AutoTokenizer`]. See [`PreTrainedTokenizer.encode`] and
            [`PreTrainedTokenizer.__call__`] for details.

            [What are input IDs?](../glossary#input-ids)
        attention_mask (`torch.FloatTensor` of shape `({0})`, *optional*):
            Mask to avoid performing attention on padding token indices. Mask values selected in `[0, 1]`:

            - 1 for tokens that are **not masked**,
            - 0 for tokens that are **masked**.

            [What are attention masks?](../glossary#attention-mask)
        token_type_ids (`torch.LongTensor` of shape `({0})`, *optional*):
            Segment token indices to indicate first and second portions of the inputs. Indices are selected in `[0,
            1]`:

            - 0 corresponds to a *sentence A* token,
            - 1 corresponds to a *sentence B* token.

            [What are token type IDs?](../glossary#token-type-ids)
        position_ids (`torch.LongTensor` of shape `({0})`, *optional*):
            Indices of positions of each input sequence tokens in the position embeddings. Selected in the range `[0,
            config.max_position_embeddings - 1]`.

            [What are position IDs?](../glossary#position-ids)
        head_mask (`torch.FloatTensor` of shape `(num_heads,)` or `(num_layers, num_heads)`, *optional*):
            Mask to nullify selected heads of the self-attention modules. Mask values selected in `[0, 1]`:

            - 1 indicates the head is **not masked**,
            - 0 indicates the head is **masked**.

        inputs_embeds (`torch.FloatTensor` of shape `({0}, hidden_size)`, *optional*):
            Optionally, instead of passing `input_ids` you can choose to directly pass an embedded representation. This
            is useful if you want more control over how to convert `input_ids` indices into associated vectors than the
            model's internal embedding lookup matrix.
        encoder_hidden_states  (`torch.FloatTensor` of shape `({0}, hidden_size)`, *optional*):
            Sequence of hidden-states at the output of the last layer of the encoder. Used in the cross-attention if
            the model is configured as a decoder.
        encoder_attention_mask (`torch.FloatTensor` of shape `({0})`, *optional*):
            Mask to avoid performing attention on the padding token indices of the encoder input. This mask is used in
            the cross-attention if the model is configured as a decoder. Mask values selected in `[0, 1]`:

            - 1 indicates the head is **not masked**,
            - 0 indicates the head is **masked**.

        output_attentions (`bool`, *optional*):
            Whether or not to return the attentions tensors of all attention layers. See `attentions` under returned
            tensors for more detail.
        output_hidden_states (`bool`, *optional*):
            Whether or not to return the hidden states of all layers. See `hidden_states` under returned tensors for
            more detail.
        return_dict (`bool`, *optional*):
            Whether or not to return a [`~utils.ModelOutput`] instead of a plain tuple.
a]  The bare Electra Model transformer outputting raw hidden-states without any specific head on top. Identical to the BERT model except that it uses an additional linear layer between the embedding layer and the encoder if the hidden size and embedding size are different. Both the generator and discriminator checkpoints may be loaded into this model.c            !       ó  ‡ — e Zd Zˆ fd„Zd„ Zd„ Zd„ Z eej                  d«      «       e
eee¬«      	 	 	 	 	 	 	 	 	 	 	 	 	 ddeej                      deej                      d	eej                      d
eej                      deej                      deej                      deej                      deej                      deeej$                        dee   dee   dee   dee   deeej                      ef   fd„«       «       Zˆ xZS )ÚElectraModelc                 ó"  •— t         ‰| �  |«       t        |«      | _        |j                  |j
                  k7  r/t        j                  |j                  |j
                  «      | _        t        |«      | _
        || _        | j                  «        y ró   )r�   r‚   rt   r§   r…   r¸   r   r¼   Úembeddings_projectr5  Úencoderra   Ú	post_initr—   s     €r0   r‚   zElectraModel.__init__$  sl   ø€ Ü‰Ñ˜Ô Ü+¨FÓ3ˆŒà× Ñ  F×$6Ñ$6Ò6Ü&(§i¡i°×0EÑ0EÀv×GYÑGYÓ&ZˆDÔ#ä% fÓ-ˆŒØˆŒà�‰Õrš   c                 ó.   — | j                   j                  S ró   ©r§   r‡   ©r˜   s    r0   Úget_input_embeddingsz!ElectraModel.get_input_embeddings0  s   € Ø�‰×.Ñ.Ð.rš   c                 ó&   — || j                   _        y ró   r  )r˜   r¿   s     r0   Úset_input_embeddingsz!ElectraModel.set_input_embeddings3  s   € Ø*/ˆ�‰Õ'rš   c                 ó˜   — |j                  «       D ]7  \  }}| j                  j                  |   j                  j	                  |«       Œ9 y)z�
        Prunes heads of the model. heads_to_prune: dict of {layer_num: list of heads to prune in this layer} See base
        class PreTrainedModel
        N)Úitemsr|  r:  r%  r  )r˜   Úheads_to_pruner:  r  s       r0   Ú_prune_headszElectraModel._prune_heads6  sE   € ð
 +×0Ñ0Ó2ò 	C‰LˆE�5Ø�L‰L×Ñ˜uÑ%×/Ñ/×;Ñ;¸EÕBñ	Crš   úbatch_size, sequence_length©Ú
checkpointÚoutput_typerp  r›   rË   r~   ry   rÌ   rœ   rÍ   rÎ   r=  rä   rÐ   r>  r?  rž   c                 ó˜  — |�|n| j                   j                  }|�|n| j                   j                  }|�|n| j                   j                  }|�|�t	        d«      ‚|�#| j                  ||«       |j                  «       }n!|�|j                  «       d d }nt	        d«      ‚|\  }}|�|j                  n|j                  }|	�|	d   d   j                  d   nd}|€t        j                  ||¬«      }|€pt        | j                  d«      r4| j                  j                  d d …d |…f   }|j                  ||«      }|}n&t        j                  |t        j                   |¬«      }| j#                  ||«      }| j                   j$                  rE|�C|j                  «       \  }}}||f}|€t        j                  ||¬«      }| j'                  |«      }nd }| j)                  || j                   j*                  «      }| j                  |||||¬	«      }t        | d
«      r| j-                  |«      }| j/                  ||||||	|
|||¬«
      }|S )NzDYou cannot specify both input_ids and inputs_embeds at the same timerz   z5You have to specify either input_ids or inputs_embedsr   r<   )r¡   r~   r    )r›   ry   r~   rœ   r�   r{  )	rË   rÌ   rÍ   rÎ   r=  rä   rÐ   r>  r?  )ra   rÐ   r>  Úuse_return_dictrY   Ú%warn_if_padding_and_no_attention_maskr•   r¡   rX   r\   Úonesr¢   r§   r~   r“   r”   r–   Úget_extended_attention_maskrÂ   Úinvert_attention_maskÚget_head_maskr9  r{  r|  )r˜   r›   rË   r~   ry   rÌ   rœ   rÍ   rÎ   r=  rä   rÐ   r>  r?  r£   Ú
batch_sizer¤   r¡   r�   r¥   r¦   Úextended_attention_maskÚencoder_batch_sizeÚencoder_sequence_lengthr<  Úencoder_hidden_shapeÚencoder_extended_attention_maskrÊ   s                               r0   r¨   zElectraModel.forward>  s…  € ð, 2CÐ1NÑ-ÐTX×T_ÑT_×TqÑTqÐà$8Ð$DÑ È$Ï+É+×JjÑJjð 	ð &1Ð%<‘kÀ$Ç+Á+×B]ÑB]ˆàÐ  ]Ð%>ÜÐcÓdÐdØÐ"Ø×6Ñ6°yÀ.ÔQØ#Ÿ.™.Ó*‰KØÐ&Ø'×,Ñ,Ó.¨s°Ð3‰KäÐTÓUÐUà!,Ñˆ
�JØ%.Ð%:�×!Ò!À×@TÑ@Tˆð DSÐC^ °Ñ!3°AÑ!6×!<Ñ!<¸QÒ!?ÐdeÐàÐ!Ü"ŸZ™Z¨¸FÔCˆNØÐ!Ü�t—‘Ð(8Ô9Ø*.¯/©/×*HÑ*HÊÈKÈZÈKÈÑ*XÐ'Ø3J×3QÑ3QÐR\Ð^hÓ3iÐ0Ø!A‘ä!&§¡¨[ÄÇ
Á
ÐSYÔ!Z�à"&×"BÑ"BÀ>ÐS^Ó"_Ðð �;‰;×!Ò!Ð&;Ð&GØ=R×=WÑ=WÓ=YÑ:ÐÐ 7¸Ø$6Ð8OÐ#PÐ Ø%Ð-Ü).¯©Ð4HÐQWÔ)XÐ&Ø.2×.HÑ.HÐI_Ó.`Ñ+à.2Ð+à×&Ñ& y°$·+±+×2OÑ2OÓPˆ	àŸ™ØØ%Ø)Ø'Ø#9ð (ó 
ˆô �4Ð-Ô.Ø ×3Ñ3°MÓBˆMàŸ™ØØ2ØØ"7Ø#BØ+ØØ/Ø!5Ø#ð %ó 
ˆð Ðrš   )NNNNNNNNNNNNN)r©   rª   r«   r‚   r�  rƒ  r‡  r    ÚELECTRA_INPUTS_DOCSTRINGÚformatr   Ú_CHECKPOINT_FOR_DOCr   Ú_CONFIG_FOR_DOCr   r\   r¯   r   r®   rõ   r   r   r¨   r°   r±   s   @r0   ry  ry    s”  ø„ ô
ò/ò0òCñ +Ð+C×+JÑ+JÐKhÓ+iÓjÙØ&Ø6Ø$ôð -1Ø15Ø15Ø/3Ø,0Ø04Ø8<Ø9=Ø=AØ$(Ø,0Ø/3Ø&*ñWà˜EŸL™LÑ)ðWð ! §¡Ñ.ðWð ! §¡Ñ.ð	Wð
 ˜uŸ|™|Ñ,ðWð ˜EŸL™LÑ)ðWð   §¡Ñ-ðWð  (¨¯©Ñ5ðWð !)¨¯©Ñ 6ðWð " $ u×'8Ñ'8Ñ"9Ñ:ðWð ˜D‘>ðWð $ D™>ðWð ' t™nðWð ˜d‘^ðWð 
ˆu�U—\‘\Ñ"Ð$FÐFÑ	GòWóó kôWrš   ry  c                   ó(   ‡ — e Zd ZdZˆ fd„Zd„ Zˆ xZS )ÚElectraClassificationHeadz-Head for sentence-level classification tasks.c                 óz  •— t         ‰| �  «        t        j                  |j                  |j                  «      | _        |j                  �|j                  n|j                  }t        d«      | _	        t        j                  |«      | _        t        j                  |j                  |j                  «      | _        y )Nra  )r�   r‚   r   r¼   r¸   rú   Úclassifier_dropoutr�   r   rX  rŽ   r�   Ú
num_labelsÚout_proj©r˜   ra   r   r™   s      €r0   r‚   z"ElectraClassificationHead.__init__¡  s‹   ø€ Ü‰ÑÔÜ—Y‘Y˜v×1Ñ1°6×3EÑ3EÓFˆŒ
à)/×)BÑ)BÐ)NˆF×%Ò%ÐTZ×TnÑTnð 	ô )¨Ó0ˆŒÜ—z‘zÐ"4Ó5ˆŒÜŸ	™	 &×"4Ñ"4°f×6GÑ6GÓHˆ�rš   c                 óÈ   — |d d …dd d …f   }| j                  |«      }| j                  |«      }| j                  |«      }| j                  |«      }| j                  |«      }|S )Nr   )r�   rú   rX  r¢  )r˜   ÚfeaturesÚkwargsrÄ   s       r0   r¨   z!ElectraClassificationHead.forward«  sZ   € Ø’Q˜š1�WÑˆØ�L‰L˜‹OˆØ�J‰J�q‹MˆØ�O‰O˜AÓˆØ�L‰L˜‹OˆØ�M‰M˜!ÓˆØˆrš   r]  r±   s   @r0   rž  rž  ž  s   ø„ Ù7ôIörš   rž  zŸ
    ELECTRA Model transformer with a sequence classification/regression head on top (a linear layer on top of the
    pooled output) e.g. for GLUE tasks.
    c                   ó¨  ‡ — e Zd Zˆ fd„Z eej                  d«      «       edee	dd¬«      	 	 	 	 	 	 	 	 	 	 dde
ej                     de
ej                     d	e
ej                     d
e
ej                     de
ej                     de
ej                     de
ej                     de
e   de
e   de
e   deeej                     ef   fd„«       «       Zˆ xZS )Ú ElectraForSequenceClassificationc                 ó´   •— t         ‰| �  |«       |j                  | _        || _        t	        |«      | _        t        |«      | _        | j                  «        y ró   )	r�   r‚   r¡  ra   ry  rf  rž  r;   r}  r—   s     €r0   r‚   z)ElectraForSequenceClassification.__init__½  sH   ø€ Ü‰Ñ˜Ô Ø ×+Ñ+ˆŒØˆŒÜ# FÓ+ˆŒÜ3°FÓ;ˆŒð 	�‰Õrš   rˆ  z$bhadresh-savani/electra-base-emotionz'joy'g¸…ëQ¸®?©rŠ  r‹  rp  Úexpected_outputÚexpected_lossr›   rË   r~   ry   rÌ   rœ   ÚlabelsrÐ   r>  r?  rž   c                 ó  — |
�|
n| j                   j                  }
| j                  ||||||||	|
¬«	      }|d   }| j                  |«      }d}|��‡| j                   j                  €�| j
                  dk(  rd| j                   _        nl| j
                  dkD  rL|j                  t        j                  k(  s|j                  t        j                  k(  rd| j                   _        nd| j                   _        | j                   j                  dk(  rIt        «       }| j
                  dk(  r& ||j                  «       |j                  «       «      }nŒ |||«      }n‚| j                   j                  dk(  r=t        «       } ||j                  d| j
                  «      |j                  d«      «      }n,| j                   j                  dk(  rt        «       } |||«      }|
s|f|dd z   }|�|f|z   S |S t        |||j                   |j"                  ¬	«      S )
a�  
        labels (`torch.LongTensor` of shape `(batch_size,)`, *optional*):
            Labels for computing the sequence classification/regression loss. Indices should be in `[0, ...,
            config.num_labels - 1]`. If `config.num_labels == 1` a regression loss is computed (Mean-Square loss), If
            `config.num_labels > 1` a classification loss is computed (Cross-Entropy).
        N©rË   r~   ry   rÌ   rœ   rÐ   r>  r?  r   r#   Ú
regressionÚsingle_label_classificationÚmulti_label_classificationrz   ©rv  r\  rÊ   rD  )ra   r�  rf  r;   Úproblem_typer¡  r€   r\   r–   rU   r   rZ  r
   rÆ   r	   r   rÊ   rD  )r˜   r›   rË   r~   ry   rÌ   rœ   r­  rÐ   r>  r?  r[  Úsequence_outputr\  rv  Úloss_fctr	  s                    r0   r¨   z(ElectraForSequenceClassification.forwardÇ  sÞ  € ð6 &1Ð%<‘kÀ$Ç+Á+×B]ÑB]ˆà&*§l¡lØØ)Ø)Ø%ØØ'Ø/Ø!5Ø#ð '3ó 
'
Ð#ð 6°aÑ8ˆØ—‘ Ó1ˆàˆØÑØ�{‰{×'Ñ'Ð/Ø—?‘? aÒ'Ø/;�D—K‘KÕ,Ø—_‘_ qÒ(¨f¯l©l¼e¿j¹jÒ.HÈFÏLÉLÔ\a×\eÑ\eÒLeØ/L�D—K‘KÕ,à/K�D—K‘KÔ,à�{‰{×'Ñ'¨<Ò7Ü"›9�Ø—?‘? aÒ'Ù# F§N¡NÓ$4°f·n±nÓ6FÓG‘Dá# F¨FÓ3‘DØ—‘×)Ñ)Ð-JÒJÜ+Ó-�Ù §¡¨B°·±Ó @À&Ç+Á+ÈbÃ/ÓR‘Ø—‘×)Ñ)Ð-IÒIÜ,Ó.�Ù ¨Ó/�áØ�YÐ!<¸Q¸RÐ!@Ñ@ˆFØ)-Ð)9�T�G˜fÑ$ÐE¸vÐEä'ØØØ5×CÑCØ2×=Ñ=ô	
ð 	
rš   ©
NNNNNNNNNN)r©   rª   r«   r‚   r    r™  rš  r   r   rœ  r   r\   r¯   rõ   r   r   r¨   r°   r±   s   @r0   r¨  r¨  µ  sC  ø„ ôñ +Ð+C×+JÑ+JÐKhÓ+iÓjÙØ9Ø,Ø$ØØôð -1Ø15Ø15Ø/3Ø,0Ø04Ø)-Ø,0Ø/3Ø&*ñD
à˜EŸL™LÑ)ðD
ð ! §¡Ñ.ðD
ð ! §¡Ñ.ð	D
ð
 ˜uŸ|™|Ñ,ðD
ð ˜EŸL™LÑ)ðD
ð   §¡Ñ-ðD
ð ˜Ÿ™Ñ&ðD
ð $ D™>ðD
ð ' t™nðD
ð ˜d‘^ðD
ð 
ˆu�U—\‘\Ñ"Ð$<Ð<Ñ	=òD
óó kôD
rš   r¨  zÊ
    Electra model with a binary classification head on top as used during pretraining for identifying generated tokens.

    It is recommended to load the discriminator checkpoint into that model.
    c                   ó¢  ‡ — e Zd Zˆ fd„Z eej                  d«      «       eee	¬«      	 	 	 	 	 	 	 	 	 	 dde
ej                     de
ej                     de
ej                     de
ej                     de
ej                     d	e
ej                     d
e
ej                     de
e   de
e   de
e   deeej                     ef   fd„«       «       Zˆ xZS )ÚElectraForPreTrainingc                 ó„   •— t         ‰| �  |«       t        |«      | _        t	        |«      | _        | j                  «        y ró   )r�   r‚   ry  rf  rU  Údiscriminator_predictionsr}  r—   s     €r0   r‚   zElectraForPreTraining.__init__  s3   ø€ Ü‰Ñ˜Ô ä# FÓ+ˆŒÜ)HÈÓ)PˆÔ&à�‰Õrš   rˆ  ©r‹  rp  r›   rË   r~   ry   rÌ   rœ   r­  rÐ   r>  r?  rž   c                 ód  — |
�|
n| j                   j                  }
| j                  ||||||||	|
¬«	      }|d   }| j                  |«      }d}|�«t	        j
                  «       }|�a|j                  d|j                  d   «      dk(  }|j                  d|j                  d   «      |   }||   } |||j                  «       «      }n4 ||j                  d|j                  d   «      |j                  «       «      }|
s|f|dd z   }|�|f|z   S |S t        |||j                  |j                  ¬«      S )a  
        labels (`torch.LongTensor` of shape `(batch_size, sequence_length)`, *optional*):
            Labels for computing the ELECTRA loss. Input should be a sequence of tokens (see `input_ids` docstring)
            Indices should be in `[0, 1]`:

            - 0 indicates the token is an original token,
            - 1 indicates the token was replaced.

        Returns:

        Examples:

        ```python
        >>> from transformers import ElectraForPreTraining, AutoTokenizer
        >>> import torch

        >>> discriminator = ElectraForPreTraining.from_pretrained("google/electra-base-discriminator")
        >>> tokenizer = AutoTokenizer.from_pretrained("google/electra-base-discriminator")

        >>> sentence = "The quick brown fox jumps over the lazy dog"
        >>> fake_sentence = "The quick brown fox fake over the lazy dog"

        >>> fake_tokens = tokenizer.tokenize(fake_sentence, add_special_tokens=True)
        >>> fake_inputs = tokenizer.encode(fake_sentence, return_tensors="pt")
        >>> discriminator_outputs = discriminator(fake_inputs)
        >>> predictions = torch.round((torch.sign(discriminator_outputs[0]) + 1) / 2)

        >>> fake_tokens
        ['[CLS]', 'the', 'quick', 'brown', 'fox', 'fake', 'over', 'the', 'lazy', 'dog', '[SEP]']

        >>> predictions.squeeze().tolist()
        [0.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 0.0]
        ```Nr¯  r   rz   r#   r³  )ra   r�  rf  r»  r   r	   rÆ   rX   Úfloatru  rÊ   rD  )r˜   r›   rË   r~   ry   rÌ   rœ   r­  rÐ   r>  r?  r[  Údiscriminator_sequence_outputr\  rv  r¶  Úactive_lossÚactive_logitsÚactive_labelsr	  s                       r0   r¨   zElectraForPreTraining.forward'  sp  € ð` &1Ð%<‘kÀ$Ç+Á+×B]ÑB]ˆà&*§l¡lØØ)Ø)Ø%ØØ'Ø/Ø!5Ø#ð '3ó 
'
Ð#ð )DÀAÑ(FÐ%à×/Ñ/Ð0MÓNˆàˆØÐÜ×+Ñ+Ó-ˆHØÐ)Ø,×1Ñ1°"Ð6S×6YÑ6YÐZ[Ñ6\Ó]ÐabÑb�Ø &§¡¨BÐ0M×0SÑ0SÐTUÑ0VÓ WÐXcÑ d�Ø & {Ñ 3�Ù ¨}×/BÑ/BÓ/DÓE‘á §¡¨BÐ0M×0SÑ0SÐTUÑ0VÓ WÐY_×YeÑYeÓYgÓh�áØ�YÐ!<¸Q¸RÐ!@Ñ@ˆFØ)-Ð)9�T�G˜fÑ$ÐE¸vÐEä*ØØØ5×CÑCØ2×=Ñ=ô	
ð 	
rš   r·  )r©   rª   r«   r‚   r    r™  rš  r"   ru  rœ  r   r\   r¯   rõ   r   r   r¨   r°   r±   s   @r0   r¹  r¹    s9  ø„ ôñ +Ð+C×+JÑ+JÐKhÓ+iÓjÙÐ+FÐUdÔeð -1Ø15Ø15Ø/3Ø,0Ø04Ø)-Ø,0Ø/3Ø&*ñS
à˜EŸL™LÑ)ðS
ð ! §¡Ñ.ðS
ð ! §¡Ñ.ð	S
ð
 ˜uŸ|™|Ñ,ðS
ð ˜EŸL™LÑ)ðS
ð   §¡Ñ-ðS
ð ˜Ÿ™Ñ&ðS
ð $ D™>ðS
ð ' t™nðS
ð ˜d‘^ðS
ð 
ˆu�U—\‘\Ñ"Ð$?Ð?Ñ	@òS
ó fó kôS
rš   r¹  zý
    Electra model with a language modeling head on top.

    Even though both the discriminator and generator may be loaded into this model, the generator is the only model of
    the two to have been trained for the masked language modeling task.
    c                   ó¼  ‡ — e Zd ZdgZˆ fd„Zd„ Zd„ Z eej                  d«      «       e
deeddd	¬
«      	 	 	 	 	 	 	 	 	 	 ddeej                     deej                     deej                     deej                     deej                     deej                     deej                     dee   dee   dee   deeej                     ef   fd„«       «       Zˆ xZS )rN   úgenerator_lm_head.weightc                 óâ   •— t         ‰| �  |«       t        |«      | _        t	        |«      | _        t        j                  |j                  |j                  «      | _
        | j                  «        y ró   )r�   r‚   ry  rf  r_  Úgenerator_predictionsr   r¼   r…   r„   Úgenerator_lm_headr}  r—   s     €r0   r‚   zElectraForMaskedLM.__init__‹  sR   ø€ Ü‰Ñ˜Ô ä# FÓ+ˆŒÜ%@ÀÓ%HˆÔ"ä!#§¡¨6×+@Ñ+@À&×BSÑBSÓ!TˆÔà�‰Õrš   c                 ó   — | j                   S ró   ©rÇ  r€  s    r0   Úget_output_embeddingsz(ElectraForMaskedLM.get_output_embeddings•  ó   € Ø×%Ñ%Ð%rš   c                 ó   — || _         y ró   rÉ  )r˜   r‡   s     r0   Úset_output_embeddingsz(ElectraForMaskedLM.set_output_embeddings˜  s
   € Ø!0ˆÕrš   rˆ  zgoogle/electra-small-generatorz[MASK]z'paris'g…ëQ¸…ó?)rŠ  r‹  rp  Úmaskr«  r¬  r›   rË   r~   ry   rÌ   rœ   r­  rÐ   r>  r?  rž   c                 óÐ  — |
�|
n| j                   j                  }
| j                  ||||||||	|
¬«	      }|d   }| j                  |«      }| j	                  |«      }d}|�Pt        j                  «       } ||j                  d| j                   j                  «      |j                  d«      «      }|
s|f|dd z   }|�|f|z   S |S t        |||j                  |j                  ¬«      S )a¢  
        labels (`torch.LongTensor` of shape `(batch_size, sequence_length)`, *optional*):
            Labels for computing the masked language modeling loss. Indices should be in `[-100, 0, ...,
            config.vocab_size]` (see `input_ids` docstring) Tokens with indices set to `-100` are ignored (masked), the
            loss is only computed for the tokens with labels in `[0, ..., config.vocab_size]`
        Nr¯  r   rz   r#   r³  )ra   r�  rf  rÆ  rÇ  r   r
   rÆ   r„   r   rÊ   rD  )r˜   r›   rË   r~   ry   rÌ   rœ   r­  rÐ   r>  r?  rc  Úgenerator_sequence_outputÚprediction_scoresrv  r¶  r	  s                    r0   r¨   zElectraForMaskedLM.forward›  s  € ð8 &1Ð%<‘kÀ$Ç+Á+×B]ÑB]ˆà"&§,¡,ØØ)Ø)Ø%ØØ'Ø/Ø!5Ø#ð #/ó 
#
Ðð %<¸AÑ$>Ð!à ×6Ñ6Ð7PÓQÐØ ×2Ñ2Ð3DÓEÐàˆàÐÜ×*Ñ*Ó,ˆHÙÐ-×2Ñ2°2°t·{±{×7MÑ7MÓNÐPV×P[ÑP[Ð\^ÓP_Ó`ˆDáØ'Ð)Ð,CÀAÀBÐ,GÑGˆFØ)-Ð)9�T�G˜fÑ$ÐE¸vÐEäØØ$Ø1×?Ñ?Ø.×9Ñ9ô	
ð 	
rš   r·  )r©   rª   r«   Ú_tied_weights_keysr‚   rÊ  rÍ  r    r™  rš  r   r   rœ  r   r\   r¯   rõ   r   r   r¨   r°   r±   s   @r0   rN   rN     sM  ø„ ð 5Ð5Ðôò&ò1ñ +Ð+C×+JÑ+JÐKhÓ+iÓjÙØ3Ø"Ø$ØØ!Øôð -1Ø15Ø15Ø/3Ø,0Ø04Ø)-Ø,0Ø/3Ø&*ñ4
à˜EŸL™LÑ)ð4
ð ! §¡Ñ.ð4
ð ! §¡Ñ.ð	4
ð
 ˜uŸ|™|Ñ,ð4
ð ˜EŸL™LÑ)ð4
ð   §¡Ñ-ð4
ð ˜Ÿ™Ñ&ð4
ð $ D™>ð4
ð ' t™nð4
ð ˜d‘^ð4
ð 
ˆu�U—\‘\Ñ" NÐ2Ñ	3ò4
óó kô4
rš   rN   z‰
    Electra model with a token classification head on top.

    Both the discriminator and generator may be loaded into this model.
    c                   ó¨  ‡ — e Zd Zˆ fd„Z eej                  d«      «       edee	dd¬«      	 	 	 	 	 	 	 	 	 	 dde
ej                     de
ej                     d	e
ej                     d
e
ej                     de
ej                     de
ej                     de
ej                     de
e   de
e   de
e   deeej                     ef   fd„«       «       Zˆ xZS )ÚElectraForTokenClassificationc                 ó`  •— t         ‰| �  |«       |j                  | _        t        |«      | _        |j
                  �|j
                  n|j                  }t        j                  |«      | _	        t        j                  |j                  |j                  «      | _        | j                  «        y ró   )r�   r‚   r¡  ry  rf  r   r�   r   rŽ   r�   r¼   r¸   r;   r}  r£  s      €r0   r‚   z&ElectraForTokenClassification.__init__ä  s†   ø€ Ü‰Ñ˜Ô Ø ×+Ñ+ˆŒä# FÓ+ˆŒà)/×)BÑ)BÐ)NˆF×%Ò%ÐTZ×TnÑTnð 	ô —z‘zÐ"4Ó5ˆŒÜŸ)™) F×$6Ñ$6¸×8IÑ8IÓJˆŒà�‰Õrš   rˆ  zDbhadresh-savani/electra-base-discriminator-finetuned-conll03-englishzK['B-LOC', 'B-ORG', 'O', 'O', 'O', 'O', 'O', 'B-LOC', 'O', 'B-LOC', 'I-LOC']g)\�Âõ(¼?rª  r›   rË   r~   ry   rÌ   rœ   r­  rÐ   r>  r?  rž   c                 ó¨  — |
�|
n| j                   j                  }
| j                  ||||||||	|
¬«	      }|d   }| j                  |«      }| j	                  |«      }d}|�<t        «       } ||j                  d| j                  «      |j                  d«      «      }|
s|f|dd z   }|�|f|z   S |S t        |||j                  |j                  ¬«      S )zÛ
        labels (`torch.LongTensor` of shape `(batch_size, sequence_length)`, *optional*):
            Labels for computing the token classification loss. Indices should be in `[0, ..., config.num_labels - 1]`.
        Nr¯  r   rz   r#   r³  )ra   r�  rf  r�   r;   r
   rÆ   r¡  r   rÊ   rD  )r˜   r›   rË   r~   ry   rÌ   rœ   r­  rÐ   r>  r?  r[  r¿  r\  rv  r¶  r	  s                    r0   r¨   z%ElectraForTokenClassification.forwardñ  sÿ   € ð2 &1Ð%<‘kÀ$Ç+Á+×B]ÑB]ˆà&*§l¡lØØ)Ø)Ø%ØØ'Ø/Ø!5Ø#ð '3ó 
'
Ð#ð )DÀAÑ(FÐ%à(,¯©Ð5RÓ(SÐ%Ø—‘Ð!>Ó?ˆàˆØÐÜ'Ó)ˆHÙ˜FŸK™K¨¨D¯O©OÓ<¸f¿k¹kÈ"»oÓNˆDáØ�YÐ!<¸Q¸RÐ!@Ñ@ˆFØ)-Ð)9�T�G˜fÑ$ÐE¸vÐEä$ØØØ5×CÑCØ2×=Ñ=ô	
ð 	
rš   r·  )r©   rª   r«   r‚   r    r™  rš  r   r   rœ  r   r\   r¯   rõ   r   r   r¨   r°   r±   s   @r0   rÔ  rÔ  Û  s6  ø„ ôñ +Ð+C×+JÑ+JÐKhÓ+iÓjÙØYØ)Ø$ØeØôð -1Ø15Ø15Ø/3Ø,0Ø04Ø)-Ø,0Ø/3Ø&*ñ1
à˜EŸL™LÑ)ð1
ð ! §¡Ñ.ð1
ð ! §¡Ñ.ð	1
ð
 ˜uŸ|™|Ñ,ð1
ð ˜EŸL™LÑ)ð1
ð   §¡Ñ-ð1
ð ˜Ÿ™Ñ&ð1
ð $ D™>ð1
ð ' t™nð1
ð ˜d‘^ð1
ð 
ˆu�U—\‘\Ñ"Ð$9Ð9Ñ	:ò1
óó kô1
rš   rÔ  zà
    ELECTRA Model with a span classification head on top for extractive question-answering tasks like SQuAD (a linear
    layers on top of the hidden-states output to compute `span start logits` and `span end logits`).
    c                   óÔ  ‡ — e Zd ZeZdZˆ fd„Z eej                  d«      «       e
deedddd¬	«      	 	 	 	 	 	 	 	 	 	 	 dd
eej                     deej                     deej                     deej                     deej                     deej                     deej                     deej                     dee   dee   dee   deeej                     ef   fd„«       «       Zˆ xZS )ÚElectraForQuestionAnsweringrf  c                 óä   •— t         ‰| �  |«       |j                  | _        t        |«      | _        t        j                  |j                  |j                  «      | _        | j                  «        y ró   )
r�   r‚   r¡  ry  rf  r   r¼   r¸   Ú
qa_outputsr}  r—   s     €r0   r‚   z$ElectraForQuestionAnswering.__init__8  sS   ø€ Ü‰Ñ˜Ô Ø ×+Ñ+ˆŒä# FÓ+ˆŒÜŸ)™) F×$6Ñ$6¸×8IÑ8IÓJˆŒð 	�‰Õrš   rˆ  z#bhadresh-savani/electra-base-squad2é   é   z'a nice puppet'g…ëQ¸@)rŠ  r‹  rp  Úqa_target_start_indexÚqa_target_end_indexr«  r¬  r›   rË   r~   ry   rÌ   rœ   Ústart_positionsÚend_positionsrÐ   r>  r?  rž   c           
      ó&  — |�|n| j                   j                  }| j                  |||||||	|
¬«      }|d   }| j                  |«      }|j	                  dd¬«      \  }}|j                  d«      j                  «       }|j                  d«      j                  «       }d}|�·|�µt        |j                  «       «      dkD  r|j                  d«      }t        |j                  «       «      dkD  r|j                  d«      }|j                  d«      }|j                  d|«      }|j                  d|«      }t        |¬«      } |||«      } |||«      }||z   dz  }|s||f|dd z   }|�|f|z   S |S t        ||||j                  |j                  ¬	«      S )
a  
        start_positions (`torch.LongTensor` of shape `(batch_size,)`, *optional*):
            Labels for position (index) of the start of the labelled span for computing the token classification loss.
            Positions are clamped to the length of the sequence (`sequence_length`). Position outside of the sequence
            are not taken into account for computing the loss.
        end_positions (`torch.LongTensor` of shape `(batch_size,)`, *optional*):
            Labels for position (index) of the end of the labelled span for computing the token classification loss.
            Positions are clamped to the length of the sequence (`sequence_length`). Position outside of the sequence
            are not taken into account for computing the loss.
        N)rË   r~   ry   rÌ   rœ   rÐ   r>  r   r#   rz   rÒ   )Úignore_indexr<   )rv  Ústart_logitsÚ
end_logitsrÊ   rD  )ra   r�  rf  rÚ  rP   rZ  rÞ   rT   r•   Úclampr
   r   rÊ   rD  )r˜   r›   rË   r~   ry   rÌ   rœ   rß  rà  rÐ   r>  r?  r[  rµ  r\  rã  rä  Ú
total_lossÚignored_indexr¶  Ú
start_lossÚend_lossr	  s                          r0   r¨   z#ElectraForQuestionAnswering.forwardB  sÍ  € ðD &1Ð%<‘kÀ$Ç+Á+×B]ÑB]ˆà&*§l¡lØØ)Ø)Ø%ØØ'Ø/Ø!5ð '3ó 	'
Ð#ð 6°aÑ8ˆà—‘ Ó1ˆØ#)§<¡<°°r <Ó#:Ñ ˆ�jØ#×+Ñ+¨BÓ/×:Ñ:Ó<ˆØ×'Ñ'¨Ó+×6Ñ6Ó8ˆ
àˆ
ØÐ&¨=Ð+Dä�?×'Ñ'Ó)Ó*¨QÒ.Ø"1×"9Ñ"9¸"Ó"=�Ü�=×%Ñ%Ó'Ó(¨1Ò,Ø -× 5Ñ 5°bÓ 9�à(×-Ñ-¨aÓ0ˆMØ-×3Ñ3°A°}ÓEˆOØ)×/Ñ/°°=ÓAˆMä'°]ÔCˆHÙ! ,°Ó@ˆJÙ 
¨MÓ:ˆHØ$ xÑ/°1Ñ4ˆJáàØðð ,¨A¨BÐ/ñ0ˆFð 0:Ð/E�Z�M FÑ*ÐQÈ6ÐQä+ØØ%Ø!Ø5×CÑCØ2×=Ñ=ô
ð 	
rš   )NNNNNNNNNNN)r©   rª   r«   r$   rp  rr  r‚   r    r™  rš  r   r   rœ  r   r\   r¯   rõ   r   r   r¨   r°   r±   s   @r0   rØ  rØ  -  sm  ø„ ð !€LØ!Ðôñ +Ð+C×+JÑ+JÐKhÓ+iÓjÙØ8Ø0Ø$Ø ØØ)Øôð -1Ø15Ø15Ø/3Ø,0Ø04Ø26Ø04Ø,0Ø/3Ø&*ñJ
à˜EŸL™LÑ)ðJ
ð ! §¡Ñ.ðJ
ð ! §¡Ñ.ð	J
ð
 ˜uŸ|™|Ñ,ðJ
ð ˜EŸL™LÑ)ðJ
ð   §¡Ñ-ðJ
ð " %§,¡,Ñ/ðJ
ð   §¡Ñ-ðJ
ð $ D™>ðJ
ð ' t™nðJ
ð ˜d‘^ðJ
ð 
ˆu�U—\‘\Ñ"Ð$@Ð@Ñ	AòJ
óó kôJ
rš   rØ  z¨
    ELECTRA Model with a multiple choice classification head on top (a linear layer on top of the pooled output and a
    softmax) e.g. for RocStories/SWAG tasks.
    c                   ó¤  ‡ — e Zd Zˆ fd„Z eej                  d«      «       eee	e
¬«      	 	 	 	 	 	 	 	 	 	 ddeej                     deej                     deej                     deej                     deej                     d	eej                     d
eej                     dee   dee   dee   deeej                     e	f   fd„«       «       Zˆ xZS )ÚElectraForMultipleChoicec                 óÎ   •— t         ‰| �  |«       t        |«      | _        t	        |«      | _        t        j                  |j                  d«      | _	        | j                  «        y rW  )r�   r‚   ry  rf  r   Úsequence_summaryr   r¼   r¸   r;   r}  r—   s     €r0   r‚   z!ElectraForMultipleChoice.__init__¡  sM   ø€ Ü‰Ñ˜Ô ä# FÓ+ˆŒÜ /°Ó 7ˆÔÜŸ)™) F×$6Ñ$6¸Ó:ˆŒð 	�‰Õrš   z(batch_size, num_choices, sequence_lengthr‰  r›   rË   r~   ry   rÌ   rœ   r­  rÐ   r>  r?  rž   c                 óL  — |
�|
n| j                   j                  }
|�|j                  d   n|j                  d   }|�!|j                  d|j	                  d«      «      nd}|�!|j                  d|j	                  d«      «      nd}|�!|j                  d|j	                  d«      «      nd}|�!|j                  d|j	                  d«      «      nd}|�1|j                  d|j	                  d«      |j	                  d«      «      nd}| j                  ||||||||	|
¬«	      }|d   }| j                  |«      }| j                  |«      }|j                  d|«      }d}|�t        «       } |||«      }|
s|f|dd z   }|�|f|z   S |S t        |||j                  |j                  ¬«      S )aJ  
        labels (`torch.LongTensor` of shape `(batch_size,)`, *optional*):
            Labels for computing the multiple choice classification loss. Indices should be in `[0, ...,
            num_choices-1]` where `num_choices` is the size of the second dimension of the input tensors. (See
            `input_ids` above)
        Nr#   rz   rÔ   r¯  r   r³  )ra   r�  rX   rÆ   r•   rf  rí  r;   r
   r   rÊ   rD  )r˜   r›   rË   r~   ry   rÌ   rœ   r­  rÐ   r>  r?  Únum_choicesr[  rµ  Úpooled_outputr\  Úreshaped_logitsrv  r¶  r	  s                       r0   r¨   z ElectraForMultipleChoice.forward«  sã  € ð2 &1Ð%<‘kÀ$Ç+Á+×B]ÑB]ˆØ,5Ð,A�i—o‘o aÒ(À}×GZÑGZÐ[\ÑG]ˆà>GÐ>S�I—N‘N 2 y§~¡~°bÓ'9Ô:ÐY]ˆ	ØM[ÐMg˜×,Ñ,¨R°×1DÑ1DÀRÓ1HÔIÐmqˆØM[ÐMg˜×,Ñ,¨R°×1DÑ1DÀRÓ1HÔIÐmqˆØGSÐG_�|×(Ñ(¨¨\×->Ñ->¸rÓ-BÔCÐeiˆð Ð(ð ×Ñ˜r =×#5Ñ#5°bÓ#9¸=×;MÑ;MÈbÓ;QÔRàð 	ð '+§l¡lØØ)Ø)Ø%ØØ'Ø/Ø!5Ø#ð '3ó 
'
Ð#ð 6°aÑ8ˆà×-Ñ-¨oÓ>ˆØ—‘ Ó/ˆØ Ÿ+™+ b¨+Ó6ˆàˆØÐÜ'Ó)ˆHÙ˜O¨VÓ4ˆDáØ%Ð'Ð*EÀaÀbÐ*IÑIˆFØ)-Ð)9�T�G˜fÑ$ÐE¸vÐEä(ØØ"Ø5×CÑCØ2×=Ñ=ô	
ð 	
rš   r·  )r©   rª   r«   r‚   r    r™  rš  r   r›  r   rœ  r   r\   r¯   rõ   r   r   r¨   r°   r±   s   @r0   rë  rë  ™  s=  ø„ ôñ +Ð+C×+JÑ+JÐKuÓ+vÓwÙØ&Ø-Ø$ôð -1Ø15Ø15Ø/3Ø,0Ø04Ø)-Ø,0Ø/3Ø&*ñ@
à˜EŸL™LÑ)ð@
ð ! §¡Ñ.ð@
ð ! §¡Ñ.ð	@
ð
 ˜uŸ|™|Ñ,ð@
ð ˜EŸL™LÑ)ð@
ð   §¡Ñ-ð@
ð ˜Ÿ™Ñ&ð@
ð $ D™>ð@
ð ' t™nð@
ð ˜d‘^ð@
ð 
ˆu�U—\‘\Ñ"Ð$=Ð=Ñ	>ò@
óó xô@
rš   rë  zIELECTRA Model with a `language modeling` head on top for CLM fine-tuning.c            #       ó,  ‡ — e Zd ZdgZˆ fd„Zd„ Zd„ Z eej                  d«      «       e
ee¬«      	 	 	 	 	 	 	 	 	 	 	 	 	 	 ddeej                     deej                     d	eej                     d
eej                     deej                     deej                     deej                     deej                     deej                     deeej                        dee   dee   dee   dee   deeej                     ef   fd„«       «       Zd„ Zˆ xZS )ÚElectraForCausalLMrÄ  c                 ó$  •— t         ‰| �  |«       |j                  st        j	                  d«       t        |«      | _        t        |«      | _        t        j                  |j                  |j                  «      | _        | j                  «        y )NzOIf you want to use `ElectraForCausalLM` as a standalone, add `is_decoder=True.`)r�   r‚   rÂ   rB   Úwarningry  rf  r_  rÆ  r   r¼   r…   r„   rÇ  Úinit_weightsr—   s     €r0   r‚   zElectraForCausalLM.__init__ú  sj   ø€ Ü‰Ñ˜Ô à× Ò Ü�N‰NÐlÔmä# FÓ+ˆŒÜ%@ÀÓ%HˆÔ"Ü!#§¡¨6×+@Ñ+@À&×BSÑBSÓ!TˆÔà×ÑÕrš   c                 ó   — | j                   S ró   rÉ  r€  s    r0   rÊ  z(ElectraForCausalLM.get_output_embeddings  rË  rš   c                 ó   — || _         y ró   rÉ  )r˜   Únew_embeddingss     r0   rÍ  z(ElectraForCausalLM.set_output_embeddings	  s
   € Ø!/ˆÕrš   rˆ  r¼  r›   rË   r~   ry   rÌ   rœ   rÍ   rÎ   r­  r=  rä   rÐ   r>  r?  rž   c                 ó¼  — |�|n| j                   j                  }|	�d}| j                  |||||||||
||||¬«      }|d   }| j                  | j	                  |«      «      }d}|	�* | j
                  ||	fd| j                   j                  i|¤Ž}|s|f|dd z   }|�|f|z   S |S t        |||j                  |j                  |j                  |j                  ¬«      S )aJ
  
        encoder_hidden_states  (`torch.FloatTensor` of shape `(batch_size, sequence_length, hidden_size)`, *optional*):
            Sequence of hidden-states at the output of the last layer of the encoder. Used in the cross-attention if
            the model is configured as a decoder.
        encoder_attention_mask (`torch.FloatTensor` of shape `(batch_size, sequence_length)`, *optional*):
            Mask to avoid performing attention on the padding token indices of the encoder input. This mask is used in
            the cross-attention if the model is configured as a decoder. Mask values selected in `[0, 1]`:

            - 1 for tokens that are **not masked**,
            - 0 for tokens that are **masked**.

        labels (`torch.LongTensor` of shape `(batch_size, sequence_length)`, *optional*):
            Labels for computing the left-to-right language modeling loss (next word prediction). Indices should be in
            `[-100, 0, ..., config.vocab_size]` (see `input_ids` docstring) Tokens with indices set to `-100` are
            ignored (masked), the loss is only computed for the tokens with labels in `[0, ..., config.vocab_size]`
        past_key_values (`tuple(tuple(torch.FloatTensor))` of length `config.n_layers` with each tuple having 4 tensors of shape `(batch_size, num_heads, sequence_length - 1, embed_size_per_head)`):
            Contains precomputed key and value hidden states of the attention blocks. Can be used to speed up decoding.

            If `past_key_values` are used, the user can optionally input only the last `decoder_input_ids` (those that
            don't have their past key value states given to this model) of shape `(batch_size, 1)` instead of all
            `decoder_input_ids` of shape `(batch_size, sequence_length)`.
        use_cache (`bool`, *optional*):
            If set to `True`, `past_key_values` key value states are returned and can be used to speed up decoding (see
            `past_key_values`).

        Returns:

        Example:

        ```python
        >>> from transformers import AutoTokenizer, ElectraForCausalLM, ElectraConfig
        >>> import torch

        >>> tokenizer = AutoTokenizer.from_pretrained("google/electra-base-generator")
        >>> config = ElectraConfig.from_pretrained("google/electra-base-generator")
        >>> config.is_decoder = True
        >>> model = ElectraForCausalLM.from_pretrained("google/electra-base-generator", config=config)

        >>> inputs = tokenizer("Hello, my dog is cute", return_tensors="pt")
        >>> outputs = model(**inputs)

        >>> prediction_logits = outputs.logits
        ```NF)rË   r~   ry   rÌ   rœ   rÍ   rÎ   r=  rä   rÐ   r>  r?  r   r„   r#   )rv  r\  r=  rÊ   rD  rE  )ra   r�  rf  rÇ  rÆ  Úloss_functionr„   r   r=  rÊ   rD  rE  )r˜   r›   rË   r~   ry   rÌ   rœ   rÍ   rÎ   r­  r=  rä   rÐ   r>  r?  r¦  rò   rµ  rÑ  Úlm_lossr	  s                        r0   r¨   zElectraForCausalLM.forward  s.  € ð~ &1Ð%<‘kÀ$Ç+Á+×B]ÑB]ˆØÐØˆIà—,‘,ØØ)Ø)Ø%ØØ'Ø"7Ø#9Ø+ØØ/Ø!5Ø#ð ó 
ˆð  " !™*ˆØ ×2Ñ2°4×3MÑ3MÈoÓ3^Ó_ÐàˆØÐØ(�d×(Ñ(Ø!Øñð  Ÿ;™;×1Ñ1ðð ñ	ˆGñ Ø'Ð)¨G°A°B¨KÑ7ˆFØ,3Ð,?�W�J Ñ'ÐKÀVÐKä0ØØ$Ø#×3Ñ3Ø!×/Ñ/Ø×)Ñ)Ø$×5Ñ5ô
ð 	
rš   c                 óJ   ‡— d}|D ]  }|t        ˆfd„|D «       «      fz  }Œ |S )Nr-   c              3   ót   •K  — | ]/  }|j                  d ‰j                  |j                  «      «      –— Œ1 y­w)r   N)Úindex_selectrØ   r¡   )r.   Ú
past_stateÚbeam_idxs     €r0   r1   z4ElectraForCausalLM._reorder_cache.<locals>.<genexpr>}  s.   øè ø€ ÒnÐU_�j×-Ñ-¨a°·±¸Z×=NÑ=NÓ1O×PÑnùs   ƒ58)rK  )r˜   r=  r  Úreordered_pastÚ
layer_pasts     `  r0   Ú_reorder_cachez!ElectraForCausalLM._reorder_cachey  s=   ø€ ØˆØ)ò 	ˆJØÜÓnÐcmÔnÓnðñ ‰Nð	ð Ðrš   )NNNNNNNNNNNNNN)r©   rª   r«   rÒ  r‚   rÊ  rÍ  r    r™  rš  r"   r   rœ  r   r\   r¯   r   rõ   r   r   r¨   r  r°   r±   s   @r0   ró  ró  ô  s°  ø„ ð 5Ð5Ðô
ò&ò0ñ +Ð+C×+JÑ+JÐKhÓ+iÓjÙÐ+LÐ[jÔkð -1Ø15Ø15Ø/3Ø,0Ø04Ø8<Ø9=Ø)-Ø8<Ø$(Ø,0Ø/3Ø&*ñh
à˜EŸL™LÑ)ðh
ð ! §¡Ñ.ðh
ð ! §¡Ñ.ð	h
ð
 ˜uŸ|™|Ñ,ðh
ð ˜EŸL™LÑ)ðh
ð   §¡Ñ-ðh
ð  (¨¯©Ñ5ðh
ð !)¨¯©Ñ 6ðh
ð ˜Ÿ™Ñ&ðh
ð " $ u§|¡|Ñ"4Ñ5ðh
ð ˜D‘>ðh
ð $ D™>ðh
ð ' t™nðh
ð ˜d‘^ðh
ð" 
ˆu�U—\‘\Ñ"Ð$EÐEÑ	Fò#h
ó ló kðh
öVrš   ró  )
ró  rN   rë  r¹  rØ  r¨  rÔ  ry  re  rr   )Údiscriminator)Or¬   rÚ   rD   Údataclassesr   Útypingr   r   r   r   r\   Útorch.utils.checkpointr   Útorch.nnr	   r
   r   Úactivationsr   r   Ú
generationr   Úmodeling_outputsr   r   r   r   r   r   r   r   Úmodeling_utilsr   r   Úpytorch_utilsr   r   r   Úutilsr   r   r   r    r!   r"   Úconfiguration_electrar$   Ú
get_loggerr©   rB   r›  rœ  rr   ÚModulert   r³   r÷   r  r  r  r  r!  r5  rU  r_  re  ru  ÚELECTRA_START_DOCSTRINGr™  ry  rž  r¨  r¹  rN   rÔ  rØ  rë  ró  Ú__all__r-   rš   r0   ú<module>r     sþ  ðñ ã Û 	Ý !ß /Ó /ã Û Ý ß AÑ Aç 1Ý )÷	÷ 	ó 	÷ ?ß lÑ l÷÷ õ 1ð 
ˆ×	Ñ	˜HÓ	%€à:Ð Ø!€óOôd?˜Ÿ	™	ô ?ôFC˜2Ÿ9™9ô CôN˜Ÿ	™	ô ð Ð!ð"Ð ô0�r—y‘yô 0ôh˜"Ÿ)™)ô ô �B—I‘Iô ôS�2—9‘9ô SônZ
�R—Y‘Yô Z
ôz b§i¡iô ô& "§)¡)ô ô$*˜_ô *ð8 ô: +ó :ó ð:ð8Ð ð 9Ð ñx ðVð
 óôxÐ)ó xóðxôv §	¡	ô ñ. ðð óôW
Ð'=ó W
óðW
ñt ðð
 óô^
Ð2ó ^
óð^
ñB ðð óôP
Ð/ó P
óðP
ñf ðð
 óôG
Ð$:ó G
óðG
ñT ðð óôb
Ð"8ó b
óðb
ñJ ðð óôQ
Ð5ó Q
óðQ
ñh ØSÐUlóôHÐ/°ó HóðHòV�rš   