Buckets:

download
raw
135 kB
import{s as rt,o as dt,n as ve}from"../chunks/scheduler.53228c21.js";import{S as ct,i as pt,e as m,s as r,c as M,h as mt,a as y,d as n,b as d,f as x,j as w,g as u,k as V,w as yt,l as b,m as a,n as h,t as g,o as J,p as f}from"../chunks/index.cac5d66a.js";import{D as Ge}from"../chunks/Docstring.494cc782.js";import{C as Be}from"../chunks/CodeBlock.606cbaf4.js";import{E as it}from"../chunks/ExampleCodeBlock.3b7276d8.js";import{H as W,E as Mt}from"../chunks/MermaidChart.svelte_svelte_type_style_lang.de76e98b.js";import{H as Us,a as Qe}from"../chunks/HfOption.6b51ddef.js";function ut(T){let s,p='Refer to the <a href="../../optimization/memory">Reduce memory usage</a> guide for more details about the various memory saving techniques.',t,o,c="The Helios model below requires ~6GB of VRAM.",i,U,Z;return U=new Be({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwZGlmZnVzZXJzJTIwaW1wb3J0JTIwQXV0b01vZGVsJTJDJTIwSGVsaW9zUGlwZWxpbmUlMEFmcm9tJTIwZGlmZnVzZXJzLmhvb2tzLmdyb3VwX29mZmxvYWRpbmclMjBpbXBvcnQlMjBhcHBseV9ncm91cF9vZmZsb2FkaW5nJTBBZnJvbSUyMGRpZmZ1c2Vycy51dGlscyUyMGltcG9ydCUyMGV4cG9ydF90b192aWRlbyUwQSUwQXZhZSUyMCUzRCUyMEF1dG9Nb2RlbC5mcm9tX3ByZXRyYWluZWQoJTIyQmVzdFdpc2hZc2glMkZIZWxpb3MtQmFzZSUyMiUyQyUyMHN1YmZvbGRlciUzRCUyMnZhZSUyMiUyQyUyMHRvcmNoX2R0eXBlJTNEdG9yY2guZmxvYXQzMiklMEElMEElMjMlMjBncm91cC1vZmZsb2FkaW5nJTBBcGlwZWxpbmUlMjAlM0QlMjBIZWxpb3NQaXBlbGluZS5mcm9tX3ByZXRyYWluZWQoJTBBJTIwJTIwJTIwJTIwJTIyQmVzdFdpc2hZc2glMkZIZWxpb3MtQmFzZS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DJTIwZnBzJTNEMjQp",highlighted:`<span class="hljs-keyword">import</span> torch
<span class="hljs-keyword">from</span> diffusers <span class="hljs-keyword">import</span> AutoModel, HeliosPipeline
<span class="hljs-keyword">from</span> diffusers.hooks.group_offloading <span class="hljs-keyword">import</span> apply_group_offloading
<span class="hljs-keyword">from</span> diffusers.utils <span class="hljs-keyword">import</span> export_to_video
vae = AutoModel.from_pretrained(<span class="hljs-string">&quot;BestWishYsh/Helios-Base&quot;</span>, subfolder=<span class="hljs-string">&quot;vae&quot;</span>, torch_dtype=torch.float32)
<span class="hljs-comment"># group-offloading</span>
pipeline = HeliosPipeline.from_pretrained(
<span class="hljs-string">&quot;BestWishYsh/Helios-Base&quot;</span>,
vae=vae,
torch_dtype=torch.bfloat16
)
pipeline.enable_group_offload(
onload_device=torch.device(<span class="hljs-string">&quot;cuda&quot;</span>),
offload_device=torch.device(<span class="hljs-string">&quot;cpu&quot;</span>),
offload_type=<span class="hljs-string">&quot;leaf_level&quot;</span>,
use_stream=<span class="hljs-literal">True</span>,
record_stream=<span class="hljs-literal">True</span>,
)
prompt = <span class="hljs-string">&quot;&quot;&quot;
A vibrant tropical fish swimming gracefully among colorful coral reefs in a clear, turquoise ocean. The fish has bright blue
and yellow scales with a small, distinctive orange spot on its side, its fins moving fluidly. The coral reefs are alive with
a variety of marine life, including small schools of colorful fish and sea turtles gliding by. The water is crystal clear,
allowing for a view of the sandy ocean floor below. The reef itself is adorned with a mix of hard and soft corals in shades
of red, orange, and green. The photo captures the fish from a slightly elevated angle, emphasizing its lively movements and
the vivid colors of its surroundings. A close-up shot with dynamic movement.
&quot;&quot;&quot;</span>
negative_prompt = <span class="hljs-string">&quot;&quot;&quot;
Bright tones, overexposed, static, blurred details, subtitles, style, works, paintings, images, static, overall gray, worst quality,
low quality, JPEG compression residue, ugly, incomplete, extra fingers, poorly drawn hands, poorly drawn faces, deformed, disfigured,
misshapen limbs, fused fingers, still picture, messy background, three legs, many people in the background, walking backwards
&quot;&quot;&quot;</span>
output = pipeline(
prompt=prompt,
negative_prompt=negative_prompt,
num_frames=<span class="hljs-number">99</span>,
num_inference_steps=<span class="hljs-number">50</span>,
guidance_scale=<span class="hljs-number">5.0</span>,
generator=torch.Generator(<span class="hljs-string">&quot;cuda&quot;</span>).manual_seed(<span class="hljs-number">42</span>),
).frames[<span class="hljs-number">0</span>]
export_to_video(output, <span class="hljs-string">&quot;helios_base_t2v_output.mp4&quot;</span>, fps=<span class="hljs-number">24</span>)`,lang:"py",wrap:!1}}),{c(){s=m("p"),s.innerHTML=p,t=r(),o=m("p"),o.textContent=c,i=r(),M(U.$$.fragment)},l(_){s=y(_,"P",{"data-svelte-h":!0}),w(s)!=="svelte-iowzkr"&&(s.innerHTML=p),t=d(_),o=y(_,"P",{"data-svelte-h":!0}),w(o)!=="svelte-1xzbzlj"&&(o.textContent=c),i=d(_),u(U.$$.fragment,_)},m(_,v){a(_,s,v),a(_,t,v),a(_,o,v),a(_,i,v),h(U,_,v),Z=!0},p:ve,i(_){Z||(g(U.$$.fragment,_),Z=!0)},o(_){J(U.$$.fragment,_),Z=!1},d(_){_&&(n(s),n(t),n(o),n(i)),f(U,_)}}}function ht(T){let s,p='<a href="../../optimization/fp16#torchcompile">Compilation</a> is slow the first time but subsequent calls to the pipeline are faster. <a href="../../optimization/attention_backends">Attention Backends</a> such as FlashAttention and SageAttention can significantly increase speed by optimizing the computation of the attention mechanism. <a href="../../training/distributed_inference#context-parallelism">Context Parallelism</a> splits the input sequence across multiple devices to enable processing of long contexts in parallel, reducing memory pressure and latency. <a href="../../optimization/cache">Caching</a> may also speed up inference by storing and reusing intermediate outputs.',t,o,c;return o=new Be({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwZGlmZnVzZXJzJTIwaW1wb3J0JTIwQXV0b01vZGVsJTJDJTIwSGVsaW9zUGlwZWxpbmUlMEFmcm9tJTIwZGlmZnVzZXJzLnV0aWxzJTIwaW1wb3J0JTIwZXhwb3J0X3RvX3ZpZGVv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hY2tncm91bmQlMkMlMjB0aHJlZSUyMGxlZ3MlMkMlMjBtYW55JTIwcGVvcGxlJTIwaW4lMjB0aGUlMjBiYWNrZ3JvdW5kJTJDJTIwd2Fsa2luZyUyMGJhY2t3YXJkcyUwQSUyMiUyMiUyMiUwQSUwQW91dHB1dCUyMCUzRCUyMHBpcGVsaW5lKCUwQSUyMCUyMCUyMCUyMHByb21wdCUzRHByb21wdCUyQyUwQSUyMCUyMCUyMCUyMG5lZ2F0aXZlX3Byb21wdCUzRG5lZ2F0aXZlX3Byb21wdCUyQyUwQSUyMCUyMCUyMCUyMG51bV9mcmFtZXMlM0Q5OSUyQyUwQSUyMCUyMCUyMCUyMG51bV9pbmZlcmVuY2Vfc3RlcHMlM0Q1MCUyQyUwQSUyMCUyMCUyMCUyMGd1aWRhbmNlX3NjYWxlJTNENS4wJTJDJTBBJTIwJTIwJTIwJTIwZ2VuZXJhdG9yJTNEdG9yY2guR2VuZXJhdG9yKCUyMmN1ZGElMjIpLm1hbnVhbF9zZWVkKDQyKSUyQyUwQSkuZnJhbWVzJTVCMCU1RCUwQWV4cG9ydF90b192aWRlbyhvdXRwdXQlMkMlMjAlMjJoZWxpb3NfYmFzZV90MnZfb3V0cHV0Lm1wNCUyMiUyQyUyMGZwcyUzRDI0KQ==",highlighted:`<span class="hljs-keyword">import</span> torch
<span class="hljs-keyword">from</span> diffusers <span class="hljs-keyword">import</span> AutoModel, HeliosPipeline
<span class="hljs-keyword">from</span> diffusers.utils <span class="hljs-keyword">import</span> export_to_video
vae = AutoModel.from_pretrained(<span class="hljs-string">&quot;BestWishYsh/Helios-Base&quot;</span>, subfolder=<span class="hljs-string">&quot;vae&quot;</span>, torch_dtype=torch.float32)
pipeline = HeliosPipeline.from_pretrained(
<span class="hljs-string">&quot;BestWishYsh/Helios-Base&quot;</span>,
vae=vae,
torch_dtype=torch.bfloat16
)
pipeline.to(<span class="hljs-string">&quot;cuda&quot;</span>)
<span class="hljs-comment"># attention backend</span>
<span class="hljs-comment"># pipeline.transformer.set_attention_backend(&quot;flash&quot;)</span>
pipeline.transformer.set_attention_backend(<span class="hljs-string">&quot;_flash_3_hub&quot;</span>) <span class="hljs-comment"># For Hopper GPUs</span>
<span class="hljs-comment"># torch.compile</span>
torch.backends.cudnn.benchmark = <span class="hljs-literal">True</span>
pipeline.text_encoder.<span class="hljs-built_in">compile</span>(mode=<span class="hljs-string">&quot;max-autotune-no-cudagraphs&quot;</span>, dynamic=<span class="hljs-literal">False</span>)
pipeline.vae.<span class="hljs-built_in">compile</span>(mode=<span class="hljs-string">&quot;max-autotune-no-cudagraphs&quot;</span>, dynamic=<span class="hljs-literal">False</span>)
pipeline.transformer.<span class="hljs-built_in">compile</span>(mode=<span class="hljs-string">&quot;max-autotune-no-cudagraphs&quot;</span>, dynamic=<span class="hljs-literal">False</span>)
prompt = <span class="hljs-string">&quot;&quot;&quot;
A vibrant tropical fish swimming gracefully among colorful coral reefs in a clear, turquoise ocean. The fish has bright blue
and yellow scales with a small, distinctive orange spot on its side, its fins moving fluidly. The coral reefs are alive with
a variety of marine life, including small schools of colorful fish and sea turtles gliding by. The water is crystal clear,
allowing for a view of the sandy ocean floor below. The reef itself is adorned with a mix of hard and soft corals in shades
of red, orange, and green. The photo captures the fish from a slightly elevated angle, emphasizing its lively movements and
the vivid colors of its surroundings. A close-up shot with dynamic movement.
&quot;&quot;&quot;</span>
negative_prompt = <span class="hljs-string">&quot;&quot;&quot;
Bright tones, overexposed, static, blurred details, subtitles, style, works, paintings, images, static, overall gray, worst quality,
low quality, JPEG compression residue, ugly, incomplete, extra fingers, poorly drawn hands, poorly drawn faces, deformed, disfigured,
misshapen limbs, fused fingers, still picture, messy background, three legs, many people in the background, walking backwards
&quot;&quot;&quot;</span>
output = pipeline(
prompt=prompt,
negative_prompt=negative_prompt,
num_frames=<span class="hljs-number">99</span>,
num_inference_steps=<span class="hljs-number">50</span>,
guidance_scale=<span class="hljs-number">5.0</span>,
generator=torch.Generator(<span class="hljs-string">&quot;cuda&quot;</span>).manual_seed(<span class="hljs-number">42</span>),
).frames[<span class="hljs-number">0</span>]
export_to_video(output, <span class="hljs-string">&quot;helios_base_t2v_output.mp4&quot;</span>, fps=<span class="hljs-number">24</span>)`,lang:"py",wrap:!1}}),{c(){s=m("p"),s.innerHTML=p,t=r(),M(o.$$.fragment)},l(i){s=y(i,"P",{"data-svelte-h":!0}),w(s)!=="svelte-19ygr0k"&&(s.innerHTML=p),t=d(i),u(o.$$.fragment,i)},m(i,U){a(i,s,U),a(i,t,U),h(o,i,U),c=!0},p:ve,i(i){c||(g(o.$$.fragment,i),c=!0)},o(i){J(o.$$.fragment,i),c=!1},d(i){i&&(n(s),n(t)),f(o,i)}}}function gt(T){let s,p,t,o;return s=new Qe({props:{id:"optimization",option:"memory",$$slots:{default:[ut]},$$scope:{ctx:T}}}),t=new Qe({props:{id:"optimization",option:"inference speed",$$slots:{default:[ht]},$$scope:{ctx:T}}}),{c(){M(s.$$.fragment),p=r(),M(t.$$.fragment)},l(c){u(s.$$.fragment,c),p=d(c),u(t.$$.fragment,c)},m(c,i){h(s,c,i),a(c,p,i),h(t,c,i),o=!0},p(c,i){const U={};i&2&&(U.$$scope={dirty:i,ctx:c}),s.$set(U);const Z={};i&2&&(Z.$$scope={dirty:i,ctx:c}),t.$set(Z)},i(c){o||(g(s.$$.fragment,c),g(t.$$.fragment,c),o=!0)},o(c){J(s.$$.fragment,c),J(t.$$.fragment,c),o=!1},d(c){c&&n(p),f(s,c),f(t,c)}}}function Jt(T){let s,p;return s=new Be({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwZGlmZnVzZXJzJTIwaW1wb3J0JTIwQXV0b01vZGVsJTJDJTIwSGVsaW9zUGlwZWxpbmUlMEFmcm9tJTIwZGlmZnVzZXJzLnV0aWxzJTIwaW1wb3J0JTIwZXhwb3J0X3RvX3ZpZGVvJTJDJTIwbG9hZF92aWRlbyUyQyUyMGxvYWRfaW1hZ2UlMEElMEF2YWUlMjAlM0Q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IwaGlnaGxpZ2h0aW5nJTIwdGhlJTIwY2FyJ3MlMjBhZ2dyZXNzaXZlJTIwc3RhbmNlJTIwYW5kJTIwdGhlJTIwc3Vycm91bmRpbmclMjBncmVlbmVyeS4lMEElMjIlMjIlMjIlMEF2aWRlb19wYXRoJTIwJTNEJTIwJTIyaHR0cHMlM0ElMkYlMkZodWdnaW5nZmFjZS5jbyUyRmRhdGFzZXRzJTJGaHVnZ2luZ2ZhY2UlMkZkb2N1bWVudGF0aW9uLWltYWdlcyUyRnJlc29sdmUlMkZtYWluJTJGZGlmZnVzZXJzJTJGaGVsaW9zJTJGY2FyLm1wNCUyMiUwQSUwQW91dHB1dCUyMCUzRCUyMHBpcGVsaW5lKCUwQSUyMCUyMCUyMCUyMHByb21wdCUzRHByb21wdCUyQyUwQSUyMCUyMCUyMCUyMG5lZ2F0aXZlX3Byb21wdCUzRG5lZ2F0aXZlX3Byb21wdCUyQyUwQSUyMCUyMCUyMCUyMHZpZGVvJTNEbG9hZF92aWRlbyh2aWRlb19wYXRoKSUyQyUwQSUyMCUyMCUyMCUyMG51bV9mcmFtZXMlM0Q5OSUyQyUwQSUyMCUyMCUyMCUyMG51bV9pbmZlcmVuY2Vfc3RlcHMlM0Q1MCUyQyUwQSUyMCUyMCUyMCUyMGd1aWRhbmNlX3NjYWxlJTNENS4wJTJDJTBBJTIwJTIwJTIwJTIwZ2VuZXJhdG9yJTNEdG9yY2guR2VuZXJhdG9yKCUyMmN1ZGElMjIpLm1hbnVhbF9zZWVkKDQyKSUyQyUwQSkuZnJhbWVzJTVCMCU1RCUwQWV4cG9ydF90b192aWRlbyhvdXRwdXQlMkMlMjAlMjJoZWxpb3NfYmFzZV92MnZfb3V0cHV0Lm1wNCUyMiUyQyUyMGZwcyUzRDI0KQ==",highlighted:`<span class="hljs-keyword">import</span> torch
<span class="hljs-keyword">from</span> diffusers <span class="hljs-keyword">import</span> AutoModel, HeliosPipeline
<span class="hljs-keyword">from</span> diffusers.utils <span class="hljs-keyword">import</span> export_to_video, load_video, load_image
vae = AutoModel.from_pretrained(<span class="hljs-string">&quot;BestWishYsh/Helios-Base&quot;</span>, subfolder=<span class="hljs-string">&quot;vae&quot;</span>, torch_dtype=torch.float32)
pipeline = HeliosPipeline.from_pretrained(
<span class="hljs-string">&quot;BestWishYsh/Helios-Base&quot;</span>,
vae=vae,
torch_dtype=torch.bfloat16
)
pipeline.to(<span class="hljs-string">&quot;cuda&quot;</span>)
negative_prompt = <span class="hljs-string">&quot;&quot;&quot;
Bright tones, overexposed, static, blurred details, subtitles, style, works, paintings, images, static, overall gray, worst quality,
low quality, JPEG compression residue, ugly, incomplete, extra fingers, poorly drawn hands, poorly drawn faces, deformed, disfigured,
misshapen limbs, fused fingers, still picture, messy background, three legs, many people in the background, walking backwards
&quot;&quot;&quot;</span>
<span class="hljs-comment"># For Text-to-Video</span>
prompt = <span class="hljs-string">&quot;&quot;&quot;
A vibrant tropical fish swimming gracefully among colorful coral reefs in a clear, turquoise ocean. The fish has bright blue
and yellow scales with a small, distinctive orange spot on its side, its fins moving fluidly. The coral reefs are alive with
a variety of marine life, including small schools of colorful fish and sea turtles gliding by. The water is crystal clear,
allowing for a view of the sandy ocean floor below. The reef itself is adorned with a mix of hard and soft corals in shades
of red, orange, and green. The photo captures the fish from a slightly elevated angle, emphasizing its lively movements and
the vivid colors of its surroundings. A close-up shot with dynamic movement.
&quot;&quot;&quot;</span>
output = pipeline(
prompt=prompt,
negative_prompt=negative_prompt,
num_frames=<span class="hljs-number">99</span>,
num_inference_steps=<span class="hljs-number">50</span>,
guidance_scale=<span class="hljs-number">5.0</span>,
generator=torch.Generator(<span class="hljs-string">&quot;cuda&quot;</span>).manual_seed(<span class="hljs-number">42</span>),
).frames[<span class="hljs-number">0</span>]
export_to_video(output, <span class="hljs-string">&quot;helios_base_t2v_output.mp4&quot;</span>, fps=<span class="hljs-number">24</span>)
<span class="hljs-comment"># For Image-to-Video</span>
prompt = <span class="hljs-string">&quot;&quot;&quot;
A towering emerald wave surges forward, its crest curling with raw power and energy. Sunlight glints off the translucent water,
illuminating the intricate textures and deep green hues within the wave’s body. A thick spray erupts from the breaking crest,
casting a misty veil that dances above the churning surface. As the perspective widens, the immense scale of the wave becomes
apparent, revealing the restless expanse of the ocean stretching beyond. The scene captures the ocean’s untamed beauty and
relentless force, with every droplet and ripple shimmering in the light. The dynamic motion and vivid colors evoke both awe and
respect for nature’s might.
&quot;&quot;&quot;</span>
image_path = <span class="hljs-string">&quot;https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/helios/wave.jpg&quot;</span>
output = pipeline(
prompt=prompt,
negative_prompt=negative_prompt,
image=load_image(image_path).resize((<span class="hljs-number">640</span>, <span class="hljs-number">384</span>)),
num_frames=<span class="hljs-number">99</span>,
num_inference_steps=<span class="hljs-number">50</span>,
guidance_scale=<span class="hljs-number">5.0</span>,
generator=torch.Generator(<span class="hljs-string">&quot;cuda&quot;</span>).manual_seed(<span class="hljs-number">42</span>),
).frames[<span class="hljs-number">0</span>]
export_to_video(output, <span class="hljs-string">&quot;helios_base_i2v_output.mp4&quot;</span>, fps=<span class="hljs-number">24</span>)
<span class="hljs-comment"># For Video-to-Video</span>
prompt = <span class="hljs-string">&quot;&quot;&quot;
A bright yellow Lamborghini Huracn Tecnica speeds along a curving mountain road, surrounded by lush green trees
under a partly cloudy sky. The car&#x27;s sleek design and vibrant color stand out against the natural backdrop,
emphasizing its dynamic movement. The road curves gently, with a guardrail visible on one side, adding depth to
the scene. The motion blur captures the sense of speed and energy, creating a thrilling and exhilarating atmosphere.
A front-facing shot from a slightly elevated angle, highlighting the car&#x27;s aggressive stance and the surrounding greenery.
&quot;&quot;&quot;</span>
video_path = <span class="hljs-string">&quot;https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/helios/car.mp4&quot;</span>
output = pipeline(
prompt=prompt,
negative_prompt=negative_prompt,
video=load_video(video_path),
num_frames=<span class="hljs-number">99</span>,
num_inference_steps=<span class="hljs-number">50</span>,
guidance_scale=<span class="hljs-number">5.0</span>,
generator=torch.Generator(<span class="hljs-string">&quot;cuda&quot;</span>).manual_seed(<span class="hljs-number">42</span>),
).frames[<span class="hljs-number">0</span>]
export_to_video(output, <span class="hljs-string">&quot;helios_base_v2v_output.mp4&quot;</span>, fps=<span class="hljs-number">24</span>)`,lang:"python",wrap:!1}}),{c(){M(s.$$.fragment)},l(t){u(s.$$.fragment,t)},m(t,o){h(s,t,o),p=!0},p:ve,i(t){p||(g(s.$$.fragment,t),p=!0)},o(t){J(s.$$.fragment,t),p=!1},d(t){f(s,t)}}}function ft(T){let s,p;return s=new Qe({props:{id:"Helios-Base usage",option:"usage",$$slots:{default:[Jt]},$$scope:{ctx:T}}}),{c(){M(s.$$.fragment)},l(t){u(s.$$.fragment,t)},m(t,o){h(s,t,o),p=!0},p(t,o){const c={};o&2&&(c.$$scope={dirty:o,ctx:t}),s.$set(c)},i(t){p||(g(s.$$.fragment,t),p=!0)},o(t){J(s.$$.fragment,t),p=!1},d(t){f(s,t)}}}function bt(T){let s,p;return s=new Be({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwZGlmZnVzZXJzJTIwaW1wb3J0JTIwQXV0b01vZGVsJTJDJTIwSGVsaW9zUHlyYW1pZFBpcGVsaW5lJTBBZnJvbSUyMGRpZmZ1c2Vycy51dGlscyUyMGltcG9ydCUyMGV4cG9ydF90b192aWRlbyUyQyUyMGxvYWRfdmlkZW8lMkMlMjBsb2FkX2ltYWdlJTBBJTBBdmFlJTIwJTNEJTIwQXV0b01vZGVsLmZyb21fcHJldHJhaW5lZCglMjJCZXN0V2lzaFlzaCUyRkhlbGlvcy1NaWQlMjIlMkMlMjBzdWJmb2xkZXIlM0QlMjJ2YWUlMjIlMkMlMjB0b3JjaF9kdHlwZSUzRHRvcmNoLmZsb2F0MzIpJTBBJTBBcGlwZWxpbmUlMjAlM0QlMjBIZWxpb3NQeXJhbWlkUGlwZWxpbmUuZnJvbV9wcmV0cmFpbmVkKCUwQ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XQlMkMlMjAlMjJoZWxpb3NfcHlyYW1pZF92MnZfb3V0cHV0Lm1wNCUyMiUyQyUyMGZwcyUzRDI0KQ==",highlighted:`<span class="hljs-keyword">import</span> torch
<span class="hljs-keyword">from</span> diffusers <span class="hljs-keyword">import</span> AutoModel, HeliosPyramidPipeline
<span class="hljs-keyword">from</span> diffusers.utils <span class="hljs-keyword">import</span> export_to_video, load_video, load_image
vae = AutoModel.from_pretrained(<span class="hljs-string">&quot;BestWishYsh/Helios-Mid&quot;</span>, subfolder=<span class="hljs-string">&quot;vae&quot;</span>, torch_dtype=torch.float32)
pipeline = HeliosPyramidPipeline.from_pretrained(
<span class="hljs-string">&quot;BestWishYsh/Helios-Mid&quot;</span>,
vae=vae,
torch_dtype=torch.bfloat16
)
pipeline.to(<span class="hljs-string">&quot;cuda&quot;</span>)
negative_prompt = <span class="hljs-string">&quot;&quot;&quot;
Bright tones, overexposed, static, blurred details, subtitles, style, works, paintings, images, static, overall gray, worst quality,
low quality, JPEG compression residue, ugly, incomplete, extra fingers, poorly drawn hands, poorly drawn faces, deformed, disfigured,
misshapen limbs, fused fingers, still picture, messy background, three legs, many people in the background, walking backwards
&quot;&quot;&quot;</span>
<span class="hljs-comment"># For Text-to-Video</span>
prompt = <span class="hljs-string">&quot;&quot;&quot;
A vibrant tropical fish swimming gracefully among colorful coral reefs in a clear, turquoise ocean. The fish has bright blue
and yellow scales with a small, distinctive orange spot on its side, its fins moving fluidly. The coral reefs are alive with
a variety of marine life, including small schools of colorful fish and sea turtles gliding by. The water is crystal clear,
allowing for a view of the sandy ocean floor below. The reef itself is adorned with a mix of hard and soft corals in shades
of red, orange, and green. The photo captures the fish from a slightly elevated angle, emphasizing its lively movements and
the vivid colors of its surroundings. A close-up shot with dynamic movement.
&quot;&quot;&quot;</span>
output = pipeline(
prompt=prompt,
negative_prompt=negative_prompt,
num_frames=<span class="hljs-number">99</span>,
pyramid_num_inference_steps_list=[<span class="hljs-number">20</span>, <span class="hljs-number">20</span>, <span class="hljs-number">20</span>],
guidance_scale=<span class="hljs-number">5.0</span>,
use_zero_init=<span class="hljs-literal">True</span>,
zero_steps=<span class="hljs-number">1</span>,
generator=torch.Generator(<span class="hljs-string">&quot;cuda&quot;</span>).manual_seed(<span class="hljs-number">42</span>),
).frames[<span class="hljs-number">0</span>]
export_to_video(output, <span class="hljs-string">&quot;helios_pyramid_t2v_output.mp4&quot;</span>, fps=<span class="hljs-number">24</span>)
<span class="hljs-comment"># For Image-to-Video</span>
prompt = <span class="hljs-string">&quot;&quot;&quot;
A towering emerald wave surges forward, its crest curling with raw power and energy. Sunlight glints off the translucent water,
illuminating the intricate textures and deep green hues within the wave’s body. A thick spray erupts from the breaking crest,
casting a misty veil that dances above the churning surface. As the perspective widens, the immense scale of the wave becomes
apparent, revealing the restless expanse of the ocean stretching beyond. The scene captures the ocean’s untamed beauty and
relentless force, with every droplet and ripple shimmering in the light. The dynamic motion and vivid colors evoke both awe and
respect for nature’s might.
&quot;&quot;&quot;</span>
image_path = <span class="hljs-string">&quot;https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/helios/wave.jpg&quot;</span>
output = pipeline(
prompt=prompt,
negative_prompt=negative_prompt,
image=load_image(image_path).resize((<span class="hljs-number">640</span>, <span class="hljs-number">384</span>)),
num_frames=<span class="hljs-number">99</span>,
pyramid_num_inference_steps_list=[<span class="hljs-number">20</span>, <span class="hljs-number">20</span>, <span class="hljs-number">20</span>],
guidance_scale=<span class="hljs-number">5.0</span>,
use_zero_init=<span class="hljs-literal">True</span>,
zero_steps=<span class="hljs-number">1</span>,
generator=torch.Generator(<span class="hljs-string">&quot;cuda&quot;</span>).manual_seed(<span class="hljs-number">42</span>),
).frames[<span class="hljs-number">0</span>]
export_to_video(output, <span class="hljs-string">&quot;helios_pyramid_i2v_output.mp4&quot;</span>, fps=<span class="hljs-number">24</span>)
<span class="hljs-comment"># For Video-to-Video</span>
prompt = <span class="hljs-string">&quot;&quot;&quot;
A bright yellow Lamborghini Huracn Tecnica speeds along a curving mountain road, surrounded by lush green trees
under a partly cloudy sky. The car&#x27;s sleek design and vibrant color stand out against the natural backdrop,
emphasizing its dynamic movement. The road curves gently, with a guardrail visible on one side, adding depth to
the scene. The motion blur captures the sense of speed and energy, creating a thrilling and exhilarating atmosphere.
A front-facing shot from a slightly elevated angle, highlighting the car&#x27;s aggressive stance and the surrounding greenery.
&quot;&quot;&quot;</span>
video_path = <span class="hljs-string">&quot;https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/helios/car.mp4&quot;</span>
output = pipeline(
prompt=prompt,
negative_prompt=negative_prompt,
video=load_video(video_path),
num_frames=<span class="hljs-number">99</span>,
pyramid_num_inference_steps_list=[<span class="hljs-number">20</span>, <span class="hljs-number">20</span>, <span class="hljs-number">20</span>],
guidance_scale=<span class="hljs-number">5.0</span>,
use_zero_init=<span class="hljs-literal">True</span>,
zero_steps=<span class="hljs-number">1</span>,
generator=torch.Generator(<span class="hljs-string">&quot;cuda&quot;</span>).manual_seed(<span class="hljs-number">42</span>),
).frames[<span class="hljs-number">0</span>]
export_to_video(output, <span class="hljs-string">&quot;helios_pyramid_v2v_output.mp4&quot;</span>, fps=<span class="hljs-number">24</span>)`,lang:"python",wrap:!1}}),{c(){M(s.$$.fragment)},l(t){u(s.$$.fragment,t)},m(t,o){h(s,t,o),p=!0},p:ve,i(t){p||(g(s.$$.fragment,t),p=!0)},o(t){J(s.$$.fragment,t),p=!1},d(t){f(s,t)}}}function wt(T){let s,p;return s=new Qe({props:{id:"Helios-Mid usage",option:"usage",$$slots:{default:[bt]},$$scope:{ctx:T}}}),{c(){M(s.$$.fragment)},l(t){u(s.$$.fragment,t)},m(t,o){h(s,t,o),p=!0},p(t,o){const c={};o&2&&(c.$$scope={dirty:o,ctx:t}),s.$set(c)},i(t){p||(g(s.$$.fragment,t),p=!0)},o(t){J(s.$$.fragment,t),p=!1},d(t){f(s,t)}}}function Ut(T){let s,p;return s=new Be({props:{code:"aW1wb3J0JTIwdG9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UyMCUyMCUyMCUyMHB5cmFtaWRfbnVtX2luZmVyZW5jZV9zdGVwc19saXN0JTNEJTVCMiUyQyUyMDIlMkMlMjAyJTVEJTJDJTBBJTIwJTIwJTIwJTIwZ3VpZGFuY2Vfc2NhbGUlM0QxLjAlMkMlMEElMjAlMjAlMjAlMjBpc19hbXBsaWZ5X2ZpcnN0X2NodW5rJTNEVHJ1ZSUyQyUwQSUyMCUyMCUyMCUyMGdlbmVyYXRvciUzRHRvcmNoLkdlbmVyYXRvciglMjJjdWRhJTIyKS5tYW51YWxfc2VlZCg0MiklMkMlMEEpLmZyYW1lcyU1QjAlNUQlMEFleHBvcnRfdG9fdmlkZW8ob3V0cHV0JTJDJTIwJTIyaGVsaW9zX2Rpc3RpbGxlZF92MnZfb3V0cHV0Lm1wNCUyMiUyQyUyMGZwcyUzRDI0KQ==",highlighted:`<span class="hljs-keyword">import</span> torch
<span class="hljs-keyword">from</span> diffusers <span class="hljs-keyword">import</span> AutoModel, HeliosPyramidPipeline
<span class="hljs-keyword">from</span> diffusers.utils <span class="hljs-keyword">import</span> export_to_video, load_video, load_image
vae = AutoModel.from_pretrained(<span class="hljs-string">&quot;BestWishYsh/Helios-Distilled&quot;</span>, subfolder=<span class="hljs-string">&quot;vae&quot;</span>, torch_dtype=torch.float32)
pipeline = HeliosPyramidPipeline.from_pretrained(
<span class="hljs-string">&quot;BestWishYsh/Helios-Distilled&quot;</span>,
vae=vae,
torch_dtype=torch.bfloat16
)
pipeline.to(<span class="hljs-string">&quot;cuda&quot;</span>)
negative_prompt = <span class="hljs-string">&quot;&quot;&quot;
Bright tones, overexposed, static, blurred details, subtitles, style, works, paintings, images, static, overall gray, worst quality,
low quality, JPEG compression residue, ugly, incomplete, extra fingers, poorly drawn hands, poorly drawn faces, deformed, disfigured,
misshapen limbs, fused fingers, still picture, messy background, three legs, many people in the background, walking backwards
&quot;&quot;&quot;</span>
<span class="hljs-comment"># For Text-to-Video</span>
prompt = <span class="hljs-string">&quot;&quot;&quot;
A vibrant tropical fish swimming gracefully among colorful coral reefs in a clear, turquoise ocean. The fish has bright blue
and yellow scales with a small, distinctive orange spot on its side, its fins moving fluidly. The coral reefs are alive with
a variety of marine life, including small schools of colorful fish and sea turtles gliding by. The water is crystal clear,
allowing for a view of the sandy ocean floor below. The reef itself is adorned with a mix of hard and soft corals in shades
of red, orange, and green. The photo captures the fish from a slightly elevated angle, emphasizing its lively movements and
the vivid colors of its surroundings. A close-up shot with dynamic movement.
&quot;&quot;&quot;</span>
output = pipeline(
prompt=prompt,
negative_prompt=negative_prompt,
num_frames=<span class="hljs-number">240</span>,
pyramid_num_inference_steps_list=[<span class="hljs-number">2</span>, <span class="hljs-number">2</span>, <span class="hljs-number">2</span>],
guidance_scale=<span class="hljs-number">1.0</span>,
is_amplify_first_chunk=<span class="hljs-literal">True</span>,
generator=torch.Generator(<span class="hljs-string">&quot;cuda&quot;</span>).manual_seed(<span class="hljs-number">42</span>),
).frames[<span class="hljs-number">0</span>]
export_to_video(output, <span class="hljs-string">&quot;helios_distilled_t2v_output.mp4&quot;</span>, fps=<span class="hljs-number">24</span>)
<span class="hljs-comment"># For Image-to-Video</span>
prompt = <span class="hljs-string">&quot;&quot;&quot;
A towering emerald wave surges forward, its crest curling with raw power and energy. Sunlight glints off the translucent water,
illuminating the intricate textures and deep green hues within the wave’s body. A thick spray erupts from the breaking crest,
casting a misty veil that dances above the churning surface. As the perspective widens, the immense scale of the wave becomes
apparent, revealing the restless expanse of the ocean stretching beyond. The scene captures the ocean’s untamed beauty and
relentless force, with every droplet and ripple shimmering in the light. The dynamic motion and vivid colors evoke both awe and
respect for nature’s might.
&quot;&quot;&quot;</span>
image_path = <span class="hljs-string">&quot;https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/helios/wave.jpg&quot;</span>
output = pipeline(
prompt=prompt,
negative_prompt=negative_prompt,
image=load_image(image_path).resize((<span class="hljs-number">640</span>, <span class="hljs-number">384</span>)),
num_frames=<span class="hljs-number">240</span>,
pyramid_num_inference_steps_list=[<span class="hljs-number">2</span>, <span class="hljs-number">2</span>, <span class="hljs-number">2</span>],
guidance_scale=<span class="hljs-number">1.0</span>,
is_amplify_first_chunk=<span class="hljs-literal">True</span>,
generator=torch.Generator(<span class="hljs-string">&quot;cuda&quot;</span>).manual_seed(<span class="hljs-number">42</span>),
).frames[<span class="hljs-number">0</span>]
export_to_video(output, <span class="hljs-string">&quot;helios_distilled_i2v_output.mp4&quot;</span>, fps=<span class="hljs-number">24</span>)
<span class="hljs-comment"># For Video-to-Video</span>
prompt = <span class="hljs-string">&quot;&quot;&quot;
A bright yellow Lamborghini Huracn Tecnica speeds along a curving mountain road, surrounded by lush green trees
under a partly cloudy sky. The car&#x27;s sleek design and vibrant color stand out against the natural backdrop,
emphasizing its dynamic movement. The road curves gently, with a guardrail visible on one side, adding depth to
the scene. The motion blur captures the sense of speed and energy, creating a thrilling and exhilarating atmosphere.
A front-facing shot from a slightly elevated angle, highlighting the car&#x27;s aggressive stance and the surrounding greenery.
&quot;&quot;&quot;</span>
video_path = <span class="hljs-string">&quot;https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/helios/car.mp4&quot;</span>
output = pipeline(
prompt=prompt,
negative_prompt=negative_prompt,
video=load_video(video_path),
num_frames=<span class="hljs-number">240</span>,
pyramid_num_inference_steps_list=[<span class="hljs-number">2</span>, <span class="hljs-number">2</span>, <span class="hljs-number">2</span>],
guidance_scale=<span class="hljs-number">1.0</span>,
is_amplify_first_chunk=<span class="hljs-literal">True</span>,
generator=torch.Generator(<span class="hljs-string">&quot;cuda&quot;</span>).manual_seed(<span class="hljs-number">42</span>),
).frames[<span class="hljs-number">0</span>]
export_to_video(output, <span class="hljs-string">&quot;helios_distilled_v2v_output.mp4&quot;</span>, fps=<span class="hljs-number">24</span>)`,lang:"python",wrap:!1}}),{c(){M(s.$$.fragment)},l(t){u(s.$$.fragment,t)},m(t,o){h(s,t,o),p=!0},p:ve,i(t){p||(g(s.$$.fragment,t),p=!0)},o(t){J(s.$$.fragment,t),p=!1},d(t){f(s,t)}}}function Tt(T){let s,p;return s=new Qe({props:{id:"Helios-Distilled usage",option:"usage",$$slots:{default:[Ut]},$$scope:{ctx:T}}}),{c(){M(s.$$.fragment)},l(t){u(s.$$.fragment,t)},m(t,o){h(s,t,o),p=!0},p(t,o){const c={};o&2&&(c.$$scope={dirty:o,ctx:t}),s.$set(c)},i(t){p||(g(s.$$.fragment,t),p=!0)},o(t){J(s.$$.fragment,t),p=!1},d(t){f(s,t)}}}function _t(T){let s,p="Examples:",t,o,c;return o=new Be({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwZGlmZnVzZXJzLnV0aWxzJTIwaW1wb3J0JTIwZXhwb3J0X3RvX3ZpZGVvJTBBZnJvbSUyMGRpZmZ1c2VycyUyMGltcG9ydCUyMEF1dG9lbmNvZGVyS0xXYW4lMkMlMjBIZWxpb3NQaXBlbGluZSUwQSUwQSUyMyUyMEF2YWlsYWJsZSUyMG1vZGVscyUzQSUyMEJlc3RXaXNoWXNoJTJGSGVsaW9zLUJhc2UlMkMlMjBCZXN0V2lzaFlzaCUyRkhlbGlvcy1NaWQlMkMlMjBCZXN0V2lzaFlzaCUyRkhlbGlvcy1EaXN0aWxsZWQlMEFtb2RlbF9pZCUyMCUzRCUyMCUyMkJlc3RXaXNoWXNoJTJGSGVsaW9zLUJhc2UlMjIlMEF2YWUlMjAlM0QlMjBBdXRvZW5jb2RlcktMV2FuLmZyb21fcHJldHJhaW5lZChtb2RlbF9pZCUyQyUyMHN1YmZvbGRlciUzRCUyMnZhZSUyMiUyQyUyMHRvcmNoX2R0eXBlJTNEdG9yY2guZmxvYXQzMiklMEFwaXBlJTIwJTNEJTIwSGVsaW9zUGlwZWxpbmUuZnJvbV9wcmV0cmFpbmVkKG1vZGVsX2lkJTJDJTIwdmFlJTNEdmFlJTJDJTIwdG9yY2hfZHR5cGUlM0R0b3JjaC5iZmxvYXQxNiklMEFwaXBlLnRvKCUyMmN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WxsJTIwcGljdHVyZSUyQyUyMG1lc3N5JTIwYmFja2dyb3VuZCUyQyUyMHRocmVlJTIwbGVncyUyQyUyMG1hbnklMjBwZW9wbGUlMjBpbiUyMHRoZSUyMGJhY2tncm91bmQlMkMlMjB3YWxraW5nJTIwYmFja3dhcmRzJTIyJTBBJTBBb3V0cHV0JTIwJTNEJTIwcGlwZSglMEElMjAlMjAlMjAlMjBwcm9tcHQlM0Rwcm9tcHQlMkMlMEElMjAlMjAlMjAlMjBuZWdhdGl2ZV9wcm9tcHQlM0RuZWdhdGl2ZV9wcm9tcHQlMkMlMEElMjAlMjAlMjAlMjBoZWlnaHQlM0QzODQlMkMlMEElMjAlMjAlMjAlMjB3aWR0aCUzRDY0MCUyQyUwQSUyMCUyMCUyMCUyMG51bV9mcmFtZXMlM0QxMzIlMkMlMEElMjAlMjAlMjAlMjBndWlkYW5jZV9zY2FsZSUzRDUuMCUyQyUwQSkuZnJhbWVzJTVCMCU1RCUwQWV4cG9ydF90b192aWRlbyhvdXRwdXQlMkMlMjAlMjJvdXRwdXQubXA0JTIyJTJDJTIwZnBzJTNEMjQp",highlighted:`<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> diffusers.utils <span class="hljs-keyword">import</span> export_to_video
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> diffusers <span class="hljs-keyword">import</span> AutoencoderKLWan, HeliosPipeline
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Available models: BestWishYsh/Helios-Base, BestWishYsh/Helios-Mid, BestWishYsh/Helios-Distilled</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>model_id = <span class="hljs-string">&quot;BestWishYsh/Helios-Base&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>vae = AutoencoderKLWan.from_pretrained(model_id, subfolder=<span class="hljs-string">&quot;vae&quot;</span>, torch_dtype=torch.float32)
<span class="hljs-meta">&gt;&gt;&gt; </span>pipe = HeliosPipeline.from_pretrained(model_id, vae=vae, torch_dtype=torch.bfloat16)
<span class="hljs-meta">&gt;&gt;&gt; </span>pipe.to(<span class="hljs-string">&quot;cuda&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>prompt = <span class="hljs-string">&quot;A cat and a dog baking a cake together in a kitchen. The cat is carefully measuring flour, while the dog is stirring the batter with a wooden spoon. The kitchen is cozy, with sunlight streaming through the window.&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>negative_prompt = <span class="hljs-string">&quot;Bright tones, overexposed, static, blurred details, subtitles, style, works, paintings, images, static, overall gray, worst quality, low quality, JPEG compression residue, ugly, incomplete, extra fingers, poorly drawn hands, poorly drawn faces, deformed, disfigured, misshapen limbs, fused fingers, still picture, messy background, three legs, many people in the background, walking backwards&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>output = pipe(
<span class="hljs-meta">... </span> prompt=prompt,
<span class="hljs-meta">... </span> negative_prompt=negative_prompt,
<span class="hljs-meta">... </span> height=<span class="hljs-number">384</span>,
<span class="hljs-meta">... </span> width=<span class="hljs-number">640</span>,
<span class="hljs-meta">... </span> num_frames=<span class="hljs-number">132</span>,
<span class="hljs-meta">... </span> guidance_scale=<span class="hljs-number">5.0</span>,
<span class="hljs-meta">... </span>).frames[<span class="hljs-number">0</span>]
<span class="hljs-meta">&gt;&gt;&gt; </span>export_to_video(output, <span class="hljs-string">&quot;output.mp4&quot;</span>, fps=<span class="hljs-number">24</span>)`,lang:"python",wrap:!1}}),{c(){s=m("p"),s.textContent=p,t=r(),M(o.$$.fragment)},l(i){s=y(i,"P",{"data-svelte-h":!0}),w(s)!=="svelte-kvfsh7"&&(s.textContent=p),t=d(i),u(o.$$.fragment,i)},m(i,U){a(i,s,U),a(i,t,U),h(o,i,U),c=!0},p:ve,i(i){c||(g(o.$$.fragment,i),c=!0)},o(i){J(o.$$.fragment,i),c=!1},d(i){i&&(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MCUyMG5lZ2F0aXZlX3Byb21wdCUzRG5lZ2F0aXZlX3Byb21wdCUyQyUwQSUyMCUyMCUyMCUyMGhlaWdodCUzRDM4NCUyQyUwQSUyMCUyMCUyMCUyMHdpZHRoJTNENjQwJTJDJTBBJTIwJTIwJTIwJTIwbnVtX2ZyYW1lcyUzRDEzMiUyQyUwQSUyMCUyMCUyMCUyMGd1aWRhbmNlX3NjYWxlJTNENS4wJTJDJTBBKS5mcmFtZXMlNUIwJTVEJTBBZXhwb3J0X3RvX3ZpZGVvKG91dHB1dCUyQyUyMCUyMm91dHB1dC5tcDQlMjIlMkMlMjBmcHMlM0QyNCk=",highlighted:`<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> diffusers.utils <span class="hljs-keyword">import</span> export_to_video
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> diffusers <span class="hljs-keyword">import</span> AutoencoderKLWan, HeliosPyramidPipeline
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Available models: BestWishYsh/Helios-Base, BestWishYsh/Helios-Mid, BestWishYsh/Helios-Distilled</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>model_id = <span class="hljs-string">&quot;BestWishYsh/Helios-Base&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>vae = AutoencoderKLWan.from_pretrained(model_id, subfolder=<span class="hljs-string">&quot;vae&quot;</span>, torch_dtype=torch.float32)
<span class="hljs-meta">&gt;&gt;&gt; </span>pipe = HeliosPyramidPipeline.from_pretrained(model_id, vae=vae, torch_dtype=torch.bfloat16)
<span class="hljs-meta">&gt;&gt;&gt; </span>pipe.to(<span class="hljs-string">&quot;cuda&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>prompt = <span class="hljs-string">&quot;A cat and a dog baking a cake together in a kitchen. The cat is carefully measuring flour, while the dog is stirring the batter with a wooden spoon. The kitchen is cozy, with sunlight streaming through the window.&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>negative_prompt = <span class="hljs-string">&quot;Bright tones, overexposed, static, blurred details, subtitles, style, works, paintings, images, static, overall gray, worst quality, low quality, JPEG compression residue, ugly, incomplete, extra fingers, poorly drawn hands, poorly drawn faces, deformed, disfigured, misshapen limbs, fused fingers, still picture, messy background, three legs, many people in the background, walking backwards&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>output = pipe(
<span class="hljs-meta">... </span> prompt=prompt,
<span class="hljs-meta">... </span> negative_prompt=negative_prompt,
<span class="hljs-meta">... </span> height=<span class="hljs-number">384</span>,
<span class="hljs-meta">... </span> width=<span class="hljs-number">640</span>,
<span class="hljs-meta">... </span> num_frames=<span class="hljs-number">132</span>,
<span class="hljs-meta">... </span> guidance_scale=<span class="hljs-number">5.0</span>,
<span class="hljs-meta">... </span>).frames[<span class="hljs-number">0</span>]
<span class="hljs-meta">&gt;&gt;&gt; </span>export_to_video(output, <span class="hljs-string">&quot;output.mp4&quot;</span>, fps=<span class="hljs-number">24</span>)`,lang:"python",wrap:!1}}),{c(){s=m("p"),s.textContent=p,t=r(),M(o.$$.fragment)},l(i){s=y(i,"P",{"data-svelte-h":!0}),w(s)!=="svelte-kvfsh7"&&(s.textContent=p),t=d(i),u(o.$$.fragment,i)},m(i,U){a(i,s,U),a(i,t,U),h(o,i,U),c=!0},p:ve,i(i){c||(g(o.$$.fragment,i),c=!0)},o(i){J(o.$$.fragment,i),c=!1},d(i){i&&(n(s),n(t)),f(o,i)}}}function jt(T){let s,p,t,o,c,i='<div class="flex flex-wrap space-x-1"><a href="https://huggingface.co/docs/diffusers/main/en/tutorials/using_peft_for_inference" target="_blank" rel="noopener"><img alt="LoRA" src="https://img.shields.io/badge/LoRA-d8b4fe?style=flat"/></a></div>',U,Z,_,v,xs='<a href="https://huggingface.co/papers/2603.04379" rel="nofollow">Helios: Real Real-Time Long Video Generation Model</a> from Peking University &amp; ByteDance &amp; etc, by Shenghai Yuan, Yuanyang Yin, Zongjian Li, Xinwei Huang, Xiao Yang, Li Yuan.',Ne,q,Ys="<li><u>We introduce Helios, the first 14B video generation model that runs at 17 FPS on a single NVIDIA H100 GPU and supports minute-scale generation while matching a strong baseline in quality.</u> We make breakthroughs along three key dimensions: (1) robustness to long-video drifting without commonly used anti-drift heuristics such as self-forcing, error banks, or keyframe sampling; (2) real-time generation without standard acceleration techniques such as KV-cache, causal masking, or sparse attention; and (3) training without parallelism or sharding frameworks, enabling image-diffusion-scale batch sizes while fitting up to four 14B models within 80 GB of GPU memory. Specifically, Helios is a 14B autoregressive diffusion model with a unified input representation that natively supports T2V, I2V, and V2V tasks. To mitigate drifting in long-video generation, we characterize its typical failure modes and propose simple yet effective training strategies that explicitly simulate drifting during training, while eliminating repetitive motion at its source. For efficiency, we heavily compress the historical and noisy context and reduce the number of sampling steps, yielding computational costs comparable to—or lower than—those of 1.3B video generative models. Moreover, we introduce infrastructure-level optimizations that accelerate both inference and training while reducing memory consumption. Extensive experiments demonstrate that Helios consistently outperforms prior methods on both short- and long-video generation. All the code and models are available at [this https URL](https://pku-yuangroup.github.io/Helios-Page).</li>",ze,D,Qs="The following Helios models are supported in Diffusers:",Fe,A,Ns='<li><a href="https://huggingface.co/BestWishYsh/Helios-Base" rel="nofollow">Helios-Base</a>: Best Quality, with v-prediction, standard CFG and custom HeliosScheduler.</li> <li><a href="https://huggingface.co/BestWishYsh/Helios-Mid" rel="nofollow">Helios-Mid</a>: Intermediate Weight, with v-prediction, CFG-Zero* and custom HeliosScheduler.</li> <li><a href="https://huggingface.co/BestWishYsh/Helios-Distilled" rel="nofollow">Helios-Distilled</a>: Best Efficiency, with x0-prediction and custom HeliosDMDScheduler.</li>',Se,Y,zs="<p>Click on the Helios models in the right sidebar for more examples of video generation.</p>",$e,L,Ee,K,Fs="The example below demonstrates how to generate a video from text optimized for memory or inference speed.",Pe,Q,qe,O,De,ee,Ss="The example below demonstrates how to use Helios-Base to generate video based on text, image or video.",Ae,N,Le,se,Ke,te,$s="The example below demonstrates how to use Helios-Mid to generate video based on text, image or video.",Oe,z,es,le,ss,ne,Es="The example below demonstrates how to use Helios-Distilled to generate video based on text, image or video.",ts,F,ls,ae,ns,oe,Ps='<tbody><tr><th style="text-align: center;">Prompt</th> <th style="text-align: center;">Generated Video</th></tr> <tr><td><small>A Viking warrior driving a modern city bus filled with passengers. The Viking has long blonde hair tied back, a beard, and is adorned with a fur-lined helmet and armor. He wears a traditional tunic and trousers, but also sports a seatbelt as he focuses on navigating the busy streets. The interior of the bus is typical, with rows of seats occupied by diverse passengers going about their daily routines. The exterior shots show the bustling urban environment, including tall buildings and traffic. Medium shot focusing on the Viking at the wheel, with occasional close-ups of his determined expression.</small></td> <td><video width="4000" controls=""><source src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/helios/t2v_showcases1.mp4" type="video/mp4"/></video></td></tr> <tr><td><small>A documentary-style nature photography shot from a camera truck moving to the left, capturing a crab quickly scurrying into its burrow. The crab has a hard, greenish-brown shell and long claws, moving with determined speed across the sandy ground. Its body is slightly arched as it burrows into the sand, leaving a small trail behind. The background shows a shallow beach with scattered rocks and seashells, and the horizon features a gentle curve of the coastline. The photo has a natural and realistic texture, emphasizing the crab&#39;s natural movement and the texture of the sand. A close-up shot from a slightly elevated angle.</small></td> <td><video width="4000" controls=""><source src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/helios/t2v_showcases2.mp4" type="video/mp4"/></video></td></tr></tbody>',as,ie,os,re,qs='<tbody><tr><th style="text-align: center;">Image</th> <th style="text-align: center;">Prompt</th> <th style="text-align: center;">Generated Video</th></tr> <tr><td><img src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/helios/i2v_showcases1.jpg" style="height: auto; width: 300px;"/></td> <td><small>A sleek red Kia car speeds along a rural road under a cloudy sky, its modern design and dynamic movement emphasized by the blurred motion of the surrounding fields and trees stretching into the distance. The car&#39;s glossy exterior reflects the overcast sky, highlighting its aerodynamic shape and sporty stance. The license plate reads &quot;KIA 626,&quot; and the vehicle&#39;s headlights are on, adding to the sense of motion and energy. The road curves gently, with the car positioned slightly off-center, creating a sense of forward momentum. A dynamic front three-quarter view captures the car&#39;s powerful presence against the serene backdrop of rolling hills and scattered trees.</small></td> <td><video width="2000" controls=""><source src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/helios/i2v_showcases1.mp4" type="video/mp4"/></video></td></tr> <tr><td><img src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/helios/i2v_showcases2.jpg" style="height: auto; width: 300px;"/></td> <td><small>A close-up captures a fluffy orange cat with striking green eyes and white whiskers, gazing intently towards the camera. The cat&#39;s fur is soft and well-groomed, with a mix of warm orange and cream tones. Its large, expressive eyes are a vivid green, reflecting curiosity and alertness. The cat&#39;s nose is small and pink, and its mouth is slightly open, revealing a hint of its pink tongue. The background is softly blurred, suggesting a cozy indoor setting with neutral tones. The photo has a shallow depth of field, focusing sharply on the cat&#39;s face while the background remains out of focus. A close-up shot from a slightly elevated perspective.</small></td> <td><video width="2000" controls=""><source src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/helios/i2v_showcases2.mp4" type="video/mp4"/></video></td></tr></tbody>',is,de,rs,ce,Ds='<tbody><tr><th style="text-align: center;">Prompt</th> <th style="text-align: center;">Generated Video</th></tr> <tr><td><small>The prompt can be found <a href="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/helios/interactive_showcases1.txt">here</a></small></td> <td><video width="680" controls=""><source src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/helios/interactive_showcases1.mp4" type="video/mp4"/></video></td></tr> <tr><td><small>The prompt can be found <a href="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/helios/interactive_showcases2.txt">here</a></small></td> <td><video width="680" controls=""><source src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/helios/interactive_showcases2.mp4" type="video/mp4"/></video></td></tr></tbody>',ds,pe,cs,me,As="Learn more about Helios with the following resources.",ps,ye,Ls='<li>Watch <a href="https://www.youtube.com/watch?v=vd_AgHtOUFQ" rel="nofollow">video1</a> and <a href="https://www.youtube.com/watch?v=1GeIU2Dn7UY" rel="nofollow">video2</a> for a demonstration of Helios’s key features.</li> <li>The research paper, <a href="https://huggingface.co/papers/2603.04379" rel="nofollow">Helios: Real Real-Time Long Video Generation Model</a> for more details.</li>',ms,Me,ys,j,ue,Ts,Ie,Ks="Pipeline for text-to-video / image-to-video / video-to-video generation using Helios.",_s,We,Os=`This model inherits from <a href="/docs/diffusers/pr_13832/en/api/pipelines/overview#diffusers.DiffusionPipeline">DiffusionPipeline</a>. Check the superclass documentation for the generic methods
implemented for all pipelines (downloading, saving, running on a particular device, etc.).`,Zs,H,he,js,He,et="The call function to the pipeline for generation.",Gs,S,vs,$,ge,Bs,ke,st="Encodes the prompt into text encoder hidden states.",Ms,Je,us,G,fe,Is,Ve,tt="Pipeline for text-to-video / image-to-video / video-to-video generation using Helios.",Ws,Ce,lt=`This model inherits from <a href="/docs/diffusers/pr_13832/en/api/pipelines/overview#diffusers.DiffusionPipeline">DiffusionPipeline</a>. Check the superclass documentation for the generic methods
implemented for all pipelines (downloading, saving, running on a particular device, etc.).`,Hs,k,be,ks,Xe,nt="The call function to the pipeline for generation.",Vs,E,Cs,P,we,Xs,Re,at="Encodes the prompt into text encoder hidden states.",hs,Ue,gs,C,Te,Rs,xe,ot="Output class for Helios pipelines.",Js,_e,fs,Ye,bs;return Z=new W({props:{title:"Helios",local:"helios",headingTag:"h1"}}),L=new W({props:{title:"Optimizing Memory and Inference Speed",local:"optimizing-memory-and-inference-speed",headingTag:"h3"}}),Q=new Us({props:{id:"optimization",options:["memory","inference speed"],$$slots:{default:[gt]},$$scope:{ctx:T}}}),O=new W({props:{title:"Generation with Helios-Base",local:"generation-with-helios-base",headingTag:"h3"}}),N=new Us({props:{id:"Helios-Base usage",options:["usage"],$$slots:{default:[ft]},$$scope:{ctx:T}}}),se=new W({props:{title:"Generation with Helios-Mid",local:"generation-with-helios-mid",headingTag:"h3"}}),z=new Us({props:{id:"Helios-Mid usage",options:["usage"],$$slots:{default:[wt]},$$scope:{ctx:T}}}),le=new W({props:{title:"Generation with Helios-Distilled",local:"generation-with-helios-distilled",headingTag:"h3"}}),F=new Us({props:{id:"Helios-Distilled usage",options:["usage"],$$slots:{default:[Tt]},$$scope:{ctx:T}}}),ae=new W({props:{title:"Text-to-Video Showcases",local:"text-to-video-showcases",headingTag:"h2"}}),ie=new W({props:{title:"Image-to-Video Showcases",local:"image-to-video-showcases",headingTag:"h2"}}),de=new W({props:{title:"Interactive-Video Showcases",local:"interactive-video-showcases",headingTag:"h2"}}),pe=new W({props:{title:"Resources",local:"resources",headingTag:"h2"}}),Me=new W({props:{title:"HeliosPipeline",local:"diffusers.HeliosPipeline",headingTag:"h2"}}),ue=new Ge({props:{name:"class diffusers.HeliosPipeline",anchor:"diffusers.HeliosPipeline",parameters:[{name:"tokenizer",val:": AutoTokenizer"},{name:"text_encoder",val:": UMT5EncoderModel"},{name:"vae",val:": AutoencoderKLWan"},{name:"scheduler",val:": HeliosScheduler"},{name:"transformer",val:": HeliosTransformer3DModel"}],parametersDescription:[{anchor:"diffusers.HeliosPipeline.tokenizer",description:`<strong>tokenizer</strong> (<code>T5Tokenizer</code>) &#x2014;
Tokenizer from <a href="https://huggingface.co/docs/transformers/en/model_doc/t5#transformers.T5Tokenizer" rel="nofollow">T5</a>,
specifically the <a href="https://huggingface.co/google/umt5-xxl" rel="nofollow">google/umt5-xxl</a> variant.`,name:"tokenizer"},{anchor:"diffusers.HeliosPipeline.text_encoder",description:`<strong>text_encoder</strong> (<code>T5EncoderModel</code>) &#x2014;
<a href="https://huggingface.co/docs/transformers/en/model_doc/t5#transformers.T5EncoderModel" rel="nofollow">T5</a>, specifically
the <a href="https://huggingface.co/google/umt5-xxl" rel="nofollow">google/umt5-xxl</a> variant.`,name:"text_encoder"},{anchor:"diffusers.HeliosPipeline.transformer",description:`<strong>transformer</strong> (<a href="/docs/diffusers/pr_13832/en/api/models/helios_transformer3d#diffusers.HeliosTransformer3DModel">HeliosTransformer3DModel</a>) &#x2014;
Conditional Transformer to denoise the input latents.`,name:"transformer"},{anchor:"diffusers.HeliosPipeline.scheduler",description:`<strong>scheduler</strong> (<a href="/docs/diffusers/pr_13832/en/api/schedulers/helios#diffusers.HeliosScheduler">HeliosScheduler</a>) &#x2014;
A scheduler to be used in combination with <code>transformer</code> to denoise the encoded image latents.`,name:"scheduler"},{anchor:"diffusers.HeliosPipeline.vae",description:`<strong>vae</strong> (<a href="/docs/diffusers/pr_13832/en/api/models/autoencoder_kl_wan#diffusers.AutoencoderKLWan">AutoencoderKLWan</a>) &#x2014;
Variational Auto-Encoder (VAE) Model to encode and decode videos to and from latent representations.`,name:"vae"}],source:"https://github.com/huggingface/diffusers/blob/vr_13832/src/diffusers/pipelines/helios/pipeline_helios.py#L108"}}),he=new Ge({props:{name:"__call__",anchor:"diffusers.HeliosPipeline.__call__",parameters:[{name:"prompt",val:": str | list[str] = None"},{name:"negative_prompt",val:": str | list[str] = None"},{name:"height",val:": int = 384"},{name:"width",val:": int = 640"},{name:"num_frames",val:": int = 132"},{name:"num_inference_steps",val:": int = 50"},{name:"sigmas",val:": list = None"},{name:"guidance_scale",val:": float = 5.0"},{name:"num_videos_per_prompt",val:": int | None = 1"},{name:"generator",val:": torch._C.Generator | list[torch._C.Generator] | None = None"},{name:"latents",val:": torch.Tensor | None = None"},{name:"prompt_embeds",val:": torch.Tensor | None = None"},{name:"negative_prompt_embeds",val:": torch.Tensor | None = None"},{name:"output_type",val:": str | None = 'np'"},{name:"return_dict",val:": bool = True"},{name:"attention_kwargs",val:": dict[str, typing.Any] | None = None"},{name:"callback_on_step_end",val:": typing.Union[typing.Callable[[int, int], NoneType], diffusers.callbacks.PipelineCallback, diffusers.callbacks.MultiPipelineCallbacks, NoneType] = None"},{name:"callback_on_step_end_tensor_inputs",val:": list = ['latents']"},{name:"max_sequence_length",val:": int = 512"},{name:"image",val:": PIL.Image.Image | numpy.ndarray | torch.Tensor | list[PIL.Image.Image] | list[numpy.ndarray] | list[torch.Tensor] | None = None"},{name:"image_latents",val:": torch.Tensor | None = None"},{name:"fake_image_latents",val:": torch.Tensor | None = None"},{name:"add_noise_to_image_latents",val:": bool = True"},{name:"image_noise_sigma_min",val:": float = 0.111"},{name:"image_noise_sigma_max",val:": float = 0.135"},{name:"video",val:": PIL.Image.Image | numpy.ndarray | torch.Tensor | list[PIL.Image.Image] | list[numpy.ndarray] | list[torch.Tensor] | None = None"},{name:"video_latents",val:": torch.Tensor | None = None"},{name:"add_noise_to_video_latents",val:": bool = True"},{name:"video_noise_sigma_min",val:": float = 0.111"},{name:"video_noise_sigma_max",val:": float = 0.135"},{name:"history_sizes",val:": list = [16, 2, 1]"},{name:"num_latent_frames_per_chunk",val:": int = 9"},{name:"keep_first_frame",val:": bool = True"},{name:"is_skip_first_chunk",val:": bool = False"}],parametersDescription:[{anchor:"diffusers.HeliosPipeline.__call__.prompt",description:`<strong>prompt</strong> (<code>str</code> or <code>list[str]</code>, <em>optional</em>) &#x2014;
The prompt or prompts to guide the image generation. If not defined, pass <code>prompt_embeds</code> instead.`,name:"prompt"},{anchor:"diffusers.HeliosPipeline.__call__.negative_prompt",description:`<strong>negative_prompt</strong> (<code>str</code> or <code>list[str]</code>, <em>optional</em>) &#x2014;
The prompt or prompts to avoid during image generation. If not defined, pass <code>negative_prompt_embeds</code>
instead. Ignored when not using guidance (<code>guidance_scale</code> &lt; <code>1</code>).`,name:"negative_prompt"},{anchor:"diffusers.HeliosPipeline.__call__.height",description:`<strong>height</strong> (<code>int</code>, defaults to <code>384</code>) &#x2014;
The height in pixels of the generated image.`,name:"height"},{anchor:"diffusers.HeliosPipeline.__call__.width",description:`<strong>width</strong> (<code>int</code>, defaults to <code>640</code>) &#x2014;
The width in pixels of the generated image.`,name:"width"},{anchor:"diffusers.HeliosPipeline.__call__.num_frames",description:`<strong>num_frames</strong> (<code>int</code>, defaults to <code>132</code>) &#x2014;
The number of frames in the generated video.`,name:"num_frames"},{anchor:"diffusers.HeliosPipeline.__call__.num_inference_steps",description:`<strong>num_inference_steps</strong> (<code>int</code>, defaults to <code>50</code>) &#x2014;
The number of denoising steps. More denoising steps usually lead to a higher quality image at the
expense of slower inference.`,name:"num_inference_steps"},{anchor:"diffusers.HeliosPipeline.__call__.sigmas",description:`<strong>sigmas</strong> (<code>list[float]</code>, <em>optional</em>) &#x2014;
Custom sigmas to use for the denoising process. If not defined, the scheduler&#x2019;s default schedule is
used.`,name:"sigmas"},{anchor:"diffusers.HeliosPipeline.__call__.guidance_scale",description:`<strong>guidance_scale</strong> (<code>float</code>, defaults to <code>5.0</code>) &#x2014;
Guidance scale as defined in <a href="https://huggingface.co/papers/2207.12598" rel="nofollow">Classifier-Free Diffusion
Guidance</a>. <code>guidance_scale</code> is defined as <code>w</code> of equation 2.
of <a href="https://huggingface.co/papers/2205.11487" rel="nofollow">Imagen Paper</a>. Guidance scale is enabled by setting
<code>guidance_scale &gt; 1</code>. Higher guidance scale encourages to generate images that are closely linked to
the text <code>prompt</code>, usually at the expense of lower image quality.`,name:"guidance_scale"},{anchor:"diffusers.HeliosPipeline.__call__.num_videos_per_prompt",description:`<strong>num_videos_per_prompt</strong> (<code>int</code>, <em>optional</em>, defaults to 1) &#x2014;
The number of images to generate per prompt.`,name:"num_videos_per_prompt"},{anchor:"diffusers.HeliosPipeline.__call__.generator",description:`<strong>generator</strong> (<code>torch.Generator</code> or <code>list[torch.Generator]</code>, <em>optional</em>) &#x2014;
A <a href="https://pytorch.org/docs/stable/generated/torch.Generator.html" rel="nofollow"><code>torch.Generator</code></a> to make
generation deterministic.`,name:"generator"},{anchor:"diffusers.HeliosPipeline.__call__.latents",description:`<strong>latents</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated noisy latents sampled from a Gaussian distribution, to be used as inputs for image
generation. Can be used to tweak the same generation with different prompts. If not provided, a latents
tensor is generated by sampling using the supplied random <code>generator</code>.`,name:"latents"},{anchor:"diffusers.HeliosPipeline.__call__.prompt_embeds",description:`<strong>prompt_embeds</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated text embeddings. Can be used to easily tweak text inputs (prompt weighting). If not
provided, text embeddings are generated from the <code>prompt</code> input argument.`,name:"prompt_embeds"},{anchor:"diffusers.HeliosPipeline.__call__.negative_prompt_embeds",description:`<strong>negative_prompt_embeds</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated negative text embeddings. If not provided, they are generated from <code>negative_prompt</code>.`,name:"negative_prompt_embeds"},{anchor:"diffusers.HeliosPipeline.__call__.output_type",description:`<strong>output_type</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;np&quot;</code>) &#x2014;
The output format of the generated image. Choose between <code>PIL.Image</code> or <code>np.array</code>.`,name:"output_type"},{anchor:"diffusers.HeliosPipeline.__call__.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether or not to return a <code>HeliosPipelineOutput</code> instead of a plain tuple.`,name:"return_dict"},{anchor:"diffusers.HeliosPipeline.__call__.attention_kwargs",description:`<strong>attention_kwargs</strong> (<code>dict</code>, <em>optional</em>) &#x2014;
A kwargs dictionary that if specified is passed along to the <code>AttentionProcessor</code> as defined under
<code>self.processor</code> in
<a href="https://github.com/huggingface/diffusers/blob/main/src/diffusers/models/attention_processor.py" rel="nofollow">diffusers.models.attention_processor</a>.`,name:"attention_kwargs"},{anchor:"diffusers.HeliosPipeline.__call__.callback_on_step_end",description:`<strong>callback_on_step_end</strong> (<code>Callable</code>, <code>PipelineCallback</code>, <code>MultiPipelineCallbacks</code>, <em>optional</em>) &#x2014;
A function or a subclass of <code>PipelineCallback</code> or <code>MultiPipelineCallbacks</code> that is called at the end of
each denoising step during the inference. with the following arguments: <code>callback_on_step_end(self: DiffusionPipeline, step: int, timestep: int, callback_kwargs: Dict)</code>. <code>callback_kwargs</code> will include a
list of all tensors as specified by <code>callback_on_step_end_tensor_inputs</code>.`,name:"callback_on_step_end"},{anchor:"diffusers.HeliosPipeline.__call__.callback_on_step_end_tensor_inputs",description:`<strong>callback_on_step_end_tensor_inputs</strong> (<code>list</code>, <em>optional</em>) &#x2014;
The list of tensor inputs for the <code>callback_on_step_end</code> function. The tensors specified in the list
will be passed as <code>callback_kwargs</code> argument. You will only be able to include variables listed in the
<code>._callback_tensor_inputs</code> attribute of your pipeline class.`,name:"callback_on_step_end_tensor_inputs"},{anchor:"diffusers.HeliosPipeline.__call__.max_sequence_length",description:`<strong>max_sequence_length</strong> (<code>int</code>, defaults to <code>512</code>) &#x2014;
The maximum sequence length of the text encoder. If the prompt is longer than this, it will be
truncated. If the prompt is shorter, it will be padded to this length.`,name:"max_sequence_length"},{anchor:"diffusers.HeliosPipeline.__call__.image",description:`<strong>image</strong> (<code>PipelineImageInput</code>, <em>optional</em>) &#x2014;
Input image used for image-to-video conditioning.`,name:"image"},{anchor:"diffusers.HeliosPipeline.__call__.image_latents",description:`<strong>image_latents</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-encoded image latents to use instead of <code>image</code>.`,name:"image_latents"},{anchor:"diffusers.HeliosPipeline.__call__.fake_image_latents",description:`<strong>fake_image_latents</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Optional fake image latents used during conditioning.`,name:"fake_image_latents"},{anchor:"diffusers.HeliosPipeline.__call__.add_noise_to_image_latents",description:`<strong>add_noise_to_image_latents</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether to add noise to the image latents prior to denoising.`,name:"add_noise_to_image_latents"},{anchor:"diffusers.HeliosPipeline.__call__.image_noise_sigma_min",description:`<strong>image_noise_sigma_min</strong> (<code>float</code>, <em>optional</em>, defaults to <code>0.111</code>) &#x2014;
Minimum sigma value for noise added to image latents.`,name:"image_noise_sigma_min"},{anchor:"diffusers.HeliosPipeline.__call__.image_noise_sigma_max",description:`<strong>image_noise_sigma_max</strong> (<code>float</code>, <em>optional</em>, defaults to <code>0.135</code>) &#x2014;
Maximum sigma value for noise added to image latents.`,name:"image_noise_sigma_max"},{anchor:"diffusers.HeliosPipeline.__call__.video",description:`<strong>video</strong> (<code>PipelineImageInput</code>, <em>optional</em>) &#x2014;
Input video used for video-to-video conditioning.`,name:"video"},{anchor:"diffusers.HeliosPipeline.__call__.video_latents",description:`<strong>video_latents</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-encoded video latents to use instead of <code>video</code>.`,name:"video_latents"},{anchor:"diffusers.HeliosPipeline.__call__.add_noise_to_video_latents",description:`<strong>add_noise_to_video_latents</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether to add noise to the video latents prior to denoising.`,name:"add_noise_to_video_latents"},{anchor:"diffusers.HeliosPipeline.__call__.video_noise_sigma_min",description:`<strong>video_noise_sigma_min</strong> (<code>float</code>, <em>optional</em>, defaults to <code>0.111</code>) &#x2014;
Minimum sigma value for noise added to video latents.`,name:"video_noise_sigma_min"},{anchor:"diffusers.HeliosPipeline.__call__.video_noise_sigma_max",description:`<strong>video_noise_sigma_max</strong> (<code>float</code>, <em>optional</em>, defaults to <code>0.135</code>) &#x2014;
Maximum sigma value for noise added to video latents.`,name:"video_noise_sigma_max"},{anchor:"diffusers.HeliosPipeline.__call__.history_sizes",description:`<strong>history_sizes</strong> (<code>list</code>, <em>optional</em>, defaults to <code>[16, 2, 1]</code>) &#x2014;
History window sizes used for autoregressive chunked generation.`,name:"history_sizes"},{anchor:"diffusers.HeliosPipeline.__call__.num_latent_frames_per_chunk",description:`<strong>num_latent_frames_per_chunk</strong> (<code>int</code>, <em>optional</em>, defaults to <code>9</code>) &#x2014;
Number of latent frames produced per chunk during autoregressive generation.`,name:"num_latent_frames_per_chunk"},{anchor:"diffusers.HeliosPipeline.__call__.keep_first_frame",description:`<strong>keep_first_frame</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether to retain the first frame across chunks.`,name:"keep_first_frame"},{anchor:"diffusers.HeliosPipeline.__call__.is_skip_first_chunk",description:`<strong>is_skip_first_chunk</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether to skip generation of the first chunk.`,name:"is_skip_first_chunk"}],source:"https://github.com/huggingface/diffusers/blob/vr_13832/src/diffusers/pipelines/helios/pipeline_helios.py#L445",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>
<p>If <code>return_dict</code> is <code>True</code>, <code>HeliosPipelineOutput</code> is returned, otherwise a <code>tuple</code> is returned where
the first element is a list with the generated images and the second element is a list of <code>bool</code>s
indicating whether the corresponding generated image contains “not-safe-for-work” (nsfw) content.</p>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>
<p><code>~HeliosPipelineOutput</code> or <code>tuple</code></p>
`}}),S=new it({props:{anchor:"diffusers.HeliosPipeline.__call__.example",$$slots:{default:[_t]},$$scope:{ctx:T}}}),ge=new Ge({props:{name:"encode_prompt",anchor:"diffusers.HeliosPipeline.encode_prompt",parameters:[{name:"prompt",val:": str | list[str]"},{name:"negative_prompt",val:": str | list[str] | None = None"},{name:"do_classifier_free_guidance",val:": bool = True"},{name:"num_videos_per_prompt",val:": int = 1"},{name:"prompt_embeds",val:": torch.Tensor | None = None"},{name:"negative_prompt_embeds",val:": torch.Tensor | None = None"},{name:"max_sequence_length",val:": int = 226"},{name:"device",val:": torch.device | None = None"},{name:"dtype",val:": torch.dtype | None = None"}],parametersDescription:[{anchor:"diffusers.HeliosPipeline.encode_prompt.prompt",description:`<strong>prompt</strong> (<code>str</code> or <code>list[str]</code>, <em>optional</em>) &#x2014;
prompt to be encoded`,name:"prompt"},{anchor:"diffusers.HeliosPipeline.encode_prompt.negative_prompt",description:`<strong>negative_prompt</strong> (<code>str</code> or <code>list[str]</code>, <em>optional</em>) &#x2014;
The prompt or prompts not to guide the image generation. If not defined, one has to pass
<code>negative_prompt_embeds</code> instead. Ignored when not using guidance (i.e., ignored if <code>guidance_scale</code> is
less than <code>1</code>).`,name:"negative_prompt"},{anchor:"diffusers.HeliosPipeline.encode_prompt.do_classifier_free_guidance",description:`<strong>do_classifier_free_guidance</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether to use classifier free guidance or not.`,name:"do_classifier_free_guidance"},{anchor:"diffusers.HeliosPipeline.encode_prompt.num_videos_per_prompt",description:`<strong>num_videos_per_prompt</strong> (<code>int</code>, <em>optional</em>, defaults to 1) &#x2014;
Number of videos that should be generated per prompt. torch device to place the resulting embeddings on`,name:"num_videos_per_prompt"},{anchor:"diffusers.HeliosPipeline.encode_prompt.prompt_embeds",description:`<strong>prompt_embeds</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated text embeddings. Can be used to easily tweak text inputs, <em>e.g.</em> prompt weighting. If not
provided, text embeddings will be generated from <code>prompt</code> input argument.`,name:"prompt_embeds"},{anchor:"diffusers.HeliosPipeline.encode_prompt.negative_prompt_embeds",description:`<strong>negative_prompt_embeds</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated negative text embeddings. Can be used to easily tweak text inputs, <em>e.g.</em> prompt
weighting. If not provided, negative_prompt_embeds will be generated from <code>negative_prompt</code> input
argument.`,name:"negative_prompt_embeds"},{anchor:"diffusers.HeliosPipeline.encode_prompt.device",description:`<strong>device</strong> &#x2014; (<code>torch.device</code>, <em>optional</em>):
torch device`,name:"device"},{anchor:"diffusers.HeliosPipeline.encode_prompt.dtype",description:`<strong>dtype</strong> &#x2014; (<code>torch.dtype</code>, <em>optional</em>):
torch dtype`,name:"dtype"}],source:"https://github.com/huggingface/diffusers/blob/vr_13832/src/diffusers/pipelines/helios/pipeline_helios.py#L196"}}),Je=new W({props:{title:"HeliosPyramidPipeline",local:"diffusers.HeliosPyramidPipeline",headingTag:"h2"}}),fe=new Ge({props:{name:"class diffusers.HeliosPyramidPipeline",anchor:"diffusers.HeliosPyramidPipeline",parameters:[{name:"tokenizer",val:": AutoTokenizer"},{name:"text_encoder",val:": UMT5EncoderModel"},{name:"vae",val:": AutoencoderKLWan"},{name:"scheduler",val:": diffusers.schedulers.scheduling_helios.HeliosScheduler | diffusers.schedulers.scheduling_helios_dmd.HeliosDMDScheduler"},{name:"transformer",val:": HeliosTransformer3DModel"},{name:"is_cfg_zero_star",val:": bool = False"},{name:"is_distilled",val:": bool = False"}],parametersDescription:[{anchor:"diffusers.HeliosPyramidPipeline.tokenizer",description:`<strong>tokenizer</strong> (<code>T5Tokenizer</code>) &#x2014;
Tokenizer from <a href="https://huggingface.co/docs/transformers/en/model_doc/t5#transformers.T5Tokenizer" rel="nofollow">T5</a>,
specifically the <a href="https://huggingface.co/google/umt5-xxl" rel="nofollow">google/umt5-xxl</a> variant.`,name:"tokenizer"},{anchor:"diffusers.HeliosPyramidPipeline.text_encoder",description:`<strong>text_encoder</strong> (<code>T5EncoderModel</code>) &#x2014;
<a href="https://huggingface.co/docs/transformers/en/model_doc/t5#transformers.T5EncoderModel" rel="nofollow">T5</a>, specifically
the <a href="https://huggingface.co/google/umt5-xxl" rel="nofollow">google/umt5-xxl</a> variant.`,name:"text_encoder"},{anchor:"diffusers.HeliosPyramidPipeline.transformer",description:`<strong>transformer</strong> (<a href="/docs/diffusers/pr_13832/en/api/models/helios_transformer3d#diffusers.HeliosTransformer3DModel">HeliosTransformer3DModel</a>) &#x2014;
Conditional Transformer to denoise the input latents.`,name:"transformer"},{anchor:"diffusers.HeliosPyramidPipeline.scheduler",description:`<strong>scheduler</strong> ([<code>HeliosScheduler</code>, <code>HeliosDMDScheduler</code>]) &#x2014;
A scheduler to be used in combination with <code>transformer</code> to denoise the encoded image latents.`,name:"scheduler"},{anchor:"diffusers.HeliosPyramidPipeline.vae",description:`<strong>vae</strong> (<a href="/docs/diffusers/pr_13832/en/api/models/autoencoder_kl_wan#diffusers.AutoencoderKLWan">AutoencoderKLWan</a>) &#x2014;
Variational Auto-Encoder (VAE) Model to encode and decode videos to and from latent representations.`,name:"vae"}],source:"https://github.com/huggingface/diffusers/blob/vr_13832/src/diffusers/pipelines/helios/pipeline_helios_pyramid.py#L121"}}),be=new Ge({props:{name:"__call__",anchor:"diffusers.HeliosPyramidPipeline.__call__",parameters:[{name:"prompt",val:": str | list[str] = None"},{name:"negative_prompt",val:": str | list[str] = None"},{name:"height",val:": int = 384"},{name:"width",val:": int = 640"},{name:"num_frames",val:": int = 132"},{name:"sigmas",val:": list = None"},{name:"guidance_scale",val:": float = 5.0"},{name:"num_videos_per_prompt",val:": int | None = 1"},{name:"generator",val:": torch._C.Generator | list[torch._C.Generator] | None = None"},{name:"latents",val:": torch.Tensor | None = None"},{name:"prompt_embeds",val:": torch.Tensor | None = None"},{name:"negative_prompt_embeds",val:": torch.Tensor | None = None"},{name:"output_type",val:": str | None = 'np'"},{name:"return_dict",val:": bool = True"},{name:"attention_kwargs",val:": dict[str, typing.Any] | None = None"},{name:"callback_on_step_end",val:": typing.Union[typing.Callable[[int, int], NoneType], diffusers.callbacks.PipelineCallback, diffusers.callbacks.MultiPipelineCallbacks, NoneType] = None"},{name:"callback_on_step_end_tensor_inputs",val:": list = ['latents']"},{name:"max_sequence_length",val:": int = 512"},{name:"image",val:": PIL.Image.Image | numpy.ndarray | torch.Tensor | list[PIL.Image.Image] | list[numpy.ndarray] | list[torch.Tensor] | None = None"},{name:"image_latents",val:": torch.Tensor | None = None"},{name:"fake_image_latents",val:": torch.Tensor | None = None"},{name:"add_noise_to_image_latents",val:": bool = True"},{name:"image_noise_sigma_min",val:": float = 0.111"},{name:"image_noise_sigma_max",val:": float = 0.135"},{name:"video",val:": PIL.Image.Image | numpy.ndarray | torch.Tensor | list[PIL.Image.Image] | list[numpy.ndarray] | list[torch.Tensor] | None = None"},{name:"video_latents",val:": torch.Tensor | None = None"},{name:"add_noise_to_video_latents",val:": bool = True"},{name:"video_noise_sigma_min",val:": float = 0.111"},{name:"video_noise_sigma_max",val:": float = 0.135"},{name:"history_sizes",val:": list = [16, 2, 1]"},{name:"num_latent_frames_per_chunk",val:": int = 9"},{name:"keep_first_frame",val:": bool = True"},{name:"is_skip_first_chunk",val:": bool = False"},{name:"pyramid_num_inference_steps_list",val:": list = [10, 10, 10]"},{name:"use_zero_init",val:": bool | None = True"},{name:"zero_steps",val:": int | None = 1"},{name:"is_amplify_first_chunk",val:": bool = False"}],parametersDescription:[{anchor:"diffusers.HeliosPyramidPipeline.__call__.prompt",description:`<strong>prompt</strong> (<code>str</code> or <code>list[str]</code>, <em>optional</em>) &#x2014;
The prompt or prompts to guide the image generation. If not defined, pass <code>prompt_embeds</code> instead.`,name:"prompt"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.negative_prompt",description:`<strong>negative_prompt</strong> (<code>str</code> or <code>list[str]</code>, <em>optional</em>) &#x2014;
The prompt or prompts to avoid during image generation. If not defined, pass <code>negative_prompt_embeds</code>
instead. Ignored when not using guidance (<code>guidance_scale</code> &lt; <code>1</code>).`,name:"negative_prompt"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.height",description:`<strong>height</strong> (<code>int</code>, defaults to <code>384</code>) &#x2014;
The height in pixels of the generated image.`,name:"height"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.width",description:`<strong>width</strong> (<code>int</code>, defaults to <code>640</code>) &#x2014;
The width in pixels of the generated image.`,name:"width"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.num_frames",description:`<strong>num_frames</strong> (<code>int</code>, defaults to <code>132</code>) &#x2014;
The number of frames in the generated video.`,name:"num_frames"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.sigmas",description:`<strong>sigmas</strong> (<code>list[float]</code>, <em>optional</em>) &#x2014;
Custom sigmas to use for the denoising process. If not defined, the scheduler&#x2019;s default schedule is
used.`,name:"sigmas"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.guidance_scale",description:`<strong>guidance_scale</strong> (<code>float</code>, defaults to <code>5.0</code>) &#x2014;
Guidance scale as defined in <a href="https://huggingface.co/papers/2207.12598" rel="nofollow">Classifier-Free Diffusion
Guidance</a>. <code>guidance_scale</code> is defined as <code>w</code> of equation 2.
of <a href="https://huggingface.co/papers/2205.11487" rel="nofollow">Imagen Paper</a>. Guidance scale is enabled by setting
<code>guidance_scale &gt; 1</code>. Higher guidance scale encourages to generate images that are closely linked to
the text <code>prompt</code>, usually at the expense of lower image quality.`,name:"guidance_scale"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.num_videos_per_prompt",description:`<strong>num_videos_per_prompt</strong> (<code>int</code>, <em>optional</em>, defaults to 1) &#x2014;
The number of images to generate per prompt.`,name:"num_videos_per_prompt"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.generator",description:`<strong>generator</strong> (<code>torch.Generator</code> or <code>list[torch.Generator]</code>, <em>optional</em>) &#x2014;
A <a href="https://pytorch.org/docs/stable/generated/torch.Generator.html" rel="nofollow"><code>torch.Generator</code></a> to make
generation deterministic.`,name:"generator"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.latents",description:`<strong>latents</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated noisy latents sampled from a Gaussian distribution, to be used as inputs for image
generation. Can be used to tweak the same generation with different prompts. If not provided, a latents
tensor is generated by sampling using the supplied random <code>generator</code>.`,name:"latents"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.prompt_embeds",description:`<strong>prompt_embeds</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated text embeddings. Can be used to easily tweak text inputs (prompt weighting). If not
provided, text embeddings are generated from the <code>prompt</code> input argument.`,name:"prompt_embeds"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.negative_prompt_embeds",description:`<strong>negative_prompt_embeds</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated negative text embeddings. If not provided, they are generated from <code>negative_prompt</code>.`,name:"negative_prompt_embeds"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.output_type",description:`<strong>output_type</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;np&quot;</code>) &#x2014;
The output format of the generated image. Choose between <code>PIL.Image</code> or <code>np.array</code>.`,name:"output_type"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether or not to return a <code>HeliosPipelineOutput</code> instead of a plain tuple.`,name:"return_dict"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.attention_kwargs",description:`<strong>attention_kwargs</strong> (<code>dict</code>, <em>optional</em>) &#x2014;
A kwargs dictionary that if specified is passed along to the <code>AttentionProcessor</code> as defined under
<code>self.processor</code> in
<a href="https://github.com/huggingface/diffusers/blob/main/src/diffusers/models/attention_processor.py" rel="nofollow">diffusers.models.attention_processor</a>.`,name:"attention_kwargs"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.callback_on_step_end",description:`<strong>callback_on_step_end</strong> (<code>Callable</code>, <code>PipelineCallback</code>, <code>MultiPipelineCallbacks</code>, <em>optional</em>) &#x2014;
A function or a subclass of <code>PipelineCallback</code> or <code>MultiPipelineCallbacks</code> that is called at the end of
each denoising step during the inference. with the following arguments: <code>callback_on_step_end(self: DiffusionPipeline, step: int, timestep: int, callback_kwargs: Dict)</code>. <code>callback_kwargs</code> will include a
list of all tensors as specified by <code>callback_on_step_end_tensor_inputs</code>.`,name:"callback_on_step_end"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.callback_on_step_end_tensor_inputs",description:`<strong>callback_on_step_end_tensor_inputs</strong> (<code>list</code>, <em>optional</em>) &#x2014;
The list of tensor inputs for the <code>callback_on_step_end</code> function. The tensors specified in the list
will be passed as <code>callback_kwargs</code> argument. You will only be able to include variables listed in the
<code>._callback_tensor_inputs</code> attribute of your pipeline class.`,name:"callback_on_step_end_tensor_inputs"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.max_sequence_length",description:`<strong>max_sequence_length</strong> (<code>int</code>, defaults to <code>512</code>) &#x2014;
The maximum sequence length of the text encoder. If the prompt is longer than this, it will be
truncated. If the prompt is shorter, it will be padded to this length.`,name:"max_sequence_length"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.image",description:`<strong>image</strong> (<code>PipelineImageInput</code>, <em>optional</em>) &#x2014;
Input image used for image-to-video conditioning.`,name:"image"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.image_latents",description:`<strong>image_latents</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-encoded image latents to use instead of <code>image</code>.`,name:"image_latents"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.fake_image_latents",description:`<strong>fake_image_latents</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Optional fake image latents used during conditioning.`,name:"fake_image_latents"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.add_noise_to_image_latents",description:`<strong>add_noise_to_image_latents</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether to add noise to the image latents prior to denoising.`,name:"add_noise_to_image_latents"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.image_noise_sigma_min",description:`<strong>image_noise_sigma_min</strong> (<code>float</code>, <em>optional</em>, defaults to <code>0.111</code>) &#x2014;
Minimum sigma value for noise added to image latents.`,name:"image_noise_sigma_min"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.image_noise_sigma_max",description:`<strong>image_noise_sigma_max</strong> (<code>float</code>, <em>optional</em>, defaults to <code>0.135</code>) &#x2014;
Maximum sigma value for noise added to image latents.`,name:"image_noise_sigma_max"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.video",description:`<strong>video</strong> (<code>PipelineImageInput</code>, <em>optional</em>) &#x2014;
Input video used for video-to-video conditioning.`,name:"video"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.video_latents",description:`<strong>video_latents</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-encoded video latents to use instead of <code>video</code>.`,name:"video_latents"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.add_noise_to_video_latents",description:`<strong>add_noise_to_video_latents</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether to add noise to the video latents prior to denoising.`,name:"add_noise_to_video_latents"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.video_noise_sigma_min",description:`<strong>video_noise_sigma_min</strong> (<code>float</code>, <em>optional</em>, defaults to <code>0.111</code>) &#x2014;
Minimum sigma value for noise added to video latents.`,name:"video_noise_sigma_min"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.video_noise_sigma_max",description:`<strong>video_noise_sigma_max</strong> (<code>float</code>, <em>optional</em>, defaults to <code>0.135</code>) &#x2014;
Maximum sigma value for noise added to video latents.`,name:"video_noise_sigma_max"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.history_sizes",description:`<strong>history_sizes</strong> (<code>list</code>, <em>optional</em>, defaults to <code>[16, 2, 1]</code>) &#x2014;
History window sizes used for autoregressive chunked generation.`,name:"history_sizes"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.num_latent_frames_per_chunk",description:`<strong>num_latent_frames_per_chunk</strong> (<code>int</code>, <em>optional</em>, defaults to <code>9</code>) &#x2014;
Number of latent frames produced per chunk during autoregressive generation.`,name:"num_latent_frames_per_chunk"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.keep_first_frame",description:`<strong>keep_first_frame</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether to retain the first frame across chunks.`,name:"keep_first_frame"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.is_skip_first_chunk",description:`<strong>is_skip_first_chunk</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether to skip generation of the first chunk.`,name:"is_skip_first_chunk"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.pyramid_num_inference_steps_list",description:`<strong>pyramid_num_inference_steps_list</strong> (<code>list</code>, <em>optional</em>, defaults to <code>[10, 10, 10]</code>) &#x2014;
Number of inference steps for each pyramid stage during Stage 2 generation.`,name:"pyramid_num_inference_steps_list"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.use_zero_init",description:`<strong>use_zero_init</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether to apply CFG zero-init at the start of denoising.`,name:"use_zero_init"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.zero_steps",description:`<strong>zero_steps</strong> (<code>int</code>, <em>optional</em>, defaults to <code>1</code>) &#x2014;
Number of initial steps that use CFG zero-init.`,name:"zero_steps"},{anchor:"diffusers.HeliosPyramidPipeline.__call__.is_amplify_first_chunk",description:`<strong>is_amplify_first_chunk</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether to amplify guidance on the first chunk (DMD-related).`,name:"is_amplify_first_chunk"}],source:"https://github.com/huggingface/diffusers/blob/vr_13832/src/diffusers/pipelines/helios/pipeline_helios_pyramid.py#L508",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>
<p>If <code>return_dict</code> is <code>True</code>, <code>HeliosPipelineOutput</code> is returned, otherwise a <code>tuple</code> is returned where
the first element is a list with the generated images and the second element is a list of <code>bool</code>s
indicating whether the corresponding generated image contains “not-safe-for-work” (nsfw) content.</p>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>
<p><code>~HeliosPipelineOutput</code> or <code>tuple</code></p>
`}}),E=new it({props:{anchor:"diffusers.HeliosPyramidPipeline.__call__.example",$$slots:{default:[Zt]},$$scope:{ctx:T}}}),we=new Ge({props:{name:"encode_prompt",anchor:"diffusers.HeliosPyramidPipeline.encode_prompt",parameters:[{name:"prompt",val:": str | list[str]"},{name:"negative_prompt",val:": str | list[str] | None = None"},{name:"do_classifier_free_guidance",val:": bool = True"},{name:"num_videos_per_prompt",val:": int = 1"},{name:"prompt_embeds",val:": torch.Tensor | None = None"},{name:"negative_prompt_embeds",val:": torch.Tensor | None = None"},{name:"max_sequence_length",val:": int = 226"},{name:"device",val:": torch.device | None = None"},{name:"dtype",val:": torch.dtype | None = None"}],parametersDescription:[{anchor:"diffusers.HeliosPyramidPipeline.encode_prompt.prompt",description:`<strong>prompt</strong> (<code>str</code> or <code>list[str]</code>, <em>optional</em>) &#x2014;
prompt to be encoded`,name:"prompt"},{anchor:"diffusers.HeliosPyramidPipeline.encode_prompt.negative_prompt",description:`<strong>negative_prompt</strong> (<code>str</code> or <code>list[str]</code>, <em>optional</em>) &#x2014;
The prompt or prompts not to guide the image generation. If not defined, one has to pass
<code>negative_prompt_embeds</code> instead. Ignored when not using guidance (i.e., ignored if <code>guidance_scale</code> is
less than <code>1</code>).`,name:"negative_prompt"},{anchor:"diffusers.HeliosPyramidPipeline.encode_prompt.do_classifier_free_guidance",description:`<strong>do_classifier_free_guidance</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether to use classifier free guidance or not.`,name:"do_classifier_free_guidance"},{anchor:"diffusers.HeliosPyramidPipeline.encode_prompt.num_videos_per_prompt",description:`<strong>num_videos_per_prompt</strong> (<code>int</code>, <em>optional</em>, defaults to 1) &#x2014;
Number of videos that should be generated per prompt. torch device to place the resulting embeddings on`,name:"num_videos_per_prompt"},{anchor:"diffusers.HeliosPyramidPipeline.encode_prompt.prompt_embeds",description:`<strong>prompt_embeds</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated text embeddings. Can be used to easily tweak text inputs, <em>e.g.</em> prompt weighting. If not
provided, text embeddings will be generated from <code>prompt</code> input argument.`,name:"prompt_embeds"},{anchor:"diffusers.HeliosPyramidPipeline.encode_prompt.negative_prompt_embeds",description:`<strong>negative_prompt_embeds</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated negative text embeddings. Can be used to easily tweak text inputs, <em>e.g.</em> prompt
weighting. If not provided, negative_prompt_embeds will be generated from <code>negative_prompt</code> input
argument.`,name:"negative_prompt_embeds"},{anchor:"diffusers.HeliosPyramidPipeline.encode_prompt.device",description:`<strong>device</strong> &#x2014; (<code>torch.device</code>, <em>optional</em>):
torch device`,name:"device"},{anchor:"diffusers.HeliosPyramidPipeline.encode_prompt.dtype",description:`<strong>dtype</strong> &#x2014; (<code>torch.dtype</code>, <em>optional</em>):
torch dtype`,name:"dtype"}],source:"https://github.com/huggingface/diffusers/blob/vr_13832/src/diffusers/pipelines/helios/pipeline_helios_pyramid.py#L214"}}),Ue=new W({props:{title:"HeliosPipelineOutput",local:"diffusers.pipelines.helios.pipeline_output.HeliosPipelineOutput",headingTag:"h2"}}),Te=new Ge({props:{name:"class diffusers.pipelines.helios.pipeline_output.HeliosPipelineOutput",anchor:"diffusers.pipelines.helios.pipeline_output.HeliosPipelineOutput",parameters:[{name:"frames",val:": Tensor"}],parametersDescription:[{anchor:"diffusers.pipelines.helios.pipeline_output.HeliosPipelineOutput.frames",description:`<strong>frames</strong> (<code>torch.Tensor</code>, <code>np.ndarray</code>, or List[List[PIL.Image.Image]]) &#x2014;
List of video outputs - It can be a nested list of length <code>batch_size,</code> with each sub-list containing
denoised PIL image sequences of length <code>num_frames.</code> It can also be a NumPy array or Torch tensor of shape
<code>(batch_size, num_frames, channels, height, width)</code>.`,name:"frames"}],source:"https://github.com/huggingface/diffusers/blob/vr_13832/src/diffusers/pipelines/helios/pipeline_output.py#L9"}}),_e=new Mt({props:{source:"https://github.com/huggingface/diffusers/blob/main/docs/source/en/api/pipelines/helios.md"}}),{c(){s=m("meta"),p=r(),t=m("p"),o=r(),c=m("div"),c.innerHTML=i,U=r(),M(Z.$$.fragment),_=r(),v=m("p"),v.innerHTML=xs,Ne=r(),q=m("ul"),q.innerHTML=Ys,ze=r(),D=m("p"),D.textContent=Qs,Fe=r(),A=m("ul"),A.innerHTML=Ns,Se=r(),Y=m("blockquote"),Y.innerHTML=zs,$e=r(),M(L.$$.fragment),Ee=r(),K=m("p"),K.textContent=Fs,Pe=r(),M(Q.$$.fragment),qe=r(),M(O.$$.fragment),De=r(),ee=m("p"),ee.textContent=Ss,Ae=r(),M(N.$$.fragment),Le=r(),M(se.$$.fragment),Ke=r(),te=m("p"),te.textContent=$s,Oe=r(),M(z.$$.fragment),es=r(),M(le.$$.fragment),ss=r(),ne=m("p"),ne.textContent=Es,ts=r(),M(F.$$.fragment),ls=r(),M(ae.$$.fragment),ns=r(),oe=m("table"),oe.innerHTML=Ps,as=r(),M(ie.$$.fragment),os=r(),re=m("table"),re.innerHTML=qs,is=r(),M(de.$$.fragment),rs=r(),ce=m("table"),ce.innerHTML=Ds,ds=r(),M(pe.$$.fragment),cs=r(),me=m("p"),me.textContent=As,ps=r(),ye=m("ul"),ye.innerHTML=Ls,ms=r(),M(Me.$$.fragment),ys=r(),j=m("div"),M(ue.$$.fragment),Ts=r(),Ie=m("p"),Ie.textContent=Ks,_s=r(),We=m("p"),We.innerHTML=Os,Zs=r(),H=m("div"),M(he.$$.fragment),js=r(),He=m("p"),He.textContent=et,Gs=r(),M(S.$$.fragment),vs=r(),$=m("div"),M(ge.$$.fragment),Bs=r(),ke=m("p"),ke.textContent=st,Ms=r(),M(Je.$$.fragment),us=r(),G=m("div"),M(fe.$$.fragment),Is=r(),Ve=m("p"),Ve.textContent=tt,Ws=r(),Ce=m("p"),Ce.innerHTML=lt,Hs=r(),k=m("div"),M(be.$$.fragment),ks=r(),Xe=m("p"),Xe.textContent=nt,Vs=r(),M(E.$$.fragment),Cs=r(),P=m("div"),M(we.$$.fragment),Xs=r(),Re=m("p"),Re.textContent=at,hs=r(),M(Ue.$$.fragment),gs=r(),C=m("div"),M(Te.$$.fragment),Rs=r(),xe=m("p"),xe.textContent=ot,Js=r(),M(_e.$$.fragment),fs=r(),Ye=m("p"),this.h()},l(e){const l=mt("svelte-u9bgzb",document.head);s=y(l,"META",{name:!0,content:!0}),l.forEach(n),p=d(e),t=y(e,"P",{}),x(t).forEach(n),o=d(e),c=y(e,"DIV",{style:!0,"data-svelte-h":!0}),w(c)!=="svelte-p206qu"&&(c.innerHTML=i),U=d(e),u(Z.$$.fragment,e),_=d(e),v=y(e,"P",{"data-svelte-h":!0}),w(v)!=="svelte-1d0a5nd"&&(v.innerHTML=xs),Ne=d(e),q=y(e,"UL",{"data-svelte-h":!0}),w(q)!=="svelte-lvagkz"&&(q.innerHTML=Ys),ze=d(e),D=y(e,"P",{"data-svelte-h":!0}),w(D)!=="svelte-14rus1k"&&(D.textContent=Qs),Fe=d(e),A=y(e,"UL",{"data-svelte-h":!0}),w(A)!=="svelte-v6k6wb"&&(A.innerHTML=Ns),Se=d(e),Y=y(e,"BLOCKQUOTE",{class:!0,"data-svelte-h":!0}),w(Y)!=="svelte-umltqm"&&(Y.innerHTML=zs),$e=d(e),u(L.$$.fragment,e),Ee=d(e),K=y(e,"P",{"data-svelte-h":!0}),w(K)!=="svelte-r8z9s6"&&(K.textContent=Fs),Pe=d(e),u(Q.$$.fragment,e),qe=d(e),u(O.$$.fragment,e),De=d(e),ee=y(e,"P",{"data-svelte-h":!0}),w(ee)!=="svelte-1vd5ica"&&(ee.textContent=Ss),Ae=d(e),u(N.$$.fragment,e),Le=d(e),u(se.$$.fragment,e),Ke=d(e),te=y(e,"P",{"data-svelte-h":!0}),w(te)!=="svelte-iof85z"&&(te.textContent=$s),Oe=d(e),u(z.$$.fragment,e),es=d(e),u(le.$$.fragment,e),ss=d(e),ne=y(e,"P",{"data-svelte-h":!0}),w(ne)!=="svelte-p21bfr"&&(ne.textContent=Es),ts=d(e),u(F.$$.fragment,e),ls=d(e),u(ae.$$.fragment,e),ns=d(e),oe=y(e,"TABLE",{"data-svelte-h":!0}),w(oe)!=="svelte-1m8gje0"&&(oe.innerHTML=Ps),as=d(e),u(ie.$$.fragment,e),os=d(e),re=y(e,"TABLE",{"data-svelte-h":!0}),w(re)!=="svelte-vk5dpg"&&(re.innerHTML=qs),is=d(e),u(de.$$.fragment,e),rs=d(e),ce=y(e,"TABLE",{"data-svelte-h":!0}),w(ce)!=="svelte-4bqqgu"&&(ce.innerHTML=Ds),ds=d(e),u(pe.$$.fragment,e),cs=d(e),me=y(e,"P",{"data-svelte-h":!0}),w(me)!=="svelte-1mr3wmx"&&(me.textContent=As),ps=d(e),ye=y(e,"UL",{"data-svelte-h":!0}),w(ye)!=="svelte-hh64rs"&&(ye.innerHTML=Ls),ms=d(e),u(Me.$$.fragment,e),ys=d(e),j=y(e,"DIV",{class:!0});var B=x(j);u(ue.$$.fragment,B),Ts=d(B),Ie=y(B,"P",{"data-svelte-h":!0}),w(Ie)!=="svelte-sltwn0"&&(Ie.textContent=Ks),_s=d(B),We=y(B,"P",{"data-svelte-h":!0}),w(We)!=="svelte-7xsvt3"&&(We.innerHTML=Os),Zs=d(B),H=y(B,"DIV",{class:!0});var X=x(H);u(he.$$.fragment,X),js=d(X),He=y(X,"P",{"data-svelte-h":!0}),w(He)!=="svelte-50j04k"&&(He.textContent=et),Gs=d(X),u(S.$$.fragment,X),X.forEach(n),vs=d(B),$=y(B,"DIV",{class:!0});var Ze=x($);u(ge.$$.fragment,Ze),Bs=d(Ze),ke=y(Ze,"P",{"data-svelte-h":!0}),w(ke)!=="svelte-16q0ax1"&&(ke.textContent=st),Ze.forEach(n),B.forEach(n),Ms=d(e),u(Je.$$.fragment,e),us=d(e),G=y(e,"DIV",{class:!0});var I=x(G);u(fe.$$.fragment,I),Is=d(I),Ve=y(I,"P",{"data-svelte-h":!0}),w(Ve)!=="svelte-sltwn0"&&(Ve.textContent=tt),Ws=d(I),Ce=y(I,"P",{"data-svelte-h":!0}),w(Ce)!=="svelte-7xsvt3"&&(Ce.innerHTML=lt),Hs=d(I),k=y(I,"DIV",{class:!0});var R=x(k);u(be.$$.fragment,R),ks=d(R),Xe=y(R,"P",{"data-svelte-h":!0}),w(Xe)!=="svelte-50j04k"&&(Xe.textContent=nt),Vs=d(R),u(E.$$.fragment,R),R.forEach(n),Cs=d(I),P=y(I,"DIV",{class:!0});var je=x(P);u(we.$$.fragment,je),Xs=d(je),Re=y(je,"P",{"data-svelte-h":!0}),w(Re)!=="svelte-16q0ax1"&&(Re.textContent=at),je.forEach(n),I.forEach(n),hs=d(e),u(Ue.$$.fragment,e),gs=d(e),C=y(e,"DIV",{class:!0});var ws=x(C);u(Te.$$.fragment,ws),Rs=d(ws),xe=y(ws,"P",{"data-svelte-h":!0}),w(xe)!=="svelte-5oeizl"&&(xe.textContent=ot),ws.forEach(n),Js=d(e),u(_e.$$.fragment,e),fs=d(e),Ye=y(e,"P",{}),x(Ye).forEach(n),this.h()},h(){V(s,"name","hf:doc:metadata"),V(s,"content",Gt),yt(c,"float","right"),V(Y,"class","tip"),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"),V($,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),V(j,"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(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(G,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),V(C,"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,l){b(document.head,s),a(e,p,l),a(e,t,l),a(e,o,l),a(e,c,l),a(e,U,l),h(Z,e,l),a(e,_,l),a(e,v,l),a(e,Ne,l),a(e,q,l),a(e,ze,l),a(e,D,l),a(e,Fe,l),a(e,A,l),a(e,Se,l),a(e,Y,l),a(e,$e,l),h(L,e,l),a(e,Ee,l),a(e,K,l),a(e,Pe,l),h(Q,e,l),a(e,qe,l),h(O,e,l),a(e,De,l),a(e,ee,l),a(e,Ae,l),h(N,e,l),a(e,Le,l),h(se,e,l),a(e,Ke,l),a(e,te,l),a(e,Oe,l),h(z,e,l),a(e,es,l),h(le,e,l),a(e,ss,l),a(e,ne,l),a(e,ts,l),h(F,e,l),a(e,ls,l),h(ae,e,l),a(e,ns,l),a(e,oe,l),a(e,as,l),h(ie,e,l),a(e,os,l),a(e,re,l),a(e,is,l),h(de,e,l),a(e,rs,l),a(e,ce,l),a(e,ds,l),h(pe,e,l),a(e,cs,l),a(e,me,l),a(e,ps,l),a(e,ye,l),a(e,ms,l),h(Me,e,l),a(e,ys,l),a(e,j,l),h(ue,j,null),b(j,Ts),b(j,Ie),b(j,_s),b(j,We),b(j,Zs),b(j,H),h(he,H,null),b(H,js),b(H,He),b(H,Gs),h(S,H,null),b(j,vs),b(j,$),h(ge,$,null),b($,Bs),b($,ke),a(e,Ms,l),h(Je,e,l),a(e,us,l),a(e,G,l),h(fe,G,null),b(G,Is),b(G,Ve),b(G,Ws),b(G,Ce),b(G,Hs),b(G,k),h(be,k,null),b(k,ks),b(k,Xe),b(k,Vs),h(E,k,null),b(G,Cs),b(G,P),h(we,P,null),b(P,Xs),b(P,Re),a(e,hs,l),h(Ue,e,l),a(e,gs,l),a(e,C,l),h(Te,C,null),b(C,Rs),b(C,xe),a(e,Js,l),h(_e,e,l),a(e,fs,l),a(e,Ye,l),bs=!0},p(e,[l]){const B={};l&2&&(B.$$scope={dirty:l,ctx:e}),Q.$set(B);const X={};l&2&&(X.$$scope={dirty:l,ctx:e}),N.$set(X);const Ze={};l&2&&(Ze.$$scope={dirty:l,ctx:e}),z.$set(Ze);const I={};l&2&&(I.$$scope={dirty:l,ctx:e}),F.$set(I);const R={};l&2&&(R.$$scope={dirty:l,ctx:e}),S.$set(R);const je={};l&2&&(je.$$scope={dirty:l,ctx:e}),E.$set(je)},i(e){bs||(g(Z.$$.fragment,e),g(L.$$.fragment,e),g(Q.$$.fragment,e),g(O.$$.fragment,e),g(N.$$.fragment,e),g(se.$$.fragment,e),g(z.$$.fragment,e),g(le.$$.fragment,e),g(F.$$.fragment,e),g(ae.$$.fragment,e),g(ie.$$.fragment,e),g(de.$$.fragment,e),g(pe.$$.fragment,e),g(Me.$$.fragment,e),g(ue.$$.fragment,e),g(he.$$.fragment,e),g(S.$$.fragment,e),g(ge.$$.fragment,e),g(Je.$$.fragment,e),g(fe.$$.fragment,e),g(be.$$.fragment,e),g(E.$$.fragment,e),g(we.$$.fragment,e),g(Ue.$$.fragment,e),g(Te.$$.fragment,e),g(_e.$$.fragment,e),bs=!0)},o(e){J(Z.$$.fragment,e),J(L.$$.fragment,e),J(Q.$$.fragment,e),J(O.$$.fragment,e),J(N.$$.fragment,e),J(se.$$.fragment,e),J(z.$$.fragment,e),J(le.$$.fragment,e),J(F.$$.fragment,e),J(ae.$$.fragment,e),J(ie.$$.fragment,e),J(de.$$.fragment,e),J(pe.$$.fragment,e),J(Me.$$.fragment,e),J(ue.$$.fragment,e),J(he.$$.fragment,e),J(S.$$.fragment,e),J(ge.$$.fragment,e),J(Je.$$.fragment,e),J(fe.$$.fragment,e),J(be.$$.fragment,e),J(E.$$.fragment,e),J(we.$$.fragment,e),J(Ue.$$.fragment,e),J(Te.$$.fragment,e),J(_e.$$.fragment,e),bs=!1},d(e){e&&(n(p),n(t),n(o),n(c),n(U),n(_),n(v),n(Ne),n(q),n(ze),n(D),n(Fe),n(A),n(Se),n(Y),n($e),n(Ee),n(K),n(Pe),n(qe),n(De),n(ee),n(Ae),n(Le),n(Ke),n(te),n(Oe),n(es),n(ss),n(ne),n(ts),n(ls),n(ns),n(oe),n(as),n(os),n(re),n(is),n(rs),n(ce),n(ds),n(cs),n(me),n(ps),n(ye),n(ms),n(ys),n(j),n(Ms),n(us),n(G),n(hs),n(gs),n(C),n(Js),n(fs),n(Ye)),n(s),f(Z,e),f(L,e),f(Q,e),f(O,e),f(N,e),f(se,e),f(z,e),f(le,e),f(F,e),f(ae,e),f(ie,e),f(de,e),f(pe,e),f(Me,e),f(ue),f(he),f(S),f(ge),f(Je,e),f(fe),f(be),f(E),f(we),f(Ue,e),f(Te),f(_e,e)}}}const Gt='{"title":"Helios","local":"helios","sections":[{"title":"Optimizing Memory and Inference Speed","local":"optimizing-memory-and-inference-speed","sections":[],"depth":3},{"title":"Generation with Helios-Base","local":"generation-with-helios-base","sections":[],"depth":3},{"title":"Generation with Helios-Mid","local":"generation-with-helios-mid","sections":[],"depth":3},{"title":"Generation with Helios-Distilled","local":"generation-with-helios-distilled","sections":[],"depth":3},{"title":"Text-to-Video Showcases","local":"text-to-video-showcases","sections":[],"depth":2},{"title":"Image-to-Video Showcases","local":"image-to-video-showcases","sections":[],"depth":2},{"title":"Interactive-Video Showcases","local":"interactive-video-showcases","sections":[],"depth":2},{"title":"Resources","local":"resources","sections":[],"depth":2},{"title":"HeliosPipeline","local":"diffusers.HeliosPipeline","sections":[],"depth":2},{"title":"HeliosPyramidPipeline","local":"diffusers.HeliosPyramidPipeline","sections":[],"depth":2},{"title":"HeliosPipelineOutput","local":"diffusers.pipelines.helios.pipeline_output.HeliosPipelineOutput","sections":[],"depth":2}],"depth":1}';function vt(T){return dt(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class Xt extends ct{constructor(s){super(),pt(this,s,vt,jt,rt,{})}}export{Xt as component};

Xet Storage Details

Size:
135 kB
·
Xet hash:
3b84512b5a3091a2dec6e43c2c3b8c585d0b932fbc8611569f2c45784325eb24

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