import{s as Ae,n as Be,o as Ie}from"../chunks/scheduler.53228c21.js";import{S as Ve,i as Me,e as l,s,c as m,h as ze,a as o,d as n,b as i,f as y,g as u,j as H,k as v,l as t,m as p,n as f,t as c,o as g,p as $}from"../chunks/index.100fac89.js";import{C as He}from"../chunks/CopyLLMTxtMenu.2cdbb51f.js";import{D as U}from"../chunks/Docstring.d46840f1.js";import{H as ke,E as Ue}from"../chunks/MermaidChart.svelte_svelte_type_style_lang.3fcbbc76.js";function Ge(we){let _,W,J,X,S,Y,C,Z,D,ee,a,L,me,G,Pe="<code>PipelineState</code> stores the state of a pipeline. It is used to pass data between pipeline blocks.",ue,b,T,fe,N,Se="Get one or multiple values from the pipeline state.",ce,x,E,ge,j,Ce="Get all values with matching kwargs_type.",$e,k,A,he,q,De="Add a value to the pipeline state.",_e,w,B,ye,K,Le="Convert PipelineState to a dictionary.",te,I,ne,h,V,ve,O,Te="Container for block state data with attribute access and formatted representation.",be,P,M,xe,R,Ee="Convert BlockState to a dictionary.",re,z,se,Q,ie;return S=new He({props:{containerStyle:"float: right; margin-left: 10px; display: inline-flex; position: relative; z-index: 10;"}}),C=new ke({props:{title:"Pipeline states",local:"pipeline-states",headingTag:"h1"}}),D=new ke({props:{title:"PipelineState",local:"diffusers.modular_pipelines.PipelineState",headingTag:"h2"}}),L=new U({props:{name:"class diffusers.modular_pipelines.PipelineState",anchor:"diffusers.modular_pipelines.PipelineState",parameters:[{name:"values",val:": typing.Dict[str, typing.Any] = <factory>"},{name:"kwargs_mapping",val:": typing.Dict[str, typing.List[str]] = <factory>"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/modular_pipelines/modular_pipeline.py#L69"}}),T=new U({props:{name:"get",anchor:"diffusers.modular_pipelines.PipelineState.get",parameters:[{name:"keys",val:": typing.Union[str, typing.List[str]]"},{name:"default",val:": typing.Any = None"}],parametersDescription:[{anchor:"diffusers.modular_pipelines.PipelineState.get.keys",description:"<strong>keys</strong> (Union[str, List[str]]) &#x2014; Key or list of keys for the values",name:"keys"},{anchor:"diffusers.modular_pipelines.PipelineState.get.default",description:"<strong>default</strong> (Any) &#x2014; The default value to return if not found",name:"default"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/modular_pipelines/modular_pipeline.py#L94",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>


<p>Single value if keys is str, dictionary of values if keys is list</p>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>


<p>Union[Any, Dict[str, Any]]</p>
`}}),E=new U({props:{name:"get_by_kwargs",anchor:"diffusers.modular_pipelines.PipelineState.get_by_kwargs",parameters:[{name:"kwargs_type",val:": str"}],parametersDescription:[{anchor:"diffusers.modular_pipelines.PipelineState.get_by_kwargs.kwargs_type",description:"<strong>kwargs_type</strong> (str) &#x2014; The kwargs_type to filter by",name:"kwargs_type"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/modular_pipelines/modular_pipeline.py#L109",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>


<p>Dictionary of values with matching kwargs_type</p>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>


<p>Dict[str, Any]</p>
`}}),A=new U({props:{name:"set",anchor:"diffusers.modular_pipelines.PipelineState.set",parameters:[{name:"key",val:": str"},{name:"value",val:": typing.Any"},{name:"kwargs_type",val:": str = None"}],parametersDescription:[{anchor:"diffusers.modular_pipelines.PipelineState.set.key",description:"<strong>key</strong> (str) &#x2014; The key for the value",name:"key"},{anchor:"diffusers.modular_pipelines.PipelineState.set.value",description:"<strong>value</strong> (Any) &#x2014; The value to store",name:"value"},{anchor:"diffusers.modular_pipelines.PipelineState.set.kwargs_type",description:"<strong>kwargs_type</strong> (str) &#x2014; The kwargs_type with which the value is associated",name:"kwargs_type"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/modular_pipelines/modular_pipeline.py#L77"}}),B=new U({props:{name:"to_dict",anchor:"diffusers.modular_pipelines.PipelineState.to_dict",parameters:[],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/modular_pipelines/modular_pipeline.py#L122"}}),I=new ke({props:{title:"BlockState",local:"diffusers.modular_pipelines.BlockState",headingTag:"h2"}}),V=new U({props:{name:"class diffusers.modular_pipelines.BlockState",anchor:"diffusers.modular_pipelines.BlockState",parameters:[{name:"**kwargs",val:""}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/modular_pipelines/modular_pipeline.py#L153"}}),M=new U({props:{name:"as_dict",anchor:"diffusers.modular_pipelines.BlockState.as_dict",parameters:[],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/modular_pipelines/modular_pipeline.py#L170",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>


<p>Dictionary containing all attributes of the BlockState</p>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>


<p>Dict[str, Any]</p>
`}}),z=new Ue({props:{source:"https://github.com/huggingface/diffusers/blob/main/docs/source/en/api/modular_diffusers/pipeline_states.md"}}),{c(){_=l("meta"),W=s(),J=l("p"),X=s(),m(S.$$.fragment),Y=s(),m(C.$$.fragment),Z=s(),m(D.$$.fragment),ee=s(),a=l("div"),m(L.$$.fragment),me=s(),G=l("p"),G.innerHTML=Pe,ue=s(),b=l("div"),m(T.$$.fragment),fe=s(),N=l("p"),N.textContent=Se,ce=s(),x=l("div"),m(E.$$.fragment),ge=s(),j=l("p"),j.textContent=Ce,$e=s(),k=l("div"),m(A.$$.fragment),he=s(),q=l("p"),q.textContent=De,_e=s(),w=l("div"),m(B.$$.fragment),ye=s(),K=l("p"),K.textContent=Le,te=s(),m(I.$$.fragment),ne=s(),h=l("div"),m(V.$$.fragment),ve=s(),O=l("p"),O.textContent=Te,be=s(),P=l("div"),m(M.$$.fragment),xe=s(),R=l("p"),R.textContent=Ee,re=s(),m(z.$$.fragment),se=s(),Q=l("p"),this.h()},l(e){const r=ze("svelte-u9bgzb",document.head);_=o(r,"META",{name:!0,content:!0}),r.forEach(n),W=i(e),J=o(e,"P",{}),y(J).forEach(n),X=i(e),u(S.$$.fragment,e),Y=i(e),u(C.$$.fragment,e),Z=i(e),u(D.$$.fragment,e),ee=i(e),a=o(e,"DIV",{class:!0});var d=y(a);u(L.$$.fragment,d),me=i(d),G=o(d,"P",{"data-svelte-h":!0}),H(G)!=="svelte-1p9z2f0"&&(G.innerHTML=Pe),ue=i(d),b=o(d,"DIV",{class:!0});var ae=y(b);u(T.$$.fragment,ae),fe=i(ae),N=o(ae,"P",{"data-svelte-h":!0}),H(N)!=="svelte-rz858h"&&(N.textContent=Se),ae.forEach(n),ce=i(d),x=o(d,"DIV",{class:!0});var le=y(x);u(E.$$.fragment,le),ge=i(le),j=o(le,"P",{"data-svelte-h":!0}),H(j)!=="svelte-nbwkc2"&&(j.textContent=Ce),le.forEach(n),$e=i(d),k=o(d,"DIV",{class:!0});var oe=y(k);u(A.$$.fragment,oe),he=i(oe),q=o(oe,"P",{"data-svelte-h":!0}),H(q)!=="svelte-11kc6w2"&&(q.textContent=De),oe.forEach(n),_e=i(d),w=o(d,"DIV",{class:!0});var pe=y(w);u(B.$$.fragment,pe),ye=i(pe),K=o(pe,"P",{"data-svelte-h":!0}),H(K)!=="svelte-yxpz8g"&&(K.textContent=Le),pe.forEach(n),d.forEach(n),te=i(e),u(I.$$.fragment,e),ne=i(e),h=o(e,"DIV",{class:!0});var F=y(h);u(V.$$.fragment,F),ve=i(F),O=o(F,"P",{"data-svelte-h":!0}),H(O)!=="svelte-i3htgy"&&(O.textContent=Te),be=i(F),P=o(F,"DIV",{class:!0});var de=y(P);u(M.$$.fragment,de),xe=i(de),R=o(de,"P",{"data-svelte-h":!0}),H(R)!=="svelte-kch88p"&&(R.textContent=Ee),de.forEach(n),F.forEach(n),re=i(e),u(z.$$.fragment,e),se=i(e),Q=o(e,"P",{}),y(Q).forEach(n),this.h()},h(){v(_,"name","hf:doc:metadata"),v(_,"content",Ne),v(b,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(x,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(k,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(w,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(a,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(P,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(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,r){t(document.head,_),p(e,W,r),p(e,J,r),p(e,X,r),f(S,e,r),p(e,Y,r),f(C,e,r),p(e,Z,r),f(D,e,r),p(e,ee,r),p(e,a,r),f(L,a,null),t(a,me),t(a,G),t(a,ue),t(a,b),f(T,b,null),t(b,fe),t(b,N),t(a,ce),t(a,x),f(E,x,null),t(x,ge),t(x,j),t(a,$e),t(a,k),f(A,k,null),t(k,he),t(k,q),t(a,_e),t(a,w),f(B,w,null),t(w,ye),t(w,K),p(e,te,r),f(I,e,r),p(e,ne,r),p(e,h,r),f(V,h,null),t(h,ve),t(h,O),t(h,be),t(h,P),f(M,P,null),t(P,xe),t(P,R),p(e,re,r),f(z,e,r),p(e,se,r),p(e,Q,r),ie=!0},p:Be,i(e){ie||(c(S.$$.fragment,e),c(C.$$.fragment,e),c(D.$$.fragment,e),c(L.$$.fragment,e),c(T.$$.fragment,e),c(E.$$.fragment,e),c(A.$$.fragment,e),c(B.$$.fragment,e),c(I.$$.fragment,e),c(V.$$.fragment,e),c(M.$$.fragment,e),c(z.$$.fragment,e),ie=!0)},o(e){g(S.$$.fragment,e),g(C.$$.fragment,e),g(D.$$.fragment,e),g(L.$$.fragment,e),g(T.$$.fragment,e),g(E.$$.fragment,e),g(A.$$.fragment,e),g(B.$$.fragment,e),g(I.$$.fragment,e),g(V.$$.fragment,e),g(M.$$.fragment,e),g(z.$$.fragment,e),ie=!1},d(e){e&&(n(W),n(J),n(X),n(Y),n(Z),n(ee),n(a),n(te),n(ne),n(h),n(re),n(se),n(Q)),n(_),$(S,e),$(C,e),$(D,e),$(L),$(T),$(E),$(A),$(B),$(I,e),$(V),$(M),$(z,e)}}}const Ne='{"title":"Pipeline states","local":"pipeline-states","sections":[{"title":"PipelineState","local":"diffusers.modular_pipelines.PipelineState","sections":[],"depth":2},{"title":"BlockState","local":"diffusers.modular_pipelines.BlockState","sections":[],"depth":2}],"depth":1}';function je(we){return Ie(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class Je extends Ve{constructor(_){super(),Me(this,_,je,Ge,Ae,{})}}export{Je as component};
