Ë
    ÜÓ^jYC  ã                   ó  — d Z ddlZddlmZ ddlZddlmZ ddlmZ	 ddl
mZmZ ddlmZ ddlmZmZ d	d
lmZmZmZmZmZmZmZmZmZ ddlmZ  ej<                  e«      Z  ed¬«      e G d„ de«      «       «       Z! G d„ de«      Z" G d„ de«      Z# G d„ de«      Z$ G d„ de«      Z% G d„ de«      Z& G d„ de«      Z'e G d„ de«      «       Z(eZ) G d„ d e(e«      Z* ed!¬«       G d"„ d#e(«      «       Z+ G d$„ d%e«      Z, G d&„ d'e«      Z-g d(¢Z.y))zPyTorch UniSpeech model.é    N)Ú	dataclassé   )Úinitialization)ÚModelOutputÚWav2Vec2BaseModelOutput)ÚPreTrainedModel)Úauto_docstringÚloggingé   )	ÚWav2Vec2EncoderÚWav2Vec2EncoderStableLayerNormÚWav2Vec2FeatureEncoderÚWav2Vec2FeatureProjectionÚWav2Vec2ForCTCÚ!Wav2Vec2ForSequenceClassificationÚWav2Vec2GumbelVectorQuantizerÚWav2Vec2ModelÚWav2Vec2PositionalConvEmbeddingé   )ÚUniSpeechConfigzh
    Output type of [`UniSpeechForPreTrainingOutput`], with potential hidden states and attentions.
    )Úcustom_introc                   ó  — e Zd ZU dZdZej                  dz  ed<   dZej                  dz  ed<   dZ	ej                  dz  ed<   dZ
ej                  dz  ed<   dZeej                     dz  ed<   dZeej                     dz  ed<   y)	ÚUniSpeechForPreTrainingOutputaÝ  
    loss (*optional*, returned when model is in train mode, `torch.FloatTensor` of shape `(1,)`):
        Total loss as the sum of the contrastive loss (L_m) and the diversity loss (L_d) as stated in the [official
        paper](https://huggingface.co/papers/2006.11477).
    projected_states (`torch.FloatTensor` of shape `(batch_size, sequence_length, config.proj_codevector_dim)`):
        Hidden-states of the model projected to *config.proj_codevector_dim* that can be used to predict the masked
        projected quantized states.
    projected_quantized_states (`torch.FloatTensor` of shape `(batch_size, sequence_length, config.proj_codevector_dim)`):
        Quantized extracted feature vectors projected to *config.proj_codevector_dim* representing the positive
        target vectors for contrastive loss.
    codevector_perplexity (`torch.FloatTensor` of shape `(1,)`):
        The perplexity of the codevector distribution, used to measure the diversity of the codebook.
    NÚlossÚprojected_statesÚprojected_quantized_statesÚcodevector_perplexityÚhidden_statesÚ
attentions)Ú__name__Ú
__module__Ú__qualname__Ú__doc__r   ÚtorchÚFloatTensorÚ__annotations__r   r   r   r   Útupler   © ó    úz/var/www/ramen.bs-engineer-server.com/venv/lib/python3.12/site-packages/transformers/models/unispeech/modular_unispeech.pyr   r   +   s”   … ñð &*€Dˆ%×
Ñ
˜dÑ
"Ó)Ø15Ð�e×'Ñ'¨$Ñ.Ó5Ø;?Ð × 1Ñ 1°DÑ 8Ó?Ø6:Ð˜5×,Ñ,¨tÑ3Ó:Ø59€M�5˜×*Ñ*Ñ+¨dÑ2Ó9Ø26€J��e×'Ñ'Ñ(¨4Ñ/Ô6r)   r   c                   ó   — e Zd Zy)Ú UniSpeechPositionalConvEmbeddingN©r    r!   r"   r(   r)   r*   r,   r,   H   ó   „ Ør)   r,   c                   ó   — e Zd Zy)ÚUniSpeechFeatureEncoderNr-   r(   r)   r*   r0   r0   L   r.   r)   r0   c                   ó   — e Zd Zy)ÚUniSpeechFeatureProjectionNr-   r(   r)   r*   r2   r2   P   r.   r)   r2   c                   ó   — e Zd Zy)ÚUniSpeechEncoderNr-   r(   r)   r*   r4   r4   T   r.   r)   r4   c                   ó   — e Zd Zy)ÚUniSpeechEncoderStableLayerNormNr-   r(   r)   r*   r6   r6   X   r.   r)   r6   c                   ó"   — e Zd Zed„ «       Zd„ Zy)ÚUniSpeechGumbelVectorQuantizerc                 óÄ   — | j                  d¬«      }t        j                  t        j                  t        j                  ||«      d¬«       «      j                  «       }|S )Nr   ©Údiméÿÿÿÿ)Úmeanr$   ÚexpÚsumÚxlogy)ÚprobsÚmarginal_probsÚ
perplexitys      r*   Ú_compute_perplexityz2UniSpeechGumbelVectorQuantizer._compute_perplexity]   sI   € àŸ™¨˜Ó*ˆÜ—Y‘Y¤§	¡	¬%¯+©+°nÀnÓ*UÐ[]Ô ^Ð^Ó_×cÑcÓeˆ
ØÐr)   c                 óÞ  — |j                   \  }}}| j                  |«      }|j                  ||z  | j                  z  d«      }| j                  ržt
        j                  j                  |j                  «       | j                  d¬«      j                  |«      }t        j                  |j                  ||z  | j                  d«      j                  «       d¬«      }| j                  |«      }n}|j                  d¬«      } |j                  |j                   Ž j!                  d|j                  dd«      d«      }|j                  ||z  | j                  d«      }| j                  |«      }|j                  ||z  d«      }|j#                  d«      | j$                  z  }	|	j                  ||z  | j                  | j&                  d«      }
|
j)                  d«      j                  ||d«      }
|
|fS )Nr<   T)ÚtauÚhardr:   r   g      ð?éþÿÿÿ)ÚshapeÚweight_projÚviewÚ
num_groupsÚtrainingÚnnÚ
functionalÚgumbel_softmaxÚfloatÚtemperatureÚtype_asr$   ÚsoftmaxrD   ÚargmaxÚ	new_zerosÚscatter_Ú	unsqueezeÚcodevectorsÚnum_varsr?   )Úselfr   Ú
batch_sizeÚsequence_lengthÚhidden_sizeÚcodevector_probsÚcodevector_soft_distrC   Úcodevector_idxÚcodevectors_per_grouprY   s              r*   Úforwardz&UniSpeechGumbelVectorQuantizer.forwardc   sÛ  € Ø3@×3FÑ3FÑ0ˆ
�O [ð ×(Ñ(¨Ó7ˆØ%×*Ñ*¨:¸Ñ+GÈ$Ï/É/Ñ+YÐ[]Ó^ˆà�=Š=ä!Ÿ}™}×;Ñ;Ø×#Ñ#Ó%¨4×+;Ñ+;À$ð  <ó  ç‰g�mÓ$ð ô
 $)§=¡=Ø×"Ñ" :°Ñ#?ÀÇÁÐRTÓU×[Ñ[Ó]Ðceô$Ð ð ×1Ñ1Ð2FÓG‰Jð +×1Ñ1°bÐ1Ó9ˆNØ6˜}×6Ñ6¸×8KÑ8KÐL×UÑUØ�N×'Ñ'¨¨AÓ.°ó Ðð  0×4Ñ4°ZÀ/Ñ5QÐSW×SbÑSbÐdfÓgÐà×1Ñ1Ð2BÓCˆJà+×0Ñ0°¸oÑ1MÈrÓRÐà 0× :Ñ :¸2Ó >À×AQÑAQÑ QÐØ+×0Ñ0°¸oÑ1MÈtÏÉÐ`d×`mÑ`mÐoqÓrˆØ!—o‘o bÓ)×.Ñ.¨z¸?ÈBÓOˆà˜JÐ&Ð&r)   N)r    r!   r"   ÚstaticmethodrD   rc   r(   r)   r*   r8   r8   \   s   „ Øñó ðó
#'r)   r8   c                   ó¸   ‡ — e Zd ZU eed<   dZdZdZdZdZ	dZ
dZ ej                  «       ˆ fd„«       Zdej                  ez  fd„Zd	ed
ej                  fd„Zˆ xZS )ÚUniSpeechPreTrainedModelÚconfigÚ	unispeechÚinput_valuesÚaudioTc           
      ó  •— t         ‰| �  |«       t        |t        «      rut	        j
                  |j                  j                  dd¬«       t	        j                  |j                  j                  «       t	        j                  |j                  «       yt        |t        «      ržt	        j
                  |j                  j                  ddt        j                  d|j                  j                   d   |j                  j"                  z  z  «      z  ¬«       t	        j$                  |j                  j                  d«       yt        |t&        «      r‡t        j                  d|j(                  j*                  z  «      }t	        j                  |j(                  j                  | |¬«       t	        j                  |j(                  j                  | |¬«       yt        |t,        j.                  «      rŒt	        j0                  |j                  «       |j                  �`t        j                  |j2                  |j"                  |j                   d   z  z  «      }t	        j                  |j                  | |¬«       yyy)zInitialize the weightsç        r   )r=   Ústdr   r   )ÚaÚbN)ÚsuperÚ_init_weightsÚ
isinstancer8   ÚinitÚnormal_rJ   ÚweightÚzeros_ÚbiasÚuniform_rY   r,   ÚconvÚmathÚsqrtÚkernel_sizeÚin_channelsÚ	constant_r2   Ú
projectionÚin_featuresrN   ÚConv1dÚkaiming_normal_Úgroups)r[   ÚmoduleÚkÚ	__class__s      €r*   rq   z&UniSpeechPreTrainedModel._init_weights”   s¶  ø€ ô 	‰Ñ˜fÔ%ä�fÔ<Ô=Ü�L‰L˜×+Ñ+×2Ñ2¸À!ÕDÜ�K‰K˜×*Ñ*×/Ñ/Ô0Ü�M‰M˜&×,Ñ,Õ-Ü˜Ô @ÔAÜ�L‰LØ—‘×"Ñ"ØØœŸ	™	 ! v§{¡{×'>Ñ'>¸qÑ'AÀFÇKÁK×D[ÑD[Ñ'[Ñ"\Ó]Ñ]õô
 �N‰N˜6Ÿ;™;×+Ñ+¨QÕ/Ü˜Ô :Ô;Ü—	‘	˜!˜f×/Ñ/×;Ñ;Ñ;Ó<ˆAÜ�M‰M˜&×+Ñ+×2Ñ2°q°b¸AÕ>Ü�M‰M˜&×+Ñ+×0Ñ0°Q°B¸!Ö<Ü˜¤§	¡	Ô*Ü× Ñ  §¡Ô/à�{‰{Ð&Ü—I‘I˜fŸm™m¨v×/AÑ/AÀF×DVÑDVÐWXÑDYÑ/YÑZÓ[�Ü—‘˜fŸk™k¨a¨R°1Ö5ð 'ð +r)   Úinput_lengthsc                 ó˜   — d„ }t        | j                  j                  | j                  j                  «      D ]  \  }} ||||«      }Œ |S )zH
        Computes the output length of the convolutional layers
        c                 ó>   — t        j                  | |z
  |d¬«      dz   S )NÚfloor)Úrounding_moder   )r$   Údiv)Úinput_lengthr|   Ústrides      r*   Ú_conv_out_lengthzSUniSpeechPreTrainedModel._get_feat_extract_output_lengths.<locals>._conv_out_length´   s"   € ô —9‘9˜\¨KÑ7¸ÈwÔWÐZ[Ñ[Ð[r)   )Úziprg   Úconv_kernelÚconv_stride)r[   r‡   r�   r|   rŽ   s        r*   Ú _get_feat_extract_output_lengthsz9UniSpeechPreTrainedModel._get_feat_extract_output_lengths¯   sQ   € ò
	\ô
 $' t§{¡{×'>Ñ'>ÀÇÁ×@WÑ@WÓ#Xò 	QÑˆK˜Ù,¨]¸KÈÓP‰Mð	Qð Ðr)   Úfeature_vector_lengthÚattention_maskc                 óø  — |j                  d¬«      d d …df   }| j                  |«      j                  t        j                  «      }|j
                  d   }t        j                  ||f|j                  |j                  ¬«      }d|t        j                  |j
                  d   |j                  ¬«      |dz
  f<   |j                  dg«      j                  d«      j                  dg«      j                  «       }|S )Nr<   r:   r   )ÚdtypeÚdevicer   )r˜   )Úcumsumr“   Útor$   ÚlongrI   Úzerosr—   r˜   ÚarangeÚflipÚbool)r[   r”   r•   Únon_padded_lengthsÚoutput_lengthsr\   s         r*   Ú"_get_feature_vector_attention_maskz;UniSpeechPreTrainedModel._get_feature_vector_attention_mask¾   së   € ð ,×2Ñ2°rÐ2Ó:º1¸b¸5ÑAÐØ×>Ñ>Ð?QÓR×UÑUÔV[×V`ÑV`ÓaˆØ#×)Ñ)¨!Ñ,ˆ
äŸ™ØÐ.Ð/°~×7KÑ7KÐTb×TiÑTiô
ˆð uvˆœŸ™ ^×%9Ñ%9¸!Ñ%<À^×EZÑEZÔ[Ð]kÐnoÑ]oÐpÑqØ'×,Ñ,¨b¨TÓ2×9Ñ9¸"Ó=×BÑBÀBÀ4ÓH×MÑMÓOˆØÐr)   )r    r!   r"   r   r&   Úbase_model_prefixÚmain_input_nameÚinput_modalitiesÚsupports_gradient_checkpointingÚ_supports_flash_attnÚ_supports_sdpaÚ_supports_flex_attnr$   Úno_gradrq   Ú
LongTensorÚintr“   r¢   Ú__classcell__©r†   s   @r*   rf   rf   ‰   s}   ø… àÓØ#ÐØ$€OØÐØ&*Ð#ØÐØ€NØÐà€U‡]�]ƒ_ó6ó ð6ð4¸e×>NÑ>NÐQTÑ>Tó ðÈð Ð]b×]mÑ]m÷ r)   rf   c                   ó´   — e Zd Zdefd„Zd„ Z	 	 	 	 	 ddej                  dz  dej                  dz  dej                  dz  de	dz  d	e	dz  d
e	dz  de
ez  fd„Zy)ÚUniSpeechModelrg   c                 ó¾  — t         j                  | |«       || _        t        |«      | _        t        |«      | _        |j                  dkD  s|j                  dkD  rEt        j                  t        j                  |j                  «      j                  «       «      | _        |j                   rt#        |«      | _        nt'        |«      | _        | j)                  «        y )Nrl   )rf   Ú__init__rg   r0   Úfeature_extractorr2   Úfeature_projectionÚmask_time_probÚmask_feature_probrN   Ú	Parameterr$   ÚTensorr^   rx   Úmasked_spec_embedÚdo_stable_layer_normr6   Úencoderr4   Ú	post_init)r[   rg   s     r*   r²   zUniSpeechModel.__init__Ò   s¤   € Ü ×)Ñ)¨$°Ô7ØˆŒÜ!8¸Ó!@ˆÔÜ"<¸VÓ"DˆÔà× Ñ  3Ò&¨&×*BÑ*BÀSÒ*HÜ%'§\¡\´%·,±,¸v×?QÑ?QÓ2R×2[Ñ2[Ó2]Ó%^ˆDÔ"à×&Ò&Ü:¸6ÓBˆD�Lä+¨FÓ3ˆDŒLð 	�‰Õr)   c                 ó   — t        d«      ‚)NzNot needed for UniSpeech)ÚAttributeError©r[   s    r*   Úfreeze_feature_encoderz%UniSpeechModel.freeze_feature_encoderã   s   € ÜÐ7Ó8Ð8r)   Nri   r•   Úmask_time_indicesÚoutput_attentionsÚoutput_hidden_statesÚreturn_dictÚreturnc                 ó
  — |�|n| j                   j                  }|�|n| j                   j                  }|�|n| j                   j                  }| j	                  |«      }|j                  dd«      }|�| j                  |j                  d   |«      }| j                  |«      \  }	}| j                  |	||¬«      }	| j                  |	||||¬«      }
|
d   }	|s
|	|f|
dd z   S t        |	||
j                  |
j                  ¬«      S )a/  
        mask_time_indices (`torch.BoolTensor` of shape `(batch_size, sequence_length)`, *optional*):
            Indices to mask extracted features for contrastive loss. When in training mode, model learns to predict
            masked extracted features in *config.proj_codevector_dim* space.
        Nr   r   )rÁ   r•   ©r•   rÂ   rÃ   rÄ   r   )Úlast_hidden_stateÚextract_featuresr   r   )rg   rÂ   rÃ   rÄ   r³   Ú	transposer¢   rI   r´   Ú_mask_hidden_statesr»   ÚUniSpeechBaseModelOutputr   r   )r[   ri   r•   rÁ   rÂ   rÃ   rÄ   ÚkwargsrÉ   r   Úencoder_outputss              r*   rc   zUniSpeechModel.forwardæ   s@  € ð 2CÐ1NÑ-ÐTX×T_ÑT_×TqÑTqÐà$8Ð$DÑ È$Ï+É+×JjÑJjð 	ð &1Ð%<‘kÀ$Ç+Á+×BYÑBYˆà×1Ñ1°,Ó?ÐØ+×5Ñ5°a¸Ó;ÐàÐ%à!×DÑDÐEU×E[ÑE[Ð\]ÑE^Ð`nÓoˆNà*.×*AÑ*AÐBRÓ*SÑ'ˆÐ'Ø×0Ñ0ØÐ->È~ð 1ó 
ˆð Ÿ,™,ØØ)Ø/Ø!5Ø#ð 'ó 
ˆð (¨Ñ*ˆáØ!Ð#3Ð4°ÀqÀrÐ7JÑJÐJä'Ø+Ø-Ø)×7Ñ7Ø&×1Ñ1ô	
ð 	
r)   )NNNNN)r    r!   r"   r   r²   rÀ   r$   r¸   r%   rŸ   r'   rÌ   rc   r(   r)   r*   r°   r°   Ñ   sœ   „ ð˜ó ò"9ð /3Ø6:Ø)-Ø,0Ø#'ñ3
à—l‘l TÑ)ð3
ð Ÿ™ tÑ+ð3
ð !×,Ñ,¨tÑ3ð	3
ð
   $™;ð3
ð # T™kð3
ð ˜D‘[ð3
ð 
Ð)Ñ	)ô3
r)   r°   zZ
    UniSpeech Model with a vector-quantization module and ctc loss for pre-training.
    c                   ó  ‡ — e Zd Zdefˆ fd„Zdefd„Zd„ Ze	 dde	j                  de	j                  de	j                  defd	„«       Ze	 	 	 	 dde	j                  d
z  de	j                  d
z  ded
z  ded
z  ded
z  deez  fd„«       Zˆ xZS )ÚUniSpeechForPreTrainingrg   c                 ó.  •— t         ‰| �  |«       t        |«      | _        t	        j
                  |j                  «      | _        t        |«      | _	        t	        j                  |j                  |j                  «      | _        t	        j                  |j                  |j                  «      | _        t	        j                  |j                  |j                   «      | _        t	        j
                  |j$                  «      | _        | j)                  «        y )N)rp   r²   r°   rh   rN   ÚDropoutÚfeat_quantizer_dropoutÚdropout_featuresr8   Ú	quantizerÚLinearÚcodevector_dimÚproj_codevector_dimÚ	project_qr^   Úproject_hidÚnum_ctc_classesÚctc_projÚfinal_dropoutÚdropoutr¼   )r[   rg   r†   s     €r*   r²   z UniSpeechForPreTraining.__init__"  s¼   ø€ Ü‰Ñ˜Ô Ü'¨Ó/ˆŒÜ "§
¡
¨6×+HÑ+HÓ IˆÔä7¸Ó?ˆŒÜŸ™ 6×#8Ñ#8¸&×:TÑ:TÓUˆŒÜŸ9™9 V×%?Ñ%?À×ASÑASÓTˆÔäŸ	™	 &×"4Ñ"4°f×6LÑ6LÓMˆŒÜ—z‘z &×"6Ñ"6Ó7ˆŒð 	�‰Õr)   rR   c                 ó&   — || j                   _        y)zb
        Set the Gumbel softmax temperature to a given value. Only necessary for training
        N)rÕ   rR   )r[   rR   s     r*   Úset_gumbel_temperaturez.UniSpeechForPreTraining.set_gumbel_temperature1  s   € ð &1ˆ�‰Õ"r)   c                 óL   — | j                   j                  j                  «        y)z¨
        Calling this function will disable the gradient computation for the feature encoder so that its parameter will
        not be updated during training.
        N)rh   r³   Ú_freeze_parametersr¿   s    r*   rÀ   z.UniSpeechForPreTraining.freeze_feature_encoder7  s   € ð
 	�‰×(Ñ(×;Ñ;Õ=r)   Útarget_featuresÚnegative_featuresÚpredicted_featuresc                 óÌ   — t        j                  | |gd¬«      } t        j                  |j                  «       | j                  «       d¬«      }|j	                  | «      }||z  }|S )zé
        Compute logits for contrastive loss based using cosine similarity as the distance measure between
        `[positive_feature, negative_features]` and `[predicted_features]`. Additionally, temperature can be applied.
        r   r:   r<   )r$   ÚcatÚcosine_similarityrQ   rS   )rã   rä   rå   rR   Úlogitss        r*   Úcompute_contrastive_logitsz2UniSpeechForPreTraining.compute_contrastive_logits>  sa   € ô  Ÿ)™) _Ð6GÐ$HÈaÔPˆä×(Ñ(Ð);×)AÑ)AÓ)CÀ_×EZÑEZÓE\ÐbdÔeˆØ—‘ Ó0ˆð ˜+Ñ%ˆØˆr)   Nri   r•   rÂ   rÃ   rÄ   rÅ   c                 óþ  — |�|n| j                   j                  }| j                  |||||¬«      }|d   }| j                  |d   «      }	| j	                  |	«      \  }
}| j                  |
j                  | j
                  j                  j                  «      «      }
| j                  |
«      }
t        j                  |j                  d«      |j                  d«      «      j                  | j                   j                  «      }|j                  dd«      }t        j                   |«      j#                  «       j                  |j$                  «      }|j                  dd«      }|j'                  d«      }|j)                  |d«      |
j)                  | d«      z   }| j+                  |«      }| j-                  |«      }d}|s|�|||
|f|dd z   S ||
|f|dd z   S t/        |||
||j0                  |j2                  ¬«      S )	a›  
        Example:

        ```python
        >>> import torch
        >>> from transformers import AutoFeatureExtractor, UniSpeechForPreTraining

        >>> feature_extractor = AutoFeatureExtractor.from_pretrained("microsoft/unispeech-large-1500h-cv")
        >>> model = UniSpeechForPreTraining.from_pretrained("microsoft/unispeech-large-1500h-cv")
        >>> # TODO: Add full pretraining example
        ```NrÇ   r   r   r<   rl   r   )r   r   r   r   r   r   )rg   rÄ   rh   rÔ   rÕ   rÙ   rš   ru   r—   rÚ   r$   ÚemptyÚsizeÚfill_Úreplace_probrÊ   Ú	bernoullirŸ   r˜   rX   Úmasked_fillrÞ   rÜ   r   r   r   )r[   ri   r•   rÂ   rÃ   rÄ   rÍ   ÚoutputsÚtransformer_featuresrÉ   Úquantized_featuresr   Úprob_replace_matrixÚsampled_replace_matrixré   r   s                   r*   rc   zUniSpeechForPreTraining.forwardR  s  € ð, &1Ð%<‘kÀ$Ç+Á+×BYÑBYˆà—.‘.ØØ)Ø/Ø!5Ø#ð !ó 
ˆð  ' q™zÐð  ×0Ñ0°¸±Ó<ÐØ48·N±NÐCSÓ4TÑ1ÐÐ1ð "Ÿ^™^Ð,>×,AÑ,AÀ$Ç.Á.×BWÑBW×B]ÑB]Ó,^Ó_ÐØ!×-Ñ-Ð.@ÓAÐä#Ÿk™kÐ*>×*CÑ*CÀAÓ*FÐH\×HaÑHaÐbcÓHdÓe×kÑkØ�K‰K×$Ñ$ó
Ðð 2×;Ñ;¸A¸qÓAÐÜ!&§¡Ð1DÓ!E×!JÑ!JÓ!L×!OÑ!OÐPd×PkÑPkÓ!lÐØ!7×!AÑ!AÀ!ÀQÓ!GÐØ!7×!AÑ!AÀ"Ó!EÐØ%×1Ñ1Ð2HÈ#ÓNØ×*Ñ*Ð,BÐ+BÀCÓHñ
ˆð
 —‘˜fÓ%ˆØ—‘˜vÓ&ˆð ˆÙØÐØÐ2Ð4FÐH]Ð^ÐahÐijÐikÐalÑlÐlØ(Ð*<Ð>SÐTÐW^Ð_`Ð_aÐWbÑbÐbä,ØØ1Ø'9Ø"7Ø!×/Ñ/Ø×)Ñ)ô
ð 	
r)   )r   )NNNN)r    r!   r"   r   r²   r¬   rà   rÀ   rd   r$   r%   rê   r	   r¸   rŸ   r'   r   rc   r­   r®   s   @r*   rÐ   rÐ     s÷   ø„ ð˜õ ð1°#ó 1ò>ð ð
 ñ	Ø×*Ñ*ðà ×,Ñ,ðð "×-Ñ-ðð ò	ó ðð& ð /3Ø)-Ø,0Ø#'ñE
à—l‘l TÑ)ðE
ð Ÿ™ tÑ+ðE
ð   $™;ð	E
ð
 # T™kðE
ð ˜D‘[ðE
ð 
Ð.Ñ	.òE
ó ôE
r)   rÐ   c                   ó   — e Zd Zy)ÚUniSpeechForCTCNr-   r(   r)   r*   rø   rø   ›  r.   r)   rø   c                   ó   — e Zd Zy)Ú"UniSpeechForSequenceClassificationNr-   r(   r)   r*   rú   rú   Ÿ  r.   r)   rú   )rø   rÐ   rú   r°   rf   )/r#   rz   Údataclassesr   r$   Útorch.nnrN   Ú r   rs   Úmodeling_outputsr   r   Úmodeling_utilsr   Úutilsr	   r
   Úwav2vec2.modeling_wav2vec2r   r   r   r   r   r   r   r   r   Úconfiguration_unispeechr   Ú
get_loggerr    Úloggerr   r,   r0   r2   r4   r6   r8   rf   rÌ   r°   rÐ   rø   rú   Ú__all__r(   r)   r*   ú<module>r     sJ  ðñ ã Ý !ã Ý å &ß DÝ -ß ,÷
÷ 
õ 
õ 5ð 
ˆ×	Ñ	˜HÓ	%€ñ ðôð
 ô7 Kó 7ó óð7ô.	Ð'Fô 	ô	Ð4ô 	ô	Ð!:ô 	ô	�ô 	ô	Ð&Dô 	ô*'Ð%Bô *'ðZ ôA˜ó Aó ðAðH 3Ð ôH
Ð-¨}ô H
ñV ðôô
w
Ð6ó w
óð
w
ôt	�nô 	ô	Ð)Jô 	ò�r)   