import{S as Is,i as Vs,s as Hs,e as n,k as p,w,t as s,M as Ks,c as a,d as o,m as h,a as r,x as y,h as i,b as c,G as e,g as _,y as S,q as T,o as $,B as k,v as Ys,L as wo}from"../../chunks/vendor-hf-doc-builder.js";import{T as pn}from"../../chunks/Tip-hf-doc-builder.js";import{D as I}from"../../chunks/Docstring-hf-doc-builder.js";import{C as yo}from"../../chunks/CodeBlock-hf-doc-builder.js";import{I as Ce}from"../../chunks/IconCopyLink-hf-doc-builder.js";import{E as bo}from"../../chunks/ExampleCodeBlock-hf-doc-builder.js";function Rs(U){let d,b,g,u,v;return u=new yo({props:{code:`from transformers import UniSpeechConfig, UniSpeechModel

# Initializing a UniSpeech facebook/unispeech-base-960h style configuration
configuration = UniSpeechConfig()

# Initializing a model (with random weights) from the facebook/unispeech-base-960h style configuration
model = UniSpeechModel(configuration)

# Accessing the model configuration
configuration = model.config`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> UniSpeechConfig, UniSpeechModel

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Initializing a UniSpeech facebook/unispeech-base-960h style configuration</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>configuration = UniSpeechConfig()

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Initializing a model (with random weights) from the facebook/unispeech-base-960h style configuration</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>model = UniSpeechModel(configuration)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Accessing the model configuration</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>configuration = model.config`}}),{c(){d=n("p"),b=s("Example:"),g=p(),w(u.$$.fragment)},l(l){d=a(l,"P",{});var m=r(d);b=i(m,"Example:"),m.forEach(o),g=h(l),y(u.$$.fragment,l)},m(l,m){_(l,d,m),e(d,b),_(l,g,m),S(u,l,m),v=!0},p:wo,i(l){v||(T(u.$$.fragment,l),v=!0)},o(l){$(u.$$.fragment,l),v=!1},d(l){l&&o(d),l&&o(g),k(u,l)}}}function Bs(U){let d,b,g,u,v;return{c(){d=n("p"),b=s("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),u=s("Module"),v=s(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=a(l,"P",{});var m=r(d);b=i(m,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=a(m,"CODE",{});var C=r(g);u=i(C,"Module"),C.forEach(o),v=i(m,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),m.forEach(o)},m(l,m){_(l,d,m),e(d,b),e(d,g),e(g,u),e(d,v)},d(l){l&&o(d)}}}function Qs(U){let d,b,g,u,v;return u=new yo({props:{code:`from transformers import AutoProcessor, UniSpeechModel
import torch
from datasets import load_dataset

dataset = load_dataset("hf-internal-testing/librispeech_asr_demo", "clean", split="validation")
dataset = dataset.sort("id")
sampling_rate = dataset.features["audio"].sampling_rate

processor = AutoProcessor.from_pretrained("patrickvonplaten/unispeech-large-1500h-cv-timit")
model = UniSpeechModel.from_pretrained("patrickvonplaten/unispeech-large-1500h-cv-timit")

# audio file is decoded on the fly
inputs = processor(dataset[0]["audio"]["array"], sampling_rate=sampling_rate, return_tensors="pt")
with torch.no_grad():
    outputs = model(**inputs)

last_hidden_states = outputs.last_hidden_state
list(last_hidden_states.shape)`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoProcessor, UniSpeechModel
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> datasets <span class="hljs-keyword">import</span> load_dataset

<span class="hljs-meta">&gt;&gt;&gt; </span>dataset = load_dataset(<span class="hljs-string">&quot;hf-internal-testing/librispeech_asr_demo&quot;</span>, <span class="hljs-string">&quot;clean&quot;</span>, split=<span class="hljs-string">&quot;validation&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>dataset = dataset.sort(<span class="hljs-string">&quot;id&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>sampling_rate = dataset.features[<span class="hljs-string">&quot;audio&quot;</span>].sampling_rate

<span class="hljs-meta">&gt;&gt;&gt; </span>processor = AutoProcessor.from_pretrained(<span class="hljs-string">&quot;patrickvonplaten/unispeech-large-1500h-cv-timit&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = UniSpeechModel.from_pretrained(<span class="hljs-string">&quot;patrickvonplaten/unispeech-large-1500h-cv-timit&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># audio file is decoded on the fly</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = processor(dataset[<span class="hljs-number">0</span>][<span class="hljs-string">&quot;audio&quot;</span>][<span class="hljs-string">&quot;array&quot;</span>], sampling_rate=sampling_rate, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">with</span> torch.no_grad():
<span class="hljs-meta">... </span>    outputs = model(**inputs)

<span class="hljs-meta">&gt;&gt;&gt; </span>last_hidden_states = outputs.last_hidden_state
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">list</span>(last_hidden_states.shape)
[<span class="hljs-number">1</span>, <span class="hljs-number">292</span>, <span class="hljs-number">1024</span>]`}}),{c(){d=n("p"),b=s("Example:"),g=p(),w(u.$$.fragment)},l(l){d=a(l,"P",{});var m=r(d);b=i(m,"Example:"),m.forEach(o),g=h(l),y(u.$$.fragment,l)},m(l,m){_(l,d,m),e(d,b),_(l,g,m),S(u,l,m),v=!0},p:wo,i(l){v||(T(u.$$.fragment,l),v=!0)},o(l){$(u.$$.fragment,l),v=!1},d(l){l&&o(d),l&&o(g),k(u,l)}}}function Xs(U){let d,b,g,u,v;return{c(){d=n("p"),b=s("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),u=s("Module"),v=s(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=a(l,"P",{});var m=r(d);b=i(m,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=a(m,"CODE",{});var C=r(g);u=i(C,"Module"),C.forEach(o),v=i(m,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),m.forEach(o)},m(l,m){_(l,d,m),e(d,b),e(d,g),e(g,u),e(d,v)},d(l){l&&o(d)}}}function Zs(U){let d,b,g,u,v;return u=new yo({props:{code:`from transformers import AutoProcessor, UniSpeechForCTC
from datasets import load_dataset
import torch

dataset = load_dataset("hf-internal-testing/librispeech_asr_demo", "clean", split="validation")
dataset = dataset.sort("id")
sampling_rate = dataset.features["audio"].sampling_rate

processor = AutoProcessor.from_pretrained("patrickvonplaten/unispeech-large-1500h-cv-timit")
model = UniSpeechForCTC.from_pretrained("patrickvonplaten/unispeech-large-1500h-cv-timit")

# audio file is decoded on the fly
inputs = processor(dataset[0]["audio"]["array"], sampling_rate=sampling_rate, return_tensors="pt")
with torch.no_grad():
    logits = model(**inputs).logits
predicted_ids = torch.argmax(logits, dim=-1)

# transcribe speech
transcription = processor.batch_decode(predicted_ids)
transcription[0]

inputs["labels"] = processor(text=dataset[0]["text"], return_tensors="pt").input_ids

# compute loss
loss = model(**inputs).loss
round(loss.item(), 2)`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoProcessor, UniSpeechForCTC
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> datasets <span class="hljs-keyword">import</span> load_dataset
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch

<span class="hljs-meta">&gt;&gt;&gt; </span>dataset = load_dataset(<span class="hljs-string">&quot;hf-internal-testing/librispeech_asr_demo&quot;</span>, <span class="hljs-string">&quot;clean&quot;</span>, split=<span class="hljs-string">&quot;validation&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>dataset = dataset.sort(<span class="hljs-string">&quot;id&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>sampling_rate = dataset.features[<span class="hljs-string">&quot;audio&quot;</span>].sampling_rate

<span class="hljs-meta">&gt;&gt;&gt; </span>processor = AutoProcessor.from_pretrained(<span class="hljs-string">&quot;patrickvonplaten/unispeech-large-1500h-cv-timit&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = UniSpeechForCTC.from_pretrained(<span class="hljs-string">&quot;patrickvonplaten/unispeech-large-1500h-cv-timit&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># audio file is decoded on the fly</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = processor(dataset[<span class="hljs-number">0</span>][<span class="hljs-string">&quot;audio&quot;</span>][<span class="hljs-string">&quot;array&quot;</span>], sampling_rate=sampling_rate, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">with</span> torch.no_grad():
<span class="hljs-meta">... </span>    logits = model(**inputs).logits
<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_ids = torch.argmax(logits, dim=-<span class="hljs-number">1</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># transcribe speech</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>transcription = processor.batch_decode(predicted_ids)
<span class="hljs-meta">&gt;&gt;&gt; </span>transcription[<span class="hljs-number">0</span>]
<span class="hljs-string">&#x27;mister quilter is the apposl of the midle classes and weare glad to welcom his gosepl&#x27;</span>

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs[<span class="hljs-string">&quot;labels&quot;</span>] = processor(text=dataset[<span class="hljs-number">0</span>][<span class="hljs-string">&quot;text&quot;</span>], return_tensors=<span class="hljs-string">&quot;pt&quot;</span>).input_ids

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># compute loss</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = model(**inputs).loss
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">round</span>(loss.item(), <span class="hljs-number">2</span>)
<span class="hljs-number">17.17</span>`}}),{c(){d=n("p"),b=s("Example:"),g=p(),w(u.$$.fragment)},l(l){d=a(l,"P",{});var m=r(d);b=i(m,"Example:"),m.forEach(o),g=h(l),y(u.$$.fragment,l)},m(l,m){_(l,d,m),e(d,b),_(l,g,m),S(u,l,m),v=!0},p:wo,i(l){v||(T(u.$$.fragment,l),v=!0)},o(l){$(u.$$.fragment,l),v=!1},d(l){l&&o(d),l&&o(g),k(u,l)}}}function Gs(U){let d,b,g,u,v;return{c(){d=n("p"),b=s("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),u=s("Module"),v=s(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=a(l,"P",{});var m=r(d);b=i(m,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=a(m,"CODE",{});var C=r(g);u=i(C,"Module"),C.forEach(o),v=i(m,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),m.forEach(o)},m(l,m){_(l,d,m),e(d,b),e(d,g),e(g,u),e(d,v)},d(l){l&&o(d)}}}function Js(U){let d,b,g,u,v;return u=new yo({props:{code:`from transformers import AutoFeatureExtractor, UniSpeechForSequenceClassification
from datasets import load_dataset
import torch

dataset = load_dataset("hf-internal-testing/librispeech_asr_demo", "clean", split="validation")
dataset = dataset.sort("id")
sampling_rate = dataset.features["audio"].sampling_rate

feature_extractor = AutoFeatureExtractor.from_pretrained("patrickvonplaten/unispeech-large-1500h-cv-timit")
model = UniSpeechForSequenceClassification.from_pretrained("patrickvonplaten/unispeech-large-1500h-cv-timit")

# audio file is decoded on the fly
inputs = feature_extractor(dataset[0]["audio"]["array"], sampling_rate=sampling_rate, return_tensors="pt")

with torch.no_grad():
    logits = model(**inputs).logits

predicted_class_ids = torch.argmax(logits, dim=-1).item()
predicted_label = model.config.id2label[predicted_class_ids]

# compute loss - target_label is e.g. "down"
target_label = model.config.id2label[0]
inputs["labels"] = torch.tensor([model.config.label2id[target_label]])
loss = model(**inputs).loss`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoFeatureExtractor, UniSpeechForSequenceClassification
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> datasets <span class="hljs-keyword">import</span> load_dataset
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch

<span class="hljs-meta">&gt;&gt;&gt; </span>dataset = load_dataset(<span class="hljs-string">&quot;hf-internal-testing/librispeech_asr_demo&quot;</span>, <span class="hljs-string">&quot;clean&quot;</span>, split=<span class="hljs-string">&quot;validation&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>dataset = dataset.sort(<span class="hljs-string">&quot;id&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>sampling_rate = dataset.features[<span class="hljs-string">&quot;audio&quot;</span>].sampling_rate

<span class="hljs-meta">&gt;&gt;&gt; </span>feature_extractor = AutoFeatureExtractor.from_pretrained(<span class="hljs-string">&quot;patrickvonplaten/unispeech-large-1500h-cv-timit&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = UniSpeechForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;patrickvonplaten/unispeech-large-1500h-cv-timit&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># audio file is decoded on the fly</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = feature_extractor(dataset[<span class="hljs-number">0</span>][<span class="hljs-string">&quot;audio&quot;</span>][<span class="hljs-string">&quot;array&quot;</span>], sampling_rate=sampling_rate, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">with</span> torch.no_grad():
<span class="hljs-meta">... </span>    logits = model(**inputs).logits

<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_class_ids = torch.argmax(logits, dim=-<span class="hljs-number">1</span>).item()
<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_label = model.config.id2label[predicted_class_ids]

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># compute loss - target_label is e.g. &quot;down&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>target_label = model.config.id2label[<span class="hljs-number">0</span>]
<span class="hljs-meta">&gt;&gt;&gt; </span>inputs[<span class="hljs-string">&quot;labels&quot;</span>] = torch.tensor([model.config.label2id[target_label]])
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = model(**inputs).loss`}}),{c(){d=n("p"),b=s("Example:"),g=p(),w(u.$$.fragment)},l(l){d=a(l,"P",{});var m=r(d);b=i(m,"Example:"),m.forEach(o),g=h(l),y(u.$$.fragment,l)},m(l,m){_(l,d,m),e(d,b),_(l,g,m),S(u,l,m),v=!0},p:wo,i(l){v||(T(u.$$.fragment,l),v=!0)},o(l){$(u.$$.fragment,l),v=!1},d(l){l&&o(d),l&&o(g),k(u,l)}}}function ei(U){let d,b,g,u,v;return{c(){d=n("p"),b=s("Although the recipe for forward pass needs to be defined within this function, one should call the "),g=n("code"),u=s("Module"),v=s(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(l){d=a(l,"P",{});var m=r(d);b=i(m,"Although the recipe for forward pass needs to be defined within this function, one should call the "),g=a(m,"CODE",{});var C=r(g);u=i(C,"Module"),C.forEach(o),v=i(m,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),m.forEach(o)},m(l,m){_(l,d,m),e(d,b),e(d,g),e(g,u),e(d,v)},d(l){l&&o(d)}}}function ti(U){let d,b,g,u,v;return u=new yo({props:{code:`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`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoFeatureExtractor, UniSpeechForPreTraining

<span class="hljs-meta">&gt;&gt;&gt; </span>feature_extractor = AutoFeatureExtractor.from_pretrained(<span class="hljs-string">&quot;microsoft/unispeech-large-1500h-cv&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = UniSpeechForPreTraining.from_pretrained(<span class="hljs-string">&quot;microsoft/unispeech-large-1500h-cv&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># <span class="hljs-doctag">TODO:</span> Add full pretraining example</span>`}}),{c(){d=n("p"),b=s("Example:"),g=p(),w(u.$$.fragment)},l(l){d=a(l,"P",{});var m=r(d);b=i(m,"Example:"),m.forEach(o),g=h(l),y(u.$$.fragment,l)},m(l,m){_(l,d,m),e(d,b),_(l,g,m),S(u,l,m),v=!0},p:wo,i(l){v||(T(u.$$.fragment,l),v=!0)},o(l){$(u.$$.fragment,l),v=!1},d(l){l&&o(d),l&&o(g),k(u,l)}}}function oi(U){let d,b,g,u,v,l,m,C,hn,So,V,ae,Ht,xe,mn,Kt,un,To,re,fn,Fe,gn,_n,$o,wt,vn,ko,yt,Yt,bn,Uo,St,wn,Co,se,je,yn,Tt,Sn,Tn,$n,qe,kn,$t,Un,Cn,xo,D,xn,Pe,Fn,jn,Ee,qn,Pn,Fo,H,ie,Rt,Me,En,Bt,Mn,jo,P,ze,zn,K,An,kt,On,Dn,Ae,Ln,Wn,Nn,Y,In,Ut,Vn,Hn,Ct,Kn,Yn,Rn,le,qo,R,ce,Qt,Oe,Bn,Xt,Qn,Po,B,De,Xn,Le,Zn,Zt,Gn,Jn,Eo,Q,de,Gt,We,ea,Jt,ta,Mo,F,Ne,oa,Ie,na,Ve,aa,ra,sa,He,ia,xt,la,ca,da,Ke,pa,Ye,ha,ma,ua,E,Re,fa,X,ga,Ft,_a,va,eo,ba,wa,ya,pe,Sa,he,zo,Z,me,to,Be,Ta,oo,$a,Ao,j,Qe,ka,G,Ua,no,Ca,xa,Xe,Fa,ja,qa,Ze,Pa,jt,Ea,Ma,za,Ge,Aa,Je,Oa,Da,La,M,et,Wa,J,Na,qt,Ia,Va,ao,Ha,Ka,Ya,ue,Ra,fe,Oo,ee,ge,ro,tt,Ba,so,Qa,Do,x,ot,Xa,io,Za,Ga,nt,Ja,at,er,tr,or,rt,nr,Pt,ar,rr,sr,st,ir,it,lr,cr,dr,z,lt,pr,te,hr,Et,mr,ur,lo,fr,gr,_r,_e,vr,ve,Lo,oe,be,co,ct,br,po,wr,Wo,q,dt,yr,pt,Sr,ht,Tr,$r,kr,mt,Ur,Mt,Cr,xr,Fr,ut,jr,ft,qr,Pr,Er,A,gt,Mr,ne,zr,zt,Ar,Or,ho,Dr,Lr,Wr,we,Nr,ye,No;return l=new Ce({}),xe=new Ce({}),Me=new Ce({}),ze=new I({props:{name:"class transformers.UniSpeechConfig",anchor:"transformers.UniSpeechConfig",parameters:[{name:"vocab_size",val:" = 32"},{name:"hidden_size",val:" = 768"},{name:"num_hidden_layers",val:" = 12"},{name:"num_attention_heads",val:" = 12"},{name:"intermediate_size",val:" = 3072"},{name:"hidden_act",val:" = 'gelu'"},{name:"hidden_dropout",val:" = 0.1"},{name:"activation_dropout",val:" = 0.1"},{name:"attention_dropout",val:" = 0.1"},{name:"feat_proj_dropout",val:" = 0.0"},{name:"feat_quantizer_dropout",val:" = 0.0"},{name:"final_dropout",val:" = 0.1"},{name:"layerdrop",val:" = 0.1"},{name:"initializer_range",val:" = 0.02"},{name:"layer_norm_eps",val:" = 1e-05"},{name:"feat_extract_norm",val:" = 'group'"},{name:"feat_extract_activation",val:" = 'gelu'"},{name:"conv_dim",val:" = (512, 512, 512, 512, 512, 512, 512)"},{name:"conv_stride",val:" = (5, 2, 2, 2, 2, 2, 2)"},{name:"conv_kernel",val:" = (10, 3, 3, 3, 3, 2, 2)"},{name:"conv_bias",val:" = False"},{name:"num_conv_pos_embeddings",val:" = 128"},{name:"num_conv_pos_embedding_groups",val:" = 16"},{name:"do_stable_layer_norm",val:" = False"},{name:"apply_spec_augment",val:" = True"},{name:"mask_time_prob",val:" = 0.05"},{name:"mask_time_length",val:" = 10"},{name:"mask_time_min_masks",val:" = 2"},{name:"mask_feature_prob",val:" = 0.0"},{name:"mask_feature_length",val:" = 10"},{name:"mask_feature_min_masks",val:" = 0"},{name:"num_codevectors_per_group",val:" = 320"},{name:"num_codevector_groups",val:" = 2"},{name:"contrastive_logits_temperature",val:" = 0.1"},{name:"num_negatives",val:" = 100"},{name:"codevector_dim",val:" = 256"},{name:"proj_codevector_dim",val:" = 256"},{name:"diversity_loss_weight",val:" = 0.1"},{name:"ctc_loss_reduction",val:" = 'mean'"},{name:"ctc_zero_infinity",val:" = False"},{name:"use_weighted_layer_sum",val:" = False"},{name:"classifier_proj_size",val:" = 256"},{name:"num_ctc_classes",val:" = 80"},{name:"pad_token_id",val:" = 0"},{name:"bos_token_id",val:" = 1"},{name:"eos_token_id",val:" = 2"},{name:"replace_prob",val:" = 0.5"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.UniSpeechConfig.vocab_size",description:`<strong>vocab_size</strong> (<code>int</code>, <em>optional</em>, defaults to 32) &#x2014;
Vocabulary size of the UniSpeech model. Defines the number of different tokens that can be represented by
the <code>inputs_ids</code> passed when calling <a href="/docs/transformers/main/en/model_doc/unispeech#transformers.UniSpeechModel">UniSpeechModel</a>. Vocabulary size of the model. Defines the
different tokens that can be represented by the <em>inputs_ids</em> passed to the forward method of
<a href="/docs/transformers/main/en/model_doc/unispeech#transformers.UniSpeechModel">UniSpeechModel</a>.`,name:"vocab_size"},{anchor:"transformers.UniSpeechConfig.hidden_size",description:`<strong>hidden_size</strong> (<code>int</code>, <em>optional</em>, defaults to 768) &#x2014;
Dimensionality of the encoder layers and the pooler layer.`,name:"hidden_size"},{anchor:"transformers.UniSpeechConfig.num_hidden_layers",description:`<strong>num_hidden_layers</strong> (<code>int</code>, <em>optional</em>, defaults to 12) &#x2014;
Number of hidden layers in the Transformer encoder.`,name:"num_hidden_layers"},{anchor:"transformers.UniSpeechConfig.num_attention_heads",description:`<strong>num_attention_heads</strong> (<code>int</code>, <em>optional</em>, defaults to 12) &#x2014;
Number of attention heads for each attention layer in the Transformer encoder.`,name:"num_attention_heads"},{anchor:"transformers.UniSpeechConfig.intermediate_size",description:`<strong>intermediate_size</strong> (<code>int</code>, <em>optional</em>, defaults to 3072) &#x2014;
Dimensionality of the &#x201C;intermediate&#x201D; (i.e., feed-forward) layer in the Transformer encoder.`,name:"intermediate_size"},{anchor:"transformers.UniSpeechConfig.hidden_act",description:`<strong>hidden_act</strong> (<code>str</code> or <code>function</code>, <em>optional</em>, defaults to <code>&quot;gelu&quot;</code>) &#x2014;
The non-linear activation function (function or string) in the encoder and pooler. If string, <code>&quot;gelu&quot;</code>,
<code>&quot;relu&quot;</code>, <code>&quot;selu&quot;</code> and <code>&quot;gelu_new&quot;</code> are supported.`,name:"hidden_act"},{anchor:"transformers.UniSpeechConfig.hidden_dropout",description:`<strong>hidden_dropout</strong> (<code>float</code>, <em>optional</em>, defaults to 0.1) &#x2014;
The dropout probability for all fully connected layers in the embeddings, encoder, and pooler.`,name:"hidden_dropout"},{anchor:"transformers.UniSpeechConfig.attention_dropout",description:`<strong>attention_dropout</strong> (<code>float</code>, <em>optional</em>, defaults to 0.1) &#x2014;
The dropout ratio for the attention probabilities.`,name:"attention_dropout"},{anchor:"transformers.UniSpeechConfig.final_dropout",description:`<strong>final_dropout</strong> (<code>float</code>, <em>optional</em>, defaults to 0.1) &#x2014;
The dropout probability for the final projection layer of <a href="/docs/transformers/main/en/model_doc/unispeech#transformers.UniSpeechForCTC">UniSpeechForCTC</a>.`,name:"final_dropout"},{anchor:"transformers.UniSpeechConfig.initializer_range",description:`<strong>initializer_range</strong> (<code>float</code>, <em>optional</em>, defaults to 0.02) &#x2014;
The standard deviation of the truncated_normal_initializer for initializing all weight matrices.`,name:"initializer_range"},{anchor:"transformers.UniSpeechConfig.layer_norm_eps",description:`<strong>layer_norm_eps</strong> (<code>float</code>, <em>optional</em>, defaults to 1e-12) &#x2014;
The epsilon used by the layer normalization layers.`,name:"layer_norm_eps"},{anchor:"transformers.UniSpeechConfig.feat_extract_norm",description:`<strong>feat_extract_norm</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;group&quot;</code>) &#x2014;
The norm to be applied to 1D convolutional layers in feature encoder. One of <code>&quot;group&quot;</code> for group
normalization of only the first 1D convolutional layer or <code>&quot;layer&quot;</code> for layer normalization of all 1D
convolutional layers.`,name:"feat_extract_norm"},{anchor:"transformers.UniSpeechConfig.feat_proj_dropout",description:`<strong>feat_proj_dropout</strong> (<code>float</code>, <em>optional</em>, defaults to 0.0) &#x2014;
The dropout probability for output of the feature encoder.`,name:"feat_proj_dropout"},{anchor:"transformers.UniSpeechConfig.feat_extract_activation",description:"<strong>feat_extract_activation</strong> (<code>str, </code>optional<code>, defaults to </code>&#x201C;gelu&#x201D;<code>) -- The non-linear activation function (function or string) in the 1D convolutional layers of the feature extractor. If string, </code>&#x201C;gelu&#x201D;<code>, </code>&#x201C;relu&#x201D;<code>, </code>&#x201C;selu&#x201D;<code>and</code>&#x201C;gelu_new&#x201D;` are supported.",name:"feat_extract_activation"},{anchor:"transformers.UniSpeechConfig.feat_quantizer_dropout",description:`<strong>feat_quantizer_dropout</strong> (<code>float</code>, <em>optional</em>, defaults to 0.0) &#x2014;
The dropout probabilitiy for quantized feature encoder states.`,name:"feat_quantizer_dropout"},{anchor:"transformers.UniSpeechConfig.conv_dim",description:`<strong>conv_dim</strong> (<code>Tuple[int]</code> or <code>List[int]</code>, <em>optional</em>, defaults to <code>(512, 512, 512, 512, 512, 512, 512)</code>) &#x2014;
A tuple of integers defining the number of input and output channels of each 1D convolutional layer in the
feature encoder. The length of <em>conv_dim</em> defines the number of 1D convolutional layers.`,name:"conv_dim"},{anchor:"transformers.UniSpeechConfig.conv_stride",description:`<strong>conv_stride</strong> (<code>Tuple[int]</code> or <code>List[int]</code>, <em>optional</em>, defaults to <code>(5, 2, 2, 2, 2, 2, 2)</code>) &#x2014;
A tuple of integers defining the stride of each 1D convolutional layer in the feature encoder. The length
of <em>conv_stride</em> defines the number of convolutional layers and has to match the length of <em>conv_dim</em>.`,name:"conv_stride"},{anchor:"transformers.UniSpeechConfig.conv_kernel",description:`<strong>conv_kernel</strong> (<code>Tuple[int]</code> or <code>List[int]</code>, <em>optional</em>, defaults to <code>(10, 3, 3, 3, 3, 3, 3)</code>) &#x2014;
A tuple of integers defining the kernel size of each 1D convolutional layer in the feature encoder. The
length of <em>conv_kernel</em> defines the number of convolutional layers and has to match the length of
<em>conv_dim</em>.`,name:"conv_kernel"},{anchor:"transformers.UniSpeechConfig.conv_bias",description:`<strong>conv_bias</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether the 1D convolutional layers have a bias.`,name:"conv_bias"},{anchor:"transformers.UniSpeechConfig.num_conv_pos_embeddings",description:`<strong>num_conv_pos_embeddings</strong> (<code>int</code>, <em>optional</em>, defaults to 128) &#x2014;
Number of convolutional positional embeddings. Defines the kernel size of 1D convolutional positional
embeddings layer.`,name:"num_conv_pos_embeddings"},{anchor:"transformers.UniSpeechConfig.num_conv_pos_embedding_groups",description:`<strong>num_conv_pos_embedding_groups</strong> (<code>int</code>, <em>optional</em>, defaults to 16) &#x2014;
Number of groups of 1D convolutional positional embeddings layer.`,name:"num_conv_pos_embedding_groups"},{anchor:"transformers.UniSpeechConfig.do_stable_layer_norm",description:`<strong>do_stable_layer_norm</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether to apply <em>stable</em> layer norm architecture of the Transformer encoder. <code>do_stable_layer_norm is True</code> corresponds to applying layer norm before the attention layer, whereas <code>do_stable_layer_norm is False</code> corresponds to applying layer norm after the attention layer.`,name:"do_stable_layer_norm"},{anchor:"transformers.UniSpeechConfig.apply_spec_augment",description:`<strong>apply_spec_augment</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether to apply <em>SpecAugment</em> data augmentation to the outputs of the feature encoder. For reference see
<a href="https://arxiv.org/abs/1904.08779" rel="nofollow">SpecAugment: A Simple Data Augmentation Method for Automatic Speech
Recognition</a>.`,name:"apply_spec_augment"},{anchor:"transformers.UniSpeechConfig.mask_time_prob",description:`<strong>mask_time_prob</strong> (<code>float</code>, <em>optional</em>, defaults to 0.05) &#x2014;
Percentage (between 0 and 1) of all feature vectors along the time axis which will be masked. The masking
procecure generates &#x201D;mask_time_prob<em>len(time_axis)/mask_time_length&#x201D; independent masks over the axis. If
reasoning from the propability of each feature vector to be chosen as the start of the vector span to be
masked, </em>mask_time_prob<em> should be \`prob_vector_start</em>mask_time_length<code>. Note that overlap may decrease the actual percentage of masked vectors. This is only relevant if </code>apply_spec_augment is True\`.`,name:"mask_time_prob"},{anchor:"transformers.UniSpeechConfig.mask_time_length",description:`<strong>mask_time_length</strong> (<code>int</code>, <em>optional</em>, defaults to 10) &#x2014;
Length of vector span along the time axis.`,name:"mask_time_length"},{anchor:"transformers.UniSpeechConfig.mask_time_min_masks",description:`<strong>mask_time_min_masks</strong> (<code>int</code>, <em>optional</em>, defaults to 2), &#x2014;
The minimum number of masks of length <code>mask_feature_length</code> generated along the time axis, each time step,
irrespectively of <code>mask_feature_prob</code>. Only relevant if &#x201D;mask_time_prob*len(time_axis)/mask_time_length &lt;
mask_time_min_masks&#x201D;`,name:"mask_time_min_masks"},{anchor:"transformers.UniSpeechConfig.mask_feature_prob",description:`<strong>mask_feature_prob</strong> (<code>float</code>, <em>optional</em>, defaults to 0.0) &#x2014;
Percentage (between 0 and 1) of all feature vectors along the feature axis which will be masked. The
masking procecure generates &#x201D;mask_feature_prob<em>len(feature_axis)/mask_time_length&#x201D; independent masks over
the axis. If reasoning from the propability of each feature vector to be chosen as the start of the vector
span to be masked, </em>mask_feature_prob<em> should be \`prob_vector_start</em>mask_feature_length<code>. Note that overlap may decrease the actual percentage of masked vectors. This is only relevant if </code>apply_spec_augment is
True\`.`,name:"mask_feature_prob"},{anchor:"transformers.UniSpeechConfig.mask_feature_length",description:`<strong>mask_feature_length</strong> (<code>int</code>, <em>optional</em>, defaults to 10) &#x2014;
Length of vector span along the feature axis.`,name:"mask_feature_length"},{anchor:"transformers.UniSpeechConfig.mask_feature_min_masks",description:`<strong>mask_feature_min_masks</strong> (<code>int</code>, <em>optional</em>, defaults to 0), &#x2014;
The minimum number of masks of length <code>mask_feature_length</code> generated along the feature axis, each time
step, irrespectively of <code>mask_feature_prob</code>. Only relevant if
&#x201D;mask_feature_prob*len(feature_axis)/mask_feature_length &lt; mask_feature_min_masks&#x201D;`,name:"mask_feature_min_masks"},{anchor:"transformers.UniSpeechConfig.num_codevectors_per_group",description:`<strong>num_codevectors_per_group</strong> (<code>int</code>, <em>optional</em>, defaults to 320) &#x2014;
Number of entries in each quantization codebook (group).`,name:"num_codevectors_per_group"},{anchor:"transformers.UniSpeechConfig.num_codevector_groups",description:`<strong>num_codevector_groups</strong> (<code>int</code>, <em>optional</em>, defaults to 2) &#x2014;
Number of codevector groups for product codevector quantization.`,name:"num_codevector_groups"},{anchor:"transformers.UniSpeechConfig.contrastive_logits_temperature",description:`<strong>contrastive_logits_temperature</strong> (<code>float</code>, <em>optional</em>, defaults to 0.1) &#x2014;
The temperature <em>kappa</em> in the contrastive loss.`,name:"contrastive_logits_temperature"},{anchor:"transformers.UniSpeechConfig.feat_quantizer_dropout",description:`<strong>feat_quantizer_dropout</strong> (<code>float</code>, <em>optional</em>, defaults to 0.0) &#x2014;
The dropout probabilitiy for the output of the feature encoder that&#x2019;s used by the quantizer.`,name:"feat_quantizer_dropout"},{anchor:"transformers.UniSpeechConfig.num_negatives",description:`<strong>num_negatives</strong> (<code>int</code>, <em>optional</em>, defaults to 100) &#x2014;
Number of negative samples for the contrastive loss.`,name:"num_negatives"},{anchor:"transformers.UniSpeechConfig.codevector_dim",description:`<strong>codevector_dim</strong> (<code>int</code>, <em>optional</em>, defaults to 256) &#x2014;
Dimensionality of the quantized feature vectors.`,name:"codevector_dim"},{anchor:"transformers.UniSpeechConfig.proj_codevector_dim",description:`<strong>proj_codevector_dim</strong> (<code>int</code>, <em>optional</em>, defaults to 256) &#x2014;
Dimensionality of the final projection of both the quantized and the transformer features.`,name:"proj_codevector_dim"},{anchor:"transformers.UniSpeechConfig.diversity_loss_weight",description:`<strong>diversity_loss_weight</strong> (<code>int</code>, <em>optional</em>, defaults to 0.1) &#x2014;
The weight of the codebook diversity loss component.`,name:"diversity_loss_weight"},{anchor:"transformers.UniSpeechConfig.ctc_loss_reduction",description:`<strong>ctc_loss_reduction</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;mean&quot;</code>) &#x2014;
Specifies the reduction to apply to the output of <code>torch.nn.CTCLoss</code>. Only relevant when training an
instance of <a href="/docs/transformers/main/en/model_doc/unispeech#transformers.UniSpeechForCTC">UniSpeechForCTC</a>.`,name:"ctc_loss_reduction"},{anchor:"transformers.UniSpeechConfig.ctc_zero_infinity",description:`<strong>ctc_zero_infinity</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether to zero infinite losses and the associated gradients of <code>torch.nn.CTCLoss</code>. Infinite losses mainly
occur when the inputs are too short to be aligned to the targets. Only relevant when training an instance
of <a href="/docs/transformers/main/en/model_doc/unispeech#transformers.UniSpeechForCTC">UniSpeechForCTC</a>.`,name:"ctc_zero_infinity"},{anchor:"transformers.UniSpeechConfig.use_weighted_layer_sum",description:`<strong>use_weighted_layer_sum</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether to use a weighted average of layer outputs with learned weights. Only relevant when using an
instance of <a href="/docs/transformers/main/en/model_doc/unispeech#transformers.UniSpeechForSequenceClassification">UniSpeechForSequenceClassification</a>.`,name:"use_weighted_layer_sum"},{anchor:"transformers.UniSpeechConfig.classifier_proj_size",description:`<strong>classifier_proj_size</strong> (<code>int</code>, <em>optional</em>, defaults to 256) &#x2014;
Dimensionality of the projection before token mean-pooling for classification.`,name:"classifier_proj_size"},{anchor:"transformers.UniSpeechConfig.replace_prob",description:`<strong>replace_prob</strong> (<code>float</code>, <em>optional</em>, defaults to 0.5) &#x2014;
Propability that transformer feature is replaced by quantized feature for pretraining.`,name:"replace_prob"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/unispeech/configuration_unispeech.py#L34"}}),le=new bo({props:{anchor:"transformers.UniSpeechConfig.example",$$slots:{default:[Rs]},$$scope:{ctx:U}}}),Oe=new Ce({}),De=new I({props:{name:"class transformers.models.unispeech.modeling_unispeech.UniSpeechForPreTrainingOutput",anchor:"transformers.models.unispeech.modeling_unispeech.UniSpeechForPreTrainingOutput",parameters:[{name:"loss",val:": typing.Optional[torch.FloatTensor] = None"},{name:"projected_states",val:": FloatTensor = None"},{name:"projected_quantized_states",val:": FloatTensor = None"},{name:"codevector_perplexity",val:": FloatTensor = None"},{name:"hidden_states",val:": typing.Optional[typing.Tuple[torch.FloatTensor]] = None"},{name:"attentions",val:": typing.Optional[typing.Tuple[torch.FloatTensor]] = None"}],parametersDescription:[{anchor:"transformers.models.unispeech.modeling_unispeech.UniSpeechForPreTrainingOutput.loss",description:`<strong>loss</strong> (<em>optional</em>, returned when model is in train mode, <code>torch.FloatTensor</code> of shape <code>(1,)</code>) &#x2014;
Total loss as the sum of the contrastive loss (L_m) and the diversity loss (L_d) as stated in the <a href="https://arxiv.org/pdf/2006.11477.pdf" rel="nofollow">official
paper</a> . (classification) loss.`,name:"loss"},{anchor:"transformers.models.unispeech.modeling_unispeech.UniSpeechForPreTrainingOutput.projected_states",description:`<strong>projected_states</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, config.proj_codevector_dim)</code>) &#x2014;
Hidden-states of the model projected to <em>config.proj_codevector_dim</em> that can be used to predict the masked
projected quantized states.`,name:"projected_states"},{anchor:"transformers.models.unispeech.modeling_unispeech.UniSpeechForPreTrainingOutput.projected_quantized_states",description:`<strong>projected_quantized_states</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, config.proj_codevector_dim)</code>) &#x2014;
Quantized extracted feature vectors projected to <em>config.proj_codevector_dim</em> representing the positive
target vectors for contrastive loss.`,name:"projected_quantized_states"},{anchor:"transformers.models.unispeech.modeling_unispeech.UniSpeechForPreTrainingOutput.hidden_states",description:`<strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) &#x2014;
Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings + one for the output of each layer) of
shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.`,name:"hidden_states"},{anchor:"transformers.models.unispeech.modeling_unispeech.UniSpeechForPreTrainingOutput.attentions",description:`<strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) &#x2014;
Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.`,name:"attentions"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/unispeech/modeling_unispeech.py#L68"}}),We=new Ce({}),Ne=new I({props:{name:"class transformers.UniSpeechModel",anchor:"transformers.UniSpeechModel",parameters:[{name:"config",val:": UniSpeechConfig"}],parametersDescription:[{anchor:"transformers.UniSpeechModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/unispeech#transformers.UniSpeechConfig">UniSpeechConfig</a>) &#x2014; 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 <a href="/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/unispeech/modeling_unispeech.py#L1071"}}),Re=new I({props:{name:"forward",anchor:"transformers.UniSpeechModel.forward",parameters:[{name:"input_values",val:": typing.Optional[torch.Tensor]"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"mask_time_indices",val:": typing.Optional[torch.FloatTensor] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"}],parametersDescription:[{anchor:"transformers.UniSpeechModel.forward.input_values",description:`<strong>input_values</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Float values of input raw speech waveform. Values can be obtained by loading a <code>.flac</code> or <code>.wav</code> audio file
into an array of type <code>List[float]</code> or a <code>numpy.ndarray</code>, <em>e.g.</em> via the soundfile library (<code>pip install soundfile</code>). To prepare the array into <code>input_values</code>, the <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoProcessor">AutoProcessor</a> should be used for padding and
conversion into a tensor of type <code>torch.FloatTensor</code>. See <a href="/docs/transformers/main/en/model_doc/wav2vec2#transformers.Wav2Vec2Processor.__call__">Wav2Vec2Processor.<strong>call</strong>()</a> for details.`,name:"input_values"},{anchor:"transformers.UniSpeechModel.forward.attention_mask",description:`<strong>attention_mask</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing convolution and attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a></p>
<div class="course-tip course-tip-orange bg-gradient-to-br dark:bg-gradient-to-r before:border-orange-500 dark:before:border-orange-800 from-orange-50 dark:from-gray-900 to-white dark:to-gray-950 border border-orange-50 text-orange-700 dark:text-gray-400">
						
<p><code>attention_mask</code> should only be passed if the corresponding processor has <code>config.return_attention_mask == True</code>. For all models whose processor has <code>config.return_attention_mask == False</code>, <code>attention_mask</code> should
<strong>not</strong> be passed to avoid degraded performance when doing batched inference. For such models
<code>input_values</code> should simply be padded with 0 and passed without <code>attention_mask</code>. Be aware that these
models also yield slightly different results depending on whether <code>input_values</code> is padded or not.</p>

					</div>`,name:"attention_mask"},{anchor:"transformers.UniSpeechModel.forward.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.UniSpeechModel.forward.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.UniSpeechModel.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/unispeech/modeling_unispeech.py#L1136",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/model_doc/wav2vec2#transformers.modeling_outputs.Wav2Vec2BaseModelOutput"
>transformers.modeling_outputs.Wav2Vec2BaseModelOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/main/en/model_doc/unispeech#transformers.UniSpeechConfig"
>UniSpeechConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>last_hidden_state</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>) \u2014 Sequence of hidden-states at the output of the last layer of the model.</p>
</li>
<li>
<p><strong>extract_features</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, conv_dim[-1])</code>) \u2014 Sequence of extracted feature vectors of the last convolutional layer of the model.</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings + one for the output of each layer) of
shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/main/en/model_doc/wav2vec2#transformers.modeling_outputs.Wav2Vec2BaseModelOutput"
>transformers.modeling_outputs.Wav2Vec2BaseModelOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),pe=new pn({props:{$$slots:{default:[Bs]},$$scope:{ctx:U}}}),he=new bo({props:{anchor:"transformers.UniSpeechModel.forward.example",$$slots:{default:[Qs]},$$scope:{ctx:U}}}),Be=new Ce({}),Qe=new I({props:{name:"class transformers.UniSpeechForCTC",anchor:"transformers.UniSpeechForCTC",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.UniSpeechForCTC.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/unispeech#transformers.UniSpeechConfig">UniSpeechConfig</a>) &#x2014; 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 <a href="/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/unispeech/modeling_unispeech.py#L1343"}}),et=new I({props:{name:"forward",anchor:"transformers.UniSpeechForCTC.forward",parameters:[{name:"input_values",val:": typing.Optional[torch.Tensor]"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"labels",val:": typing.Optional[torch.Tensor] = None"}],parametersDescription:[{anchor:"transformers.UniSpeechForCTC.forward.input_values",description:`<strong>input_values</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Float values of input raw speech waveform. Values can be obtained by loading a <code>.flac</code> or <code>.wav</code> audio file
into an array of type <code>List[float]</code> or a <code>numpy.ndarray</code>, <em>e.g.</em> via the soundfile library (<code>pip install soundfile</code>). To prepare the array into <code>input_values</code>, the <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoProcessor">AutoProcessor</a> should be used for padding and
conversion into a tensor of type <code>torch.FloatTensor</code>. See <a href="/docs/transformers/main/en/model_doc/wav2vec2#transformers.Wav2Vec2Processor.__call__">Wav2Vec2Processor.<strong>call</strong>()</a> for details.`,name:"input_values"},{anchor:"transformers.UniSpeechForCTC.forward.attention_mask",description:`<strong>attention_mask</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing convolution and attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a></p>
<div class="course-tip course-tip-orange bg-gradient-to-br dark:bg-gradient-to-r before:border-orange-500 dark:before:border-orange-800 from-orange-50 dark:from-gray-900 to-white dark:to-gray-950 border border-orange-50 text-orange-700 dark:text-gray-400">
						
<p><code>attention_mask</code> should only be passed if the corresponding processor has <code>config.return_attention_mask == True</code>. For all models whose processor has <code>config.return_attention_mask == False</code>, <code>attention_mask</code> should
<strong>not</strong> be passed to avoid degraded performance when doing batched inference. For such models
<code>input_values</code> should simply be padded with 0 and passed without <code>attention_mask</code>. Be aware that these
models also yield slightly different results depending on whether <code>input_values</code> is padded or not.</p>

					</div>`,name:"attention_mask"},{anchor:"transformers.UniSpeechForCTC.forward.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.UniSpeechForCTC.forward.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.UniSpeechForCTC.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.UniSpeechForCTC.forward.labels",description:`<strong>labels</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, target_length)</code>, <em>optional</em>) &#x2014;
Labels for connectionist temporal classification. Note that <code>target_length</code> has to be smaller or equal to
the sequence length of the output logits. Indices are selected in <code>[-100, 0, ..., config.vocab_size - 1]</code>.
All labels set to <code>-100</code> are ignored (masked), the loss is only computed for labels in <code>[0, ..., config.vocab_size - 1]</code>.`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/unispeech/modeling_unispeech.py#L1384",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_outputs.CausalLMOutput"
>transformers.modeling_outputs.CausalLMOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/main/en/model_doc/unispeech#transformers.UniSpeechConfig"
>UniSpeechConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>torch.FloatTensor</code> of shape <code>(1,)</code>, <em>optional</em>, returned when <code>labels</code> is provided) \u2014 Language modeling loss (for next-token prediction).</p>
</li>
<li>
<p><strong>logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, config.vocab_size)</code>) \u2014 Prediction scores of the language modeling head (scores for each vocabulary token before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_outputs.CausalLMOutput"
>transformers.modeling_outputs.CausalLMOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),ue=new pn({props:{$$slots:{default:[Xs]},$$scope:{ctx:U}}}),fe=new bo({props:{anchor:"transformers.UniSpeechForCTC.forward.example",$$slots:{default:[Zs]},$$scope:{ctx:U}}}),tt=new Ce({}),ot=new I({props:{name:"class transformers.UniSpeechForSequenceClassification",anchor:"transformers.UniSpeechForSequenceClassification",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.UniSpeechForSequenceClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/unispeech#transformers.UniSpeechConfig">UniSpeechConfig</a>) &#x2014; 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 <a href="/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/unispeech/modeling_unispeech.py#L1472"}}),lt=new I({props:{name:"forward",anchor:"transformers.UniSpeechForSequenceClassification.forward",parameters:[{name:"input_values",val:": typing.Optional[torch.Tensor]"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"labels",val:": typing.Optional[torch.Tensor] = None"}],parametersDescription:[{anchor:"transformers.UniSpeechForSequenceClassification.forward.input_values",description:`<strong>input_values</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Float values of input raw speech waveform. Values can be obtained by loading a <code>.flac</code> or <code>.wav</code> audio file
into an array of type <code>List[float]</code> or a <code>numpy.ndarray</code>, <em>e.g.</em> via the soundfile library (<code>pip install soundfile</code>). To prepare the array into <code>input_values</code>, the <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoProcessor">AutoProcessor</a> should be used for padding and
conversion into a tensor of type <code>torch.FloatTensor</code>. See <a href="/docs/transformers/main/en/model_doc/wav2vec2#transformers.Wav2Vec2Processor.__call__">Wav2Vec2Processor.<strong>call</strong>()</a> for details.`,name:"input_values"},{anchor:"transformers.UniSpeechForSequenceClassification.forward.attention_mask",description:`<strong>attention_mask</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing convolution and attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a></p>
<div class="course-tip course-tip-orange bg-gradient-to-br dark:bg-gradient-to-r before:border-orange-500 dark:before:border-orange-800 from-orange-50 dark:from-gray-900 to-white dark:to-gray-950 border border-orange-50 text-orange-700 dark:text-gray-400">
						
<p><code>attention_mask</code> should only be passed if the corresponding processor has <code>config.return_attention_mask == True</code>. For all models whose processor has <code>config.return_attention_mask == False</code>, <code>attention_mask</code> should
<strong>not</strong> be passed to avoid degraded performance when doing batched inference. For such models
<code>input_values</code> should simply be padded with 0 and passed without <code>attention_mask</code>. Be aware that these
models also yield slightly different results depending on whether <code>input_values</code> is padded or not.</p>

					</div>`,name:"attention_mask"},{anchor:"transformers.UniSpeechForSequenceClassification.forward.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.UniSpeechForSequenceClassification.forward.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.UniSpeechForSequenceClassification.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.UniSpeechForSequenceClassification.forward.labels",description:`<strong>labels</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for computing the sequence classification/regression loss. Indices should be in <code>[0, ..., config.num_labels - 1]</code>. If <code>config.num_labels == 1</code> a regression loss is computed (Mean-Square loss), If
<code>config.num_labels &gt; 1</code> a classification loss is computed (Cross-Entropy).`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/unispeech/modeling_unispeech.py#L1520",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_outputs.SequenceClassifierOutput"
>transformers.modeling_outputs.SequenceClassifierOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/main/en/model_doc/unispeech#transformers.UniSpeechConfig"
>UniSpeechConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>torch.FloatTensor</code> of shape <code>(1,)</code>, <em>optional</em>, returned when <code>labels</code> is provided) \u2014 Classification (or regression if config.num_labels==1) loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, config.num_labels)</code>) \u2014 Classification (or regression if config.num_labels==1) scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/main/en/main_classes/output#transformers.modeling_outputs.SequenceClassifierOutput"
>transformers.modeling_outputs.SequenceClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),_e=new pn({props:{$$slots:{default:[Gs]},$$scope:{ctx:U}}}),ve=new bo({props:{anchor:"transformers.UniSpeechForSequenceClassification.forward.example",$$slots:{default:[Js]},$$scope:{ctx:U}}}),ct=new Ce({}),dt=new I({props:{name:"class transformers.UniSpeechForPreTraining",anchor:"transformers.UniSpeechForPreTraining",parameters:[{name:"config",val:": UniSpeechConfig"}],parametersDescription:[{anchor:"transformers.UniSpeechForPreTraining.config",description:`<strong>config</strong> (<a href="/docs/transformers/main/en/model_doc/unispeech#transformers.UniSpeechConfig">UniSpeechConfig</a>) &#x2014; 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 <a href="/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/unispeech/modeling_unispeech.py#L1195"}}),gt=new I({props:{name:"forward",anchor:"transformers.UniSpeechForPreTraining.forward",parameters:[{name:"input_values",val:": typing.Optional[torch.Tensor]"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"}],parametersDescription:[{anchor:"transformers.UniSpeechForPreTraining.forward.input_values",description:`<strong>input_values</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Float values of input raw speech waveform. Values can be obtained by loading a <code>.flac</code> or <code>.wav</code> audio file
into an array of type <code>List[float]</code> or a <code>numpy.ndarray</code>, <em>e.g.</em> via the soundfile library (<code>pip install soundfile</code>). To prepare the array into <code>input_values</code>, the <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoProcessor">AutoProcessor</a> should be used for padding and
conversion into a tensor of type <code>torch.FloatTensor</code>. See <a href="/docs/transformers/main/en/model_doc/wav2vec2#transformers.Wav2Vec2Processor.__call__">Wav2Vec2Processor.<strong>call</strong>()</a> for details.`,name:"input_values"},{anchor:"transformers.UniSpeechForPreTraining.forward.attention_mask",description:`<strong>attention_mask</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing convolution and attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a></p>
<div class="course-tip course-tip-orange bg-gradient-to-br dark:bg-gradient-to-r before:border-orange-500 dark:before:border-orange-800 from-orange-50 dark:from-gray-900 to-white dark:to-gray-950 border border-orange-50 text-orange-700 dark:text-gray-400">
						
<p><code>attention_mask</code> should only be passed if the corresponding processor has <code>config.return_attention_mask == True</code>. For all models whose processor has <code>config.return_attention_mask == False</code>, <code>attention_mask</code> should
<strong>not</strong> be passed to avoid degraded performance when doing batched inference. For such models
<code>input_values</code> should simply be padded with 0 and passed without <code>attention_mask</code>. Be aware that these
models also yield slightly different results depending on whether <code>input_values</code> is padded or not.</p>

					</div>`,name:"attention_mask"},{anchor:"transformers.UniSpeechForPreTraining.forward.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.UniSpeechForPreTraining.forward.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.UniSpeechForPreTraining.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/main/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.UniSpeechForPreTraining.forward.mask_time_indices",description:`<strong>mask_time_indices</strong> (<code>torch.BoolTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices to mask extracted features for contrastive loss. When in training mode, model learns to predict
masked extracted features in <em>config.proj_codevector_dim</em> space.`,name:"mask_time_indices"},{anchor:"transformers.UniSpeechForPreTraining.forward.sampled_negative_indices",description:`<strong>sampled_negative_indices</strong> (<code>torch.BoolTensor</code> of shape <code>(batch_size, sequence_length, num_negatives)</code>, <em>optional</em>) &#x2014;
Indices indicating which quantized target vectors are used as negative sampled vectors in contrastive loss.
Required input for pre-training.`,name:"sampled_negative_indices"}],source:"https://github.com/huggingface/transformers/blob/main/src/transformers/models/unispeech/modeling_unispeech.py#L1256",returnDescription:`
<p>A <a
  href="/docs/transformers/main/en/model_doc/unispeech#transformers.models.unispeech.modeling_unispeech.UniSpeechForPreTrainingOutput"
>transformers.models.unispeech.modeling_unispeech.UniSpeechForPreTrainingOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/main/en/model_doc/unispeech#transformers.UniSpeechConfig"
>UniSpeechConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<em>optional</em>, returned when model is in train mode, <code>torch.FloatTensor</code> of shape <code>(1,)</code>) \u2014 Total loss as the sum of the contrastive loss (L_m) and the diversity loss (L_d) as stated in the <a
  href="https://arxiv.org/pdf/2006.11477.pdf"
  rel="nofollow"
>official
paper</a> . (classification) loss.</p>
</li>
<li>
<p><strong>projected_states</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, config.proj_codevector_dim)</code>) \u2014 Hidden-states of the model projected to <em>config.proj_codevector_dim</em> that can be used to predict the masked
projected quantized states.</p>
</li>
<li>
<p><strong>projected_quantized_states</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, config.proj_codevector_dim)</code>) \u2014 Quantized extracted feature vectors projected to <em>config.proj_codevector_dim</em> representing the positive
target vectors for contrastive loss.</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings + one for the output of each layer) of
shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/main/en/model_doc/unispeech#transformers.models.unispeech.modeling_unispeech.UniSpeechForPreTrainingOutput"
>transformers.models.unispeech.modeling_unispeech.UniSpeechForPreTrainingOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),we=new pn({props:{$$slots:{default:[ei]},$$scope:{ctx:U}}}),ye=new bo({props:{anchor:"transformers.UniSpeechForPreTraining.forward.example",$$slots:{default:[ti]},$$scope:{ctx:U}}}),{c(){d=n("meta"),b=p(),g=n("h1"),u=n("a"),v=n("span"),w(l.$$.fragment),m=p(),C=n("span"),hn=s("UniSpeech"),So=p(),V=n("h2"),ae=n("a"),Ht=n("span"),w(xe.$$.fragment),mn=p(),Kt=n("span"),un=s("Overview"),To=p(),re=n("p"),fn=s("The UniSpeech model was proposed in "),Fe=n("a"),gn=s("UniSpeech: Unified Speech Representation Learning with Labeled and Unlabeled Data"),_n=s(` by Chengyi Wang, Yu Wu, Yao Qian, Kenichi Kumatani, Shujie Liu, Furu Wei, Michael
Zeng, Xuedong Huang .`),$o=p(),wt=n("p"),vn=s("The abstract from the paper is the following:"),ko=p(),yt=n("p"),Yt=n("em"),bn=s(`In this paper, we propose a unified pre-training approach called UniSpeech to learn speech representations with both
unlabeled and labeled data, in which supervised phonetic CTC learning and phonetically-aware contrastive
self-supervised learning are conducted in a multi-task learning manner. The resultant representations can capture
information more correlated with phonetic structures and improve the generalization across languages and domains. We
evaluate the effectiveness of UniSpeech for cross-lingual representation learning on public CommonVoice corpus. The
results show that UniSpeech outperforms self-supervised pretraining and supervised transfer learning for speech
recognition by a maximum of 13.4% and 17.8% relative phone error rate reductions respectively (averaged over all
testing languages). The transferability of UniSpeech is also demonstrated on a domain-shift speech recognition task,
i.e., a relative word error rate reduction of 6% against the previous approach.`),Uo=p(),St=n("p"),wn=s("Tips:"),Co=p(),se=n("ul"),je=n("li"),yn=s(`UniSpeech is a speech model that accepts a float array corresponding to the raw waveform of the speech signal. Please
use `),Tt=n("a"),Sn=s("Wav2Vec2Processor"),Tn=s(" for the feature extraction."),$n=p(),qe=n("li"),kn=s(`UniSpeech model can be fine-tuned using connectionist temporal classification (CTC) so the model output has to be
decoded using `),$t=n("a"),Un=s("Wav2Vec2CTCTokenizer"),Cn=s("."),xo=p(),D=n("p"),xn=s("This model was contributed by "),Pe=n("a"),Fn=s("patrickvonplaten"),jn=s(`. The Authors\u2019 code can be
found `),Ee=n("a"),qn=s("here"),Pn=s("."),Fo=p(),H=n("h2"),ie=n("a"),Rt=n("span"),w(Me.$$.fragment),En=p(),Bt=n("span"),Mn=s("UniSpeechConfig"),jo=p(),P=n("div"),w(ze.$$.fragment),zn=p(),K=n("p"),An=s("This is the configuration class to store the configuration of a "),kt=n("a"),On=s("UniSpeechModel"),Dn=s(`. It is used to instantiate an
UniSpeech model according to the specified arguments, defining the model architecture. Instantiating a
configuration with the defaults will yield a similar configuration to that of the UniSpeech
`),Ae=n("a"),Ln=s("microsoft/unispeech-large-1500h-cv"),Wn=s(" architecture."),Nn=p(),Y=n("p"),In=s("Configuration objects inherit from "),Ut=n("a"),Vn=s("PretrainedConfig"),Hn=s(` and can be used to control the model outputs. Read the
documentation from `),Ct=n("a"),Kn=s("PretrainedConfig"),Yn=s(" for more information."),Rn=p(),w(le.$$.fragment),qo=p(),R=n("h2"),ce=n("a"),Qt=n("span"),w(Oe.$$.fragment),Bn=p(),Xt=n("span"),Qn=s("UniSpeech specific outputs"),Po=p(),B=n("div"),w(De.$$.fragment),Xn=p(),Le=n("p"),Zn=s("Output type of "),Zt=n("code"),Gn=s("UniSpeechForPreTrainingOutput"),Jn=s(", with potential hidden states and attentions."),Eo=p(),Q=n("h2"),de=n("a"),Gt=n("span"),w(We.$$.fragment),ea=p(),Jt=n("span"),ta=s("UniSpeechModel"),Mo=p(),F=n("div"),w(Ne.$$.fragment),oa=p(),Ie=n("p"),na=s(`The bare UniSpeech Model transformer outputting raw hidden-states without any specific head on top.
UniSpeech was proposed in `),Ve=n("a"),aa=s(`UniSpeech: Unified Speech Representation Learning with Labeled and Unlabeled
Data`),ra=s(` by Chengyi Wang, Yu Wu, Yao Qian, Kenichi Kumatani, Shujie Liu, Furu Wei,
Michael Zeng, Xuedong Huang.`),sa=p(),He=n("p"),ia=s("This model inherits from "),xt=n("a"),la=s("PreTrainedModel"),ca=s(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving etc.).`),da=p(),Ke=n("p"),pa=s("This model is a PyTorch "),Ye=n("a"),ha=s("torch.nn.Module"),ma=s(` sub-class. Use
it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage and
behavior.`),ua=p(),E=n("div"),w(Re.$$.fragment),fa=p(),X=n("p"),ga=s("The "),Ft=n("a"),_a=s("UniSpeechModel"),va=s(" forward method, overrides the "),eo=n("code"),ba=s("__call__"),wa=s(" special method."),ya=p(),w(pe.$$.fragment),Sa=p(),w(he.$$.fragment),zo=p(),Z=n("h2"),me=n("a"),to=n("span"),w(Be.$$.fragment),Ta=p(),oo=n("span"),$a=s("UniSpeechForCTC"),Ao=p(),j=n("div"),w(Qe.$$.fragment),ka=p(),G=n("p"),Ua=s("UniSpeech Model with a "),no=n("code"),Ca=s("language modeling"),xa=s(` head on top for Connectionist Temporal Classification (CTC).
UniSpeech was proposed in `),Xe=n("a"),Fa=s(`UniSpeech: Unified Speech Representation Learning with Labeled and Unlabeled
Data`),ja=s(` by Chengyi Wang, Yu Wu, Yao Qian, Kenichi Kumatani, Shujie Liu, Furu Wei,
Michael Zeng, Xuedong Huang.`),qa=p(),Ze=n("p"),Pa=s("This model inherits from "),jt=n("a"),Ea=s("PreTrainedModel"),Ma=s(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving etc.).`),za=p(),Ge=n("p"),Aa=s("This model is a PyTorch "),Je=n("a"),Oa=s("torch.nn.Module"),Da=s(` sub-class. Use
it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage and
behavior.`),La=p(),M=n("div"),w(et.$$.fragment),Wa=p(),J=n("p"),Na=s("The "),qt=n("a"),Ia=s("UniSpeechForCTC"),Va=s(" forward method, overrides the "),ao=n("code"),Ha=s("__call__"),Ka=s(" special method."),Ya=p(),w(ue.$$.fragment),Ra=p(),w(fe.$$.fragment),Oo=p(),ee=n("h2"),ge=n("a"),ro=n("span"),w(tt.$$.fragment),Ba=p(),so=n("span"),Qa=s("UniSpeechForSequenceClassification"),Do=p(),x=n("div"),w(ot.$$.fragment),Xa=p(),io=n("p"),Za=s(`UniSpeech Model with a sequence classification head on top (a linear layer over the pooled output) for tasks like
SUPERB Keyword Spotting.`),Ga=p(),nt=n("p"),Ja=s("UniSpeech was proposed in "),at=n("a"),er=s(`UniSpeech: Unified Speech Representation Learning with Labeled and Unlabeled
Data`),tr=s(` by Chengyi Wang, Yu Wu, Yao Qian, Kenichi Kumatani, Shujie Liu, Furu Wei,
Michael Zeng, Xuedong Huang.`),or=p(),rt=n("p"),nr=s("This model inherits from "),Pt=n("a"),ar=s("PreTrainedModel"),rr=s(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving etc.).`),sr=p(),st=n("p"),ir=s("This model is a PyTorch "),it=n("a"),lr=s("torch.nn.Module"),cr=s(` sub-class. Use
it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage and
behavior.`),dr=p(),z=n("div"),w(lt.$$.fragment),pr=p(),te=n("p"),hr=s("The "),Et=n("a"),mr=s("UniSpeechForSequenceClassification"),ur=s(" forward method, overrides the "),lo=n("code"),fr=s("__call__"),gr=s(" special method."),_r=p(),w(_e.$$.fragment),vr=p(),w(ve.$$.fragment),Lo=p(),oe=n("h2"),be=n("a"),co=n("span"),w(ct.$$.fragment),br=p(),po=n("span"),wr=s("UniSpeechForPreTraining"),Wo=p(),q=n("div"),w(dt.$$.fragment),yr=p(),pt=n("p"),Sr=s(`UniSpeech Model with a vector-quantization module and ctc loss for pre-training.
UniSpeech was proposed in `),ht=n("a"),Tr=s(`UniSpeech: Unified Speech Representation Learning with Labeled and Unlabeled
Data`),$r=s(` by Chengyi Wang, Yu Wu, Yao Qian, Kenichi Kumatani, Shujie Liu, Furu Wei,
Michael Zeng, Xuedong Huang.`),kr=p(),mt=n("p"),Ur=s("This model inherits from "),Mt=n("a"),Cr=s("PreTrainedModel"),xr=s(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving etc.).`),Fr=p(),ut=n("p"),jr=s("This model is a PyTorch "),ft=n("a"),qr=s("torch.nn.Module"),Pr=s(` sub-class. Use
it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage and
behavior.`),Er=p(),A=n("div"),w(gt.$$.fragment),Mr=p(),ne=n("p"),zr=s("The "),zt=n("a"),Ar=s("UniSpeechForPreTraining"),Or=s(" forward method, overrides the "),ho=n("code"),Dr=s("__call__"),Lr=s(" special method."),Wr=p(),w(we.$$.fragment),Nr=p(),w(ye.$$.fragment),this.h()},l(t){const f=Ks('[data-svelte="svelte-1phssyn"]',document.head);d=a(f,"META",{name:!0,content:!0}),f.forEach(o),b=h(t),g=a(t,"H1",{class:!0});var _t=r(g);u=a(_t,"A",{id:!0,class:!0,href:!0});var mo=r(u);v=a(mo,"SPAN",{});var uo=r(v);y(l.$$.fragment,uo),uo.forEach(o),mo.forEach(o),m=h(_t),C=a(_t,"SPAN",{});var fo=r(C);hn=i(fo,"UniSpeech"),fo.forEach(o),_t.forEach(o),So=h(t),V=a(t,"H2",{class:!0});var vt=r(V);ae=a(vt,"A",{id:!0,class:!0,href:!0});var go=r(ae);Ht=a(go,"SPAN",{});var _o=r(Ht);y(xe.$$.fragment,_o),_o.forEach(o),go.forEach(o),mn=h(vt),Kt=a(vt,"SPAN",{});var vo=r(Kt);un=i(vo,"Overview"),vo.forEach(o),vt.forEach(o),To=h(t),re=a(t,"P",{});var bt=r(re);fn=i(bt,"The UniSpeech model was proposed in "),Fe=a(bt,"A",{href:!0,rel:!0});var Ir=r(Fe);gn=i(Ir,"UniSpeech: Unified Speech Representation Learning with Labeled and Unlabeled Data"),Ir.forEach(o),_n=i(bt,` by Chengyi Wang, Yu Wu, Yao Qian, Kenichi Kumatani, Shujie Liu, Furu Wei, Michael
Zeng, Xuedong Huang .`),bt.forEach(o),$o=h(t),wt=a(t,"P",{});var Vr=r(wt);vn=i(Vr,"The abstract from the paper is the following:"),Vr.forEach(o),ko=h(t),yt=a(t,"P",{});var Hr=r(yt);Yt=a(Hr,"EM",{});var Kr=r(Yt);bn=i(Kr,`In this paper, we propose a unified pre-training approach called UniSpeech to learn speech representations with both
unlabeled and labeled data, in which supervised phonetic CTC learning and phonetically-aware contrastive
self-supervised learning are conducted in a multi-task learning manner. The resultant representations can capture
information more correlated with phonetic structures and improve the generalization across languages and domains. We
evaluate the effectiveness of UniSpeech for cross-lingual representation learning on public CommonVoice corpus. The
results show that UniSpeech outperforms self-supervised pretraining and supervised transfer learning for speech
recognition by a maximum of 13.4% and 17.8% relative phone error rate reductions respectively (averaged over all
testing languages). The transferability of UniSpeech is also demonstrated on a domain-shift speech recognition task,
i.e., a relative word error rate reduction of 6% against the previous approach.`),Kr.forEach(o),Hr.forEach(o),Uo=h(t),St=a(t,"P",{});var Yr=r(St);wn=i(Yr,"Tips:"),Yr.forEach(o),Co=h(t),se=a(t,"UL",{});var Io=r(se);je=a(Io,"LI",{});var Vo=r(je);yn=i(Vo,`UniSpeech is a speech model that accepts a float array corresponding to the raw waveform of the speech signal. Please
use `),Tt=a(Vo,"A",{href:!0});var Rr=r(Tt);Sn=i(Rr,"Wav2Vec2Processor"),Rr.forEach(o),Tn=i(Vo," for the feature extraction."),Vo.forEach(o),$n=h(Io),qe=a(Io,"LI",{});var Ho=r(qe);kn=i(Ho,`UniSpeech model can be fine-tuned using connectionist temporal classification (CTC) so the model output has to be
decoded using `),$t=a(Ho,"A",{href:!0});var Br=r($t);Un=i(Br,"Wav2Vec2CTCTokenizer"),Br.forEach(o),Cn=i(Ho,"."),Ho.forEach(o),Io.forEach(o),xo=h(t),D=a(t,"P",{});var At=r(D);xn=i(At,"This model was contributed by "),Pe=a(At,"A",{href:!0,rel:!0});var Qr=r(Pe);Fn=i(Qr,"patrickvonplaten"),Qr.forEach(o),jn=i(At,`. The Authors\u2019 code can be
found `),Ee=a(At,"A",{href:!0,rel:!0});var Xr=r(Ee);qn=i(Xr,"here"),Xr.forEach(o),Pn=i(At,"."),At.forEach(o),Fo=h(t),H=a(t,"H2",{class:!0});var Ko=r(H);ie=a(Ko,"A",{id:!0,class:!0,href:!0});var Zr=r(ie);Rt=a(Zr,"SPAN",{});var Gr=r(Rt);y(Me.$$.fragment,Gr),Gr.forEach(o),Zr.forEach(o),En=h(Ko),Bt=a(Ko,"SPAN",{});var Jr=r(Bt);Mn=i(Jr,"UniSpeechConfig"),Jr.forEach(o),Ko.forEach(o),jo=h(t),P=a(t,"DIV",{class:!0});var Se=r(P);y(ze.$$.fragment,Se),zn=h(Se),K=a(Se,"P",{});var Ot=r(K);An=i(Ot,"This is the configuration class to store the configuration of a "),kt=a(Ot,"A",{href:!0});var es=r(kt);On=i(es,"UniSpeechModel"),es.forEach(o),Dn=i(Ot,`. It is used to instantiate an
UniSpeech model according to the specified arguments, defining the model architecture. Instantiating a
configuration with the defaults will yield a similar configuration to that of the UniSpeech
`),Ae=a(Ot,"A",{href:!0,rel:!0});var ts=r(Ae);Ln=i(ts,"microsoft/unispeech-large-1500h-cv"),ts.forEach(o),Wn=i(Ot," architecture."),Ot.forEach(o),Nn=h(Se),Y=a(Se,"P",{});var Dt=r(Y);In=i(Dt,"Configuration objects inherit from "),Ut=a(Dt,"A",{href:!0});var os=r(Ut);Vn=i(os,"PretrainedConfig"),os.forEach(o),Hn=i(Dt,` and can be used to control the model outputs. Read the
documentation from `),Ct=a(Dt,"A",{href:!0});var ns=r(Ct);Kn=i(ns,"PretrainedConfig"),ns.forEach(o),Yn=i(Dt," for more information."),Dt.forEach(o),Rn=h(Se),y(le.$$.fragment,Se),Se.forEach(o),qo=h(t),R=a(t,"H2",{class:!0});var Yo=r(R);ce=a(Yo,"A",{id:!0,class:!0,href:!0});var as=r(ce);Qt=a(as,"SPAN",{});var rs=r(Qt);y(Oe.$$.fragment,rs),rs.forEach(o),as.forEach(o),Bn=h(Yo),Xt=a(Yo,"SPAN",{});var ss=r(Xt);Qn=i(ss,"UniSpeech specific outputs"),ss.forEach(o),Yo.forEach(o),Po=h(t),B=a(t,"DIV",{class:!0});var Ro=r(B);y(De.$$.fragment,Ro),Xn=h(Ro),Le=a(Ro,"P",{});var Bo=r(Le);Zn=i(Bo,"Output type of "),Zt=a(Bo,"CODE",{});var is=r(Zt);Gn=i(is,"UniSpeechForPreTrainingOutput"),is.forEach(o),Jn=i(Bo,", with potential hidden states and attentions."),Bo.forEach(o),Ro.forEach(o),Eo=h(t),Q=a(t,"H2",{class:!0});var Qo=r(Q);de=a(Qo,"A",{id:!0,class:!0,href:!0});var ls=r(de);Gt=a(ls,"SPAN",{});var cs=r(Gt);y(We.$$.fragment,cs),cs.forEach(o),ls.forEach(o),ea=h(Qo),Jt=a(Qo,"SPAN",{});var ds=r(Jt);ta=i(ds,"UniSpeechModel"),ds.forEach(o),Qo.forEach(o),Mo=h(t),F=a(t,"DIV",{class:!0});var L=r(F);y(Ne.$$.fragment,L),oa=h(L),Ie=a(L,"P",{});var Xo=r(Ie);na=i(Xo,`The bare UniSpeech Model transformer outputting raw hidden-states without any specific head on top.
UniSpeech was proposed in `),Ve=a(Xo,"A",{href:!0,rel:!0});var ps=r(Ve);aa=i(ps,`UniSpeech: Unified Speech Representation Learning with Labeled and Unlabeled
Data`),ps.forEach(o),ra=i(Xo,` by Chengyi Wang, Yu Wu, Yao Qian, Kenichi Kumatani, Shujie Liu, Furu Wei,
Michael Zeng, Xuedong Huang.`),Xo.forEach(o),sa=h(L),He=a(L,"P",{});var Zo=r(He);ia=i(Zo,"This model inherits from "),xt=a(Zo,"A",{href:!0});var hs=r(xt);la=i(hs,"PreTrainedModel"),hs.forEach(o),ca=i(Zo,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving etc.).`),Zo.forEach(o),da=h(L),Ke=a(L,"P",{});var Go=r(Ke);pa=i(Go,"This model is a PyTorch "),Ye=a(Go,"A",{href:!0,rel:!0});var ms=r(Ye);ha=i(ms,"torch.nn.Module"),ms.forEach(o),ma=i(Go,` sub-class. Use
it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage and
behavior.`),Go.forEach(o),ua=h(L),E=a(L,"DIV",{class:!0});var Te=r(E);y(Re.$$.fragment,Te),fa=h(Te),X=a(Te,"P",{});var Lt=r(X);ga=i(Lt,"The "),Ft=a(Lt,"A",{href:!0});var us=r(Ft);_a=i(us,"UniSpeechModel"),us.forEach(o),va=i(Lt," forward method, overrides the "),eo=a(Lt,"CODE",{});var fs=r(eo);ba=i(fs,"__call__"),fs.forEach(o),wa=i(Lt," special method."),Lt.forEach(o),ya=h(Te),y(pe.$$.fragment,Te),Sa=h(Te),y(he.$$.fragment,Te),Te.forEach(o),L.forEach(o),zo=h(t),Z=a(t,"H2",{class:!0});var Jo=r(Z);me=a(Jo,"A",{id:!0,class:!0,href:!0});var gs=r(me);to=a(gs,"SPAN",{});var _s=r(to);y(Be.$$.fragment,_s),_s.forEach(o),gs.forEach(o),Ta=h(Jo),oo=a(Jo,"SPAN",{});var vs=r(oo);$a=i(vs,"UniSpeechForCTC"),vs.forEach(o),Jo.forEach(o),Ao=h(t),j=a(t,"DIV",{class:!0});var W=r(j);y(Qe.$$.fragment,W),ka=h(W),G=a(W,"P",{});var Wt=r(G);Ua=i(Wt,"UniSpeech Model with a "),no=a(Wt,"CODE",{});var bs=r(no);Ca=i(bs,"language modeling"),bs.forEach(o),xa=i(Wt,` head on top for Connectionist Temporal Classification (CTC).
UniSpeech was proposed in `),Xe=a(Wt,"A",{href:!0,rel:!0});var ws=r(Xe);Fa=i(ws,`UniSpeech: Unified Speech Representation Learning with Labeled and Unlabeled
Data`),ws.forEach(o),ja=i(Wt,` by Chengyi Wang, Yu Wu, Yao Qian, Kenichi Kumatani, Shujie Liu, Furu Wei,
Michael Zeng, Xuedong Huang.`),Wt.forEach(o),qa=h(W),Ze=a(W,"P",{});var en=r(Ze);Pa=i(en,"This model inherits from "),jt=a(en,"A",{href:!0});var ys=r(jt);Ea=i(ys,"PreTrainedModel"),ys.forEach(o),Ma=i(en,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving etc.).`),en.forEach(o),za=h(W),Ge=a(W,"P",{});var tn=r(Ge);Aa=i(tn,"This model is a PyTorch "),Je=a(tn,"A",{href:!0,rel:!0});var Ss=r(Je);Oa=i(Ss,"torch.nn.Module"),Ss.forEach(o),Da=i(tn,` sub-class. Use
it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage and
behavior.`),tn.forEach(o),La=h(W),M=a(W,"DIV",{class:!0});var $e=r(M);y(et.$$.fragment,$e),Wa=h($e),J=a($e,"P",{});var Nt=r(J);Na=i(Nt,"The "),qt=a(Nt,"A",{href:!0});var Ts=r(qt);Ia=i(Ts,"UniSpeechForCTC"),Ts.forEach(o),Va=i(Nt," forward method, overrides the "),ao=a(Nt,"CODE",{});var $s=r(ao);Ha=i($s,"__call__"),$s.forEach(o),Ka=i(Nt," special method."),Nt.forEach(o),Ya=h($e),y(ue.$$.fragment,$e),Ra=h($e),y(fe.$$.fragment,$e),$e.forEach(o),W.forEach(o),Oo=h(t),ee=a(t,"H2",{class:!0});var on=r(ee);ge=a(on,"A",{id:!0,class:!0,href:!0});var ks=r(ge);ro=a(ks,"SPAN",{});var Us=r(ro);y(tt.$$.fragment,Us),Us.forEach(o),ks.forEach(o),Ba=h(on),so=a(on,"SPAN",{});var Cs=r(so);Qa=i(Cs,"UniSpeechForSequenceClassification"),Cs.forEach(o),on.forEach(o),Do=h(t),x=a(t,"DIV",{class:!0});var O=r(x);y(ot.$$.fragment,O),Xa=h(O),io=a(O,"P",{});var xs=r(io);Za=i(xs,`UniSpeech Model with a sequence classification head on top (a linear layer over the pooled output) for tasks like
SUPERB Keyword Spotting.`),xs.forEach(o),Ga=h(O),nt=a(O,"P",{});var nn=r(nt);Ja=i(nn,"UniSpeech was proposed in "),at=a(nn,"A",{href:!0,rel:!0});var Fs=r(at);er=i(Fs,`UniSpeech: Unified Speech Representation Learning with Labeled and Unlabeled
Data`),Fs.forEach(o),tr=i(nn,` by Chengyi Wang, Yu Wu, Yao Qian, Kenichi Kumatani, Shujie Liu, Furu Wei,
Michael Zeng, Xuedong Huang.`),nn.forEach(o),or=h(O),rt=a(O,"P",{});var an=r(rt);nr=i(an,"This model inherits from "),Pt=a(an,"A",{href:!0});var js=r(Pt);ar=i(js,"PreTrainedModel"),js.forEach(o),rr=i(an,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving etc.).`),an.forEach(o),sr=h(O),st=a(O,"P",{});var rn=r(st);ir=i(rn,"This model is a PyTorch "),it=a(rn,"A",{href:!0,rel:!0});var qs=r(it);lr=i(qs,"torch.nn.Module"),qs.forEach(o),cr=i(rn,` sub-class. Use
it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage and
behavior.`),rn.forEach(o),dr=h(O),z=a(O,"DIV",{class:!0});var ke=r(z);y(lt.$$.fragment,ke),pr=h(ke),te=a(ke,"P",{});var It=r(te);hr=i(It,"The "),Et=a(It,"A",{href:!0});var Ps=r(Et);mr=i(Ps,"UniSpeechForSequenceClassification"),Ps.forEach(o),ur=i(It," forward method, overrides the "),lo=a(It,"CODE",{});var Es=r(lo);fr=i(Es,"__call__"),Es.forEach(o),gr=i(It," special method."),It.forEach(o),_r=h(ke),y(_e.$$.fragment,ke),vr=h(ke),y(ve.$$.fragment,ke),ke.forEach(o),O.forEach(o),Lo=h(t),oe=a(t,"H2",{class:!0});var sn=r(oe);be=a(sn,"A",{id:!0,class:!0,href:!0});var Ms=r(be);co=a(Ms,"SPAN",{});var zs=r(co);y(ct.$$.fragment,zs),zs.forEach(o),Ms.forEach(o),br=h(sn),po=a(sn,"SPAN",{});var As=r(po);wr=i(As,"UniSpeechForPreTraining"),As.forEach(o),sn.forEach(o),Wo=h(t),q=a(t,"DIV",{class:!0});var N=r(q);y(dt.$$.fragment,N),yr=h(N),pt=a(N,"P",{});var ln=r(pt);Sr=i(ln,`UniSpeech Model with a vector-quantization module and ctc loss for pre-training.
UniSpeech was proposed in `),ht=a(ln,"A",{href:!0,rel:!0});var Os=r(ht);Tr=i(Os,`UniSpeech: Unified Speech Representation Learning with Labeled and Unlabeled
Data`),Os.forEach(o),$r=i(ln,` by Chengyi Wang, Yu Wu, Yao Qian, Kenichi Kumatani, Shujie Liu, Furu Wei,
Michael Zeng, Xuedong Huang.`),ln.forEach(o),kr=h(N),mt=a(N,"P",{});var cn=r(mt);Ur=i(cn,"This model inherits from "),Mt=a(cn,"A",{href:!0});var Ds=r(Mt);Cr=i(Ds,"PreTrainedModel"),Ds.forEach(o),xr=i(cn,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving etc.).`),cn.forEach(o),Fr=h(N),ut=a(N,"P",{});var dn=r(ut);jr=i(dn,"This model is a PyTorch "),ft=a(dn,"A",{href:!0,rel:!0});var Ls=r(ft);qr=i(Ls,"torch.nn.Module"),Ls.forEach(o),Pr=i(dn,` sub-class. Use
it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage and
behavior.`),dn.forEach(o),Er=h(N),A=a(N,"DIV",{class:!0});var Ue=r(A);y(gt.$$.fragment,Ue),Mr=h(Ue),ne=a(Ue,"P",{});var Vt=r(ne);zr=i(Vt,"The "),zt=a(Vt,"A",{href:!0});var Ws=r(zt);Ar=i(Ws,"UniSpeechForPreTraining"),Ws.forEach(o),Or=i(Vt," forward method, overrides the "),ho=a(Vt,"CODE",{});var Ns=r(ho);Dr=i(Ns,"__call__"),Ns.forEach(o),Lr=i(Vt," special method."),Vt.forEach(o),Wr=h(Ue),y(we.$$.fragment,Ue),Nr=h(Ue),y(ye.$$.fragment,Ue),Ue.forEach(o),N.forEach(o),this.h()},h(){c(d,"name","hf:doc:metadata"),c(d,"content",JSON.stringify(ni)),c(u,"id","unispeech"),c(u,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(u,"href","#unispeech"),c(g,"class","relative group"),c(ae,"id","overview"),c(ae,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(ae,"href","#overview"),c(V,"class","relative group"),c(Fe,"href","https://arxiv.org/abs/2101.07597"),c(Fe,"rel","nofollow"),c(Tt,"href","/docs/transformers/main/en/model_doc/wav2vec2#transformers.Wav2Vec2Processor"),c($t,"href","/docs/transformers/main/en/model_doc/wav2vec2#transformers.Wav2Vec2CTCTokenizer"),c(Pe,"href","https://huggingface.co/patrickvonplaten"),c(Pe,"rel","nofollow"),c(Ee,"href","https://github.com/microsoft/UniSpeech/tree/main/UniSpeech"),c(Ee,"rel","nofollow"),c(ie,"id","transformers.UniSpeechConfig"),c(ie,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(ie,"href","#transformers.UniSpeechConfig"),c(H,"class","relative group"),c(kt,"href","/docs/transformers/main/en/model_doc/unispeech#transformers.UniSpeechModel"),c(Ae,"href","https://huggingface.co/microsoft/unispeech-large-1500h-cv"),c(Ae,"rel","nofollow"),c(Ut,"href","/docs/transformers/main/en/main_classes/configuration#transformers.PretrainedConfig"),c(Ct,"href","/docs/transformers/main/en/main_classes/configuration#transformers.PretrainedConfig"),c(P,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ce,"id","transformers.models.unispeech.modeling_unispeech.UniSpeechForPreTrainingOutput"),c(ce,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(ce,"href","#transformers.models.unispeech.modeling_unispeech.UniSpeechForPreTrainingOutput"),c(R,"class","relative group"),c(B,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(de,"id","transformers.UniSpeechModel"),c(de,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(de,"href","#transformers.UniSpeechModel"),c(Q,"class","relative group"),c(Ve,"href","https://arxiv.org/abs/2101.07597"),c(Ve,"rel","nofollow"),c(xt,"href","/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel"),c(Ye,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(Ye,"rel","nofollow"),c(Ft,"href","/docs/transformers/main/en/model_doc/unispeech#transformers.UniSpeechModel"),c(E,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(F,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(me,"id","transformers.UniSpeechForCTC"),c(me,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(me,"href","#transformers.UniSpeechForCTC"),c(Z,"class","relative group"),c(Xe,"href","https://arxiv.org/abs/2101.07597"),c(Xe,"rel","nofollow"),c(jt,"href","/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel"),c(Je,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(Je,"rel","nofollow"),c(qt,"href","/docs/transformers/main/en/model_doc/unispeech#transformers.UniSpeechForCTC"),c(M,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(j,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ge,"id","transformers.UniSpeechForSequenceClassification"),c(ge,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(ge,"href","#transformers.UniSpeechForSequenceClassification"),c(ee,"class","relative group"),c(at,"href","https://arxiv.org/abs/2101.07597"),c(at,"rel","nofollow"),c(Pt,"href","/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel"),c(it,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(it,"rel","nofollow"),c(Et,"href","/docs/transformers/main/en/model_doc/unispeech#transformers.UniSpeechForSequenceClassification"),c(z,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(x,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(be,"id","transformers.UniSpeechForPreTraining"),c(be,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(be,"href","#transformers.UniSpeechForPreTraining"),c(oe,"class","relative group"),c(ht,"href","https://arxiv.org/abs/2101.07597"),c(ht,"rel","nofollow"),c(Mt,"href","/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel"),c(ft,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(ft,"rel","nofollow"),c(zt,"href","/docs/transformers/main/en/model_doc/unispeech#transformers.UniSpeechForPreTraining"),c(A,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(q,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8")},m(t,f){e(document.head,d),_(t,b,f),_(t,g,f),e(g,u),e(u,v),S(l,v,null),e(g,m),e(g,C),e(C,hn),_(t,So,f),_(t,V,f),e(V,ae),e(ae,Ht),S(xe,Ht,null),e(V,mn),e(V,Kt),e(Kt,un),_(t,To,f),_(t,re,f),e(re,fn),e(re,Fe),e(Fe,gn),e(re,_n),_(t,$o,f),_(t,wt,f),e(wt,vn),_(t,ko,f),_(t,yt,f),e(yt,Yt),e(Yt,bn),_(t,Uo,f),_(t,St,f),e(St,wn),_(t,Co,f),_(t,se,f),e(se,je),e(je,yn),e(je,Tt),e(Tt,Sn),e(je,Tn),e(se,$n),e(se,qe),e(qe,kn),e(qe,$t),e($t,Un),e(qe,Cn),_(t,xo,f),_(t,D,f),e(D,xn),e(D,Pe),e(Pe,Fn),e(D,jn),e(D,Ee),e(Ee,qn),e(D,Pn),_(t,Fo,f),_(t,H,f),e(H,ie),e(ie,Rt),S(Me,Rt,null),e(H,En),e(H,Bt),e(Bt,Mn),_(t,jo,f),_(t,P,f),S(ze,P,null),e(P,zn),e(P,K),e(K,An),e(K,kt),e(kt,On),e(K,Dn),e(K,Ae),e(Ae,Ln),e(K,Wn),e(P,Nn),e(P,Y),e(Y,In),e(Y,Ut),e(Ut,Vn),e(Y,Hn),e(Y,Ct),e(Ct,Kn),e(Y,Yn),e(P,Rn),S(le,P,null),_(t,qo,f),_(t,R,f),e(R,ce),e(ce,Qt),S(Oe,Qt,null),e(R,Bn),e(R,Xt),e(Xt,Qn),_(t,Po,f),_(t,B,f),S(De,B,null),e(B,Xn),e(B,Le),e(Le,Zn),e(Le,Zt),e(Zt,Gn),e(Le,Jn),_(t,Eo,f),_(t,Q,f),e(Q,de),e(de,Gt),S(We,Gt,null),e(Q,ea),e(Q,Jt),e(Jt,ta),_(t,Mo,f),_(t,F,f),S(Ne,F,null),e(F,oa),e(F,Ie),e(Ie,na),e(Ie,Ve),e(Ve,aa),e(Ie,ra),e(F,sa),e(F,He),e(He,ia),e(He,xt),e(xt,la),e(He,ca),e(F,da),e(F,Ke),e(Ke,pa),e(Ke,Ye),e(Ye,ha),e(Ke,ma),e(F,ua),e(F,E),S(Re,E,null),e(E,fa),e(E,X),e(X,ga),e(X,Ft),e(Ft,_a),e(X,va),e(X,eo),e(eo,ba),e(X,wa),e(E,ya),S(pe,E,null),e(E,Sa),S(he,E,null),_(t,zo,f),_(t,Z,f),e(Z,me),e(me,to),S(Be,to,null),e(Z,Ta),e(Z,oo),e(oo,$a),_(t,Ao,f),_(t,j,f),S(Qe,j,null),e(j,ka),e(j,G),e(G,Ua),e(G,no),e(no,Ca),e(G,xa),e(G,Xe),e(Xe,Fa),e(G,ja),e(j,qa),e(j,Ze),e(Ze,Pa),e(Ze,jt),e(jt,Ea),e(Ze,Ma),e(j,za),e(j,Ge),e(Ge,Aa),e(Ge,Je),e(Je,Oa),e(Ge,Da),e(j,La),e(j,M),S(et,M,null),e(M,Wa),e(M,J),e(J,Na),e(J,qt),e(qt,Ia),e(J,Va),e(J,ao),e(ao,Ha),e(J,Ka),e(M,Ya),S(ue,M,null),e(M,Ra),S(fe,M,null),_(t,Oo,f),_(t,ee,f),e(ee,ge),e(ge,ro),S(tt,ro,null),e(ee,Ba),e(ee,so),e(so,Qa),_(t,Do,f),_(t,x,f),S(ot,x,null),e(x,Xa),e(x,io),e(io,Za),e(x,Ga),e(x,nt),e(nt,Ja),e(nt,at),e(at,er),e(nt,tr),e(x,or),e(x,rt),e(rt,nr),e(rt,Pt),e(Pt,ar),e(rt,rr),e(x,sr),e(x,st),e(st,ir),e(st,it),e(it,lr),e(st,cr),e(x,dr),e(x,z),S(lt,z,null),e(z,pr),e(z,te),e(te,hr),e(te,Et),e(Et,mr),e(te,ur),e(te,lo),e(lo,fr),e(te,gr),e(z,_r),S(_e,z,null),e(z,vr),S(ve,z,null),_(t,Lo,f),_(t,oe,f),e(oe,be),e(be,co),S(ct,co,null),e(oe,br),e(oe,po),e(po,wr),_(t,Wo,f),_(t,q,f),S(dt,q,null),e(q,yr),e(q,pt),e(pt,Sr),e(pt,ht),e(ht,Tr),e(pt,$r),e(q,kr),e(q,mt),e(mt,Ur),e(mt,Mt),e(Mt,Cr),e(mt,xr),e(q,Fr),e(q,ut),e(ut,jr),e(ut,ft),e(ft,qr),e(ut,Pr),e(q,Er),e(q,A),S(gt,A,null),e(A,Mr),e(A,ne),e(ne,zr),e(ne,zt),e(zt,Ar),e(ne,Or),e(ne,ho),e(ho,Dr),e(ne,Lr),e(A,Wr),S(we,A,null),e(A,Nr),S(ye,A,null),No=!0},p(t,[f]){const _t={};f&2&&(_t.$$scope={dirty:f,ctx:t}),le.$set(_t);const mo={};f&2&&(mo.$$scope={dirty:f,ctx:t}),pe.$set(mo);const uo={};f&2&&(uo.$$scope={dirty:f,ctx:t}),he.$set(uo);const fo={};f&2&&(fo.$$scope={dirty:f,ctx:t}),ue.$set(fo);const vt={};f&2&&(vt.$$scope={dirty:f,ctx:t}),fe.$set(vt);const go={};f&2&&(go.$$scope={dirty:f,ctx:t}),_e.$set(go);const _o={};f&2&&(_o.$$scope={dirty:f,ctx:t}),ve.$set(_o);const vo={};f&2&&(vo.$$scope={dirty:f,ctx:t}),we.$set(vo);const bt={};f&2&&(bt.$$scope={dirty:f,ctx:t}),ye.$set(bt)},i(t){No||(T(l.$$.fragment,t),T(xe.$$.fragment,t),T(Me.$$.fragment,t),T(ze.$$.fragment,t),T(le.$$.fragment,t),T(Oe.$$.fragment,t),T(De.$$.fragment,t),T(We.$$.fragment,t),T(Ne.$$.fragment,t),T(Re.$$.fragment,t),T(pe.$$.fragment,t),T(he.$$.fragment,t),T(Be.$$.fragment,t),T(Qe.$$.fragment,t),T(et.$$.fragment,t),T(ue.$$.fragment,t),T(fe.$$.fragment,t),T(tt.$$.fragment,t),T(ot.$$.fragment,t),T(lt.$$.fragment,t),T(_e.$$.fragment,t),T(ve.$$.fragment,t),T(ct.$$.fragment,t),T(dt.$$.fragment,t),T(gt.$$.fragment,t),T(we.$$.fragment,t),T(ye.$$.fragment,t),No=!0)},o(t){$(l.$$.fragment,t),$(xe.$$.fragment,t),$(Me.$$.fragment,t),$(ze.$$.fragment,t),$(le.$$.fragment,t),$(Oe.$$.fragment,t),$(De.$$.fragment,t),$(We.$$.fragment,t),$(Ne.$$.fragment,t),$(Re.$$.fragment,t),$(pe.$$.fragment,t),$(he.$$.fragment,t),$(Be.$$.fragment,t),$(Qe.$$.fragment,t),$(et.$$.fragment,t),$(ue.$$.fragment,t),$(fe.$$.fragment,t),$(tt.$$.fragment,t),$(ot.$$.fragment,t),$(lt.$$.fragment,t),$(_e.$$.fragment,t),$(ve.$$.fragment,t),$(ct.$$.fragment,t),$(dt.$$.fragment,t),$(gt.$$.fragment,t),$(we.$$.fragment,t),$(ye.$$.fragment,t),No=!1},d(t){o(d),t&&o(b),t&&o(g),k(l),t&&o(So),t&&o(V),k(xe),t&&o(To),t&&o(re),t&&o($o),t&&o(wt),t&&o(ko),t&&o(yt),t&&o(Uo),t&&o(St),t&&o(Co),t&&o(se),t&&o(xo),t&&o(D),t&&o(Fo),t&&o(H),k(Me),t&&o(jo),t&&o(P),k(ze),k(le),t&&o(qo),t&&o(R),k(Oe),t&&o(Po),t&&o(B),k(De),t&&o(Eo),t&&o(Q),k(We),t&&o(Mo),t&&o(F),k(Ne),k(Re),k(pe),k(he),t&&o(zo),t&&o(Z),k(Be),t&&o(Ao),t&&o(j),k(Qe),k(et),k(ue),k(fe),t&&o(Oo),t&&o(ee),k(tt),t&&o(Do),t&&o(x),k(ot),k(lt),k(_e),k(ve),t&&o(Lo),t&&o(oe),k(ct),t&&o(Wo),t&&o(q),k(dt),k(gt),k(we),k(ye)}}}const ni={local:"unispeech",sections:[{local:"overview",title:"Overview"},{local:"transformers.UniSpeechConfig",title:"UniSpeechConfig"},{local:"transformers.models.unispeech.modeling_unispeech.UniSpeechForPreTrainingOutput",title:"UniSpeech specific outputs"},{local:"transformers.UniSpeechModel",title:"UniSpeechModel"},{local:"transformers.UniSpeechForCTC",title:"UniSpeechForCTC"},{local:"transformers.UniSpeechForSequenceClassification",title:"UniSpeechForSequenceClassification"},{local:"transformers.UniSpeechForPreTraining",title:"UniSpeechForPreTraining"}],title:"UniSpeech"};function ai(U){return Ys(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class pi extends Is{constructor(d){super();Vs(this,d,ai,oi,Hs,{})}}export{pi as default,ni as metadata};
