Buckets:

hf-doc-build/doc / datasets /main /en /_app /immutable /chunks /CodeBlockFw.85ad7f8a.js
rtrm's picture
download
raw
6.37 kB
import{s as q,e as z,z as X,r as Y}from"./scheduler.bdbef820.js";import{S as K,i as M,g as b,h as $,j as y,f as m,k,a as _,o as I,d as h,q as j,b as B,t as g,z as Z,s as D,m as x,c as S,n as ee,D as C,p as te,r as V,u as w,e as O,v as P,w as N,x as E,H as U,E as A}from"./index.6a1ed56b.js";import{g as J,I as ne,a as oe}from"./IconTensorflow.58baa544.js";import{a as L}from"./CodeBlock.995edef9.js";import{e as R}from"./each.e59479a4.js";function F(s,e,n){const r=s.slice();return r[8]=e[n],r[10]=n,r}function G(s){let e,n,r;var i=s[8].icon;function o(c,l){return{props:{classNames:"mr-1.5"}}}return i&&(e=V(i,o())),{c(){e&&w(e.$$.fragment),n=O()},l(c){e&&P(e.$$.fragment,c),n=O()},m(c,l){e&&N(e,c,l),_(c,n,l),r=!0},p(c,l){if(l&1&&i!==(i=c[8].icon)){if(e){j();const u=e;g(u.$$.fragment,1,0,()=>{E(u,1)}),B()}i?(e=V(i,o()),w(e.$$.fragment),h(e.$$.fragment,1),N(e,n.parentNode,n)):e=null}},i(c){r||(e&&h(e.$$.fragment,c),r=!0)},o(c){e&&g(e.$$.fragment,c),r=!1},d(c){c&&m(n),e&&E(e,c)}}}function H(s){let e,n,r,i=s[8].name+"",o,c,l,u,t,a,f,p=s[8].icon&&G(s);function W(){return s[6](s[8])}return{c(){e=b("button"),p&&p.c(),n=D(),r=b("p"),o=x(i),l=D(),this.h()},l(v){e=$(v,"BUTTON",{class:!0});var d=y(e);p&&p.l(d),n=S(d),r=$(d,"P",{class:!0});var T=y(r);o=ee(T,i),T.forEach(m),l=S(d),d.forEach(m),this.h()},h(){k(r,"class",c="!m-0 "+s[8].classNames),k(e,"class",u="flex justify-center py-1.5 px-2.5 focus:outline-none rounded-"+(s[10]?"r":"l")+" "+(s[8].group!==s[1]&&"text-gray-500 filter grayscale"))},m(v,d){_(v,e,d),p&&p.m(e,null),I(e,n),I(e,r),I(r,o),I(e,l),t=!0,a||(f=C(e,"click",W),a=!0)},p(v,d){s=v,s[8].icon?p?(p.p(s,d),d&1&&h(p,1)):(p=G(s),p.c(),h(p,1),p.m(e,n)):p&&(j(),g(p,1,1,()=>{p=null}),B()),(!t||d&1)&&i!==(i=s[8].name+"")&&te(o,i),(!t||d&1&&c!==(c="!m-0 "+s[8].classNames))&&k(r,"class",c),(!t||d&3&&u!==(u="flex justify-center py-1.5 px-2.5 focus:outline-none rounded-"+(s[10]?"r":"l")+" "+(s[8].group!==s[1]&&"text-gray-500 filter grayscale")))&&k(e,"class",u)},i(v){t||(h(p),t=!0)},o(v){g(p),t=!1},d(v){v&&m(e),p&&p.d(),a=!1,f()}}}function re(s){let e,n,r,i=R(s[3].filter(s[5])),o=[];for(let l=0;l<i.length;l+=1)o[l]=H(F(s,i,l));const c=l=>g(o[l],1,1,()=>{o[l]=null});return{c(){e=b("div"),n=b("div");for(let l=0;l<o.length;l+=1)o[l].c();this.h()},l(l){e=$(l,"DIV",{});var u=y(e);n=$(u,"DIV",{class:!0});var t=y(n);for(let a=0;a<o.length;a+=1)o[a].l(t);t.forEach(m),u.forEach(m),this.h()},h(){k(n,"class","bg-white leading-none border border-gray-100 rounded-lg inline-flex p-0.5 text-sm mb-4 select-none")},m(l,u){_(l,e,u),I(e,n);for(let t=0;t<o.length;t+=1)o[t]&&o[t].m(n,null);r=!0},p(l,[u]){if(u&27){i=R(l[3].filter(l[5]));let t;for(t=0;t<i.length;t+=1){const a=F(l,i,t);o[t]?(o[t].p(a,u),h(o[t],1)):(o[t]=H(a),o[t].c(),h(o[t],1),o[t].m(n,null))}for(j(),t=i.length;t<o.length;t+=1)c(t);B()}},i(l){if(!r){for(let u=0;u<i.length;u+=1)h(o[u]);r=!0}},o(l){o=o.filter(Boolean);for(let u=0;u<o.length;u+=1)g(o[u]);r=!1},d(l){l&&m(e),Z(o,l)}}}function se(s,e,n){let r,{ids:i}=e;const o=i.join("-"),c=J(o);z(s,c,f=>n(1,r=f));const l=[{id:"pt",classNames:"",icon:ne,name:"Pytorch",group:"group1"},{id:"tf",classNames:"",icon:oe,name:"TensorFlow",group:"group2"},{id:"stringapi",classNames:"text-blue-600",name:"String API",group:"group1"},{id:"readinstruction",classNames:"text-blue-600",name:"ReadInstruction",group:"group2"}];function u(f){X(c,r=f,r)}const t=f=>i.includes(f.id),a=f=>u(f.group);return s.$$set=f=>{"ids"in f&&n(0,i=f.ids)},[i,r,c,l,u,t,a]}class Q extends K{constructor(e){super(),M(this,e,se,re,q,{ids:0})}}function le(s){let e,n,r,i,o,c,l=s[1].highlighted+"",u;return n=new L({props:{classNames:"transition duration-200 ease-in-out "+(s[2]&&"opacity-0"),title:"Copy code excerpt to clipboard",value:s[1].code}}),o=new Q({props:{ids:s[4]}}),{c(){e=b("div"),w(n.$$.fragment),r=D(),i=b("pre"),w(o.$$.fragment),c=new U(!1),this.h()},l(t){e=$(t,"DIV",{class:!0});var a=y(e);P(n.$$.fragment,a),a.forEach(m),r=S(t),i=$(t,"PRE",{});var f=y(i);P(o.$$.fragment,f),c=A(f,!1),f.forEach(m),this.h()},h(){k(e,"class","absolute top-2.5 right-4"),c.a=null},m(t,a){_(t,e,a),N(n,e,null),_(t,r,a),_(t,i,a),N(o,i,null),c.m(l,i),u=!0},p(t,a){const f={};a&4&&(f.classNames="transition duration-200 ease-in-out "+(t[2]&&"opacity-0")),a&2&&(f.value=t[1].code),n.$set(f),(!u||a&2)&&l!==(l=t[1].highlighted+"")&&c.p(l)},i(t){u||(h(n.$$.fragment,t),h(o.$$.fragment,t),u=!0)},o(t){g(n.$$.fragment,t),g(o.$$.fragment,t),u=!1},d(t){t&&(m(e),m(r),m(i)),E(n),E(o)}}}function ae(s){let e,n,r,i,o,c,l=s[0].highlighted+"",u;return n=new L({props:{classNames:"transition duration-200 ease-in-out "+(s[2]&&"opacity-0"),title:"Copy code excerpt to clipboard",value:s[0].code}}),o=new Q({props:{ids:s[4]}}),{c(){e=b("div"),w(n.$$.fragment),r=D(),i=b("pre"),w(o.$$.fragment),c=new U(!1),this.h()},l(t){e=$(t,"DIV",{class:!0});var a=y(e);P(n.$$.fragment,a),a.forEach(m),r=S(t),i=$(t,"PRE",{});var f=y(i);P(o.$$.fragment,f),c=A(f,!1),f.forEach(m),this.h()},h(){k(e,"class","absolute top-2.5 right-4"),c.a=null},m(t,a){_(t,e,a),N(n,e,null),_(t,r,a),_(t,i,a),N(o,i,null),c.m(l,i),u=!0},p(t,a){const f={};a&4&&(f.classNames="transition duration-200 ease-in-out "+(t[2]&&"opacity-0")),a&1&&(f.value=t[0].code),n.$set(f),(!u||a&1)&&l!==(l=t[0].highlighted+"")&&c.p(l)},i(t){u||(h(n.$$.fragment,t),h(o.$$.fragment,t),u=!0)},o(t){g(n.$$.fragment,t),g(o.$$.fragment,t),u=!1},d(t){t&&(m(e),m(r),m(i)),E(n),E(o)}}}function ie(s){let e,n,r,i,o,c;const l=[ae,le],u=[];function t(a,f){return a[3]==="group1"?0:1}return n=t(s),r=u[n]=l[n](s),{c(){e=b("div"),r.c(),this.h()},l(a){e=$(a,"DIV",{class:!0});var f=y(e);r.l(f),f.forEach(m),this.h()},h(){k(e,"class","code-block relative")},m(a,f){_(a,e,f),u[n].m(e,null),i=!0,o||(c=[C(e,"mouseover",s[6]),C(e,"focus",s[6]),C(e,"mouseout",s[7]),C(e,"focus",s[7])],o=!0)},p(a,[f]){let p=n;n=t(a),n===p?u[n].p(a,f):(j(),g(u[p],1,1,()=>{u[p]=null}),B(),r=u[n],r?r.p(a,f):(r=u[n]=l[n](a),r.c()),h(r,1),r.m(e,null))},i(a){i||(h(r),i=!0)},o(a){g(r),i=!1},d(a){a&&m(e),u[n].d(),o=!1,Y(c)}}}function ue(s,e,n){let r,{group1:i}=e,{group2:o}=e;const c=[i.id,o.id],l=c.join("-"),u=J(l);z(s,u,p=>n(3,r=p));let t=!0;function a(){n(2,t=!1)}function f(){n(2,t=!0)}return s.$$set=p=>{"group1"in p&&n(0,i=p.group1),"group2"in p&&n(1,o=p.group2)},[i,o,t,r,c,u,a,f]}class de extends K{constructor(e){super(),M(this,e,ue,ie,q,{group1:0,group2:1})}}export{de as C};

Xet Storage Details

Size:
6.37 kB
·
Xet hash:
b6604d953d5b9de94d0398dbde9913cc9d8dd93ffd266da16b6633ac8ca715d4

Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.