import{S as oi,i as si,s as ai,e as r,k as m,w,t as s,M as ri,c as n,d as o,m as h,a as i,x as $,h as a,b as c,G as e,g,y as T,q as y,o as k,B as I,v as ni,L as Vo}from"../../chunks/vendor-hf-doc-builder.js";import{T as fo}from"../../chunks/Tip-hf-doc-builder.js";import{D as $e}from"../../chunks/Docstring-hf-doc-builder.js";import{C as Wo}from"../../chunks/CodeBlock-hf-doc-builder.js";import{I as Ke}from"../../chunks/IconCopyLink-hf-doc-builder.js";import{E as So}from"../../chunks/ExampleCodeBlock-hf-doc-builder.js";import{P as ii}from"../../chunks/PipelineTag-hf-doc-builder.js";function li(x){let d,C,v,f,_;return f=new Wo({props:{code:`from transformers import CvtConfig, CvtModel

# Initializing a Cvt msft/cvt style configuration
configuration = CvtConfig()

# Initializing a model (with random weights) from the msft/cvt style configuration
model = CvtModel(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> CvtConfig, CvtModel

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Initializing a Cvt msft/cvt style configuration</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>configuration = CvtConfig()

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Initializing a model (with random weights) from the msft/cvt style configuration</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>model = CvtModel(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=r("p"),C=s("Example:"),v=m(),w(f.$$.fragment)},l(l){d=n(l,"P",{});var p=i(d);C=a(p,"Example:"),p.forEach(o),v=h(l),$(f.$$.fragment,l)},m(l,p){g(l,d,p),e(d,C),g(l,v,p),T(f,l,p),_=!0},p:Vo,i(l){_||(y(f.$$.fragment,l),_=!0)},o(l){k(f.$$.fragment,l),_=!1},d(l){l&&o(d),l&&o(v),I(f,l)}}}function di(x){let d,C,v,f,_;return{c(){d=r("p"),C=s("Although the recipe for forward pass needs to be defined within this function, one should call the "),v=r("code"),f=s("Module"),_=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=n(l,"P",{});var p=i(d);C=a(p,"Although the recipe for forward pass needs to be defined within this function, one should call the "),v=n(p,"CODE",{});var E=i(v);f=a(E,"Module"),E.forEach(o),_=a(p,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),p.forEach(o)},m(l,p){g(l,d,p),e(d,C),e(d,v),e(v,f),e(d,_)},d(l){l&&o(d)}}}function ci(x){let d,C,v,f,_;return f=new Wo({props:{code:`from transformers import AutoImageProcessor, CvtModel
import torch
from datasets import load_dataset

dataset = load_dataset("huggingface/cats-image")
image = dataset["test"]["image"][0]

image_processor = AutoImageProcessor.from_pretrained("microsoft/cvt-13")
model = CvtModel.from_pretrained("microsoft/cvt-13")

inputs = image_processor(image, 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> AutoImageProcessor, CvtModel
<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;huggingface/cats-image&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>image = dataset[<span class="hljs-string">&quot;test&quot;</span>][<span class="hljs-string">&quot;image&quot;</span>][<span class="hljs-number">0</span>]

<span class="hljs-meta">&gt;&gt;&gt; </span>image_processor = AutoImageProcessor.from_pretrained(<span class="hljs-string">&quot;microsoft/cvt-13&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = CvtModel.from_pretrained(<span class="hljs-string">&quot;microsoft/cvt-13&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = image_processor(image, 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">384</span>, <span class="hljs-number">14</span>, <span class="hljs-number">14</span>]`}}),{c(){d=r("p"),C=s("Example:"),v=m(),w(f.$$.fragment)},l(l){d=n(l,"P",{});var p=i(d);C=a(p,"Example:"),p.forEach(o),v=h(l),$(f.$$.fragment,l)},m(l,p){g(l,d,p),e(d,C),g(l,v,p),T(f,l,p),_=!0},p:Vo,i(l){_||(y(f.$$.fragment,l),_=!0)},o(l){k(f.$$.fragment,l),_=!1},d(l){l&&o(d),l&&o(v),I(f,l)}}}function fi(x){let d,C,v,f,_;return{c(){d=r("p"),C=s("Although the recipe for forward pass needs to be defined within this function, one should call the "),v=r("code"),f=s("Module"),_=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=n(l,"P",{});var p=i(d);C=a(p,"Although the recipe for forward pass needs to be defined within this function, one should call the "),v=n(p,"CODE",{});var E=i(v);f=a(E,"Module"),E.forEach(o),_=a(p,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),p.forEach(o)},m(l,p){g(l,d,p),e(d,C),e(d,v),e(v,f),e(d,_)},d(l){l&&o(d)}}}function mi(x){let d,C,v,f,_;return f=new Wo({props:{code:`from transformers import AutoImageProcessor, CvtForImageClassification
import torch
from datasets import load_dataset

dataset = load_dataset("huggingface/cats-image")
image = dataset["test"]["image"][0]

image_processor = AutoImageProcessor.from_pretrained("microsoft/cvt-13")
model = CvtForImageClassification.from_pretrained("microsoft/cvt-13")

inputs = image_processor(image, return_tensors="pt")

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

# model predicts one of the 1000 ImageNet classes
predicted_label = logits.argmax(-1).item()
print(model.config.id2label[predicted_label])`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoImageProcessor, CvtForImageClassification
<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;huggingface/cats-image&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>image = dataset[<span class="hljs-string">&quot;test&quot;</span>][<span class="hljs-string">&quot;image&quot;</span>][<span class="hljs-number">0</span>]

<span class="hljs-meta">&gt;&gt;&gt; </span>image_processor = AutoImageProcessor.from_pretrained(<span class="hljs-string">&quot;microsoft/cvt-13&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = CvtForImageClassification.from_pretrained(<span class="hljs-string">&quot;microsoft/cvt-13&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = image_processor(image, 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><span class="hljs-comment"># model predicts one of the 1000 ImageNet classes</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_label = logits.argmax(-<span class="hljs-number">1</span>).item()
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">print</span>(model.config.id2label[predicted_label])
tabby, tabby cat`}}),{c(){d=r("p"),C=s("Example:"),v=m(),w(f.$$.fragment)},l(l){d=n(l,"P",{});var p=i(d);C=a(p,"Example:"),p.forEach(o),v=h(l),$(f.$$.fragment,l)},m(l,p){g(l,d,p),e(d,C),g(l,v,p),T(f,l,p),_=!0},p:Vo,i(l){_||(y(f.$$.fragment,l),_=!0)},o(l){k(f.$$.fragment,l),_=!1},d(l){l&&o(d),l&&o(v),I(f,l)}}}function hi(x){let d,C,v,f,_,l,p,E,G,S,F,z,M,O,J,A,Q,R;return{c(){d=r("p"),C=s("TF 2.0 models accepts two formats as inputs:"),v=m(),f=r("ul"),_=r("li"),l=s("having all inputs as keyword arguments (like PyTorch models), or"),p=m(),E=r("li"),G=s("having all inputs as a list, tuple or dict in the first positional arguments."),S=m(),F=r("p"),z=s("This second option is useful when using "),M=r("code"),O=s("tf.keras.Model.fit"),J=s(` method which currently requires having all the
tensors in the first argument of the model call function: `),A=r("code"),Q=s("model(inputs)"),R=s(".")},l(b){d=n(b,"P",{});var j=i(d);C=a(j,"TF 2.0 models accepts two formats as inputs:"),j.forEach(o),v=h(b),f=n(b,"UL",{});var q=i(f);_=n(q,"LI",{});var ae=i(_);l=a(ae,"having all inputs as keyword arguments (like PyTorch models), or"),ae.forEach(o),p=h(q),E=n(q,"LI",{});var re=i(E);G=a(re,"having all inputs as a list, tuple or dict in the first positional arguments."),re.forEach(o),q.forEach(o),S=h(b),F=n(b,"P",{});var P=i(F);z=a(P,"This second option is useful when using "),M=n(P,"CODE",{});var ne=i(M);O=a(ne,"tf.keras.Model.fit"),ne.forEach(o),J=a(P,` method which currently requires having all the
tensors in the first argument of the model call function: `),A=n(P,"CODE",{});var ie=i(A);Q=a(ie,"model(inputs)"),ie.forEach(o),R=a(P,"."),P.forEach(o)},m(b,j){g(b,d,j),e(d,C),g(b,v,j),g(b,f,j),e(f,_),e(_,l),e(f,p),e(f,E),e(E,G),g(b,S,j),g(b,F,j),e(F,z),e(F,M),e(M,O),e(F,J),e(F,A),e(A,Q),e(F,R)},d(b){b&&o(d),b&&o(v),b&&o(f),b&&o(S),b&&o(F)}}}function pi(x){let d,C,v,f,_;return{c(){d=r("p"),C=s("Although the recipe for forward pass needs to be defined within this function, one should call the "),v=r("code"),f=s("Module"),_=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=n(l,"P",{});var p=i(d);C=a(p,"Although the recipe for forward pass needs to be defined within this function, one should call the "),v=n(p,"CODE",{});var E=i(v);f=a(E,"Module"),E.forEach(o),_=a(p,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),p.forEach(o)},m(l,p){g(l,d,p),e(d,C),e(d,v),e(v,f),e(d,_)},d(l){l&&o(d)}}}function ui(x){let d,C,v,f,_;return f=new Wo({props:{code:`from transformers import AutoImageProcessor, TFCvtModel
from PIL import Image
import requests

url = "http://images.cocodataset.org/val2017/000000039769.jpg"
image = Image.open(requests.get(url, stream=True).raw)

image_processor = AutoImageProcessor.from_pretrained("microsoft/cvt-13")
model = TFCvtModel.from_pretrained("microsoft/cvt-13")

inputs = image_processor(images=image, return_tensors="tf")
outputs = model(**inputs)
last_hidden_states = outputs.last_hidden_state`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoImageProcessor, TFCvtModel
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> PIL <span class="hljs-keyword">import</span> Image
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> requests

<span class="hljs-meta">&gt;&gt;&gt; </span>url = <span class="hljs-string">&quot;http://images.cocodataset.org/val2017/000000039769.jpg&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>image = Image.<span class="hljs-built_in">open</span>(requests.get(url, stream=<span class="hljs-literal">True</span>).raw)

<span class="hljs-meta">&gt;&gt;&gt; </span>image_processor = AutoImageProcessor.from_pretrained(<span class="hljs-string">&quot;microsoft/cvt-13&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFCvtModel.from_pretrained(<span class="hljs-string">&quot;microsoft/cvt-13&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = image_processor(images=image, return_tensors=<span class="hljs-string">&quot;tf&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs)
<span class="hljs-meta">&gt;&gt;&gt; </span>last_hidden_states = outputs.last_hidden_state`}}),{c(){d=r("p"),C=s("Examples:"),v=m(),w(f.$$.fragment)},l(l){d=n(l,"P",{});var p=i(d);C=a(p,"Examples:"),p.forEach(o),v=h(l),$(f.$$.fragment,l)},m(l,p){g(l,d,p),e(d,C),g(l,v,p),T(f,l,p),_=!0},p:Vo,i(l){_||(y(f.$$.fragment,l),_=!0)},o(l){k(f.$$.fragment,l),_=!1},d(l){l&&o(d),l&&o(v),I(f,l)}}}function gi(x){let d,C,v,f,_,l,p,E,G,S,F,z,M,O,J,A,Q,R;return{c(){d=r("p"),C=s("TF 2.0 models accepts two formats as inputs:"),v=m(),f=r("ul"),_=r("li"),l=s("having all inputs as keyword arguments (like PyTorch models), or"),p=m(),E=r("li"),G=s("having all inputs as a list, tuple or dict in the first positional arguments."),S=m(),F=r("p"),z=s("This second option is useful when using "),M=r("code"),O=s("tf.keras.Model.fit"),J=s(` method which currently requires having all the
tensors in the first argument of the model call function: `),A=r("code"),Q=s("model(inputs)"),R=s(".")},l(b){d=n(b,"P",{});var j=i(d);C=a(j,"TF 2.0 models accepts two formats as inputs:"),j.forEach(o),v=h(b),f=n(b,"UL",{});var q=i(f);_=n(q,"LI",{});var ae=i(_);l=a(ae,"having all inputs as keyword arguments (like PyTorch models), or"),ae.forEach(o),p=h(q),E=n(q,"LI",{});var re=i(E);G=a(re,"having all inputs as a list, tuple or dict in the first positional arguments."),re.forEach(o),q.forEach(o),S=h(b),F=n(b,"P",{});var P=i(F);z=a(P,"This second option is useful when using "),M=n(P,"CODE",{});var ne=i(M);O=a(ne,"tf.keras.Model.fit"),ne.forEach(o),J=a(P,` method which currently requires having all the
tensors in the first argument of the model call function: `),A=n(P,"CODE",{});var ie=i(A);Q=a(ie,"model(inputs)"),ie.forEach(o),R=a(P,"."),P.forEach(o)},m(b,j){g(b,d,j),e(d,C),g(b,v,j),g(b,f,j),e(f,_),e(_,l),e(f,p),e(f,E),e(E,G),g(b,S,j),g(b,F,j),e(F,z),e(F,M),e(M,O),e(F,J),e(F,A),e(A,Q),e(F,R)},d(b){b&&o(d),b&&o(v),b&&o(f),b&&o(S),b&&o(F)}}}function vi(x){let d,C,v,f,_;return{c(){d=r("p"),C=s("Although the recipe for forward pass needs to be defined within this function, one should call the "),v=r("code"),f=s("Module"),_=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=n(l,"P",{});var p=i(d);C=a(p,"Although the recipe for forward pass needs to be defined within this function, one should call the "),v=n(p,"CODE",{});var E=i(v);f=a(E,"Module"),E.forEach(o),_=a(p,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),p.forEach(o)},m(l,p){g(l,d,p),e(d,C),e(d,v),e(v,f),e(d,_)},d(l){l&&o(d)}}}function _i(x){let d,C,v,f,_;return f=new Wo({props:{code:`from transformers import AutoImageProcessor, TFCvtForImageClassification
import tensorflow as tf
from PIL import Image
import requests

url = "http://images.cocodataset.org/val2017/000000039769.jpg"
image = Image.open(requests.get(url, stream=True).raw)

image_processor = AutoImageProcessor.from_pretrained("microsoft/cvt-13")
model = TFCvtForImageClassification.from_pretrained("microsoft/cvt-13")

inputs = image_processor(images=image, return_tensors="tf")
outputs = model(**inputs)
logits = outputs.logits
# model predicts one of the 1000 ImageNet classes
predicted_class_idx = tf.math.argmax(logits, axis=-1)[0]
print("Predicted class:", model.config.id2label[int(predicted_class_idx)])`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoImageProcessor, TFCvtForImageClassification
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> tensorflow <span class="hljs-keyword">as</span> tf
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> PIL <span class="hljs-keyword">import</span> Image
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> requests

<span class="hljs-meta">&gt;&gt;&gt; </span>url = <span class="hljs-string">&quot;http://images.cocodataset.org/val2017/000000039769.jpg&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>image = Image.<span class="hljs-built_in">open</span>(requests.get(url, stream=<span class="hljs-literal">True</span>).raw)

<span class="hljs-meta">&gt;&gt;&gt; </span>image_processor = AutoImageProcessor.from_pretrained(<span class="hljs-string">&quot;microsoft/cvt-13&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFCvtForImageClassification.from_pretrained(<span class="hljs-string">&quot;microsoft/cvt-13&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = image_processor(images=image, return_tensors=<span class="hljs-string">&quot;tf&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs)
<span class="hljs-meta">&gt;&gt;&gt; </span>logits = outputs.logits
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># model predicts one of the 1000 ImageNet classes</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_class_idx = tf.math.argmax(logits, axis=-<span class="hljs-number">1</span>)[<span class="hljs-number">0</span>]
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">print</span>(<span class="hljs-string">&quot;Predicted class:&quot;</span>, model.config.id2label[<span class="hljs-built_in">int</span>(predicted_class_idx)])`}}),{c(){d=r("p"),C=s("Examples:"),v=m(),w(f.$$.fragment)},l(l){d=n(l,"P",{});var p=i(d);C=a(p,"Examples:"),p.forEach(o),v=h(l),$(f.$$.fragment,l)},m(l,p){g(l,d,p),e(d,C),g(l,v,p),T(f,l,p),_=!0},p:Vo,i(l){_||(y(f.$$.fragment,l),_=!0)},o(l){k(f.$$.fragment,l),_=!1},d(l){l&&o(d),l&&o(v),I(f,l)}}}function Ci(x){let d,C,v,f,_,l,p,E,G,S,F,z,M,O,J,A,Q,R,b,j,q,ae,re,P,ne,ie,Ro,Mt,ys,Ho,At,mo,ks,Uo,qt,Is,Bo,te,Xe,Fs,Lt,Es,xs,js,D,Ps,Ye,Ms,As,Nt,qs,Ls,zt,Ns,zs,Ot,Os,Ds,Dt,Ss,Vs,Ws,le,Rs,Ze,Hs,Us,Ge,Bs,Ks,Ko,oe,Xs,Je,Ys,Zs,Qe,Gs,Js,Xo,de,Te,ho,et,Qs,po,ea,Yo,St,ta,Zo,tt,Go,ye,se,Vt,oa,sa,ot,aa,ra,st,na,ia,la,Wt,da,Rt,ca,Jo,Ht,fa,Qo,ce,ke,uo,at,ma,go,ha,es,V,rt,pa,fe,ua,Ut,ga,va,nt,_a,Ca,ba,me,wa,Bt,$a,Ta,Kt,ya,ka,Ia,Ie,ts,he,Fe,vo,it,Fa,_o,Ea,os,ee,lt,xa,dt,ja,ct,Pa,Ma,Aa,H,ft,qa,pe,La,Xt,Na,za,Co,Oa,Da,Sa,Ee,Va,xe,ss,ue,je,bo,mt,Wa,wo,Ra,as,W,ht,Ha,$o,Ua,Ba,pt,Ka,ut,Xa,Ya,Za,U,gt,Ga,ge,Ja,Yt,Qa,er,To,tr,or,sr,Pe,ar,Me,rs,ve,Ae,yo,vt,rr,ko,nr,ns,L,_t,ir,Io,lr,dr,Ct,cr,Zt,fr,mr,hr,bt,pr,wt,ur,gr,vr,qe,_r,B,$t,Cr,_e,br,Gt,wr,$r,Fo,Tr,yr,kr,Le,Ir,Ne,is,Ce,ze,Eo,Tt,Fr,xo,Er,ls,N,yt,xr,jo,jr,Pr,kt,Mr,Jt,Ar,qr,Lr,It,Nr,Ft,zr,Or,Dr,Oe,Sr,K,Et,Vr,be,Wr,Qt,Rr,Hr,Po,Ur,Br,Kr,De,Xr,Se,ds;return l=new Ke({}),O=new Ke({}),et=new Ke({}),tt=new ii({props:{pipeline:"image-classification"}}),at=new Ke({}),rt=new $e({props:{name:"class transformers.CvtConfig",anchor:"transformers.CvtConfig",parameters:[{name:"num_channels",val:" = 3"},{name:"patch_sizes",val:" = [7, 3, 3]"},{name:"patch_stride",val:" = [4, 2, 2]"},{name:"patch_padding",val:" = [2, 1, 1]"},{name:"embed_dim",val:" = [64, 192, 384]"},{name:"num_heads",val:" = [1, 3, 6]"},{name:"depth",val:" = [1, 2, 10]"},{name:"mlp_ratio",val:" = [4.0, 4.0, 4.0]"},{name:"attention_drop_rate",val:" = [0.0, 0.0, 0.0]"},{name:"drop_rate",val:" = [0.0, 0.0, 0.0]"},{name:"drop_path_rate",val:" = [0.0, 0.0, 0.1]"},{name:"qkv_bias",val:" = [True, True, True]"},{name:"cls_token",val:" = [False, False, True]"},{name:"qkv_projection_method",val:" = ['dw_bn', 'dw_bn', 'dw_bn']"},{name:"kernel_qkv",val:" = [3, 3, 3]"},{name:"padding_kv",val:" = [1, 1, 1]"},{name:"stride_kv",val:" = [2, 2, 2]"},{name:"padding_q",val:" = [1, 1, 1]"},{name:"stride_q",val:" = [1, 1, 1]"},{name:"initializer_range",val:" = 0.02"},{name:"layer_norm_eps",val:" = 1e-12"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.CvtConfig.num_channels",description:`<strong>num_channels</strong> (<code>int</code>, <em>optional</em>, defaults to 3) &#x2014;
The number of input channels.`,name:"num_channels"},{anchor:"transformers.CvtConfig.patch_sizes",description:`<strong>patch_sizes</strong> (<code>List[int]</code>, <em>optional</em>, defaults to <code>[7, 3, 3]</code>) &#x2014;
The kernel size of each encoder&#x2019;s patch embedding.`,name:"patch_sizes"},{anchor:"transformers.CvtConfig.patch_stride",description:`<strong>patch_stride</strong> (<code>List[int]</code>, <em>optional</em>, defaults to <code>[4, 2, 2]</code>) &#x2014;
The stride size of each encoder&#x2019;s patch embedding.`,name:"patch_stride"},{anchor:"transformers.CvtConfig.patch_padding",description:`<strong>patch_padding</strong> (<code>List[int]</code>, <em>optional</em>, defaults to <code>[2, 1, 1]</code>) &#x2014;
The padding size of each encoder&#x2019;s patch embedding.`,name:"patch_padding"},{anchor:"transformers.CvtConfig.embed_dim",description:`<strong>embed_dim</strong> (<code>List[int]</code>, <em>optional</em>, defaults to <code>[64, 192, 384]</code>) &#x2014;
Dimension of each of the encoder blocks.`,name:"embed_dim"},{anchor:"transformers.CvtConfig.num_heads",description:`<strong>num_heads</strong> (<code>List[int]</code>, <em>optional</em>, defaults to <code>[1, 3, 6]</code>) &#x2014;
Number of attention heads for each attention layer in each block of the Transformer encoder.`,name:"num_heads"},{anchor:"transformers.CvtConfig.depth",description:`<strong>depth</strong> (<code>List[int]</code>, <em>optional</em>, defaults to <code>[1, 2, 10]</code>) &#x2014;
The number of layers in each encoder block.`,name:"depth"},{anchor:"transformers.CvtConfig.mlp_ratios",description:`<strong>mlp_ratios</strong> (<code>List[float]</code>, <em>optional</em>, defaults to <code>[4.0, 4.0, 4.0, 4.0]</code>) &#x2014;
Ratio of the size of the hidden layer compared to the size of the input layer of the Mix FFNs in the
encoder blocks.`,name:"mlp_ratios"},{anchor:"transformers.CvtConfig.attention_drop_rate",description:`<strong>attention_drop_rate</strong> (<code>List[float]</code>, <em>optional</em>, defaults to <code>[0.0, 0.0, 0.0]</code>) &#x2014;
The dropout ratio for the attention probabilities.`,name:"attention_drop_rate"},{anchor:"transformers.CvtConfig.drop_rate",description:`<strong>drop_rate</strong> (<code>List[float]</code>, <em>optional</em>, defaults to <code>[0.0, 0.0, 0.0]</code>) &#x2014;
The dropout ratio for the patch embeddings probabilities.`,name:"drop_rate"},{anchor:"transformers.CvtConfig.drop_path_rate",description:`<strong>drop_path_rate</strong> (<code>List[float]</code>, <em>optional</em>, defaults to <code>[0.0, 0.0, 0.1]</code>) &#x2014;
The dropout probability for stochastic depth, used in the blocks of the Transformer encoder.`,name:"drop_path_rate"},{anchor:"transformers.CvtConfig.qkv_bias",description:`<strong>qkv_bias</strong> (<code>List[bool]</code>, <em>optional</em>, defaults to <code>[True, True, True]</code>) &#x2014;
The bias bool for query, key and value in attentions`,name:"qkv_bias"},{anchor:"transformers.CvtConfig.cls_token",description:`<strong>cls_token</strong> (<code>List[bool]</code>, <em>optional</em>, defaults to <code>[False, False, True]</code>) &#x2014;
Whether or not to add a classification token to the output of each of the last 3 stages.`,name:"cls_token"},{anchor:"transformers.CvtConfig.qkv_projection_method",description:`<strong>qkv_projection_method</strong> (<code>List[string]</code>, <em>optional</em>, defaults to [&#x201C;dw_bn&#x201D;, &#x201C;dw_bn&#x201D;, &#x201C;dw_bn&#x201D;]\`) &#x2014;
The projection method for query, key and value Default is depth-wise convolutions with batch norm. For
Linear projection use &#x201C;avg&#x201D;.`,name:"qkv_projection_method"},{anchor:"transformers.CvtConfig.kernel_qkv",description:`<strong>kernel_qkv</strong> (<code>List[int]</code>, <em>optional</em>, defaults to <code>[3, 3, 3]</code>) &#x2014;
The kernel size for query, key and value in attention layer`,name:"kernel_qkv"},{anchor:"transformers.CvtConfig.padding_kv",description:`<strong>padding_kv</strong> (<code>List[int]</code>, <em>optional</em>, defaults to <code>[1, 1, 1]</code>) &#x2014;
The padding size for key and value in attention layer`,name:"padding_kv"},{anchor:"transformers.CvtConfig.stride_kv",description:`<strong>stride_kv</strong> (<code>List[int]</code>, <em>optional</em>, defaults to <code>[2, 2, 2]</code>) &#x2014;
The stride size for key and value in attention layer`,name:"stride_kv"},{anchor:"transformers.CvtConfig.padding_q",description:`<strong>padding_q</strong> (<code>List[int]</code>, <em>optional</em>, defaults to <code>[1, 1, 1]</code>) &#x2014;
The padding size for query in attention layer`,name:"padding_q"},{anchor:"transformers.CvtConfig.stride_q",description:`<strong>stride_q</strong> (<code>List[int]</code>, <em>optional</em>, defaults to <code>[1, 1, 1]</code>) &#x2014;
The stride size for query in attention layer`,name:"stride_q"},{anchor:"transformers.CvtConfig.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.CvtConfig.layer_norm_eps",description:`<strong>layer_norm_eps</strong> (<code>float</code>, <em>optional</em>, defaults to 1e-6) &#x2014;
The epsilon used by the layer normalization layers.`,name:"layer_norm_eps"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/cvt/configuration_cvt.py#L29"}}),Ie=new So({props:{anchor:"transformers.CvtConfig.example",$$slots:{default:[li]},$$scope:{ctx:x}}}),it=new Ke({}),lt=new $e({props:{name:"class transformers.CvtModel",anchor:"transformers.CvtModel",parameters:[{name:"config",val:""},{name:"add_pooling_layer",val:" = True"}],parametersDescription:[{anchor:"transformers.CvtModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/cvt#transformers.CvtConfig">CvtConfig</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/v4.29.0/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/v4.29.0/src/transformers/models/cvt/modeling_cvt.py#L590"}}),ft=new $e({props:{name:"forward",anchor:"transformers.CvtModel.forward",parameters:[{name:"pixel_values",val:": typing.Optional[torch.Tensor] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"}],parametersDescription:[{anchor:"transformers.CvtModel.forward.pixel_values",description:`<strong>pixel_values</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, num_channels, height, width)</code>) &#x2014;
Pixel values. Pixel values can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoImageProcessor">AutoImageProcessor</a>. See <code>CvtImageProcessor.__call__</code>
for details.`,name:"pixel_values"},{anchor:"transformers.CvtModel.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.CvtModel.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/v4.29.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/cvt/modeling_cvt.py#L605",returnDescription:`
<p>A <code>transformers.models.cvt.modeling_cvt.BaseModelOutputWithCLSToken</code> 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/v4.29.0/en/model_doc/cvt#transformers.CvtConfig"
>CvtConfig</a>) and inputs.</p>
<ul>
<li><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.</li>
<li><strong>cls_token_value</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, 1, hidden_size)</code>) \u2014 Classification token at the output of the last layer of the model.</li>
<li><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>. Hidden-states of the model at the output of each layer
plus the initial embedding outputs.</li>
</ul>
`,returnType:`
<p><code>transformers.models.cvt.modeling_cvt.BaseModelOutputWithCLSToken</code> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Ee=new fo({props:{$$slots:{default:[di]},$$scope:{ctx:x}}}),xe=new So({props:{anchor:"transformers.CvtModel.forward.example",$$slots:{default:[ci]},$$scope:{ctx:x}}}),mt=new Ke({}),ht=new $e({props:{name:"class transformers.CvtForImageClassification",anchor:"transformers.CvtForImageClassification",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.CvtForImageClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/cvt#transformers.CvtConfig">CvtConfig</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/v4.29.0/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/v4.29.0/src/transformers/models/cvt/modeling_cvt.py#L651"}}),gt=new $e({props:{name:"forward",anchor:"transformers.CvtForImageClassification.forward",parameters:[{name:"pixel_values",val:": typing.Optional[torch.Tensor] = None"},{name:"labels",val:": typing.Optional[torch.Tensor] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"}],parametersDescription:[{anchor:"transformers.CvtForImageClassification.forward.pixel_values",description:`<strong>pixel_values</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, num_channels, height, width)</code>) &#x2014;
Pixel values. Pixel values can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoImageProcessor">AutoImageProcessor</a>. See <code>CvtImageProcessor.__call__</code>
for details.`,name:"pixel_values"},{anchor:"transformers.CvtForImageClassification.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.CvtForImageClassification.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/v4.29.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.CvtForImageClassification.forward.labels",description:`<strong>labels</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for computing the image 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/v4.29.0/src/transformers/models/cvt/modeling_cvt.py#L666",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_outputs.ImageClassifierOutputWithNoAttention"
>transformers.modeling_outputs.ImageClassifierOutputWithNoAttention</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/v4.29.0/en/model_doc/cvt#transformers.CvtConfig"
>CvtConfig</a>) and inputs.</p>
<ul>
<li><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.</li>
<li><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).</li>
<li><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 stage) of shape <code>(batch_size, num_channels, height, width)</code>. Hidden-states (also
called feature maps) of the model at the output of each stage.</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_outputs.ImageClassifierOutputWithNoAttention"
>transformers.modeling_outputs.ImageClassifierOutputWithNoAttention</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),Pe=new fo({props:{$$slots:{default:[fi]},$$scope:{ctx:x}}}),Me=new So({props:{anchor:"transformers.CvtForImageClassification.forward.example",$$slots:{default:[mi]},$$scope:{ctx:x}}}),vt=new Ke({}),_t=new $e({props:{name:"class transformers.TFCvtModel",anchor:"transformers.TFCvtModel",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFCvtModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/cvt#transformers.CvtConfig">CvtConfig</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/v4.29.0/en/main_classes/model#transformers.TFPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/cvt/modeling_tf_cvt.py#L789"}}),qe=new fo({props:{$$slots:{default:[hi]},$$scope:{ctx:x}}}),$t=new $e({props:{name:"call",anchor:"transformers.TFCvtModel.call",parameters:[{name:"pixel_values",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"training",val:": typing.Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFCvtModel.call.pixel_values",description:`<strong>pixel_values</strong> (<code>np.ndarray</code>, <code>tf.Tensor</code>, <code>List[tf.Tensor]</code> \`<code>Dict[str, tf.Tensor]</code> or <code>Dict[str, np.ndarray]</code> and each example must have the shape <code>(batch_size, num_channels, height, width)</code>) &#x2014;
Pixel values. Pixel values can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoImageProcessor">AutoImageProcessor</a>. See <code>CvtImageProcessor.__call__</code>
for details.`,name:"pixel_values"},{anchor:"transformers.TFCvtModel.call.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. This argument can be used only in eager mode, in graph mode the value in the config will be
used instead.`,name:"output_hidden_states"},{anchor:"transformers.TFCvtModel.call.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple. This argument can be used in
eager mode, in graph mode the value will always be set to True.`,name:"return_dict"},{anchor:"transformers.TFCvtModel.call.training",description:`<strong>training</strong> (<code>bool</code>, <em>optional</em>, defaults to \`False&#x201C;) &#x2014;
Whether or not to use the model in training mode (some modules like dropout modules have different
behaviors between training and evaluation).`,name:"training"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/cvt/modeling_tf_cvt.py#L795",returnDescription:`
<p>A <code>transformers.models.cvt.modeling_tf_cvt.TFBaseModelOutputWithCLSToken</code> or a tuple of <code>tf.Tensor</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/v4.29.0/en/model_doc/cvt#transformers.CvtConfig"
>CvtConfig</a>) and inputs.</p>
<ul>
<li><strong>last_hidden_state</strong> (<code>tf.Tensor</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.</li>
<li><strong>cls_token_value</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, 1, hidden_size)</code>) \u2014 Classification token at the output of the last layer of the model.</li>
<li><strong>hidden_states</strong> (<code>tuple(tf.Tensor)</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>tf.Tensor</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>. Hidden-states of the model at the output of each layer plus
the initial embedding outputs.</li>
</ul>
`,returnType:`
<p><code>transformers.models.cvt.modeling_tf_cvt.TFBaseModelOutputWithCLSToken</code> or <code>tuple(tf.Tensor)</code></p>
`}}),Le=new fo({props:{$$slots:{default:[pi]},$$scope:{ctx:x}}}),Ne=new So({props:{anchor:"transformers.TFCvtModel.call.example",$$slots:{default:[ui]},$$scope:{ctx:x}}}),Tt=new Ke({}),yt=new $e({props:{name:"class transformers.TFCvtForImageClassification",anchor:"transformers.TFCvtForImageClassification",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFCvtForImageClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/cvt#transformers.CvtConfig">CvtConfig</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/v4.29.0/en/main_classes/model#transformers.TFPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/cvt/modeling_tf_cvt.py#L860"}}),Oe=new fo({props:{$$slots:{default:[gi]},$$scope:{ctx:x}}}),Et=new $e({props:{name:"call",anchor:"transformers.TFCvtForImageClassification.call",parameters:[{name:"pixel_values",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = None"},{name:"labels",val:": typing.Optional[tensorflow.python.framework.ops.Tensor] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"training",val:": typing.Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFCvtForImageClassification.call.pixel_values",description:`<strong>pixel_values</strong> (<code>np.ndarray</code>, <code>tf.Tensor</code>, <code>List[tf.Tensor]</code> \`<code>Dict[str, tf.Tensor]</code> or <code>Dict[str, np.ndarray]</code> and each example must have the shape <code>(batch_size, num_channels, height, width)</code>) &#x2014;
Pixel values. Pixel values can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoImageProcessor">AutoImageProcessor</a>. See <code>CvtImageProcessor.__call__</code>
for details.`,name:"pixel_values"},{anchor:"transformers.TFCvtForImageClassification.call.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. This argument can be used only in eager mode, in graph mode the value in the config will be
used instead.`,name:"output_hidden_states"},{anchor:"transformers.TFCvtForImageClassification.call.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple. This argument can be used in
eager mode, in graph mode the value will always be set to True.`,name:"return_dict"},{anchor:"transformers.TFCvtForImageClassification.call.training",description:`<strong>training</strong> (<code>bool</code>, <em>optional</em>, defaults to \`False&#x201C;) &#x2014;
Whether or not to use the model in training mode (some modules like dropout modules have different
behaviors between training and evaluation).`,name:"training"},{anchor:"transformers.TFCvtForImageClassification.call.labels",description:`<strong>labels</strong> (<code>tf.Tensor</code> or <code>np.ndarray</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for computing the image 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/v4.29.0/src/transformers/models/cvt/modeling_tf_cvt.py#L878",returnDescription:`
<p>A <code>transformers.modeling_tf_outputs.TFImageClassifierOutputWithNoAttention</code> or a tuple of <code>tf.Tensor</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/v4.29.0/en/model_doc/cvt#transformers.CvtConfig"
>CvtConfig</a>) and inputs.</p>
<ul>
<li><strong>loss</strong> (<code>tf.Tensor</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.</li>
<li><strong>logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, config.num_labels)</code>) \u2014 Classification (or regression if config.num_labels==1) scores (before SoftMax).</li>
<li><strong>hidden_states</strong> (<code>tuple(tf.Tensor)</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>tf.Tensor</code> (one for the output of the embeddings, if the model has an embedding layer, + one for
the output of each stage) of shape <code>(batch_size, num_channels, height, width)</code>. Hidden-states (also called
feature maps) of the model at the output of each stage.</li>
</ul>
`,returnType:`
<p><code>transformers.modeling_tf_outputs.TFImageClassifierOutputWithNoAttention</code> or <code>tuple(tf.Tensor)</code></p>
`}}),De=new fo({props:{$$slots:{default:[vi]},$$scope:{ctx:x}}}),Se=new So({props:{anchor:"transformers.TFCvtForImageClassification.call.example",$$slots:{default:[_i]},$$scope:{ctx:x}}}),{c(){d=r("meta"),C=m(),v=r("h1"),f=r("a"),_=r("span"),w(l.$$.fragment),p=m(),E=r("span"),G=s("Convolutional Vision Transformer (CvT)"),S=m(),F=r("h2"),z=r("a"),M=r("span"),w(O.$$.fragment),J=m(),A=r("span"),Q=s("Overview"),R=m(),b=r("p"),j=s("The CvT model was proposed in "),q=r("a"),ae=s("CvT: Introducing Convolutions to Vision Transformers"),re=s(" by Haiping Wu, Bin Xiao, Noel Codella, Mengchen Liu, Xiyang Dai, Lu Yuan and Lei Zhang. The Convolutional vision Transformer (CvT) improves the "),P=r("a"),ne=s("Vision Transformer (ViT)"),ie=s(" in performance and efficiency by introducing convolutions into ViT to yield the best of both designs."),Ro=m(),Mt=r("p"),ys=s("The abstract from the paper is the following:"),Ho=m(),At=r("p"),mo=r("em"),ks=s(`We present in this paper a new architecture, named Convolutional vision Transformer (CvT), that improves Vision Transformer (ViT)
in performance and efficiency by introducing convolutions into ViT to yield the best of both designs. This is accomplished through
two primary modifications: a hierarchy of Transformers containing a new convolutional token embedding, and a convolutional Transformer
block leveraging a convolutional projection. These changes introduce desirable properties of convolutional neural networks (CNNs)
to the ViT architecture (\\ie shift, scale, and distortion invariance) while maintaining the merits of Transformers (\\ie dynamic attention,
global context, and better generalization). We validate CvT by conducting extensive experiments, showing that this approach achieves
state-of-the-art performance over other Vision Transformers and ResNets on ImageNet-1k, with fewer parameters and lower FLOPs. In addition,
performance gains are maintained when pretrained on larger datasets (\\eg ImageNet-22k) and fine-tuned to downstream tasks. Pre-trained on
ImageNet-22k, our CvT-W24 obtains a top-1 accuracy of 87.7\\% on the ImageNet-1k val set. Finally, our results show that the positional encoding,
a crucial component in existing Vision Transformers, can be safely removed in our model, simplifying the design for higher resolution vision tasks.`),Uo=m(),qt=r("p"),Is=s("Tips:"),Bo=m(),te=r("ul"),Xe=r("li"),Fs=s("CvT models are regular Vision Transformers, but trained with convolutions. They outperform the "),Lt=r("a"),Es=s("original model (ViT)"),xs=s(" when fine-tuned on ImageNet-1K and CIFAR-100."),js=m(),D=r("li"),Ps=s("You can check out demo notebooks regarding inference as well as fine-tuning on custom data "),Ye=r("a"),Ms=s("here"),As=s(" (you can just replace "),Nt=r("a"),qs=s("ViTFeatureExtractor"),Ls=s(" by "),zt=r("a"),Ns=s("AutoImageProcessor"),zs=s(" and "),Ot=r("a"),Os=s("ViTForImageClassification"),Ds=s(" by "),Dt=r("a"),Ss=s("CvtForImageClassification"),Vs=s(")."),Ws=m(),le=r("li"),Rs=s("The available checkpoints are either (1) pre-trained on "),Ze=r("a"),Hs=s("ImageNet-22k"),Us=s(" (a collection of 14 million images and 22k classes) only, (2) also fine-tuned on ImageNet-22k or (3) also fine-tuned on "),Ge=r("a"),Bs=s("ImageNet-1k"),Ks=s(` (also referred to as ILSVRC 2012, a collection of 1.3 million
images and 1,000 classes).`),Ko=m(),oe=r("p"),Xs=s("This model was contributed by "),Je=r("a"),Ys=s("anugunj"),Zs=s(". The original code can be found "),Qe=r("a"),Gs=s("here"),Js=s("."),Xo=m(),de=r("h2"),Te=r("a"),ho=r("span"),w(et.$$.fragment),Qs=m(),po=r("span"),ea=s("Resources"),Yo=m(),St=r("p"),ta=s("A list of official Hugging Face and community (indicated by \u{1F30E}) resources to help you get started with CvT."),Zo=m(),w(tt.$$.fragment),Go=m(),ye=r("ul"),se=r("li"),Vt=r("a"),oa=s("CvtForImageClassification"),sa=s(" is supported by this "),ot=r("a"),aa=s("example script"),ra=s(" and "),st=r("a"),na=s("notebook"),ia=s("."),la=m(),Wt=r("li"),da=s("See also: "),Rt=r("a"),ca=s("Image classification task guide"),Jo=m(),Ht=r("p"),fa=s("If you\u2019re interested in submitting a resource to be included here, please feel free to open a Pull Request and we\u2019ll review it! The resource should ideally demonstrate something new instead of duplicating an existing resource."),Qo=m(),ce=r("h2"),ke=r("a"),uo=r("span"),w(at.$$.fragment),ma=m(),go=r("span"),ha=s("CvtConfig"),es=m(),V=r("div"),w(rt.$$.fragment),pa=m(),fe=r("p"),ua=s("This is the configuration class to store the configuration of a "),Ut=r("a"),ga=s("CvtModel"),va=s(`. It is used to instantiate a CvT 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 CvT
`),nt=r("a"),_a=s("microsoft/cvt-13"),Ca=s(" architecture."),ba=m(),me=r("p"),wa=s("Configuration objects inherit from "),Bt=r("a"),$a=s("PretrainedConfig"),Ta=s(` and can be used to control the model outputs. Read the
documentation from `),Kt=r("a"),ya=s("PretrainedConfig"),ka=s(" for more information."),Ia=m(),w(Ie.$$.fragment),ts=m(),he=r("h2"),Fe=r("a"),vo=r("span"),w(it.$$.fragment),Fa=m(),_o=r("span"),Ea=s("CvtModel"),os=m(),ee=r("div"),w(lt.$$.fragment),xa=m(),dt=r("p"),ja=s(`The bare Cvt Model transformer outputting raw hidden-states without any specific head on top.
This model is a PyTorch `),ct=r("a"),Pa=s("torch.nn.Module"),Ma=s(` subclass. Use it
as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage and
behavior.`),Aa=m(),H=r("div"),w(ft.$$.fragment),qa=m(),pe=r("p"),La=s("The "),Xt=r("a"),Na=s("CvtModel"),za=s(" forward method, overrides the "),Co=r("code"),Oa=s("__call__"),Da=s(" special method."),Sa=m(),w(Ee.$$.fragment),Va=m(),w(xe.$$.fragment),ss=m(),ue=r("h2"),je=r("a"),bo=r("span"),w(mt.$$.fragment),Wa=m(),wo=r("span"),Ra=s("CvtForImageClassification"),as=m(),W=r("div"),w(ht.$$.fragment),Ha=m(),$o=r("p"),Ua=s(`Cvt Model transformer with an image classification head on top (a linear layer on top of the final hidden state of
the [CLS] token) e.g. for ImageNet.`),Ba=m(),pt=r("p"),Ka=s("This model is a PyTorch "),ut=r("a"),Xa=s("torch.nn.Module"),Ya=s(` subclass. Use it
as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage and
behavior.`),Za=m(),U=r("div"),w(gt.$$.fragment),Ga=m(),ge=r("p"),Ja=s("The "),Yt=r("a"),Qa=s("CvtForImageClassification"),er=s(" forward method, overrides the "),To=r("code"),tr=s("__call__"),or=s(" special method."),sr=m(),w(Pe.$$.fragment),ar=m(),w(Me.$$.fragment),rs=m(),ve=r("h2"),Ae=r("a"),yo=r("span"),w(vt.$$.fragment),rr=m(),ko=r("span"),nr=s("TFCvtModel"),ns=m(),L=r("div"),w(_t.$$.fragment),ir=m(),Io=r("p"),lr=s("The bare Cvt Model transformer outputting raw hidden-states without any specific head on top."),dr=m(),Ct=r("p"),cr=s("This model inherits from "),Zt=r("a"),fr=s("TFPreTrainedModel"),mr=s(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),hr=m(),bt=r("p"),pr=s("This model is also a "),wt=r("a"),ur=s("tf.keras.Model"),gr=s(` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),vr=m(),w(qe.$$.fragment),_r=m(),B=r("div"),w($t.$$.fragment),Cr=m(),_e=r("p"),br=s("The "),Gt=r("a"),wr=s("TFCvtModel"),$r=s(" forward method, overrides the "),Fo=r("code"),Tr=s("__call__"),yr=s(" special method."),kr=m(),w(Le.$$.fragment),Ir=m(),w(Ne.$$.fragment),is=m(),Ce=r("h2"),ze=r("a"),Eo=r("span"),w(Tt.$$.fragment),Fr=m(),xo=r("span"),Er=s("TFCvtForImageClassification"),ls=m(),N=r("div"),w(yt.$$.fragment),xr=m(),jo=r("p"),jr=s(`Cvt Model transformer with an image classification head on top (a linear layer on top of the final hidden state of
the [CLS] token) e.g. for ImageNet.`),Pr=m(),kt=r("p"),Mr=s("This model inherits from "),Jt=r("a"),Ar=s("TFPreTrainedModel"),qr=s(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Lr=m(),It=r("p"),Nr=s("This model is also a "),Ft=r("a"),zr=s("tf.keras.Model"),Or=s(` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),Dr=m(),w(Oe.$$.fragment),Sr=m(),K=r("div"),w(Et.$$.fragment),Vr=m(),be=r("p"),Wr=s("The "),Qt=r("a"),Rr=s("TFCvtForImageClassification"),Hr=s(" forward method, overrides the "),Po=r("code"),Ur=s("__call__"),Br=s(" special method."),Kr=m(),w(De.$$.fragment),Xr=m(),w(Se.$$.fragment),this.h()},l(t){const u=ri('[data-svelte="svelte-1phssyn"]',document.head);d=n(u,"META",{name:!0,content:!0}),u.forEach(o),C=h(t),v=n(t,"H1",{class:!0});var xt=i(v);f=n(xt,"A",{id:!0,class:!0,href:!0});var Mo=i(f);_=n(Mo,"SPAN",{});var Ao=i(_);$(l.$$.fragment,Ao),Ao.forEach(o),Mo.forEach(o),p=h(xt),E=n(xt,"SPAN",{});var qo=i(E);G=a(qo,"Convolutional Vision Transformer (CvT)"),qo.forEach(o),xt.forEach(o),S=h(t),F=n(t,"H2",{class:!0});var jt=i(F);z=n(jt,"A",{id:!0,class:!0,href:!0});var Lo=i(z);M=n(Lo,"SPAN",{});var No=i(M);$(O.$$.fragment,No),No.forEach(o),Lo.forEach(o),J=h(jt),A=n(jt,"SPAN",{});var zo=i(A);Q=a(zo,"Overview"),zo.forEach(o),jt.forEach(o),R=h(t),b=n(t,"P",{});var we=i(b);j=a(we,"The CvT model was proposed in "),q=n(we,"A",{href:!0,rel:!0});var Oo=i(q);ae=a(Oo,"CvT: Introducing Convolutions to Vision Transformers"),Oo.forEach(o),re=a(we," by Haiping Wu, Bin Xiao, Noel Codella, Mengchen Liu, Xiyang Dai, Lu Yuan and Lei Zhang. The Convolutional vision Transformer (CvT) improves the "),P=n(we,"A",{href:!0});var Do=i(P);ne=a(Do,"Vision Transformer (ViT)"),Do.forEach(o),ie=a(we," in performance and efficiency by introducing convolutions into ViT to yield the best of both designs."),we.forEach(o),Ro=h(t),Mt=n(t,"P",{});var Zr=i(Mt);ys=a(Zr,"The abstract from the paper is the following:"),Zr.forEach(o),Ho=h(t),At=n(t,"P",{});var Gr=i(At);mo=n(Gr,"EM",{});var Jr=i(mo);ks=a(Jr,`We present in this paper a new architecture, named Convolutional vision Transformer (CvT), that improves Vision Transformer (ViT)
in performance and efficiency by introducing convolutions into ViT to yield the best of both designs. This is accomplished through
two primary modifications: a hierarchy of Transformers containing a new convolutional token embedding, and a convolutional Transformer
block leveraging a convolutional projection. These changes introduce desirable properties of convolutional neural networks (CNNs)
to the ViT architecture (\\ie shift, scale, and distortion invariance) while maintaining the merits of Transformers (\\ie dynamic attention,
global context, and better generalization). We validate CvT by conducting extensive experiments, showing that this approach achieves
state-of-the-art performance over other Vision Transformers and ResNets on ImageNet-1k, with fewer parameters and lower FLOPs. In addition,
performance gains are maintained when pretrained on larger datasets (\\eg ImageNet-22k) and fine-tuned to downstream tasks. Pre-trained on
ImageNet-22k, our CvT-W24 obtains a top-1 accuracy of 87.7\\% on the ImageNet-1k val set. Finally, our results show that the positional encoding,
a crucial component in existing Vision Transformers, can be safely removed in our model, simplifying the design for higher resolution vision tasks.`),Jr.forEach(o),Gr.forEach(o),Uo=h(t),qt=n(t,"P",{});var Qr=i(qt);Is=a(Qr,"Tips:"),Qr.forEach(o),Bo=h(t),te=n(t,"UL",{});var eo=i(te);Xe=n(eo,"LI",{});var cs=i(Xe);Fs=a(cs,"CvT models are regular Vision Transformers, but trained with convolutions. They outperform the "),Lt=n(cs,"A",{href:!0});var en=i(Lt);Es=a(en,"original model (ViT)"),en.forEach(o),xs=a(cs," when fine-tuned on ImageNet-1K and CIFAR-100."),cs.forEach(o),js=h(eo),D=n(eo,"LI",{});var X=i(D);Ps=a(X,"You can check out demo notebooks regarding inference as well as fine-tuning on custom data "),Ye=n(X,"A",{href:!0,rel:!0});var tn=i(Ye);Ms=a(tn,"here"),tn.forEach(o),As=a(X," (you can just replace "),Nt=n(X,"A",{href:!0});var on=i(Nt);qs=a(on,"ViTFeatureExtractor"),on.forEach(o),Ls=a(X," by "),zt=n(X,"A",{href:!0});var sn=i(zt);Ns=a(sn,"AutoImageProcessor"),sn.forEach(o),zs=a(X," and "),Ot=n(X,"A",{href:!0});var an=i(Ot);Os=a(an,"ViTForImageClassification"),an.forEach(o),Ds=a(X," by "),Dt=n(X,"A",{href:!0});var rn=i(Dt);Ss=a(rn,"CvtForImageClassification"),rn.forEach(o),Vs=a(X,")."),X.forEach(o),Ws=h(eo),le=n(eo,"LI",{});var to=i(le);Rs=a(to,"The available checkpoints are either (1) pre-trained on "),Ze=n(to,"A",{href:!0,rel:!0});var nn=i(Ze);Hs=a(nn,"ImageNet-22k"),nn.forEach(o),Us=a(to," (a collection of 14 million images and 22k classes) only, (2) also fine-tuned on ImageNet-22k or (3) also fine-tuned on "),Ge=n(to,"A",{href:!0,rel:!0});var ln=i(Ge);Bs=a(ln,"ImageNet-1k"),ln.forEach(o),Ks=a(to,` (also referred to as ILSVRC 2012, a collection of 1.3 million
images and 1,000 classes).`),to.forEach(o),eo.forEach(o),Ko=h(t),oe=n(t,"P",{});var oo=i(oe);Xs=a(oo,"This model was contributed by "),Je=n(oo,"A",{href:!0,rel:!0});var dn=i(Je);Ys=a(dn,"anugunj"),dn.forEach(o),Zs=a(oo,". The original code can be found "),Qe=n(oo,"A",{href:!0,rel:!0});var cn=i(Qe);Gs=a(cn,"here"),cn.forEach(o),Js=a(oo,"."),oo.forEach(o),Xo=h(t),de=n(t,"H2",{class:!0});var fs=i(de);Te=n(fs,"A",{id:!0,class:!0,href:!0});var fn=i(Te);ho=n(fn,"SPAN",{});var mn=i(ho);$(et.$$.fragment,mn),mn.forEach(o),fn.forEach(o),Qs=h(fs),po=n(fs,"SPAN",{});var hn=i(po);ea=a(hn,"Resources"),hn.forEach(o),fs.forEach(o),Yo=h(t),St=n(t,"P",{});var pn=i(St);ta=a(pn,"A list of official Hugging Face and community (indicated by \u{1F30E}) resources to help you get started with CvT."),pn.forEach(o),Zo=h(t),$(tt.$$.fragment,t),Go=h(t),ye=n(t,"UL",{});var ms=i(ye);se=n(ms,"LI",{});var Pt=i(se);Vt=n(Pt,"A",{href:!0});var un=i(Vt);oa=a(un,"CvtForImageClassification"),un.forEach(o),sa=a(Pt," is supported by this "),ot=n(Pt,"A",{href:!0,rel:!0});var gn=i(ot);aa=a(gn,"example script"),gn.forEach(o),ra=a(Pt," and "),st=n(Pt,"A",{href:!0,rel:!0});var vn=i(st);na=a(vn,"notebook"),vn.forEach(o),ia=a(Pt,"."),Pt.forEach(o),la=h(ms),Wt=n(ms,"LI",{});var Yr=i(Wt);da=a(Yr,"See also: "),Rt=n(Yr,"A",{href:!0});var _n=i(Rt);ca=a(_n,"Image classification task guide"),_n.forEach(o),Yr.forEach(o),ms.forEach(o),Jo=h(t),Ht=n(t,"P",{});var Cn=i(Ht);fa=a(Cn,"If you\u2019re interested in submitting a resource to be included here, please feel free to open a Pull Request and we\u2019ll review it! The resource should ideally demonstrate something new instead of duplicating an existing resource."),Cn.forEach(o),Qo=h(t),ce=n(t,"H2",{class:!0});var hs=i(ce);ke=n(hs,"A",{id:!0,class:!0,href:!0});var bn=i(ke);uo=n(bn,"SPAN",{});var wn=i(uo);$(at.$$.fragment,wn),wn.forEach(o),bn.forEach(o),ma=h(hs),go=n(hs,"SPAN",{});var $n=i(go);ha=a($n,"CvtConfig"),$n.forEach(o),hs.forEach(o),es=h(t),V=n(t,"DIV",{class:!0});var Ve=i(V);$(rt.$$.fragment,Ve),pa=h(Ve),fe=n(Ve,"P",{});var so=i(fe);ua=a(so,"This is the configuration class to store the configuration of a "),Ut=n(so,"A",{href:!0});var Tn=i(Ut);ga=a(Tn,"CvtModel"),Tn.forEach(o),va=a(so,`. It is used to instantiate a CvT 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 CvT
`),nt=n(so,"A",{href:!0,rel:!0});var yn=i(nt);_a=a(yn,"microsoft/cvt-13"),yn.forEach(o),Ca=a(so," architecture."),so.forEach(o),ba=h(Ve),me=n(Ve,"P",{});var ao=i(me);wa=a(ao,"Configuration objects inherit from "),Bt=n(ao,"A",{href:!0});var kn=i(Bt);$a=a(kn,"PretrainedConfig"),kn.forEach(o),Ta=a(ao,` and can be used to control the model outputs. Read the
documentation from `),Kt=n(ao,"A",{href:!0});var In=i(Kt);ya=a(In,"PretrainedConfig"),In.forEach(o),ka=a(ao," for more information."),ao.forEach(o),Ia=h(Ve),$(Ie.$$.fragment,Ve),Ve.forEach(o),ts=h(t),he=n(t,"H2",{class:!0});var ps=i(he);Fe=n(ps,"A",{id:!0,class:!0,href:!0});var Fn=i(Fe);vo=n(Fn,"SPAN",{});var En=i(vo);$(it.$$.fragment,En),En.forEach(o),Fn.forEach(o),Fa=h(ps),_o=n(ps,"SPAN",{});var xn=i(_o);Ea=a(xn,"CvtModel"),xn.forEach(o),ps.forEach(o),os=h(t),ee=n(t,"DIV",{class:!0});var ro=i(ee);$(lt.$$.fragment,ro),xa=h(ro),dt=n(ro,"P",{});var us=i(dt);ja=a(us,`The bare Cvt Model transformer outputting raw hidden-states without any specific head on top.
This model is a PyTorch `),ct=n(us,"A",{href:!0,rel:!0});var jn=i(ct);Pa=a(jn,"torch.nn.Module"),jn.forEach(o),Ma=a(us,` subclass. Use it
as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage and
behavior.`),us.forEach(o),Aa=h(ro),H=n(ro,"DIV",{class:!0});var We=i(H);$(ft.$$.fragment,We),qa=h(We),pe=n(We,"P",{});var no=i(pe);La=a(no,"The "),Xt=n(no,"A",{href:!0});var Pn=i(Xt);Na=a(Pn,"CvtModel"),Pn.forEach(o),za=a(no," forward method, overrides the "),Co=n(no,"CODE",{});var Mn=i(Co);Oa=a(Mn,"__call__"),Mn.forEach(o),Da=a(no," special method."),no.forEach(o),Sa=h(We),$(Ee.$$.fragment,We),Va=h(We),$(xe.$$.fragment,We),We.forEach(o),ro.forEach(o),ss=h(t),ue=n(t,"H2",{class:!0});var gs=i(ue);je=n(gs,"A",{id:!0,class:!0,href:!0});var An=i(je);bo=n(An,"SPAN",{});var qn=i(bo);$(mt.$$.fragment,qn),qn.forEach(o),An.forEach(o),Wa=h(gs),wo=n(gs,"SPAN",{});var Ln=i(wo);Ra=a(Ln,"CvtForImageClassification"),Ln.forEach(o),gs.forEach(o),as=h(t),W=n(t,"DIV",{class:!0});var Re=i(W);$(ht.$$.fragment,Re),Ha=h(Re),$o=n(Re,"P",{});var Nn=i($o);Ua=a(Nn,`Cvt Model transformer with an image classification head on top (a linear layer on top of the final hidden state of
the [CLS] token) e.g. for ImageNet.`),Nn.forEach(o),Ba=h(Re),pt=n(Re,"P",{});var vs=i(pt);Ka=a(vs,"This model is a PyTorch "),ut=n(vs,"A",{href:!0,rel:!0});var zn=i(ut);Xa=a(zn,"torch.nn.Module"),zn.forEach(o),Ya=a(vs,` subclass. Use it
as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage and
behavior.`),vs.forEach(o),Za=h(Re),U=n(Re,"DIV",{class:!0});var He=i(U);$(gt.$$.fragment,He),Ga=h(He),ge=n(He,"P",{});var io=i(ge);Ja=a(io,"The "),Yt=n(io,"A",{href:!0});var On=i(Yt);Qa=a(On,"CvtForImageClassification"),On.forEach(o),er=a(io," forward method, overrides the "),To=n(io,"CODE",{});var Dn=i(To);tr=a(Dn,"__call__"),Dn.forEach(o),or=a(io," special method."),io.forEach(o),sr=h(He),$(Pe.$$.fragment,He),ar=h(He),$(Me.$$.fragment,He),He.forEach(o),Re.forEach(o),rs=h(t),ve=n(t,"H2",{class:!0});var _s=i(ve);Ae=n(_s,"A",{id:!0,class:!0,href:!0});var Sn=i(Ae);yo=n(Sn,"SPAN",{});var Vn=i(yo);$(vt.$$.fragment,Vn),Vn.forEach(o),Sn.forEach(o),rr=h(_s),ko=n(_s,"SPAN",{});var Wn=i(ko);nr=a(Wn,"TFCvtModel"),Wn.forEach(o),_s.forEach(o),ns=h(t),L=n(t,"DIV",{class:!0});var Y=i(L);$(_t.$$.fragment,Y),ir=h(Y),Io=n(Y,"P",{});var Rn=i(Io);lr=a(Rn,"The bare Cvt Model transformer outputting raw hidden-states without any specific head on top."),Rn.forEach(o),dr=h(Y),Ct=n(Y,"P",{});var Cs=i(Ct);cr=a(Cs,"This model inherits from "),Zt=n(Cs,"A",{href:!0});var Hn=i(Zt);fr=a(Hn,"TFPreTrainedModel"),Hn.forEach(o),mr=a(Cs,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Cs.forEach(o),hr=h(Y),bt=n(Y,"P",{});var bs=i(bt);pr=a(bs,"This model is also a "),wt=n(bs,"A",{href:!0,rel:!0});var Un=i(wt);ur=a(Un,"tf.keras.Model"),Un.forEach(o),gr=a(bs,` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),bs.forEach(o),vr=h(Y),$(qe.$$.fragment,Y),_r=h(Y),B=n(Y,"DIV",{class:!0});var Ue=i(B);$($t.$$.fragment,Ue),Cr=h(Ue),_e=n(Ue,"P",{});var lo=i(_e);br=a(lo,"The "),Gt=n(lo,"A",{href:!0});var Bn=i(Gt);wr=a(Bn,"TFCvtModel"),Bn.forEach(o),$r=a(lo," forward method, overrides the "),Fo=n(lo,"CODE",{});var Kn=i(Fo);Tr=a(Kn,"__call__"),Kn.forEach(o),yr=a(lo," special method."),lo.forEach(o),kr=h(Ue),$(Le.$$.fragment,Ue),Ir=h(Ue),$(Ne.$$.fragment,Ue),Ue.forEach(o),Y.forEach(o),is=h(t),Ce=n(t,"H2",{class:!0});var ws=i(Ce);ze=n(ws,"A",{id:!0,class:!0,href:!0});var Xn=i(ze);Eo=n(Xn,"SPAN",{});var Yn=i(Eo);$(Tt.$$.fragment,Yn),Yn.forEach(o),Xn.forEach(o),Fr=h(ws),xo=n(ws,"SPAN",{});var Zn=i(xo);Er=a(Zn,"TFCvtForImageClassification"),Zn.forEach(o),ws.forEach(o),ls=h(t),N=n(t,"DIV",{class:!0});var Z=i(N);$(yt.$$.fragment,Z),xr=h(Z),jo=n(Z,"P",{});var Gn=i(jo);jr=a(Gn,`Cvt Model transformer with an image classification head on top (a linear layer on top of the final hidden state of
the [CLS] token) e.g. for ImageNet.`),Gn.forEach(o),Pr=h(Z),kt=n(Z,"P",{});var $s=i(kt);Mr=a($s,"This model inherits from "),Jt=n($s,"A",{href:!0});var Jn=i(Jt);Ar=a(Jn,"TFPreTrainedModel"),Jn.forEach(o),qr=a($s,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),$s.forEach(o),Lr=h(Z),It=n(Z,"P",{});var Ts=i(It);Nr=a(Ts,"This model is also a "),Ft=n(Ts,"A",{href:!0,rel:!0});var Qn=i(Ft);zr=a(Qn,"tf.keras.Model"),Qn.forEach(o),Or=a(Ts,` subclass. Use it
as a regular TF 2.0 Keras Model and refer to the TF 2.0 documentation for all matter related to general usage and
behavior.`),Ts.forEach(o),Dr=h(Z),$(Oe.$$.fragment,Z),Sr=h(Z),K=n(Z,"DIV",{class:!0});var Be=i(K);$(Et.$$.fragment,Be),Vr=h(Be),be=n(Be,"P",{});var co=i(be);Wr=a(co,"The "),Qt=n(co,"A",{href:!0});var ei=i(Qt);Rr=a(ei,"TFCvtForImageClassification"),ei.forEach(o),Hr=a(co," forward method, overrides the "),Po=n(co,"CODE",{});var ti=i(Po);Ur=a(ti,"__call__"),ti.forEach(o),Br=a(co," special method."),co.forEach(o),Kr=h(Be),$(De.$$.fragment,Be),Xr=h(Be),$(Se.$$.fragment,Be),Be.forEach(o),Z.forEach(o),this.h()},h(){c(d,"name","hf:doc:metadata"),c(d,"content",JSON.stringify(bi)),c(f,"id","convolutional-vision-transformer-cvt"),c(f,"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(f,"href","#convolutional-vision-transformer-cvt"),c(v,"class","relative group"),c(z,"id","overview"),c(z,"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(z,"href","#overview"),c(F,"class","relative group"),c(q,"href","https://arxiv.org/abs/2103.15808"),c(q,"rel","nofollow"),c(P,"href","vit"),c(Lt,"href","vit"),c(Ye,"href","https://github.com/NielsRogge/Transformers-Tutorials/tree/master/VisionTransformer"),c(Ye,"rel","nofollow"),c(Nt,"href","/docs/transformers/v4.29.0/en/model_doc/vit#transformers.ViTFeatureExtractor"),c(zt,"href","/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoImageProcessor"),c(Ot,"href","/docs/transformers/v4.29.0/en/model_doc/vit#transformers.ViTForImageClassification"),c(Dt,"href","/docs/transformers/v4.29.0/en/model_doc/cvt#transformers.CvtForImageClassification"),c(Ze,"href","http://www.image-net.org/"),c(Ze,"rel","nofollow"),c(Ge,"href","http://www.image-net.org/challenges/LSVRC/2012/"),c(Ge,"rel","nofollow"),c(Je,"href","https://huggingface.co/anugunj"),c(Je,"rel","nofollow"),c(Qe,"href","https://github.com/microsoft/CvT"),c(Qe,"rel","nofollow"),c(Te,"id","resources"),c(Te,"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(Te,"href","#resources"),c(de,"class","relative group"),c(Vt,"href","/docs/transformers/v4.29.0/en/model_doc/cvt#transformers.CvtForImageClassification"),c(ot,"href","https://github.com/huggingface/transformers/tree/main/examples/pytorch/image-classification"),c(ot,"rel","nofollow"),c(st,"href","https://colab.research.google.com/github/huggingface/notebooks/blob/main/examples/image_classification.ipynb"),c(st,"rel","nofollow"),c(Rt,"href","../tasks/image_classification"),c(ke,"id","transformers.CvtConfig"),c(ke,"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(ke,"href","#transformers.CvtConfig"),c(ce,"class","relative group"),c(Ut,"href","/docs/transformers/v4.29.0/en/model_doc/cvt#transformers.CvtModel"),c(nt,"href","https://huggingface.co/microsoft/cvt-13"),c(nt,"rel","nofollow"),c(Bt,"href","/docs/transformers/v4.29.0/en/main_classes/configuration#transformers.PretrainedConfig"),c(Kt,"href","/docs/transformers/v4.29.0/en/main_classes/configuration#transformers.PretrainedConfig"),c(V,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Fe,"id","transformers.CvtModel"),c(Fe,"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(Fe,"href","#transformers.CvtModel"),c(he,"class","relative group"),c(ct,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(ct,"rel","nofollow"),c(Xt,"href","/docs/transformers/v4.29.0/en/model_doc/cvt#transformers.CvtModel"),c(H,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ee,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(je,"id","transformers.CvtForImageClassification"),c(je,"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(je,"href","#transformers.CvtForImageClassification"),c(ue,"class","relative group"),c(ut,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),c(ut,"rel","nofollow"),c(Yt,"href","/docs/transformers/v4.29.0/en/model_doc/cvt#transformers.CvtForImageClassification"),c(U,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(W,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Ae,"id","transformers.TFCvtModel"),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","#transformers.TFCvtModel"),c(ve,"class","relative group"),c(Zt,"href","/docs/transformers/v4.29.0/en/main_classes/model#transformers.TFPreTrainedModel"),c(wt,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(wt,"rel","nofollow"),c(Gt,"href","/docs/transformers/v4.29.0/en/model_doc/cvt#transformers.TFCvtModel"),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(L,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ze,"id","transformers.TFCvtForImageClassification"),c(ze,"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(ze,"href","#transformers.TFCvtForImageClassification"),c(Ce,"class","relative group"),c(Jt,"href","/docs/transformers/v4.29.0/en/main_classes/model#transformers.TFPreTrainedModel"),c(Ft,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),c(Ft,"rel","nofollow"),c(Qt,"href","/docs/transformers/v4.29.0/en/model_doc/cvt#transformers.TFCvtForImageClassification"),c(K,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(N,"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,u){e(document.head,d),g(t,C,u),g(t,v,u),e(v,f),e(f,_),T(l,_,null),e(v,p),e(v,E),e(E,G),g(t,S,u),g(t,F,u),e(F,z),e(z,M),T(O,M,null),e(F,J),e(F,A),e(A,Q),g(t,R,u),g(t,b,u),e(b,j),e(b,q),e(q,ae),e(b,re),e(b,P),e(P,ne),e(b,ie),g(t,Ro,u),g(t,Mt,u),e(Mt,ys),g(t,Ho,u),g(t,At,u),e(At,mo),e(mo,ks),g(t,Uo,u),g(t,qt,u),e(qt,Is),g(t,Bo,u),g(t,te,u),e(te,Xe),e(Xe,Fs),e(Xe,Lt),e(Lt,Es),e(Xe,xs),e(te,js),e(te,D),e(D,Ps),e(D,Ye),e(Ye,Ms),e(D,As),e(D,Nt),e(Nt,qs),e(D,Ls),e(D,zt),e(zt,Ns),e(D,zs),e(D,Ot),e(Ot,Os),e(D,Ds),e(D,Dt),e(Dt,Ss),e(D,Vs),e(te,Ws),e(te,le),e(le,Rs),e(le,Ze),e(Ze,Hs),e(le,Us),e(le,Ge),e(Ge,Bs),e(le,Ks),g(t,Ko,u),g(t,oe,u),e(oe,Xs),e(oe,Je),e(Je,Ys),e(oe,Zs),e(oe,Qe),e(Qe,Gs),e(oe,Js),g(t,Xo,u),g(t,de,u),e(de,Te),e(Te,ho),T(et,ho,null),e(de,Qs),e(de,po),e(po,ea),g(t,Yo,u),g(t,St,u),e(St,ta),g(t,Zo,u),T(tt,t,u),g(t,Go,u),g(t,ye,u),e(ye,se),e(se,Vt),e(Vt,oa),e(se,sa),e(se,ot),e(ot,aa),e(se,ra),e(se,st),e(st,na),e(se,ia),e(ye,la),e(ye,Wt),e(Wt,da),e(Wt,Rt),e(Rt,ca),g(t,Jo,u),g(t,Ht,u),e(Ht,fa),g(t,Qo,u),g(t,ce,u),e(ce,ke),e(ke,uo),T(at,uo,null),e(ce,ma),e(ce,go),e(go,ha),g(t,es,u),g(t,V,u),T(rt,V,null),e(V,pa),e(V,fe),e(fe,ua),e(fe,Ut),e(Ut,ga),e(fe,va),e(fe,nt),e(nt,_a),e(fe,Ca),e(V,ba),e(V,me),e(me,wa),e(me,Bt),e(Bt,$a),e(me,Ta),e(me,Kt),e(Kt,ya),e(me,ka),e(V,Ia),T(Ie,V,null),g(t,ts,u),g(t,he,u),e(he,Fe),e(Fe,vo),T(it,vo,null),e(he,Fa),e(he,_o),e(_o,Ea),g(t,os,u),g(t,ee,u),T(lt,ee,null),e(ee,xa),e(ee,dt),e(dt,ja),e(dt,ct),e(ct,Pa),e(dt,Ma),e(ee,Aa),e(ee,H),T(ft,H,null),e(H,qa),e(H,pe),e(pe,La),e(pe,Xt),e(Xt,Na),e(pe,za),e(pe,Co),e(Co,Oa),e(pe,Da),e(H,Sa),T(Ee,H,null),e(H,Va),T(xe,H,null),g(t,ss,u),g(t,ue,u),e(ue,je),e(je,bo),T(mt,bo,null),e(ue,Wa),e(ue,wo),e(wo,Ra),g(t,as,u),g(t,W,u),T(ht,W,null),e(W,Ha),e(W,$o),e($o,Ua),e(W,Ba),e(W,pt),e(pt,Ka),e(pt,ut),e(ut,Xa),e(pt,Ya),e(W,Za),e(W,U),T(gt,U,null),e(U,Ga),e(U,ge),e(ge,Ja),e(ge,Yt),e(Yt,Qa),e(ge,er),e(ge,To),e(To,tr),e(ge,or),e(U,sr),T(Pe,U,null),e(U,ar),T(Me,U,null),g(t,rs,u),g(t,ve,u),e(ve,Ae),e(Ae,yo),T(vt,yo,null),e(ve,rr),e(ve,ko),e(ko,nr),g(t,ns,u),g(t,L,u),T(_t,L,null),e(L,ir),e(L,Io),e(Io,lr),e(L,dr),e(L,Ct),e(Ct,cr),e(Ct,Zt),e(Zt,fr),e(Ct,mr),e(L,hr),e(L,bt),e(bt,pr),e(bt,wt),e(wt,ur),e(bt,gr),e(L,vr),T(qe,L,null),e(L,_r),e(L,B),T($t,B,null),e(B,Cr),e(B,_e),e(_e,br),e(_e,Gt),e(Gt,wr),e(_e,$r),e(_e,Fo),e(Fo,Tr),e(_e,yr),e(B,kr),T(Le,B,null),e(B,Ir),T(Ne,B,null),g(t,is,u),g(t,Ce,u),e(Ce,ze),e(ze,Eo),T(Tt,Eo,null),e(Ce,Fr),e(Ce,xo),e(xo,Er),g(t,ls,u),g(t,N,u),T(yt,N,null),e(N,xr),e(N,jo),e(jo,jr),e(N,Pr),e(N,kt),e(kt,Mr),e(kt,Jt),e(Jt,Ar),e(kt,qr),e(N,Lr),e(N,It),e(It,Nr),e(It,Ft),e(Ft,zr),e(It,Or),e(N,Dr),T(Oe,N,null),e(N,Sr),e(N,K),T(Et,K,null),e(K,Vr),e(K,be),e(be,Wr),e(be,Qt),e(Qt,Rr),e(be,Hr),e(be,Po),e(Po,Ur),e(be,Br),e(K,Kr),T(De,K,null),e(K,Xr),T(Se,K,null),ds=!0},p(t,[u]){const xt={};u&2&&(xt.$$scope={dirty:u,ctx:t}),Ie.$set(xt);const Mo={};u&2&&(Mo.$$scope={dirty:u,ctx:t}),Ee.$set(Mo);const Ao={};u&2&&(Ao.$$scope={dirty:u,ctx:t}),xe.$set(Ao);const qo={};u&2&&(qo.$$scope={dirty:u,ctx:t}),Pe.$set(qo);const jt={};u&2&&(jt.$$scope={dirty:u,ctx:t}),Me.$set(jt);const Lo={};u&2&&(Lo.$$scope={dirty:u,ctx:t}),qe.$set(Lo);const No={};u&2&&(No.$$scope={dirty:u,ctx:t}),Le.$set(No);const zo={};u&2&&(zo.$$scope={dirty:u,ctx:t}),Ne.$set(zo);const we={};u&2&&(we.$$scope={dirty:u,ctx:t}),Oe.$set(we);const Oo={};u&2&&(Oo.$$scope={dirty:u,ctx:t}),De.$set(Oo);const Do={};u&2&&(Do.$$scope={dirty:u,ctx:t}),Se.$set(Do)},i(t){ds||(y(l.$$.fragment,t),y(O.$$.fragment,t),y(et.$$.fragment,t),y(tt.$$.fragment,t),y(at.$$.fragment,t),y(rt.$$.fragment,t),y(Ie.$$.fragment,t),y(it.$$.fragment,t),y(lt.$$.fragment,t),y(ft.$$.fragment,t),y(Ee.$$.fragment,t),y(xe.$$.fragment,t),y(mt.$$.fragment,t),y(ht.$$.fragment,t),y(gt.$$.fragment,t),y(Pe.$$.fragment,t),y(Me.$$.fragment,t),y(vt.$$.fragment,t),y(_t.$$.fragment,t),y(qe.$$.fragment,t),y($t.$$.fragment,t),y(Le.$$.fragment,t),y(Ne.$$.fragment,t),y(Tt.$$.fragment,t),y(yt.$$.fragment,t),y(Oe.$$.fragment,t),y(Et.$$.fragment,t),y(De.$$.fragment,t),y(Se.$$.fragment,t),ds=!0)},o(t){k(l.$$.fragment,t),k(O.$$.fragment,t),k(et.$$.fragment,t),k(tt.$$.fragment,t),k(at.$$.fragment,t),k(rt.$$.fragment,t),k(Ie.$$.fragment,t),k(it.$$.fragment,t),k(lt.$$.fragment,t),k(ft.$$.fragment,t),k(Ee.$$.fragment,t),k(xe.$$.fragment,t),k(mt.$$.fragment,t),k(ht.$$.fragment,t),k(gt.$$.fragment,t),k(Pe.$$.fragment,t),k(Me.$$.fragment,t),k(vt.$$.fragment,t),k(_t.$$.fragment,t),k(qe.$$.fragment,t),k($t.$$.fragment,t),k(Le.$$.fragment,t),k(Ne.$$.fragment,t),k(Tt.$$.fragment,t),k(yt.$$.fragment,t),k(Oe.$$.fragment,t),k(Et.$$.fragment,t),k(De.$$.fragment,t),k(Se.$$.fragment,t),ds=!1},d(t){o(d),t&&o(C),t&&o(v),I(l),t&&o(S),t&&o(F),I(O),t&&o(R),t&&o(b),t&&o(Ro),t&&o(Mt),t&&o(Ho),t&&o(At),t&&o(Uo),t&&o(qt),t&&o(Bo),t&&o(te),t&&o(Ko),t&&o(oe),t&&o(Xo),t&&o(de),I(et),t&&o(Yo),t&&o(St),t&&o(Zo),I(tt,t),t&&o(Go),t&&o(ye),t&&o(Jo),t&&o(Ht),t&&o(Qo),t&&o(ce),I(at),t&&o(es),t&&o(V),I(rt),I(Ie),t&&o(ts),t&&o(he),I(it),t&&o(os),t&&o(ee),I(lt),I(ft),I(Ee),I(xe),t&&o(ss),t&&o(ue),I(mt),t&&o(as),t&&o(W),I(ht),I(gt),I(Pe),I(Me),t&&o(rs),t&&o(ve),I(vt),t&&o(ns),t&&o(L),I(_t),I(qe),I($t),I(Le),I(Ne),t&&o(is),t&&o(Ce),I(Tt),t&&o(ls),t&&o(N),I(yt),I(Oe),I(Et),I(De),I(Se)}}}const bi={local:"convolutional-vision-transformer-cvt",sections:[{local:"overview",title:"Overview"},{local:"resources",title:"Resources"},{local:"transformers.CvtConfig",title:"CvtConfig"},{local:"transformers.CvtModel",title:"CvtModel"},{local:"transformers.CvtForImageClassification",title:"CvtForImageClassification"},{local:"transformers.TFCvtModel",title:"TFCvtModel"},{local:"transformers.TFCvtForImageClassification",title:"TFCvtForImageClassification"}],title:"Convolutional Vision Transformer (CvT)"};function wi(x){return ni(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class xi extends oi{constructor(d){super();si(this,d,wi,Ci,ai,{})}}export{xi as default,bi as metadata};
