import{s as zt,o as Yt,n as St}from"../chunks/scheduler.f3b1e791.js";import{S as At,i as Ot,e as i,s as o,c,h as en,a as d,d as n,b as l,f as I,g as p,j as h,k as J,l as a,m as r,n as m,t as k,o as u,p as f}from"../chunks/index.023a9934.js";import{C as tn}from"../chunks/CopyLLMTxtMenu.ee636735.js";import{D as Z,E as Kt}from"../chunks/ExampleCodeBlock.1b5fd494.js";import{C as Qt}from"../chunks/CodeBlock.5aa52fca.js";import{H as C,E as nn}from"../chunks/MermaidChart.svelte_svelte_type_style_lang.9b009efe.js";function on(ke){let g,j="Example:",b,$,_;return $=new Qt({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwa2VybmVscyUyMGltcG9ydCUyMGdldF9rZXJuZWwlMEElMEFhY3RpdmF0aW9uJTIwJTNEJTIwZ2V0X2tlcm5lbCglMjJrZXJuZWxzLWNvbW11bml0eSUyRnJlbHUlMjIlMkMlMjB2ZXJzaW9uJTNEMSklMEF4JTIwJTNEJTIwdG9yY2gucmFuZG4oMTAlMkMlMjAyMCUyQyUyMGRldmljZSUzRCUyMmN1ZGElMjIpJTBBb3V0JTIwJTNEJTIwdG9yY2guZW1wdHlfbGlrZSh4KSUwQXJlc3VsdCUyMCUzRCUyMGFjdGl2YXRpb24ucmVsdShvdXQlMkMlMjB4KQ==",highlighted:`<span class="hljs-keyword">import</span> torch
<span class="hljs-keyword">from</span> kernels <span class="hljs-keyword">import</span> get_kernel

activation = get_kernel(<span class="hljs-string">&quot;kernels-community/relu&quot;</span>, version=<span class="hljs-number">1</span>)
x = torch.randn(<span class="hljs-number">10</span>, <span class="hljs-number">20</span>, device=<span class="hljs-string">&quot;cuda&quot;</span>)
out = torch.empty_like(x)
result = activation.relu(out, x)`,wrap:!1}}),{c(){g=i("p"),g.textContent=j,b=o(),c($.$$.fragment)},l(s){g=d(s,"P",{"data-svelte-h":!0}),h(g)!=="svelte-11lpom8"&&(g.textContent=j),b=l(s),p($.$$.fragment,s)},m(s,v){r(s,g,v),r(s,b,v),m($,s,v),_=!0},p:St,i(s){_||(k($.$$.fragment,s),_=!0)},o(s){u($.$$.fragment,s),_=!1},d(s){s&&(n(g),n(b)),f($,s)}}}function ln(ke){let g,j="Example:",b,$,_;return $=new Qt({props:{code:"ZnJvbSUyMGtlcm5lbHMlMjBpbXBvcnQlMjBnZXRfa2VybmVsJTJDJTIwZ2V0X2xvYWRlZF9rZXJuZWxzJTBBJTBBZ2V0X2tlcm5lbCglMjJrZXJuZWxzLWNvbW11bml0eSUyRmFjdGl2YXRpb24lMjIlMkMlMjB2ZXJzaW9uJTNEMSklMEFmb3IlMjBsb2FkZWQlMjBpbiUyMGdldF9sb2FkZWRfa2VybmVscygpJTNBJTBBJTIwJTIwJTIwJTIwcHJpbnQobG9hZGVkLm1ldGFkYXRhLm5hbWUlMkMlMjBsb2FkZWQucmVwb19pbmZvKQ==",highlighted:`<span class="hljs-keyword">from</span> kernels <span class="hljs-keyword">import</span> get_kernel, get_loaded_kernels

get_kernel(<span class="hljs-string">&quot;kernels-community/activation&quot;</span>, version=<span class="hljs-number">1</span>)
<span class="hljs-keyword">for</span> loaded <span class="hljs-keyword">in</span> get_loaded_kernels():
    <span class="hljs-built_in">print</span>(loaded.metadata.name, loaded.repo_info)`,wrap:!1}}),{c(){g=i("p"),g.textContent=j,b=o(),c($.$$.fragment)},l(s){g=d(s,"P",{"data-svelte-h":!0}),h(g)!=="svelte-11lpom8"&&(g.textContent=j),b=l(s),p($.$$.fragment,s)},m(s,v){r(s,g,v),r(s,b,v),m($,s,v),_=!0},p:St,i(s){_||(k($.$$.fragment,s),_=!0)},o(s){u($.$$.fragment,s),_=!1},d(s){s&&(n(g),n(b)),f($,s)}}}function rn(ke){let g,j,b,$,_,s,v,Ne,G,Pe,U,qe,y,B,it,ue,Mt="Load a kernel from the kernel hub.",dt,fe,Lt=`This function downloads a kernel to the local Hugging Face Hub cache directory (if it was not downloaded before)
and then loads the kernel.`,ct,D,He,W,Ze,N,X,pt,ge,It="Import a kernel from a local kernel repository path.",De,K,Re,P,S,mt,he,Jt="Check whether a kernel build exists for the current environment (Torch version and compute framework).",Ve,Q,Fe,T,z,kt,$e,jt="Return a snapshot of every kernel that has been loaded into the current process.",ut,_e,Et="The returned list is a new list; mutating it does not affect the registry.",ft,R,Ge,Y,Ue,A,Be,M,O,gt,be,Nt="Get a pre-downloaded, locked kernel.",ht,ve,Pt="If <code>lockfile</code> is not specified, the lockfile will be loaded from the caller’s package metadata.",We,ee,Xe,te,qt="<<<<<<< kernels-use-kernels-data",Ke,q,ne,$t,xe,Ht="Get a kernel using a lock file.",Se,oe,Qe,le,ze,x,re,_t,ye,Zt="This dataclass provides information about a loaded kernel:",bt,Te,Dt=`<li><code>metadata</code> (<code>Metadata</code>): kernel metadata.</li> <li><code>module</code> (<code>ModuleType</code>): the imported kernel module.</li> <li><code>repo_info</code> (<code>kernels.utils.RepoInfo | None</code>): populated only for
kernels loaded via <code>get_kernel</code>. Loaders that work from a local path
(<code>get_local_kernel</code>) or a lockfile (<code>get_locked_kernel</code>, <code>load_kernel</code>)
leave this as <code>None</code>.</li>`,vt,we,Rt="The metadata includes the following properties that describe a kernel:",xt,Ce,Vt="<li><code>id</code> (<code>str</code>): kernel identifier that is unique to the kernel version + backend.</li> <li><code>name</code> (<code>str</code>): the name of the kernel.</li> <li><code>version</code> (<code>int</code>): the version of the kernel.</li> <li><code>license</code> (<code>str</code>): the license of the kernel.</li> <li><code>upstream</code> (<code>str | None</code>): the upstream repository of the kernel.</li> <li><code>python_depends</code> (<code>list[str]</code>): required Python dependencies.</li> <li><code>backend</code>: information about the kernel’s backend.</li>",Ye,ae,Ae,w,se,yt,Me,Ft="This dataclass stores the origin of the kernel.",Tt,Le,Gt="The following fields are available:",wt,Ie,Ut="<li><code>repo_id</code> (<code>str</code>): the Hub repository containing the kernel.</li> <li><code>revision</code> (<code>str</code>): the specific revision of the kernel.</li>",Oe,ie,Bt="=======",et,H,de,Ct,Je,Wt="Get a kernel using a lock file.",tt,ce,Xt="<blockquote><blockquote><blockquote><blockquote><blockquote><blockquote><p>main</p></blockquote></blockquote></blockquote></blockquote></blockquote></blockquote>",nt,pe,ot,Ee,lt;return _=new tn({props:{containerStyle:"float: right; margin-left: 10px; display: inline-flex; position: relative; z-index: 10;"}}),v=new C({props:{title:"Kernels API Reference",local:"kernels-api-reference",headingTag:"h1"}}),G=new C({props:{title:"Main Functions",local:"main-functions",headingTag:"h2"}}),U=new C({props:{title:"get_kernel",local:"kernels.get_kernel",headingTag:"h3"}}),B=new Z({props:{name:"kernels.get_kernel",anchor:"kernels.get_kernel",parameters:[{name:"repo_id",val:": str"},{name:"revision",val:": str | None = None"},{name:"version",val:": int | None = None"},{name:"backend",val:": str | None = None"},{name:"user_agent",val:": str | dict | None = None"}],parametersDescription:[{anchor:"kernels.get_kernel.repo_id",description:`<strong>repo_id</strong> (<code>str</code>) &#x2014;
The Hub repository containing the kernel.`,name:"repo_id"},{anchor:"kernels.get_kernel.revision",description:`<strong>revision</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;main&quot;</code>) &#x2014;
The specific revision (branch, tag, or commit) to download. Cannot be used together with <code>version</code>.`,name:"revision"},{anchor:"kernels.get_kernel.version",description:`<strong>version</strong> (<code>int</code>, <em>optional</em>) &#x2014;
The kernel version to download. Cannot be used together with <code>revision</code>.`,name:"version"},{anchor:"kernels.get_kernel.backend",description:`<strong>backend</strong> (<code>str</code>, <em>optional</em>) &#x2014;
The backend to load the kernel for. Can only be <code>cpu</code> or the backend that Torch is compiled for.
The backend will be detected automatically if not provided.`,name:"backend"},{anchor:"kernels.get_kernel.user_agent",description:`<strong>user_agent</strong> (<code>Union[str, dict]</code>, <em>optional</em>) &#x2014;
The <code>user_agent</code> info to pass to <code>snapshot_download()</code> for internal telemetry.`,name:"user_agent"}],source:"https://github.com/huggingface/kernels/blob/main/kernels/src/kernels/utils.py#L290",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>


<p>The imported kernel module.</p>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>


<p><code>ModuleType</code></p>
`}}),D=new Kt({props:{anchor:"kernels.get_kernel.example",$$slots:{default:[on]},$$scope:{ctx:ke}}}),W=new C({props:{title:"get_local_kernel",local:"kernels.get_local_kernel",headingTag:"h3"}}),X=new Z({props:{name:"kernels.get_local_kernel",anchor:"kernels.get_local_kernel",parameters:[{name:"repo_path",val:": Path"},{name:"backend",val:": str | None = None"}],parametersDescription:[{anchor:"kernels.get_local_kernel.repo_path",description:`<strong>repo_path</strong> (<code>Path</code>) &#x2014;
The local path to the kernel repository.`,name:"repo_path"},{anchor:"kernels.get_local_kernel.backend",description:`<strong>backend</strong> (<code>str</code>, <em>optional</em>) &#x2014;
The backend to load the kernel for. Can only be <code>cpu</code> or the backend that Torch is compiled for.
The backend will be detected automatically if not provided.`,name:"backend"}],source:"https://github.com/huggingface/kernels/blob/main/kernels/src/kernels/utils.py#L348",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>


<p>The imported kernel module.</p>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>


<p><code>ModuleType</code></p>
`}}),K=new C({props:{title:"has_kernel",local:"kernels.has_kernel",headingTag:"h3"}}),S=new Z({props:{name:"kernels.has_kernel",anchor:"kernels.has_kernel",parameters:[{name:"repo_id",val:": str"},{name:"revision",val:": str | None = None"},{name:"version",val:": int | None = None"},{name:"backend",val:": str | None = None"}],parametersDescription:[{anchor:"kernels.has_kernel.repo_id",description:`<strong>repo_id</strong> (<code>str</code>) &#x2014;
The Hub repository containing the kernel.`,name:"repo_id"},{anchor:"kernels.has_kernel.revision",description:`<strong>revision</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;main&quot;</code>) &#x2014;
The specific revision (branch, tag, or commit) to download. Cannot be used together with <code>version</code>.`,name:"revision"},{anchor:"kernels.has_kernel.version",description:`<strong>version</strong> (<code>int</code>, <em>optional</em>) &#x2014;
The kernel version to download. Cannot be used together with <code>revision</code>.`,name:"version"},{anchor:"kernels.has_kernel.backend",description:`<strong>backend</strong> (<code>str</code>, <em>optional</em>) &#x2014;
The backend to load the kernel for. Can only be <code>cpu</code> or the backend that Torch is compiled for.
The backend will be detected automatically if not provided.`,name:"backend"}],source:"https://github.com/huggingface/kernels/blob/main/kernels/src/kernels/utils.py#L381",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>


<p><code>True</code> if a kernel is available for the current environment.</p>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>


<p><code>bool</code></p>
`}}),Q=new C({props:{title:"get_loaded_kernels",local:"kernels.get_loaded_kernels",headingTag:"h3"}}),z=new Z({props:{name:"kernels.get_loaded_kernels",anchor:"kernels.get_loaded_kernels",parameters:[],source:"https://github.com/huggingface/kernels/blob/main/kernels/src/kernels/utils.py#L81",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>


<p>One <a
  href="/docs/kernels/main/en/api/kernels#kernels.LoadedKernel"
>LoadedKernel</a> per distinct kernel variant path
loaded in this process.</p>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>


<p><code>list[LoadedKernel]</code></p>
`}}),R=new Kt({props:{anchor:"kernels.get_loaded_kernels.example",$$slots:{default:[ln]},$$scope:{ctx:ke}}}),Y=new C({props:{title:"Loading locked kernels",local:"loading-locked-kernels",headingTag:"h2"}}),A=new C({props:{title:"load_kernel",local:"kernels.load_kernel",headingTag:"h3"}}),O=new Z({props:{name:"kernels.load_kernel",anchor:"kernels.load_kernel",parameters:[{name:"repo_id",val:": str"},{name:"lockfile",val:": pathlib.Path | None"},{name:"backend",val:": str | None = None"}],parametersDescription:[{anchor:"kernels.load_kernel.repo_id",description:`<strong>repo_id</strong> (<code>str</code>) &#x2014;
The Hub repository containing the kernel.`,name:"repo_id"},{anchor:"kernels.load_kernel.lockfile",description:`<strong>lockfile</strong> (<code>Path</code>, <em>optional</em>) &#x2014;
Path to the lockfile. If not provided, the lockfile will be loaded from the caller&#x2019;s package metadata.`,name:"lockfile"},{anchor:"kernels.load_kernel.backend",description:`<strong>backend</strong> (<code>str</code>, <em>optional</em>) &#x2014;
The backend to load the kernel for. Can only be <code>cpu</code> or the backend that Torch is compiled for.
The backend will be detected automatically if not provided.`,name:"backend"}],source:"https://github.com/huggingface/kernels/blob/main/kernels/src/kernels/utils.py#L421",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>


<p>The imported kernel module.</p>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>


<p><code>ModuleType</code></p>
`}}),ee=new C({props:{title:"get_locked_kernel",local:"kernels.get_locked_kernel",headingTag:"h3"}}),ne=new Z({props:{name:"kernels.get_locked_kernel",anchor:"kernels.get_locked_kernel",parameters:[{name:"repo_id",val:": str"},{name:"local_files_only",val:": bool = False"}],parametersDescription:[{anchor:"kernels.get_locked_kernel.repo_id",description:`<strong>repo_id</strong> (<code>str</code>) &#x2014;
The Hub repository containing the kernel.`,name:"repo_id"},{anchor:"kernels.get_locked_kernel.local_files_only",description:`<strong>local_files_only</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether to only use local files and not download from the Hub.`,name:"local_files_only"}],source:"https://github.com/huggingface/kernels/blob/main/kernels/src/kernels/utils.py#L491",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>


<p>The imported kernel module.</p>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>


<p><code>ModuleType</code></p>
`}}),oe=new C({props:{title:"Classes",local:"classes",headingTag:"h2"}}),le=new C({props:{title:"LoadedKernel",local:"kernels.LoadedKernel",headingTag:"h3"}}),re=new Z({props:{name:"class kernels.LoadedKernel",anchor:"kernels.LoadedKernel",parameters:[{name:"metadata",val:": Metadata"},{name:"module",val:": module"},{name:"repo_info",val:": kernels.utils.RepoInfo | None"}],source:"https://github.com/huggingface/kernels/blob/main/kernels/src/kernels/utils.py#L51"}}),ae=new C({props:{title:"RepoInfo",local:"kernels.RepoInfo",headingTag:"h3"}}),se=new Z({props:{name:"class kernels.RepoInfo",anchor:"kernels.RepoInfo",parameters:[{name:"repo_id",val:": str"},{name:"revision",val:": str"}],source:"https://github.com/huggingface/kernels/blob/main/kernels/src/kernels/utils.py#L36"}}),de=new Z({props:{name:"kernels.get_locked_kernel",anchor:"kernels.get_locked_kernel",parameters:[{name:"repo_id",val:": str"},{name:"local_files_only",val:": bool = False"}],parametersDescription:[{anchor:"kernels.get_locked_kernel.repo_id",description:`<strong>repo_id</strong> (<code>str</code>) &#x2014;
The Hub repository containing the kernel.`,name:"repo_id"},{anchor:"kernels.get_locked_kernel.local_files_only",description:`<strong>local_files_only</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether to only use local files and not download from the Hub.`,name:"local_files_only"}],source:"https://github.com/huggingface/kernels/blob/main/kernels/src/kernels/utils.py#L491",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>


<p>The imported kernel module.</p>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>


<p><code>ModuleType</code></p>
`}}),pe=new nn({props:{source:"https://github.com/huggingface/kernels/blob/main/docs/source/api/kernels.md"}}),{c(){g=i("meta"),j=o(),b=i("p"),$=o(),c(_.$$.fragment),s=o(),c(v.$$.fragment),Ne=o(),c(G.$$.fragment),Pe=o(),c(U.$$.fragment),qe=o(),y=i("div"),c(B.$$.fragment),it=o(),ue=i("p"),ue.textContent=Mt,dt=o(),fe=i("p"),fe.textContent=Lt,ct=o(),c(D.$$.fragment),He=o(),c(W.$$.fragment),Ze=o(),N=i("div"),c(X.$$.fragment),pt=o(),ge=i("p"),ge.textContent=It,De=o(),c(K.$$.fragment),Re=o(),P=i("div"),c(S.$$.fragment),mt=o(),he=i("p"),he.textContent=Jt,Ve=o(),c(Q.$$.fragment),Fe=o(),T=i("div"),c(z.$$.fragment),kt=o(),$e=i("p"),$e.textContent=jt,ut=o(),_e=i("p"),_e.textContent=Et,ft=o(),c(R.$$.fragment),Ge=o(),c(Y.$$.fragment),Ue=o(),c(A.$$.fragment),Be=o(),M=i("div"),c(O.$$.fragment),gt=o(),be=i("p"),be.textContent=Nt,ht=o(),ve=i("p"),ve.innerHTML=Pt,We=o(),c(ee.$$.fragment),Xe=o(),te=i("p"),te.textContent=qt,Ke=o(),q=i("div"),c(ne.$$.fragment),$t=o(),xe=i("p"),xe.textContent=Ht,Se=o(),c(oe.$$.fragment),Qe=o(),c(le.$$.fragment),ze=o(),x=i("div"),c(re.$$.fragment),_t=o(),ye=i("p"),ye.textContent=Zt,bt=o(),Te=i("ul"),Te.innerHTML=Dt,vt=o(),we=i("p"),we.textContent=Rt,xt=o(),Ce=i("ul"),Ce.innerHTML=Vt,Ye=o(),c(ae.$$.fragment),Ae=o(),w=i("div"),c(se.$$.fragment),yt=o(),Me=i("p"),Me.textContent=Ft,Tt=o(),Le=i("p"),Le.textContent=Gt,wt=o(),Ie=i("ul"),Ie.innerHTML=Ut,Oe=o(),ie=i("p"),ie.textContent=Bt,et=o(),H=i("div"),c(de.$$.fragment),Ct=o(),Je=i("p"),Je.textContent=Wt,tt=o(),ce=i("blockquote"),ce.innerHTML=Xt,nt=o(),c(pe.$$.fragment),ot=o(),Ee=i("p"),this.h()},l(e){const t=en("svelte-u9bgzb",document.head);g=d(t,"META",{name:!0,content:!0}),t.forEach(n),j=l(e),b=d(e,"P",{}),I(b).forEach(n),$=l(e),p(_.$$.fragment,e),s=l(e),p(v.$$.fragment,e),Ne=l(e),p(G.$$.fragment,e),Pe=l(e),p(U.$$.fragment,e),qe=l(e),y=d(e,"DIV",{class:!0});var L=I(y);p(B.$$.fragment,L),it=l(L),ue=d(L,"P",{"data-svelte-h":!0}),h(ue)!=="svelte-v6pak5"&&(ue.textContent=Mt),dt=l(L),fe=d(L,"P",{"data-svelte-h":!0}),h(fe)!=="svelte-1adbar6"&&(fe.textContent=Lt),ct=l(L),p(D.$$.fragment,L),L.forEach(n),He=l(e),p(W.$$.fragment,e),Ze=l(e),N=d(e,"DIV",{class:!0});var me=I(N);p(X.$$.fragment,me),pt=l(me),ge=d(me,"P",{"data-svelte-h":!0}),h(ge)!=="svelte-ysgxyb"&&(ge.textContent=It),me.forEach(n),De=l(e),p(K.$$.fragment,e),Re=l(e),P=d(e,"DIV",{class:!0});var rt=I(P);p(S.$$.fragment,rt),mt=l(rt),he=d(rt,"P",{"data-svelte-h":!0}),h(he)!=="svelte-oel36i"&&(he.textContent=Jt),rt.forEach(n),Ve=l(e),p(Q.$$.fragment,e),Fe=l(e),T=d(e,"DIV",{class:!0});var V=I(T);p(z.$$.fragment,V),kt=l(V),$e=d(V,"P",{"data-svelte-h":!0}),h($e)!=="svelte-hargcl"&&($e.textContent=jt),ut=l(V),_e=d(V,"P",{"data-svelte-h":!0}),h(_e)!=="svelte-bvc5k7"&&(_e.textContent=Et),ft=l(V),p(R.$$.fragment,V),V.forEach(n),Ge=l(e),p(Y.$$.fragment,e),Ue=l(e),p(A.$$.fragment,e),Be=l(e),M=d(e,"DIV",{class:!0});var je=I(M);p(O.$$.fragment,je),gt=l(je),be=d(je,"P",{"data-svelte-h":!0}),h(be)!=="svelte-1s7s7e5"&&(be.textContent=Nt),ht=l(je),ve=d(je,"P",{"data-svelte-h":!0}),h(ve)!=="svelte-16266qf"&&(ve.innerHTML=Pt),je.forEach(n),We=l(e),p(ee.$$.fragment,e),Xe=l(e),te=d(e,"P",{"data-svelte-h":!0}),h(te)!=="svelte-1pcuyo"&&(te.textContent=qt),Ke=l(e),q=d(e,"DIV",{class:!0});var at=I(q);p(ne.$$.fragment,at),$t=l(at),xe=d(at,"P",{"data-svelte-h":!0}),h(xe)!=="svelte-ui0v8u"&&(xe.textContent=Ht),at.forEach(n),Se=l(e),p(oe.$$.fragment,e),Qe=l(e),p(le.$$.fragment,e),ze=l(e),x=d(e,"DIV",{class:!0});var E=I(x);p(re.$$.fragment,E),_t=l(E),ye=d(E,"P",{"data-svelte-h":!0}),h(ye)!=="svelte-10yajky"&&(ye.textContent=Zt),bt=l(E),Te=d(E,"UL",{"data-svelte-h":!0}),h(Te)!=="svelte-1133git"&&(Te.innerHTML=Dt),vt=l(E),we=d(E,"P",{"data-svelte-h":!0}),h(we)!=="svelte-eh9buy"&&(we.textContent=Rt),xt=l(E),Ce=d(E,"UL",{"data-svelte-h":!0}),h(Ce)!=="svelte-qcje4a"&&(Ce.innerHTML=Vt),E.forEach(n),Ye=l(e),p(ae.$$.fragment,e),Ae=l(e),w=d(e,"DIV",{class:!0});var F=I(w);p(se.$$.fragment,F),yt=l(F),Me=d(F,"P",{"data-svelte-h":!0}),h(Me)!=="svelte-1qmhf0s"&&(Me.textContent=Ft),Tt=l(F),Le=d(F,"P",{"data-svelte-h":!0}),h(Le)!=="svelte-1j3sm3i"&&(Le.textContent=Gt),wt=l(F),Ie=d(F,"UL",{"data-svelte-h":!0}),h(Ie)!=="svelte-nl2d40"&&(Ie.innerHTML=Ut),F.forEach(n),Oe=l(e),ie=d(e,"P",{"data-svelte-h":!0}),h(ie)!=="svelte-756rwd"&&(ie.textContent=Bt),et=l(e),H=d(e,"DIV",{class:!0});var st=I(H);p(de.$$.fragment,st),Ct=l(st),Je=d(st,"P",{"data-svelte-h":!0}),h(Je)!=="svelte-ui0v8u"&&(Je.textContent=Wt),st.forEach(n),tt=l(e),ce=d(e,"BLOCKQUOTE",{"data-svelte-h":!0}),h(ce)!=="svelte-1bl9tk8"&&(ce.innerHTML=Xt),nt=l(e),p(pe.$$.fragment,e),ot=l(e),Ee=d(e,"P",{}),I(Ee).forEach(n),this.h()},h(){J(g,"name","hf:doc:metadata"),J(g,"content",an),J(y,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),J(N,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),J(P,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),J(T,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),J(M,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),J(q,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),J(x,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),J(w,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),J(H,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8")},m(e,t){a(document.head,g),r(e,j,t),r(e,b,t),r(e,$,t),m(_,e,t),r(e,s,t),m(v,e,t),r(e,Ne,t),m(G,e,t),r(e,Pe,t),m(U,e,t),r(e,qe,t),r(e,y,t),m(B,y,null),a(y,it),a(y,ue),a(y,dt),a(y,fe),a(y,ct),m(D,y,null),r(e,He,t),m(W,e,t),r(e,Ze,t),r(e,N,t),m(X,N,null),a(N,pt),a(N,ge),r(e,De,t),m(K,e,t),r(e,Re,t),r(e,P,t),m(S,P,null),a(P,mt),a(P,he),r(e,Ve,t),m(Q,e,t),r(e,Fe,t),r(e,T,t),m(z,T,null),a(T,kt),a(T,$e),a(T,ut),a(T,_e),a(T,ft),m(R,T,null),r(e,Ge,t),m(Y,e,t),r(e,Ue,t),m(A,e,t),r(e,Be,t),r(e,M,t),m(O,M,null),a(M,gt),a(M,be),a(M,ht),a(M,ve),r(e,We,t),m(ee,e,t),r(e,Xe,t),r(e,te,t),r(e,Ke,t),r(e,q,t),m(ne,q,null),a(q,$t),a(q,xe),r(e,Se,t),m(oe,e,t),r(e,Qe,t),m(le,e,t),r(e,ze,t),r(e,x,t),m(re,x,null),a(x,_t),a(x,ye),a(x,bt),a(x,Te),a(x,vt),a(x,we),a(x,xt),a(x,Ce),r(e,Ye,t),m(ae,e,t),r(e,Ae,t),r(e,w,t),m(se,w,null),a(w,yt),a(w,Me),a(w,Tt),a(w,Le),a(w,wt),a(w,Ie),r(e,Oe,t),r(e,ie,t),r(e,et,t),r(e,H,t),m(de,H,null),a(H,Ct),a(H,Je),r(e,tt,t),r(e,ce,t),r(e,nt,t),m(pe,e,t),r(e,ot,t),r(e,Ee,t),lt=!0},p(e,[t]){const L={};t&2&&(L.$$scope={dirty:t,ctx:e}),D.$set(L);const me={};t&2&&(me.$$scope={dirty:t,ctx:e}),R.$set(me)},i(e){lt||(k(_.$$.fragment,e),k(v.$$.fragment,e),k(G.$$.fragment,e),k(U.$$.fragment,e),k(B.$$.fragment,e),k(D.$$.fragment,e),k(W.$$.fragment,e),k(X.$$.fragment,e),k(K.$$.fragment,e),k(S.$$.fragment,e),k(Q.$$.fragment,e),k(z.$$.fragment,e),k(R.$$.fragment,e),k(Y.$$.fragment,e),k(A.$$.fragment,e),k(O.$$.fragment,e),k(ee.$$.fragment,e),k(ne.$$.fragment,e),k(oe.$$.fragment,e),k(le.$$.fragment,e),k(re.$$.fragment,e),k(ae.$$.fragment,e),k(se.$$.fragment,e),k(de.$$.fragment,e),k(pe.$$.fragment,e),lt=!0)},o(e){u(_.$$.fragment,e),u(v.$$.fragment,e),u(G.$$.fragment,e),u(U.$$.fragment,e),u(B.$$.fragment,e),u(D.$$.fragment,e),u(W.$$.fragment,e),u(X.$$.fragment,e),u(K.$$.fragment,e),u(S.$$.fragment,e),u(Q.$$.fragment,e),u(z.$$.fragment,e),u(R.$$.fragment,e),u(Y.$$.fragment,e),u(A.$$.fragment,e),u(O.$$.fragment,e),u(ee.$$.fragment,e),u(ne.$$.fragment,e),u(oe.$$.fragment,e),u(le.$$.fragment,e),u(re.$$.fragment,e),u(ae.$$.fragment,e),u(se.$$.fragment,e),u(de.$$.fragment,e),u(pe.$$.fragment,e),lt=!1},d(e){e&&(n(j),n(b),n($),n(s),n(Ne),n(Pe),n(qe),n(y),n(He),n(Ze),n(N),n(De),n(Re),n(P),n(Ve),n(Fe),n(T),n(Ge),n(Ue),n(Be),n(M),n(We),n(Xe),n(te),n(Ke),n(q),n(Se),n(Qe),n(ze),n(x),n(Ye),n(Ae),n(w),n(Oe),n(ie),n(et),n(H),n(tt),n(ce),n(nt),n(ot),n(Ee)),n(g),f(_,e),f(v,e),f(G,e),f(U,e),f(B),f(D),f(W,e),f(X),f(K,e),f(S),f(Q,e),f(z),f(R),f(Y,e),f(A,e),f(O),f(ee,e),f(ne),f(oe,e),f(le,e),f(re),f(ae,e),f(se),f(de),f(pe,e)}}}const an='{"title":"Kernels API Reference","local":"kernels-api-reference","sections":[{"title":"Main Functions","local":"main-functions","sections":[{"title":"get_kernel","local":"kernels.get_kernel","sections":[],"depth":3},{"title":"get_local_kernel","local":"kernels.get_local_kernel","sections":[],"depth":3},{"title":"has_kernel","local":"kernels.has_kernel","sections":[],"depth":3},{"title":"get_loaded_kernels","local":"kernels.get_loaded_kernels","sections":[],"depth":3}],"depth":2},{"title":"Loading locked kernels","local":"loading-locked-kernels","sections":[{"title":"load_kernel","local":"kernels.load_kernel","sections":[],"depth":3},{"title":"get_locked_kernel","local":"kernels.get_locked_kernel","sections":[],"depth":3}],"depth":2},{"title":"Classes","local":"classes","sections":[{"title":"LoadedKernel","local":"kernels.LoadedKernel","sections":[],"depth":3},{"title":"RepoInfo","local":"kernels.RepoInfo","sections":[],"depth":3}],"depth":2}],"depth":1}';function sn(ke){return Yt(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class fn extends At{constructor(g){super(),Ot(this,g,sn,rn,zt,{})}}export{fn as component};
