import{s as ya,f as va,o as ba,n as tt}from"../chunks/scheduler.9bc65507.js";import{S as _a,i as Ta,g as o,s as i,u as y,A as Ma,h as r,f as t,c as u,j as H,v,y as f,k as g,o as k,a as l,w as b,d as _,t as T,x as M}from"../chunks/index.78c82d43.js";import{T as ka}from"../chunks/Tip.87d55b76.js";import{Y as Ca}from"../chunks/Youtube.b19762b6.js";import{I as le}from"../chunks/IconCopyLink.bedaa44d.js";import{C as P}from"../chunks/CodeBlock.48618ec2.js";import{F as wa,M as ht}from"../chunks/Markdown.993b48ef.js";function Ha(W){let n,h='To share a model with the community, you need an account on <a href="https://huggingface.co/join" rel="nofollow">huggingface.co</a>. You can also join an existing organization or create a new one.';return{c(){n=o("p"),n.innerHTML=h},l(s){n=r(s,"P",{"data-svelte-h":!0}),f(n)!=="svelte-n70tme"&&(n.innerHTML=h)},m(s,p){l(s,n,p)},p:tt,d(s){s&&t(n)}}}function xa(W){let n,h="Specify <code>from_tf=True</code> to convert a checkpoint from TensorFlow to PyTorch:",s,p,d;return p=new P({props:{code:"cHRfbW9kZWwlMjAlM0QlMjBEaXN0aWxCZXJ0Rm9yU2VxdWVuY2VDbGFzc2lmaWNhdGlvbi5mcm9tX3ByZXRyYWluZWQoJTIycGF0aCUyRnRvJTJGYXdlc29tZS1uYW1lLXlvdS1waWNrZWQlMjIlMkMlMjBmcm9tX3RmJTNEVHJ1ZSklMEFwdF9tb2RlbC5zYXZlX3ByZXRyYWluZWQoJTIycGF0aCUyRnRvJTJGYXdlc29tZS1uYW1lLXlvdS1waWNrZWQlMjIp",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>pt_model = DistilBertForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;path/to/awesome-name-you-picked&quot;</span>, from_tf=<span class="hljs-literal">True</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>pt_model.save_pretrained(<span class="hljs-string">&quot;path/to/awesome-name-you-picked&quot;</span>)`}}),{c(){n=o("p"),n.innerHTML=h,s=i(),y(p.$$.fragment)},l(m){n=r(m,"P",{"data-svelte-h":!0}),f(n)!=="svelte-t2b4fg"&&(n.innerHTML=h),s=u(m),v(p.$$.fragment,m)},m(m,C){l(m,n,C),l(m,s,C),b(p,m,C),d=!0},p:tt,i(m){d||(_(p.$$.fragment,m),d=!0)},o(m){T(p.$$.fragment,m),d=!1},d(m){m&&(t(n),t(s)),M(p,m)}}}function Ja(W){let n,h;return n=new ht({props:{$$slots:{default:[xa]},$$scope:{ctx:W}}}),{c(){y(n.$$.fragment)},l(s){v(n.$$.fragment,s)},m(s,p){b(n,s,p),h=!0},p(s,p){const d={};p&2&&(d.$$scope={dirty:p,ctx:s}),n.$set(d)},i(s){h||(_(n.$$.fragment,s),h=!0)},o(s){T(n.$$.fragment,s),h=!1},d(s){M(n,s)}}}function ja(W){let n,h="Specify <code>from_pt=True</code> to convert a checkpoint from PyTorch to TensorFlow:",s,p,d,m,C="Then you can save your new TensorFlow model with its new checkpoint:",x,j,F;return p=new P({props:{code:"dGZfbW9kZWwlMjAlM0QlMjBURkRpc3RpbEJlcnRGb3JTZXF1ZW5jZUNsYXNzaWZpY2F0aW9uLmZyb21fcHJldHJhaW5lZCglMjJwYXRoJTJGdG8lMkZhd2Vzb21lLW5hbWUteW91LXBpY2tlZCUyMiUyQyUyMGZyb21fcHQlM0RUcnVlKQ==",highlighted:'<span class="hljs-meta">&gt;&gt;&gt; </span>tf_model = TFDistilBertForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;path/to/awesome-name-you-picked&quot;</span>, from_pt=<span class="hljs-literal">True</span>)'}}),j=new P({props:{code:"dGZfbW9kZWwuc2F2ZV9wcmV0cmFpbmVkKCUyMnBhdGglMkZ0byUyRmF3ZXNvbWUtbmFtZS15b3UtcGlja2VkJTIyKQ==",highlighted:'<span class="hljs-meta">&gt;&gt;&gt; </span>tf_model.save_pretrained(<span class="hljs-string">&quot;path/to/awesome-name-you-picked&quot;</span>)'}}),{c(){n=o("p"),n.innerHTML=h,s=i(),y(p.$$.fragment),d=i(),m=o("p"),m.textContent=C,x=i(),y(j.$$.fragment)},l($){n=r($,"P",{"data-svelte-h":!0}),f(n)!=="svelte-17l9qm6"&&(n.innerHTML=h),s=u($),v(p.$$.fragment,$),d=u($),m=r($,"P",{"data-svelte-h":!0}),f(m)!=="svelte-4w3hzs"&&(m.textContent=C),x=u($),v(j.$$.fragment,$)},m($,J){l($,n,J),l($,s,J),b(p,$,J),l($,d,J),l($,m,J),l($,x,J),b(j,$,J),F=!0},p:tt,i($){F||(_(p.$$.fragment,$),_(j.$$.fragment,$),F=!0)},o($){T(p.$$.fragment,$),T(j.$$.fragment,$),F=!1},d($){$&&(t(n),t(s),t(d),t(m),t(x)),M(p,$),M(j,$)}}}function Wa(W){let n,h;return n=new ht({props:{$$slots:{default:[ja]},$$scope:{ctx:W}}}),{c(){y(n.$$.fragment)},l(s){v(n.$$.fragment,s)},m(s,p){b(n,s,p),h=!0},p(s,p){const d={};p&2&&(d.$$scope={dirty:p,ctx:s}),n.$set(d)},i(s){h||(_(n.$$.fragment,s),h=!0)},o(s){T(n.$$.fragment,s),h=!1},d(s){M(n,s)}}}function Za(W){let n,h="If a model is available in Flax, you can also convert a checkpoint from PyTorch to Flax:",s,p,d;return p=new P({props:{code:"ZmxheF9tb2RlbCUyMCUzRCUyMEZsYXhEaXN0aWxCZXJ0Rm9yU2VxdWVuY2VDbGFzc2lmaWNhdGlvbi5mcm9tX3ByZXRyYWluZWQoJTBBJTIwJTIwJTIwJTIwJTIycGF0aCUyRnRvJTJGYXdlc29tZS1uYW1lLXlvdS1waWNrZWQlMjIlMkMlMjBmcm9tX3B0JTNEVHJ1ZSUwQSk=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>flax_model = FlaxDistilBertForSequenceClassification.from_pretrained(
<span class="hljs-meta">... </span>    <span class="hljs-string">&quot;path/to/awesome-name-you-picked&quot;</span>, from_pt=<span class="hljs-literal">True</span>
<span class="hljs-meta">... </span>)`}}),{c(){n=o("p"),n.textContent=h,s=i(),y(p.$$.fragment)},l(m){n=r(m,"P",{"data-svelte-h":!0}),f(n)!=="svelte-1wdqh65"&&(n.textContent=h),s=u(m),v(p.$$.fragment,m)},m(m,C){l(m,n,C),l(m,s,C),b(p,m,C),d=!0},p:tt,i(m){d||(_(p.$$.fragment,m),d=!0)},o(m){T(p.$$.fragment,m),d=!1},d(m){m&&(t(n),t(s)),M(p,m)}}}function La(W){let n,h;return n=new ht({props:{$$slots:{default:[Za]},$$scope:{ctx:W}}}),{c(){y(n.$$.fragment)},l(s){v(n.$$.fragment,s)},m(s,p){b(n,s,p),h=!0},p(s,p){const d={};p&2&&(d.$$scope={dirty:p,ctx:s}),n.$set(d)},i(s){h||(_(n.$$.fragment,s),h=!0)},o(s){T(n.$$.fragment,s),h=!1},d(s){M(n,s)}}}function Fa(W){let n,h,s,p='Sharing a model to the Hub is as simple as adding an extra parameter or callback. Remember from the <a href="training">fine-tuning tutorial</a>, the <a href="/docs/transformers/v4.33.3/en/main_classes/trainer#transformers.TrainingArguments">TrainingArguments</a> class is where you specify hyperparameters and additional training options. One of these training options includes the ability to push a model directly to the Hub. Set <code>push_to_hub=True</code> in your <a href="/docs/transformers/v4.33.3/en/main_classes/trainer#transformers.TrainingArguments">TrainingArguments</a>:',d,m,C,x,j='Pass your training arguments as usual to <a href="/docs/transformers/v4.33.3/en/main_classes/trainer#transformers.Trainer">Trainer</a>:',F,$,J,L,w='After you fine-tune your model, call <a href="/docs/transformers/v4.33.3/en/main_classes/trainer#transformers.Trainer.push_to_hub">push_to_hub()</a> on <a href="/docs/transformers/v4.33.3/en/main_classes/trainer#transformers.Trainer">Trainer</a> to push the trained model to the Hub. 🤗 Transformers will even automatically add training hyperparameters, training results and framework versions to your model card!',U,X,ae;return n=new Ca({props:{id:"Z1-XMy-GNLQ"}}),m=new P({props:{code:"dHJhaW5pbmdfYXJncyUyMCUzRCUyMFRyYWluaW5nQXJndW1lbnRzKG91dHB1dF9kaXIlM0QlMjJteS1hd2Vzb21lLW1vZGVsJTIyJTJDJTIwcHVzaF90b19odWIlM0RUcnVlKQ==",highlighted:'<span class="hljs-meta">&gt;&gt;&gt; </span>training_args = TrainingArguments(output_dir=<span class="hljs-string">&quot;my-awesome-model&quot;</span>, push_to_hub=<span class="hljs-literal">True</span>)'}}),$=new P({props:{code:"dHJhaW5lciUyMCUzRCUyMFRyYWluZXIoJTBBJTIwJTIwJTIwJTIwbW9kZWwlM0Rtb2RlbCUyQyUwQSUyMCUyMCUyMCUyMGFyZ3MlM0R0cmFpbmluZ19hcmdzJTJDJTBBJTIwJTIwJTIwJTIwdHJhaW5fZGF0YXNldCUzRHNtYWxsX3RyYWluX2RhdGFzZXQlMkMlMEElMjAlMjAlMjAlMjBldmFsX2RhdGFzZXQlM0RzbWFsbF9ldmFsX2RhdGFzZXQlMkMlMEElMjAlMjAlMjAlMjBjb21wdXRlX21ldHJpY3MlM0Rjb21wdXRlX21ldHJpY3MlMkMlMEEp",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>trainer = Trainer(
<span class="hljs-meta">... </span>    model=model,
<span class="hljs-meta">... </span>    args=training_args,
<span class="hljs-meta">... </span>    train_dataset=small_train_dataset,
<span class="hljs-meta">... </span>    eval_dataset=small_eval_dataset,
<span class="hljs-meta">... </span>    compute_metrics=compute_metrics,
<span class="hljs-meta">... </span>)`}}),X=new P({props:{code:"dHJhaW5lci5wdXNoX3RvX2h1Yigp",highlighted:'<span class="hljs-meta">&gt;&gt;&gt; </span>trainer.push_to_hub()'}}),{c(){y(n.$$.fragment),h=i(),s=o("p"),s.innerHTML=p,d=i(),y(m.$$.fragment),C=i(),x=o("p"),x.innerHTML=j,F=i(),y($.$$.fragment),J=i(),L=o("p"),L.innerHTML=w,U=i(),y(X.$$.fragment)},l(c){v(n.$$.fragment,c),h=u(c),s=r(c,"P",{"data-svelte-h":!0}),f(s)!=="svelte-1s5v38b"&&(s.innerHTML=p),d=u(c),v(m.$$.fragment,c),C=u(c),x=r(c,"P",{"data-svelte-h":!0}),f(x)!=="svelte-146nb2b"&&(x.innerHTML=j),F=u(c),v($.$$.fragment,c),J=u(c),L=r(c,"P",{"data-svelte-h":!0}),f(L)!=="svelte-1ahx0h3"&&(L.innerHTML=w),U=u(c),v(X.$$.fragment,c)},m(c,Z){b(n,c,Z),l(c,h,Z),l(c,s,Z),l(c,d,Z),b(m,c,Z),l(c,C,Z),l(c,x,Z),l(c,F,Z),b($,c,Z),l(c,J,Z),l(c,L,Z),l(c,U,Z),b(X,c,Z),ae=!0},p:tt,i(c){ae||(_(n.$$.fragment,c),_(m.$$.fragment,c),_($.$$.fragment,c),_(X.$$.fragment,c),ae=!0)},o(c){T(n.$$.fragment,c),T(m.$$.fragment,c),T($.$$.fragment,c),T(X.$$.fragment,c),ae=!1},d(c){c&&(t(h),t(s),t(d),t(C),t(x),t(F),t(J),t(L),t(U)),M(n,c),M(m,c),M($,c),M(X,c)}}}function Ua(W){let n,h;return n=new ht({props:{$$slots:{default:[Fa]},$$scope:{ctx:W}}}),{c(){y(n.$$.fragment)},l(s){v(n.$$.fragment,s)},m(s,p){b(n,s,p),h=!0},p(s,p){const d={};p&2&&(d.$$scope={dirty:p,ctx:s}),n.$set(d)},i(s){h||(_(n.$$.fragment,s),h=!0)},o(s){T(n.$$.fragment,s),h=!1},d(s){M(n,s)}}}function Pa(W){let n,h='Share a model to the Hub with <a href="/docs/transformers/v4.33.3/en/main_classes/keras_callbacks#transformers.PushToHubCallback">PushToHubCallback</a>. In the <a href="/docs/transformers/v4.33.3/en/main_classes/keras_callbacks#transformers.PushToHubCallback">PushToHubCallback</a> function, add:',s,p,d="<li>An output directory for your model.</li> <li>A tokenizer.</li> <li>The <code>hub_model_id</code>, which is your Hub username and model name.</li>",m,C,x,j,F='Add the callback to <a href="https://keras.io/api/models/model_training_apis/" rel="nofollow"><code>fit</code></a>, and 🤗 Transformers will push the trained model to the Hub:',$,J,L;return C=new P({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMFB1c2hUb0h1YkNhbGxiYWNrJTBBJTBBcHVzaF90b19odWJfY2FsbGJhY2slMjAlM0QlMjBQdXNoVG9IdWJDYWxsYmFjayglMEElMjAlMjAlMjAlMjBvdXRwdXRfZGlyJTNEJTIyLiUyRnlvdXJfbW9kZWxfc2F2ZV9wYXRoJTIyJTJDJTIwdG9rZW5pemVyJTNEdG9rZW5pemVyJTJDJTIwaHViX21vZGVsX2lkJTNEJTIyeW91ci11c2VybmFtZSUyRm15LWF3ZXNvbWUtbW9kZWwlMjIlMEEp",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> PushToHubCallback

<span class="hljs-meta">&gt;&gt;&gt; </span>push_to_hub_callback = PushToHubCallback(
<span class="hljs-meta">... </span>    output_dir=<span class="hljs-string">&quot;./your_model_save_path&quot;</span>, tokenizer=tokenizer, hub_model_id=<span class="hljs-string">&quot;your-username/my-awesome-model&quot;</span>
<span class="hljs-meta">... </span>)`}}),J=new P({props:{code:"bW9kZWwuZml0KHRmX3RyYWluX2RhdGFzZXQlMkMlMjB2YWxpZGF0aW9uX2RhdGElM0R0Zl92YWxpZGF0aW9uX2RhdGFzZXQlMkMlMjBlcG9jaHMlM0QzJTJDJTIwY2FsbGJhY2tzJTNEcHVzaF90b19odWJfY2FsbGJhY2sp",highlighted:'<span class="hljs-meta">&gt;&gt;&gt; </span>model.fit(tf_train_dataset, validation_data=tf_validation_dataset, epochs=<span class="hljs-number">3</span>, callbacks=push_to_hub_callback)'}}),{c(){n=o("p"),n.innerHTML=h,s=i(),p=o("ul"),p.innerHTML=d,m=i(),y(C.$$.fragment),x=i(),j=o("p"),j.innerHTML=F,$=i(),y(J.$$.fragment)},l(w){n=r(w,"P",{"data-svelte-h":!0}),f(n)!=="svelte-cmdkgl"&&(n.innerHTML=h),s=u(w),p=r(w,"UL",{"data-svelte-h":!0}),f(p)!=="svelte-165fubm"&&(p.innerHTML=d),m=u(w),v(C.$$.fragment,w),x=u(w),j=r(w,"P",{"data-svelte-h":!0}),f(j)!=="svelte-1f8ao70"&&(j.innerHTML=F),$=u(w),v(J.$$.fragment,w)},m(w,U){l(w,n,U),l(w,s,U),l(w,p,U),l(w,m,U),b(C,w,U),l(w,x,U),l(w,j,U),l(w,$,U),b(J,w,U),L=!0},p:tt,i(w){L||(_(C.$$.fragment,w),_(J.$$.fragment,w),L=!0)},o(w){T(C.$$.fragment,w),T(J.$$.fragment,w),L=!1},d(w){w&&(t(n),t(s),t(p),t(m),t(x),t(j),t($)),M(C,w),M(J,w)}}}function Xa(W){let n,h;return n=new ht({props:{$$slots:{default:[Pa]},$$scope:{ctx:W}}}),{c(){y(n.$$.fragment)},l(s){v(n.$$.fragment,s)},m(s,p){b(n,s,p),h=!0},p(s,p){const d={};p&2&&(d.$$scope={dirty:p,ctx:s}),n.$set(d)},i(s){h||(_(n.$$.fragment,s),h=!0)},o(s){T(n.$$.fragment,s),h=!1},d(s){M(n,s)}}}function Ra(W){let n,h,s,p,d,m,C,x,j,F,$="Share a model",J,L,w="The last two tutorials showed how you can fine-tune a model with PyTorch, Keras, and 🤗 Accelerate for distributed setups. The next step is to share your model with the community! At Hugging Face, we believe in openly sharing knowledge and resources to democratize artificial intelligence for everyone. We encourage you to consider sharing your model with the community to help others save time and resources.",U,X,ae='In this tutorial, you will learn two methods for sharing a trained or fine-tuned model on the <a href="https://huggingface.co/models" rel="nofollow">Model Hub</a>:',c,Z,_l="<li>Programmatically push your files to the Hub.</li> <li>Drag-and-drop your files to the Hub with the web interface.</li>",ft,R,Tl,ct,N,dt,G,V,lt,ne,dl,qe,Ml="Repository features",$t,se,kl="Each repository on the Model Hub behaves like a typical GitHub repository. Our repositories offer versioning, commit history, and the ability to visualize differences.",gt,oe,Cl='The Model Hub’s built-in versioning is based on git and <a href="https://git-lfs.github.com/" rel="nofollow">git-lfs</a>. In other words, you can treat one model as one repository, enabling greater access control and scalability. Version control allows <em>revisions</em>, a method for pinning a specific version of a model with a commit hash, tag or branch.',wt,re,Hl="As a result, you can load a specific model version with the <code>revision</code> parameter:",yt,ie,vt,ue,xl="Files are also easily edited in a repository, and you can view the commit history as well as the difference:",bt,pe,Jl='<img src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/vis_diff.png" alt="vis_diff"/>',_t,E,q,at,me,$l,Be,jl="Setup",Tt,he,Wl="Before sharing a model to the Hub, you will need your Hugging Face credentials. If you have access to a terminal, run the following command in the virtual environment where 🤗 Transformers is installed. This will store your access token in your Hugging Face cache folder (<code>~/.cache/</code> by default):",Mt,fe,kt,ce,Zl='If you are using a notebook like Jupyter or Colaboratory, make sure you have the <a href="https://huggingface.co/docs/hub/adding-a-library" rel="nofollow"><code>huggingface_hub</code></a> library installed. This library allows you to programmatically interact with the Hub.',Ct,de,Ht,$e,Ll='Then use <code>notebook_login</code> to sign-in to the Hub, and follow the link <a href="https://huggingface.co/settings/token" rel="nofollow">here</a> to generate a token to login with:',xt,ge,Jt,I,B,nt,we,gl,Qe,Fl="Convert a model for all frameworks",jt,ye,Ul="To ensure your model can be used by someone working with a different framework, we recommend you convert and upload your model with both PyTorch and TensorFlow checkpoints. While users are still able to load your model from a different framework if you skip this step, it will be slower because 🤗 Transformers will need to convert the checkpoint on-the-fly.",Wt,ve,Pl='Converting a checkpoint for another framework is easy. Make sure you have PyTorch and TensorFlow installed (see <a href="installation">here</a> for installation instructions), and then find the specific model for your task in the other framework.',Zt,Q,Lt,S,D,st,be,wl,De,Xl="Push a model during training",Ft,K,Ut,Y,O,ot,_e,yl,Ke,Rl="Use the <code>push_to_hub</code> function",Pt,Te,Gl="You can also call <code>push_to_hub</code> directly on your model to upload it to the Hub.",Xt,Me,El="Specify your model name in <code>push_to_hub</code>:",Rt,ke,Gt,Ce,Il="This creates a repository under your username with the model name <code>my-awesome-model</code>. Users can now load your model with the <code>from_pretrained</code> function:",Et,He,It,xe,Sl="If you belong to an organization and want to push your model under the organization name instead, just add it to the <code>repo_id</code>:",St,Je,Yt,je,Yl="The <code>push_to_hub</code> function can also be used to add other files to a model repository. For example, add a tokenizer to a model repository:",At,We,zt,Ze,Al="Or perhaps you’d like to add the TensorFlow version of your fine-tuned PyTorch model:",Nt,Le,Vt,Fe,zl="Now when you navigate to your Hugging Face profile, you should see your newly created model repository. Clicking on the <strong>Files</strong> tab will display all the files you’ve uploaded to the repository.",qt,Ue,Nl='For more details on how to create and upload files to a repository, refer to the Hub documentation <a href="https://huggingface.co/docs/hub/how-to-upstream" rel="nofollow">here</a>.',Bt,A,ee,rt,Pe,vl,Oe,Vl="Upload with the web interface",Qt,Xe,ql='Users who prefer a no-code approach are able to upload a model through the Hub’s web interface. Visit <a href="https://huggingface.co/new" rel="nofollow">huggingface.co/new</a> to create a new repository:',Dt,Re,Bl='<img src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/new_model_repo.png" alt="new_model_repo"/>',Kt,Ge,Ql="From here, add some information about your model:",Ot,Ee,Dl="<li>Select the <strong>owner</strong> of the repository. This can be yourself or any of the organizations you belong to.</li> <li>Pick a name for your model, which will also be the repository name.</li> <li>Choose whether your model is public or private.</li> <li>Specify the license usage for your model.</li>",el,Ie,Kl="Now click on the <strong>Files</strong> tab and click on the <strong>Add file</strong> button to upload a new file to your repository. Then drag-and-drop a file to upload and add a commit message.",tl,Se,Ol='<img src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/upload_file.png" alt="upload_file"/>',ll,z,te,it,Ye,bl,et,ea="Add a model card",al,Ae,ta="To make sure users understand your model’s capabilities, limitations, potential biases and ethical considerations, please add a model card to your repository. The model card is defined in the <code>README.md</code> file. You can add a model card by:",nl,ze,la="<li>Manually creating and uploading a <code>README.md</code> file.</li> <li>Clicking on the <strong>Edit model card</strong> button in your model repository.</li>",sl,Ne,aa='Take a look at the DistilBert <a href="https://huggingface.co/distilbert-base-uncased" rel="nofollow">model card</a> for a good example of the type of information a model card should include. For more details about other options you can control in the <code>README.md</code> file such as a model’s carbon footprint or widget examples, refer to the documentation <a href="https://huggingface.co/docs/hub/models-cards" rel="nofollow">here</a>.',ol,ut,rl;return x=new le({}),N=new ka({props:{$$slots:{default:[Ha]},$$scope:{ctx:W}}}),ne=new le({}),ie=new P({props:{code:"bW9kZWwlMjAlM0QlMjBBdXRvTW9kZWwuZnJvbV9wcmV0cmFpbmVkKCUwQSUyMCUyMCUyMCUyMCUyMmp1bGllbi1jJTJGRXNwZXJCRVJUby1zbWFsbCUyMiUyQyUyMHJldmlzaW9uJTNEJTIydjIuMC4xJTIyJTIwJTIwJTIzJTIwdGFnJTIwbmFtZSUyQyUyMG9yJTIwYnJhbmNoJTIwbmFtZSUyQyUyMG9yJTIwY29tbWl0JTIwaGFzaCUwQSk=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>model = AutoModel.from_pretrained(
<span class="hljs-meta">... </span>    <span class="hljs-string">&quot;julien-c/EsperBERTo-small&quot;</span>, revision=<span class="hljs-string">&quot;v2.0.1&quot;</span>  <span class="hljs-comment"># tag name, or branch name, or commit hash</span>
<span class="hljs-meta">... </span>)`}}),me=new le({}),fe=new P({props:{code:"aHVnZ2luZ2ZhY2UtY2xpJTIwbG9naW4=",highlighted:"huggingface-cli login"}}),de=new P({props:{code:"cGlwJTIwaW5zdGFsbCUyMGh1Z2dpbmdmYWNlX2h1Yg==",highlighted:"pip install huggingface_hub"}}),ge=new P({props:{code:"ZnJvbSUyMGh1Z2dpbmdmYWNlX2h1YiUyMGltcG9ydCUyMG5vdGVib29rX2xvZ2luJTBBJTBBbm90ZWJvb2tfbG9naW4oKQ==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> huggingface_hub <span class="hljs-keyword">import</span> notebook_login

<span class="hljs-meta">&gt;&gt;&gt; </span>notebook_login()`}}),we=new le({}),Q=new wa({props:{pytorch:!0,tensorflow:!0,jax:!0,$$slots:{jax:[La],tensorflow:[Wa],pytorch:[Ja]},$$scope:{ctx:W}}}),be=new le({}),K=new wa({props:{pytorch:!0,tensorflow:!0,jax:!1,$$slots:{tensorflow:[Xa],pytorch:[Ua]},$$scope:{ctx:W}}}),_e=new le({}),ke=new P({props:{code:"cHRfbW9kZWwucHVzaF90b19odWIoJTIybXktYXdlc29tZS1tb2RlbCUyMik=",highlighted:'<span class="hljs-meta">&gt;&gt;&gt; </span>pt_model.push_to_hub(<span class="hljs-string">&quot;my-awesome-model&quot;</span>)'}}),He=new P({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Nb2RlbCUwQSUwQW1vZGVsJTIwJTNEJTIwQXV0b01vZGVsLmZyb21fcHJldHJhaW5lZCglMjJ5b3VyX3VzZXJuYW1lJTJGbXktYXdlc29tZS1tb2RlbCUyMik=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoModel

<span class="hljs-meta">&gt;&gt;&gt; </span>model = AutoModel.from_pretrained(<span class="hljs-string">&quot;your_username/my-awesome-model&quot;</span>)`}}),Je=new P({props:{code:"cHRfbW9kZWwucHVzaF90b19odWIoJTIybXktYXdlc29tZS1vcmclMkZteS1hd2Vzb21lLW1vZGVsJTIyKQ==",highlighted:'<span class="hljs-meta">&gt;&gt;&gt; </span>pt_model.push_to_hub(<span class="hljs-string">&quot;my-awesome-org/my-awesome-model&quot;</span>)'}}),We=new P({props:{code:"dG9rZW5pemVyLnB1c2hfdG9faHViKCUyMm15LWF3ZXNvbWUtbW9kZWwlMjIp",highlighted:'<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer.push_to_hub(<span class="hljs-string">&quot;my-awesome-model&quot;</span>)'}}),Le=new P({props:{code:"dGZfbW9kZWwucHVzaF90b19odWIoJTIybXktYXdlc29tZS1tb2RlbCUyMik=",highlighted:'<span class="hljs-meta">&gt;&gt;&gt; </span>tf_model.push_to_hub(<span class="hljs-string">&quot;my-awesome-model&quot;</span>)'}}),Pe=new le({}),Ye=new le({}),{c(){n=o("meta"),h=i(),s=o("p"),p=i(),d=o("h1"),m=o("a"),C=o("span"),y(x.$$.fragment),j=i(),F=o("span"),F.textContent=$,J=i(),L=o("p"),L.textContent=w,U=i(),X=o("p"),X.innerHTML=ae,c=i(),Z=o("ul"),Z.innerHTML=_l,ft=i(),R=o("iframe"),ct=i(),y(N.$$.fragment),dt=i(),G=o("h2"),V=o("a"),lt=o("span"),y(ne.$$.fragment),dl=i(),qe=o("span"),qe.textContent=Ml,$t=i(),se=o("p"),se.textContent=kl,gt=i(),oe=o("p"),oe.innerHTML=Cl,wt=i(),re=o("p"),re.innerHTML=Hl,yt=i(),y(ie.$$.fragment),vt=i(),ue=o("p"),ue.textContent=xl,bt=i(),pe=o("p"),pe.innerHTML=Jl,_t=i(),E=o("h2"),q=o("a"),at=o("span"),y(me.$$.fragment),$l=i(),Be=o("span"),Be.textContent=jl,Tt=i(),he=o("p"),he.innerHTML=Wl,Mt=i(),y(fe.$$.fragment),kt=i(),ce=o("p"),ce.innerHTML=Zl,Ct=i(),y(de.$$.fragment),Ht=i(),$e=o("p"),$e.innerHTML=Ll,xt=i(),y(ge.$$.fragment),Jt=i(),I=o("h2"),B=o("a"),nt=o("span"),y(we.$$.fragment),gl=i(),Qe=o("span"),Qe.textContent=Fl,jt=i(),ye=o("p"),ye.textContent=Ul,Wt=i(),ve=o("p"),ve.innerHTML=Pl,Zt=i(),y(Q.$$.fragment),Lt=i(),S=o("h2"),D=o("a"),st=o("span"),y(be.$$.fragment),wl=i(),De=o("span"),De.textContent=Xl,Ft=i(),y(K.$$.fragment),Ut=i(),Y=o("h2"),O=o("a"),ot=o("span"),y(_e.$$.fragment),yl=i(),Ke=o("span"),Ke.innerHTML=Rl,Pt=i(),Te=o("p"),Te.innerHTML=Gl,Xt=i(),Me=o("p"),Me.innerHTML=El,Rt=i(),y(ke.$$.fragment),Gt=i(),Ce=o("p"),Ce.innerHTML=Il,Et=i(),y(He.$$.fragment),It=i(),xe=o("p"),xe.innerHTML=Sl,St=i(),y(Je.$$.fragment),Yt=i(),je=o("p"),je.innerHTML=Yl,At=i(),y(We.$$.fragment),zt=i(),Ze=o("p"),Ze.textContent=Al,Nt=i(),y(Le.$$.fragment),Vt=i(),Fe=o("p"),Fe.innerHTML=zl,qt=i(),Ue=o("p"),Ue.innerHTML=Nl,Bt=i(),A=o("h2"),ee=o("a"),rt=o("span"),y(Pe.$$.fragment),vl=i(),Oe=o("span"),Oe.textContent=Vl,Qt=i(),Xe=o("p"),Xe.innerHTML=ql,Dt=i(),Re=o("p"),Re.innerHTML=Bl,Kt=i(),Ge=o("p"),Ge.textContent=Ql,Ot=i(),Ee=o("ul"),Ee.innerHTML=Dl,el=i(),Ie=o("p"),Ie.innerHTML=Kl,tl=i(),Se=o("p"),Se.innerHTML=Ol,ll=i(),z=o("h2"),te=o("a"),it=o("span"),y(Ye.$$.fragment),bl=i(),et=o("span"),et.textContent=ea,al=i(),Ae=o("p"),Ae.innerHTML=ta,nl=i(),ze=o("ul"),ze.innerHTML=la,sl=i(),Ne=o("p"),Ne.innerHTML=aa,ol=i(),ut=o("p"),this.h()},l(e){const a=Ma("svelte-1phssyn",document.head);n=r(a,"META",{name:!0,content:!0}),a.forEach(t),h=u(e),s=r(e,"P",{}),H(s).forEach(t),p=u(e),d=r(e,"H1",{class:!0});var Ve=H(d);m=r(Ve,"A",{id:!0,class:!0,href:!0});var pt=H(m);C=r(pt,"SPAN",{});var mt=H(C);v(x.$$.fragment,mt),mt.forEach(t),pt.forEach(t),j=u(Ve),F=r(Ve,"SPAN",{"data-svelte-h":!0}),f(F)!=="svelte-14mqaj2"&&(F.textContent=$),Ve.forEach(t),J=u(e),L=r(e,"P",{"data-svelte-h":!0}),f(L)!=="svelte-15mf9cm"&&(L.textContent=w),U=u(e),X=r(e,"P",{"data-svelte-h":!0}),f(X)!=="svelte-1oy12p9"&&(X.innerHTML=ae),c=u(e),Z=r(e,"UL",{"data-svelte-h":!0}),f(Z)!=="svelte-1yyi6js"&&(Z.innerHTML=_l),ft=u(e),R=r(e,"IFRAME",{width:!0,height:!0,src:!0,title:!0,frameborder:!0,allow:!0}),H(R).forEach(t),ct=u(e),v(N.$$.fragment,e),dt=u(e),G=r(e,"H2",{class:!0});var il=H(G);V=r(il,"A",{id:!0,class:!0,href:!0});var na=H(V);lt=r(na,"SPAN",{});var sa=H(lt);v(ne.$$.fragment,sa),sa.forEach(t),na.forEach(t),dl=u(il),qe=r(il,"SPAN",{"data-svelte-h":!0}),f(qe)!=="svelte-ahxkqg"&&(qe.textContent=Ml),il.forEach(t),$t=u(e),se=r(e,"P",{"data-svelte-h":!0}),f(se)!=="svelte-1cn28ug"&&(se.textContent=kl),gt=u(e),oe=r(e,"P",{"data-svelte-h":!0}),f(oe)!=="svelte-1ws64pt"&&(oe.innerHTML=Cl),wt=u(e),re=r(e,"P",{"data-svelte-h":!0}),f(re)!=="svelte-19e11vj"&&(re.innerHTML=Hl),yt=u(e),v(ie.$$.fragment,e),vt=u(e),ue=r(e,"P",{"data-svelte-h":!0}),f(ue)!=="svelte-1p8nvr9"&&(ue.textContent=xl),bt=u(e),pe=r(e,"P",{"data-svelte-h":!0}),f(pe)!=="svelte-hnu2bf"&&(pe.innerHTML=Jl),_t=u(e),E=r(e,"H2",{class:!0});var ul=H(E);q=r(ul,"A",{id:!0,class:!0,href:!0});var oa=H(q);at=r(oa,"SPAN",{});var ra=H(at);v(me.$$.fragment,ra),ra.forEach(t),oa.forEach(t),$l=u(ul),Be=r(ul,"SPAN",{"data-svelte-h":!0}),f(Be)!=="svelte-1bbncge"&&(Be.textContent=jl),ul.forEach(t),Tt=u(e),he=r(e,"P",{"data-svelte-h":!0}),f(he)!=="svelte-16kxv5p"&&(he.innerHTML=Wl),Mt=u(e),v(fe.$$.fragment,e),kt=u(e),ce=r(e,"P",{"data-svelte-h":!0}),f(ce)!=="svelte-tjzd4u"&&(ce.innerHTML=Zl),Ct=u(e),v(de.$$.fragment,e),Ht=u(e),$e=r(e,"P",{"data-svelte-h":!0}),f($e)!=="svelte-obyz8o"&&($e.innerHTML=Ll),xt=u(e),v(ge.$$.fragment,e),Jt=u(e),I=r(e,"H2",{class:!0});var pl=H(I);B=r(pl,"A",{id:!0,class:!0,href:!0});var ia=H(B);nt=r(ia,"SPAN",{});var ua=H(nt);v(we.$$.fragment,ua),ua.forEach(t),ia.forEach(t),gl=u(pl),Qe=r(pl,"SPAN",{"data-svelte-h":!0}),f(Qe)!=="svelte-dplbgf"&&(Qe.textContent=Fl),pl.forEach(t),jt=u(e),ye=r(e,"P",{"data-svelte-h":!0}),f(ye)!=="svelte-9ao4c4"&&(ye.textContent=Ul),Wt=u(e),ve=r(e,"P",{"data-svelte-h":!0}),f(ve)!=="svelte-kq5z9m"&&(ve.innerHTML=Pl),Zt=u(e),v(Q.$$.fragment,e),Lt=u(e),S=r(e,"H2",{class:!0});var ml=H(S);D=r(ml,"A",{id:!0,class:!0,href:!0});var pa=H(D);st=r(pa,"SPAN",{});var ma=H(st);v(be.$$.fragment,ma),ma.forEach(t),pa.forEach(t),wl=u(ml),De=r(ml,"SPAN",{"data-svelte-h":!0}),f(De)!=="svelte-eivpk0"&&(De.textContent=Xl),ml.forEach(t),Ft=u(e),v(K.$$.fragment,e),Ut=u(e),Y=r(e,"H2",{class:!0});var hl=H(Y);O=r(hl,"A",{id:!0,class:!0,href:!0});var ha=H(O);ot=r(ha,"SPAN",{});var fa=H(ot);v(_e.$$.fragment,fa),fa.forEach(t),ha.forEach(t),yl=u(hl),Ke=r(hl,"SPAN",{"data-svelte-h":!0}),f(Ke)!=="svelte-vhcmem"&&(Ke.innerHTML=Rl),hl.forEach(t),Pt=u(e),Te=r(e,"P",{"data-svelte-h":!0}),f(Te)!=="svelte-1ajv3us"&&(Te.innerHTML=Gl),Xt=u(e),Me=r(e,"P",{"data-svelte-h":!0}),f(Me)!=="svelte-1k2vywi"&&(Me.innerHTML=El),Rt=u(e),v(ke.$$.fragment,e),Gt=u(e),Ce=r(e,"P",{"data-svelte-h":!0}),f(Ce)!=="svelte-1t06m9y"&&(Ce.innerHTML=Il),Et=u(e),v(He.$$.fragment,e),It=u(e),xe=r(e,"P",{"data-svelte-h":!0}),f(xe)!=="svelte-mi63rk"&&(xe.innerHTML=Sl),St=u(e),v(Je.$$.fragment,e),Yt=u(e),je=r(e,"P",{"data-svelte-h":!0}),f(je)!=="svelte-gpmj4u"&&(je.innerHTML=Yl),At=u(e),v(We.$$.fragment,e),zt=u(e),Ze=r(e,"P",{"data-svelte-h":!0}),f(Ze)!=="svelte-zov16a"&&(Ze.textContent=Al),Nt=u(e),v(Le.$$.fragment,e),Vt=u(e),Fe=r(e,"P",{"data-svelte-h":!0}),f(Fe)!=="svelte-1j1dvvi"&&(Fe.innerHTML=zl),qt=u(e),Ue=r(e,"P",{"data-svelte-h":!0}),f(Ue)!=="svelte-1nvaa8l"&&(Ue.innerHTML=Nl),Bt=u(e),A=r(e,"H2",{class:!0});var fl=H(A);ee=r(fl,"A",{id:!0,class:!0,href:!0});var ca=H(ee);rt=r(ca,"SPAN",{});var da=H(rt);v(Pe.$$.fragment,da),da.forEach(t),ca.forEach(t),vl=u(fl),Oe=r(fl,"SPAN",{"data-svelte-h":!0}),f(Oe)!=="svelte-35nzmm"&&(Oe.textContent=Vl),fl.forEach(t),Qt=u(e),Xe=r(e,"P",{"data-svelte-h":!0}),f(Xe)!=="svelte-fcl9f1"&&(Xe.innerHTML=ql),Dt=u(e),Re=r(e,"P",{"data-svelte-h":!0}),f(Re)!=="svelte-ahj3l9"&&(Re.innerHTML=Bl),Kt=u(e),Ge=r(e,"P",{"data-svelte-h":!0}),f(Ge)!=="svelte-xicbqw"&&(Ge.textContent=Ql),Ot=u(e),Ee=r(e,"UL",{"data-svelte-h":!0}),f(Ee)!=="svelte-lokm6g"&&(Ee.innerHTML=Dl),el=u(e),Ie=r(e,"P",{"data-svelte-h":!0}),f(Ie)!=="svelte-zmzt5c"&&(Ie.innerHTML=Kl),tl=u(e),Se=r(e,"P",{"data-svelte-h":!0}),f(Se)!=="svelte-32sxm9"&&(Se.innerHTML=Ol),ll=u(e),z=r(e,"H2",{class:!0});var cl=H(z);te=r(cl,"A",{id:!0,class:!0,href:!0});var $a=H(te);it=r($a,"SPAN",{});var ga=H(it);v(Ye.$$.fragment,ga),ga.forEach(t),$a.forEach(t),bl=u(cl),et=r(cl,"SPAN",{"data-svelte-h":!0}),f(et)!=="svelte-2j26ru"&&(et.textContent=ea),cl.forEach(t),al=u(e),Ae=r(e,"P",{"data-svelte-h":!0}),f(Ae)!=="svelte-11tnibt"&&(Ae.innerHTML=ta),nl=u(e),ze=r(e,"UL",{"data-svelte-h":!0}),f(ze)!=="svelte-1rmq5mo"&&(ze.innerHTML=la),sl=u(e),Ne=r(e,"P",{"data-svelte-h":!0}),f(Ne)!=="svelte-15xbiqz"&&(Ne.innerHTML=aa),ol=u(e),ut=r(e,"P",{}),H(ut).forEach(t),this.h()},h(){g(n,"name","hf:doc:metadata"),g(n,"content",JSON.stringify(Ga)),g(m,"id","share-a-model"),g(m,"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"),g(m,"href","#share-a-model"),g(d,"class","relative group"),g(R,"width","560"),g(R,"height","315"),va(R.src,Tl="https://www.youtube.com/embed/XvSGPZFEjDY")||g(R,"src",Tl),g(R,"title","YouTube video player"),g(R,"frameborder","0"),g(R,"allow",`accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope;
picture-in-picture`),R.allowFullscreen="",g(V,"id","repository-features"),g(V,"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"),g(V,"href","#repository-features"),g(G,"class","relative group"),g(q,"id","setup"),g(q,"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"),g(q,"href","#setup"),g(E,"class","relative group"),g(B,"id","convert-a-model-for-all-frameworks"),g(B,"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"),g(B,"href","#convert-a-model-for-all-frameworks"),g(I,"class","relative group"),g(D,"id","push-a-model-during-training"),g(D,"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"),g(D,"href","#push-a-model-during-training"),g(S,"class","relative group"),g(O,"id","use-the-pushtohub-function"),g(O,"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"),g(O,"href","#use-the-pushtohub-function"),g(Y,"class","relative group"),g(ee,"id","upload-with-the-web-interface"),g(ee,"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"),g(ee,"href","#upload-with-the-web-interface"),g(A,"class","relative group"),g(te,"id","add-a-model-card"),g(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"),g(te,"href","#add-a-model-card"),g(z,"class","relative group")},m(e,a){k(document.head,n),l(e,h,a),l(e,s,a),l(e,p,a),l(e,d,a),k(d,m),k(m,C),b(x,C,null),k(d,j),k(d,F),l(e,J,a),l(e,L,a),l(e,U,a),l(e,X,a),l(e,c,a),l(e,Z,a),l(e,ft,a),l(e,R,a),l(e,ct,a),b(N,e,a),l(e,dt,a),l(e,G,a),k(G,V),k(V,lt),b(ne,lt,null),k(G,dl),k(G,qe),l(e,$t,a),l(e,se,a),l(e,gt,a),l(e,oe,a),l(e,wt,a),l(e,re,a),l(e,yt,a),b(ie,e,a),l(e,vt,a),l(e,ue,a),l(e,bt,a),l(e,pe,a),l(e,_t,a),l(e,E,a),k(E,q),k(q,at),b(me,at,null),k(E,$l),k(E,Be),l(e,Tt,a),l(e,he,a),l(e,Mt,a),b(fe,e,a),l(e,kt,a),l(e,ce,a),l(e,Ct,a),b(de,e,a),l(e,Ht,a),l(e,$e,a),l(e,xt,a),b(ge,e,a),l(e,Jt,a),l(e,I,a),k(I,B),k(B,nt),b(we,nt,null),k(I,gl),k(I,Qe),l(e,jt,a),l(e,ye,a),l(e,Wt,a),l(e,ve,a),l(e,Zt,a),b(Q,e,a),l(e,Lt,a),l(e,S,a),k(S,D),k(D,st),b(be,st,null),k(S,wl),k(S,De),l(e,Ft,a),b(K,e,a),l(e,Ut,a),l(e,Y,a),k(Y,O),k(O,ot),b(_e,ot,null),k(Y,yl),k(Y,Ke),l(e,Pt,a),l(e,Te,a),l(e,Xt,a),l(e,Me,a),l(e,Rt,a),b(ke,e,a),l(e,Gt,a),l(e,Ce,a),l(e,Et,a),b(He,e,a),l(e,It,a),l(e,xe,a),l(e,St,a),b(Je,e,a),l(e,Yt,a),l(e,je,a),l(e,At,a),b(We,e,a),l(e,zt,a),l(e,Ze,a),l(e,Nt,a),b(Le,e,a),l(e,Vt,a),l(e,Fe,a),l(e,qt,a),l(e,Ue,a),l(e,Bt,a),l(e,A,a),k(A,ee),k(ee,rt),b(Pe,rt,null),k(A,vl),k(A,Oe),l(e,Qt,a),l(e,Xe,a),l(e,Dt,a),l(e,Re,a),l(e,Kt,a),l(e,Ge,a),l(e,Ot,a),l(e,Ee,a),l(e,el,a),l(e,Ie,a),l(e,tl,a),l(e,Se,a),l(e,ll,a),l(e,z,a),k(z,te),k(te,it),b(Ye,it,null),k(z,bl),k(z,et),l(e,al,a),l(e,Ae,a),l(e,nl,a),l(e,ze,a),l(e,sl,a),l(e,Ne,a),l(e,ol,a),l(e,ut,a),rl=!0},p(e,[a]){const Ve={};a&2&&(Ve.$$scope={dirty:a,ctx:e}),N.$set(Ve);const pt={};a&2&&(pt.$$scope={dirty:a,ctx:e}),Q.$set(pt);const mt={};a&2&&(mt.$$scope={dirty:a,ctx:e}),K.$set(mt)},i(e){rl||(_(x.$$.fragment,e),_(N.$$.fragment,e),_(ne.$$.fragment,e),_(ie.$$.fragment,e),_(me.$$.fragment,e),_(fe.$$.fragment,e),_(de.$$.fragment,e),_(ge.$$.fragment,e),_(we.$$.fragment,e),_(Q.$$.fragment,e),_(be.$$.fragment,e),_(K.$$.fragment,e),_(_e.$$.fragment,e),_(ke.$$.fragment,e),_(He.$$.fragment,e),_(Je.$$.fragment,e),_(We.$$.fragment,e),_(Le.$$.fragment,e),_(Pe.$$.fragment,e),_(Ye.$$.fragment,e),rl=!0)},o(e){T(x.$$.fragment,e),T(N.$$.fragment,e),T(ne.$$.fragment,e),T(ie.$$.fragment,e),T(me.$$.fragment,e),T(fe.$$.fragment,e),T(de.$$.fragment,e),T(ge.$$.fragment,e),T(we.$$.fragment,e),T(Q.$$.fragment,e),T(be.$$.fragment,e),T(K.$$.fragment,e),T(_e.$$.fragment,e),T(ke.$$.fragment,e),T(He.$$.fragment,e),T(Je.$$.fragment,e),T(We.$$.fragment,e),T(Le.$$.fragment,e),T(Pe.$$.fragment,e),T(Ye.$$.fragment,e),rl=!1},d(e){e&&(t(h),t(s),t(p),t(d),t(J),t(L),t(U),t(X),t(c),t(Z),t(ft),t(R),t(ct),t(dt),t(G),t($t),t(se),t(gt),t(oe),t(wt),t(re),t(yt),t(vt),t(ue),t(bt),t(pe),t(_t),t(E),t(Tt),t(he),t(Mt),t(kt),t(ce),t(Ct),t(Ht),t($e),t(xt),t(Jt),t(I),t(jt),t(ye),t(Wt),t(ve),t(Zt),t(Lt),t(S),t(Ft),t(Ut),t(Y),t(Pt),t(Te),t(Xt),t(Me),t(Rt),t(Gt),t(Ce),t(Et),t(It),t(xe),t(St),t(Yt),t(je),t(At),t(zt),t(Ze),t(Nt),t(Vt),t(Fe),t(qt),t(Ue),t(Bt),t(A),t(Qt),t(Xe),t(Dt),t(Re),t(Kt),t(Ge),t(Ot),t(Ee),t(el),t(Ie),t(tl),t(Se),t(ll),t(z),t(al),t(Ae),t(nl),t(ze),t(sl),t(Ne),t(ol),t(ut)),t(n),M(x),M(N,e),M(ne),M(ie,e),M(me),M(fe,e),M(de,e),M(ge,e),M(we),M(Q,e),M(be),M(K,e),M(_e),M(ke,e),M(He,e),M(Je,e),M(We,e),M(Le,e),M(Pe),M(Ye)}}}const Ga={local:"share-a-model",sections:[{local:"repository-features",title:"Repository features"},{local:"setup",title:"Setup"},{local:"convert-a-model-for-all-frameworks",title:"Convert a model for all frameworks"},{local:"push-a-model-during-training",title:"Push a model during training"},{local:"use-the-pushtohub-function",title:"Use the `push_to_hub` function"},{local:"upload-with-the-web-interface",title:"Upload with the web interface"},{local:"add-a-model-card",title:"Add a model card"}],title:"Share a model"};function Ea(W){return ba(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class qa extends _a{constructor(n){super(),Ta(this,n,Ea,Ra,ya,{})}}export{qa as component};
