Buckets:

HuggingFaceDocBuilder's picture
download
raw
127 kB
import{s as xs,o as Qs,n as fe}from"../chunks/scheduler.53228c21.js";import{S as Ns,i as zs,e as m,s as c,c as y,h as Fs,a as M,d as n,b as p,f as R,j as T,g as u,k,w as Ss,l as U,m as r,n as h,t as J,o as g,p as f}from"../chunks/index.100fac89.js";import{D as ge}from"../chunks/Docstring.8934f3ee.js";import{C as Ue}from"../chunks/CodeBlock.0adb3827.js";import{E as Ys}from"../chunks/ExampleCodeBlock.0fb1da6c.js";import{H as P,E as Es}from"../chunks/MermaidChart.svelte_svelte_type_style_lang.b70fb789.js";import{H as ns,a as We}from"../chunks/HfOption.fad27e59.js";function $s(w){let s,d='Refer to the <a href="../../optimization/memory">Reduce memory usage</a> guide for more details about the various memory saving techniques.',l,a,i="The Helios model below requires ~6GB of VRAM.",o,b,Z;return b=new Ue({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwZGlmZnVzZXJzJTIwaW1wb3J0JTIwQXV0b01vZGVsJTJDJTIwSGVsaW9zUGlwZWxpbmUlMEFmcm9tJTIwZGlmZnVzZXJzLmhvb2tzLmdyb3VwX29mZmxvYWRpbmclMjBpbXBvcnQlMjBhcHBseV9ncm91cF9vZmZsb2FkaW5nJTBBZnJvbSUyMGRpZmZ1c2Vycy51dGlscyUyMGltcG9ydCUyMGV4cG9ydF90b192aWRlbyUwQSUwQXZhZSUyMCUzRCUyMEF1dG9Nb2RlbC5mcm9tX3ByZXRyYWluZWQoJTIyQmVzdFdpc2hZc2glMkZIZWxpb3MtQmFzZSUyMiUyQyUyMHN1YmZvbGRlciUzRCUyMnZhZSUyMiUyQyUyMHRvcmNoX2R0eXBlJTNEdG9yY2guZmxvYXQzMiklMEElMEElMjMlMjBncm91cC1vZmZsb2FkaW5nJTBBcGlwZWxpbmUlMjAlM0QlMjBIZWxpb3NQaXBlbGluZS5mcm9tX3ByZXRyYWluZWQoJTBBJTIwJTIwJTIwJTIwJTIyQmVzdFdpc2hZc2gl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dXRwdXQubXA0JTIyJTJDJTIwZnBzJTNEMjQp",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=d,l=c(),a=m("p"),a.textContent=i,o=c(),y(b.$$.fragment)},l(_){s=M(_,"P",{"data-svelte-h":!0}),T(s)!=="svelte-iowzkr"&&(s.innerHTML=d),l=p(_),a=M(_,"P",{"data-svelte-h":!0}),T(a)!=="svelte-1xzbzlj"&&(a.textContent=i),o=p(_),u(b.$$.fragment,_)},m(_,B){r(_,s,B),r(_,l,B),r(_,a,B),r(_,o,B),h(b,_,B),Z=!0},p:fe,i(_){Z||(J(b.$$.fragment,_),Z=!0)},o(_){g(b.$$.fragment,_),Z=!1},d(_){_&&(n(s),n(l),n(a),n(o)),f(b,_)}}}function Ps(w){let s,d='<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.',l,a,i;return a=new Ue({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwZGlmZnVzZXJzJTIwaW1wb3J0JTIwQXV0b01vZGVsJTJDJTIwSGVsaW9zUGlwZWxpbmUlMEFmcm9tJTIwZGlmZnVzZXJzLnV0aWxzJTIwaW1wb3J0JTIwZ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lMkMlMjBtZXNzeSUyMGJhY2tncm91bmQlMkMlMjB0aHJlZSUyMGxlZ3MlMkMlMjBtYW55JTIwcGVvcGxlJTIwaW4lMjB0aGUlMjBiYWNrZ3JvdW5kJTJDJTIwd2Fsa2luZyUyMGJhY2t3YXJkcyUwQSUyMiUyMiUyMiUwQSUwQW91dHB1dCUyMCUzRCUyMHBpcGVsaW5lKCUwQSUyMCUyMCUyMCUyMHByb21wdCUzRHByb21wdCUyQyUwQSUyMCUyMCUyMCUyMG5lZ2F0aXZlX3Byb21wdCUzRG5lZ2F0aXZlX3Byb21wdCUyQyUwQSUyMCUyMCUyMCUyMG51bV9mcmFtZXMlM0Q5OSUyQyUwQSUyMCUyMCUyMCUyMG51bV9pbmZlcmVuY2Vfc3RlcHMlM0Q1MCUyQyUwQSUyMCUyMCUyMCUyMGd1aWRhbmNlX3NjYWxlJTNENS4wJTJDJTBBJTIwJTIwJTIwJTIwZ2VuZXJhdG9yJTNEdG9yY2guR2VuZXJhdG9yKCUyMmN1ZGElMjIpLm1hbnVhbF9zZWVkKDQyKSUyQyUwQSkuZnJhbWVzJTVCMCU1RCUwQWV4cG9ydF90b192aWRlbyhvdXRwdXQlMkMlMjAlMjJoZWxpb3NfYmFzZV90MnZfb3V0cHV0Lm1wNCUyMiUyQyUyMGZwcyUzRDI0KQ==",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=d,l=c(),y(a.$$.fragment)},l(o){s=M(o,"P",{"data-svelte-h":!0}),T(s)!=="svelte-19ygr0k"&&(s.innerHTML=d),l=p(o),u(a.$$.fragment,o)},m(o,b){r(o,s,b),r(o,l,b),h(a,o,b),i=!0},p:fe,i(o){i||(J(a.$$.fragment,o),i=!0)},o(o){g(a.$$.fragment,o),i=!1},d(o){o&&(n(s),n(l)),f(a,o)}}}function qs(w){let s,d,l,a;return s=new We({props:{id:"optimization",option:"memory",$$slots:{default:[$s]},$$scope:{ctx:w}}}),l=new We({props:{id:"optimization",option:"inference speed",$$slots:{default:[Ps]},$$scope:{ctx:w}}}),{c(){y(s.$$.fragment),d=c(),y(l.$$.fragment)},l(i){u(s.$$.fragment,i),d=p(i),u(l.$$.fragment,i)},m(i,o){h(s,i,o),r(i,d,o),h(l,i,o),a=!0},p(i,o){const b={};o&2&&(b.$$scope={dirty:o,ctx:i}),s.$set(b);const Z={};o&2&&(Z.$$scope={dirty:o,ctx:i}),l.$set(Z)},i(i){a||(J(s.$$.fragment,i),J(l.$$.fragment,i),a=!0)},o(i){g(s.$$.fragment,i),g(l.$$.fragment,i),a=!1},d(i){i&&n(d),f(s,i),f(l,i)}}}function Ds(w){let s,d;return s=new Ue({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwZGlmZnVzZXJzJTIwaW1wb3J0JTIwQXV0b01vZGVsJTJDJTIwSGVsaW9zUGlwZWxpbmUlMEFmcm9tJTIwZGlmZnVzZXJzLnV0aWxzJTIwaW1wb3J0JTIwZXhwb3J0X3RvX3ZpZGVvJTJDJTIwbG9hZF92aWRlbyUyQyUyMGxvYWRfaW1hZ2Ul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CUyMGFuZ2xlJTJDJTIwaGlnaGxpZ2h0aW5nJTIwdGhlJTIwY2FyJ3MlMjBhZ2dyZXNzaXZlJTIwc3RhbmNlJTIwYW5kJTIwdGhlJTIwc3Vycm91bmRpbmclMjBncmVlbmVyeS4lMEElMjIlMjIlMjIlMEF2aWRlb19wYXRoJTIwJTNEJTIwJTIyaHR0cHMlM0ElMkYlMkZodWdnaW5nZmFjZS5jbyUyRmRhdGFzZXRzJTJGaHVnZ2luZ2ZhY2UlMkZkb2N1bWVudGF0aW9uLWltYWdlcyUyRnJlc29sdmUlMkZtYWluJTJGZGlmZnVzZXJzJTJGaGVsaW9zJTJGY2FyLm1wNCUyMiUwQSUwQW91dHB1dCUyMCUzRCUyMHBpcGVsaW5lKCUwQSUyMCUyMCUyMCUyMHByb21wdCUzRHByb21wdCUyQyUwQSUyMCUyMCUyMCUyMG5lZ2F0aXZlX3Byb21wdCUzRG5lZ2F0aXZlX3Byb21wdCUyQyUwQSUyMCUyMCUyMCUyMHZpZGVvJTNEbG9hZF92aWRlbyh2aWRlb19wYXRoKSUyQyUwQSUyMCUyMCUyMCUyMG51bV9mcmFtZXMlM0Q5OSUyQyUwQSUyMCUyMCUyMCUyMG51bV9pbmZlcmVuY2Vfc3RlcHMlM0Q1MCUyQyUwQSUyMCUyMCUyMCUyMGd1aWRhbmNlX3NjYWxlJTNENS4wJTJDJTBBJTIwJTIwJTIwJTIwZ2VuZXJhdG9yJTNEdG9yY2guR2VuZXJhdG9yKCUyMmN1ZGElMjIpLm1hbnVhbF9zZWVkKDQyKSUyQyUwQSkuZnJhbWVzJTVCMCU1RCUwQWV4cG9ydF90b192aWRlbyhvdXRwdXQlMkMlMjAlMjJoZWxpb3NfYmFzZV92MnZfb3V0cHV0Lm1wNCUyMiUyQyUyMGZwcyUzRDI0KQ==",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(){y(s.$$.fragment)},l(l){u(s.$$.fragment,l)},m(l,a){h(s,l,a),d=!0},p:fe,i(l){d||(J(s.$$.fragment,l),d=!0)},o(l){g(s.$$.fragment,l),d=!1},d(l){f(s,l)}}}function As(w){let s,d;return s=new We({props:{id:"Helios-Base usage",option:"usage",$$slots:{default:[Ds]},$$scope:{ctx:w}}}),{c(){y(s.$$.fragment)},l(l){u(s.$$.fragment,l)},m(l,a){h(s,l,a),d=!0},p(l,a){const i={};a&2&&(i.$$scope={dirty:a,ctx:l}),s.$set(i)},i(l){d||(J(s.$$.fragment,l),d=!0)},o(l){g(s.$$.fragment,l),d=!1},d(l){f(s,l)}}}function Ls(w){let s,d;return s=new Ue({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwZGlmZnVzZXJzJTIwaW1wb3J0JTIwQXV0b01vZGVsJTJDJTIwSGVsaW9zUHlyYW1pZFBpcGVsaW5lJTBBZnJvbSUyMGRpZmZ1c2Vycy51dGlscyUyMGltcG9ydCUyMGV4cG9ydF90b192aWRlbyUyQyUyMGxvYWRfdmlkZW8lMkMlMjBsb2FkX2ltYWdlJTBBJTBBdmFlJTIwJTNEJTIwQXV0b01vZGVsLmZyb21fcHJldHJhaW5lZCglMjJCZXN0V2lzaFlzaCUyRkhlbGlvcy1NaWQlMjIlMkMlMjBzdWJmb2xkZXIlM0QlMjJ2YWUlMjIlMkMlMjB0b3JjaF9kdHlwZSUzRHRvcmNoLmZsb2F0MzIpJTBBJTBBcGlwZWxpbmUlMjAlM0QlMjBIZWxpb3NQeXJhbWlkUGlwZWxpbmUuZnJvbV9w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F90b192aWRlbyhvdXRwdXQlMkMlMjAlMjJoZWxpb3NfcHlyYW1pZF92MnZfb3V0cHV0Lm1wNCUyMiUyQyUyMGZwcyUzRDI0KQ==",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(){y(s.$$.fragment)},l(l){u(s.$$.fragment,l)},m(l,a){h(s,l,a),d=!0},p:fe,i(l){d||(J(s.$$.fragment,l),d=!0)},o(l){g(s.$$.fragment,l),d=!1},d(l){f(s,l)}}}function Ks(w){let s,d;return s=new We({props:{id:"Helios-Mid usage",option:"usage",$$slots:{default:[Ls]},$$scope:{ctx:w}}}),{c(){y(s.$$.fragment)},l(l){u(s.$$.fragment,l)},m(l,a){h(s,l,a),d=!0},p(l,a){const i={};a&2&&(i.$$scope={dirty:a,ctx:l}),s.$set(i)},i(l){d||(J(s.$$.fragment,l),d=!0)},o(l){g(s.$$.fragment,l),d=!1},d(l){f(s,l)}}}function Os(w){let s,d;return s=new Ue({props:{code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yUzRDI0MCUyQyUwQSUyMCUyMCUyMCUyMHB5cmFtaWRfbnVtX2luZmVyZW5jZV9zdGVwc19saXN0JTNEJTVCMiUyQyUyMDIlMkMlMjAyJTVEJTJDJTBBJTIwJTIwJTIwJTIwZ3VpZGFuY2Vfc2NhbGUlM0QxLjAlMkMlMEElMjAlMjAlMjAlMjBpc19hbXBsaWZ5X2ZpcnN0X2NodW5rJTNEVHJ1ZSUyQyUwQSUyMCUyMCUyMCUyMGdlbmVyYXRvciUzRHRvcmNoLkdlbmVyYXRvciglMjJjdWRhJTIyKS5tYW51YWxfc2VlZCg0MiklMkMlMEEpLmZyYW1lcyU1QjAlNUQlMEFleHBvcnRfdG9fdmlkZW8ob3V0cHV0JTJDJTIwJTIyaGVsaW9zX2Rpc3RpbGxlZF92MnZfb3V0cHV0Lm1wNCUyMiUyQyUyMGZwcyUzRDI0KQ==",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(){y(s.$$.fragment)},l(l){u(s.$$.fragment,l)},m(l,a){h(s,l,a),d=!0},p:fe,i(l){d||(J(s.$$.fragment,l),d=!0)},o(l){g(s.$$.fragment,l),d=!1},d(l){f(s,l)}}}function el(w){let s,d;return s=new We({props:{id:"Helios-Distilled usage",option:"usage",$$slots:{default:[Os]},$$scope:{ctx:w}}}),{c(){y(s.$$.fragment)},l(l){u(s.$$.fragment,l)},m(l,a){h(s,l,a),d=!0},p(l,a){const i={};a&2&&(i.$$scope={dirty:a,ctx:l}),s.$set(i)},i(l){d||(J(s.$$.fragment,l),d=!0)},o(l){g(s.$$.fragment,l),d=!1},d(l){f(s,l)}}}function sl(w){let s,d="Examples:",l,a,i;return a=new Ue({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwZGlmZnVzZXJzLnV0aWxzJTIwaW1wb3J0JTIwZXhwb3J0X3RvX3ZpZGVvJTBBZnJvbSUyMGRpZmZ1c2VycyUyMGltcG9ydCUyMEF1dG9lbmNvZGVyS0xXYW4lMkMlMjBIZWxpb3NQaXBlbGluZSUwQSUwQSUyMyUyMEF2YWlsYWJsZSUyMG1vZGVscyUzQSUyMEJlc3RXaXNoWXNoJTJGSGVsaW9zLUJhc2UlMkMlMjBCZXN0V2lzaFlzaCUyRkhlbGlvcy1NaWQlMkMlMjBCZXN0V2lzaFlzaCUyRkhlbGlvcy1EaXN0aWxsZWQlMEFtb2RlbF9pZCUyMCUzRCUyMCUyMkJlc3RXaXNoWXNoJTJGSGVsaW9zLUJhc2UlMjIlMEF2YWUlMjAlM0QlMjBBdXRvZW5jb2RlcktMV2FuLmZyb21fcHJldHJhaW5lZChtb2RlbF9pZCUyQyUyMHN1YmZvbGRlciUzRCUyMnZhZSUyMiUyQyUyMHRvcmNoX2R0eXBlJTNEdG9yY2guZmxvYXQzMiklMEFwaXBlJTIwJTNEJTIwSGVsaW9zUGlwZWxpbmUuZnJvbV9wcmV0cmFpbmVkKG1vZGVsX2lkJTJDJTIwdmFlJTNEdmFlJTJDJTIwdG9yY2hfZHR5cGUlM0R0b3JjaC5iZmxvYXQxNiklMEFwaX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ycyUyQyUyMHN0aWxsJTIwcGljdHVyZSUyQyUyMG1lc3N5JTIwYmFja2dyb3VuZCUyQyUyMHRocmVlJTIwbGVncyUyQyUyMG1hbnklMjBwZW9wbGUlMjBpbiUyMHRoZSUyMGJhY2tncm91bmQlMkMlMjB3YWxraW5nJTIwYmFja3dhcmRzJTIyJTBBJTBBb3V0cHV0JTIwJTNEJTIwcGlwZSglMEElMjAlMjAlMjAlMjBwcm9tcHQlM0Rwcm9tcHQlMkMlMEElMjAlMjAlMjAlMjBuZWdhdGl2ZV9wcm9tcHQlM0RuZWdhdGl2ZV9wcm9tcHQlMkMlMEElMjAlMjAlMjAlMjBoZWlnaHQlM0QzODQlMkMlMEElMjAlMjAlMjAlMjB3aWR0aCUzRDY0MCUyQyUwQSUyMCUyMCUyMCUyMG51bV9mcmFtZXMlM0QxMzIlMkMlMEElMjAlMjAlMjAlMjBndWlkYW5jZV9zY2FsZSUzRDUuMCUyQyUwQSkuZnJhbWVzJTVCMCU1RCUwQWV4cG9ydF90b192aWRlbyhvdXRwdXQlMkMlMjAlMjJvdXRwdXQubXA0JTIyJTJDJTIwZnBzJTNEMjQp",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=d,l=c(),y(a.$$.fragment)},l(o){s=M(o,"P",{"data-svelte-h":!0}),T(s)!=="svelte-kvfsh7"&&(s.textContent=d),l=p(o),u(a.$$.fragment,o)},m(o,b){r(o,s,b),r(o,l,b),h(a,o,b),i=!0},p:fe,i(o){i||(J(a.$$.fragment,o),i=!0)},o(o){g(a.$$.fragment,o),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wQSUyMCUyMCUyMCUyMG5lZ2F0aXZlX3Byb21wdCUzRG5lZ2F0aXZlX3Byb21wdCUyQyUwQSUyMCUyMCUyMCUyMGhlaWdodCUzRDM4NCUyQyUwQSUyMCUyMCUyMCUyMHdpZHRoJTNENjQwJTJDJTBBJTIwJTIwJTIwJTIwbnVtX2ZyYW1lcyUzRDEzMiUyQyUwQSUyMCUyMCUyMCUyMGd1aWRhbmNlX3NjYWxlJTNENS4wJTJDJTBBKS5mcmFtZXMlNUIwJTVEJTBBZXhwb3J0X3RvX3ZpZGVvKG91dHB1dCUyQyUyMCUyMm91dHB1dC5tcDQlMjIlMkMlMjBmcHMlM0QyNCk=",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=d,l=c(),y(a.$$.fragment)},l(o){s=M(o,"P",{"data-svelte-h":!0}),T(s)!=="svelte-kvfsh7"&&(s.textContent=d),l=p(o),u(a.$$.fragment,o)},m(o,b){r(o,s,b),r(o,l,b),h(a,o,b),i=!0},p:fe,i(o){i||(J(a.$$.fragment,o),i=!0)},o(o){g(a.$$.fragment,o),i=!1},d(o){o&&(n(s),n(l)),f(a,o)}}}function tl(w){let s,d,l,a,i,o='<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>',b,Z,_,B,Us='<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.',He,q,bs="<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>",ke,D,ws="The following Helios models are supported in Diffusers:",Ve,A,Ts='<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>',Ce,Y,_s="<p>Click on the Helios models in the right sidebar for more examples of video generation.</p>",Xe,L,Re,K,Zs="The example below demonstrates how to generate a video from text optimized for memory or inference speed.",Ye,x,xe,O,Qe,ee,js="The example below demonstrates how to use Helios-Base to generate video based on text, image or video.",Ne,Q,ze,se,Fe,le,Gs="The example below demonstrates how to use Helios-Mid to generate video based on text, image or video.",Se,N,Ee,te,$e,ne,Bs="The example below demonstrates how to use Helios-Distilled to generate video based on text, image or video.",Pe,z,qe,ae,De,j,oe,as,be,Is="Pipeline for text-to-video / image-to-video / video-to-video generation using Helios.",os,we,vs=`This model inherits from <a href="/docs/diffusers/pr_13769/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.).`,is,W,ie,rs,Te,Ws="The call function to the pipeline for generation.",ds,F,cs,S,re,ps,_e,Hs="Encodes the prompt into text encoder hidden states.",Ae,de,Le,G,ce,ms,Ze,ks="Pipeline for text-to-video / image-to-video / video-to-video generation using Helios.",Ms,je,Vs=`This model inherits from <a href="/docs/diffusers/pr_13769/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.).`,ys,H,pe,us,Ge,Cs="The call function to the pipeline for generation.",hs,E,Js,$,me,gs,Be,Xs="Encodes the prompt into text encoder hidden states.",Ke,Me,Oe,V,ye,fs,Ie,Rs="Output class for Helios pipelines.",es,ue,ss,ve,ls;return Z=new P({props:{title:"Helios",local:"helios",headingTag:"h1"}}),L=new P({props:{title:"Optimizing Memory and Inference Speed",local:"optimizing-memory-and-inference-speed",headingTag:"h3"}}),x=new ns({props:{id:"optimization",options:["memory","inference speed"],$$slots:{default:[qs]},$$scope:{ctx:w}}}),O=new P({props:{title:"Generation with Helios-Base",local:"generation-with-helios-base",headingTag:"h3"}}),Q=new ns({props:{id:"Helios-Base usage",options:["usage"],$$slots:{default:[As]},$$scope:{ctx:w}}}),se=new P({props:{title:"Generation with Helios-Mid",local:"generation-with-helios-mid",headingTag:"h3"}}),N=new ns({props:{id:"Helios-Mid usage",options:["usage"],$$slots:{default:[Ks]},$$scope:{ctx:w}}}),te=new P({props:{title:"Generation with Helios-Distilled",local:"generation-with-helios-distilled",headingTag:"h3"}}),z=new ns({props:{id:"Helios-Distilled usage",options:["usage"],$$slots:{default:[el]},$$scope:{ctx:w}}}),ae=new P({props:{title:"HeliosPipeline",local:"diffusers.HeliosPipeline",headingTag:"h2"}}),oe=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_13769/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_13769/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_13769/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_13769/src/diffusers/pipelines/helios/pipeline_helios.py#L108"}}),ie=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_13769/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>
`}}),F=new Ys({props:{anchor:"diffusers.HeliosPipeline.__call__.example",$$slots:{default:[sl]},$$scope:{ctx:w}}}),re=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_13769/src/diffusers/pipelines/helios/pipeline_helios.py#L196"}}),de=new P({props:{title:"HeliosPyramidPipeline",local:"diffusers.HeliosPyramidPipeline",headingTag:"h2"}}),ce=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_13769/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_13769/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_13769/src/diffusers/pipelines/helios/pipeline_helios_pyramid.py#L121"}}),pe=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_13769/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 Ys({props:{anchor:"diffusers.HeliosPyramidPipeline.__call__.example",$$slots:{default:[ll]},$$scope:{ctx:w}}}),me=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_13769/src/diffusers/pipelines/helios/pipeline_helios_pyramid.py#L214"}}),Me=new P({props:{title:"HeliosPipelineOutput",local:"diffusers.pipelines.helios.pipeline_output.HeliosPipelineOutput",headingTag:"h2"}}),ye=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_13769/src/diffusers/pipelines/helios/pipeline_output.py#L9"}}),ue=new Es({props:{source:"https://github.com/huggingface/diffusers/blob/main/docs/source/en/api/pipelines/helios.md"}}),{c(){s=m("meta"),d=c(),l=m("p"),a=c(),i=m("div"),i.innerHTML=o,b=c(),y(Z.$$.fragment),_=c(),B=m("p"),B.innerHTML=Us,He=c(),q=m("ul"),q.innerHTML=bs,ke=c(),D=m("p"),D.textContent=ws,Ve=c(),A=m("ul"),A.innerHTML=Ts,Ce=c(),Y=m("blockquote"),Y.innerHTML=_s,Xe=c(),y(L.$$.fragment),Re=c(),K=m("p"),K.textContent=Zs,Ye=c(),y(x.$$.fragment),xe=c(),y(O.$$.fragment),Qe=c(),ee=m("p"),ee.textContent=js,Ne=c(),y(Q.$$.fragment),ze=c(),y(se.$$.fragment),Fe=c(),le=m("p"),le.textContent=Gs,Se=c(),y(N.$$.fragment),Ee=c(),y(te.$$.fragment),$e=c(),ne=m("p"),ne.textContent=Bs,Pe=c(),y(z.$$.fragment),qe=c(),y(ae.$$.fragment),De=c(),j=m("div"),y(oe.$$.fragment),as=c(),be=m("p"),be.textContent=Is,os=c(),we=m("p"),we.innerHTML=vs,is=c(),W=m("div"),y(ie.$$.fragment),rs=c(),Te=m("p"),Te.textContent=Ws,ds=c(),y(F.$$.fragment),cs=c(),S=m("div"),y(re.$$.fragment),ps=c(),_e=m("p"),_e.textContent=Hs,Ae=c(),y(de.$$.fragment),Le=c(),G=m("div"),y(ce.$$.fragment),ms=c(),Ze=m("p"),Ze.textContent=ks,Ms=c(),je=m("p"),je.innerHTML=Vs,ys=c(),H=m("div"),y(pe.$$.fragment),us=c(),Ge=m("p"),Ge.textContent=Cs,hs=c(),y(E.$$.fragment),Js=c(),$=m("div"),y(me.$$.fragment),gs=c(),Be=m("p"),Be.textContent=Xs,Ke=c(),y(Me.$$.fragment),Oe=c(),V=m("div"),y(ye.$$.fragment),fs=c(),Ie=m("p"),Ie.textContent=Rs,es=c(),y(ue.$$.fragment),ss=c(),ve=m("p"),this.h()},l(e){const t=Fs("svelte-u9bgzb",document.head);s=M(t,"META",{name:!0,content:!0}),t.forEach(n),d=p(e),l=M(e,"P",{}),R(l).forEach(n),a=p(e),i=M(e,"DIV",{style:!0,"data-svelte-h":!0}),T(i)!=="svelte-p206qu"&&(i.innerHTML=o),b=p(e),u(Z.$$.fragment,e),_=p(e),B=M(e,"P",{"data-svelte-h":!0}),T(B)!=="svelte-1d0a5nd"&&(B.innerHTML=Us),He=p(e),q=M(e,"UL",{"data-svelte-h":!0}),T(q)!=="svelte-lvagkz"&&(q.innerHTML=bs),ke=p(e),D=M(e,"P",{"data-svelte-h":!0}),T(D)!=="svelte-14rus1k"&&(D.textContent=ws),Ve=p(e),A=M(e,"UL",{"data-svelte-h":!0}),T(A)!=="svelte-v6k6wb"&&(A.innerHTML=Ts),Ce=p(e),Y=M(e,"BLOCKQUOTE",{class:!0,"data-svelte-h":!0}),T(Y)!=="svelte-umltqm"&&(Y.innerHTML=_s),Xe=p(e),u(L.$$.fragment,e),Re=p(e),K=M(e,"P",{"data-svelte-h":!0}),T(K)!=="svelte-r8z9s6"&&(K.textContent=Zs),Ye=p(e),u(x.$$.fragment,e),xe=p(e),u(O.$$.fragment,e),Qe=p(e),ee=M(e,"P",{"data-svelte-h":!0}),T(ee)!=="svelte-1vd5ica"&&(ee.textContent=js),Ne=p(e),u(Q.$$.fragment,e),ze=p(e),u(se.$$.fragment,e),Fe=p(e),le=M(e,"P",{"data-svelte-h":!0}),T(le)!=="svelte-iof85z"&&(le.textContent=Gs),Se=p(e),u(N.$$.fragment,e),Ee=p(e),u(te.$$.fragment,e),$e=p(e),ne=M(e,"P",{"data-svelte-h":!0}),T(ne)!=="svelte-p21bfr"&&(ne.textContent=Bs),Pe=p(e),u(z.$$.fragment,e),qe=p(e),u(ae.$$.fragment,e),De=p(e),j=M(e,"DIV",{class:!0});var I=R(j);u(oe.$$.fragment,I),as=p(I),be=M(I,"P",{"data-svelte-h":!0}),T(be)!=="svelte-sltwn0"&&(be.textContent=Is),os=p(I),we=M(I,"P",{"data-svelte-h":!0}),T(we)!=="svelte-1lkeods"&&(we.innerHTML=vs),is=p(I),W=M(I,"DIV",{class:!0});var C=R(W);u(ie.$$.fragment,C),rs=p(C),Te=M(C,"P",{"data-svelte-h":!0}),T(Te)!=="svelte-50j04k"&&(Te.textContent=Ws),ds=p(C),u(F.$$.fragment,C),C.forEach(n),cs=p(I),S=M(I,"DIV",{class:!0});var he=R(S);u(re.$$.fragment,he),ps=p(he),_e=M(he,"P",{"data-svelte-h":!0}),T(_e)!=="svelte-16q0ax1"&&(_e.textContent=Hs),he.forEach(n),I.forEach(n),Ae=p(e),u(de.$$.fragment,e),Le=p(e),G=M(e,"DIV",{class:!0});var v=R(G);u(ce.$$.fragment,v),ms=p(v),Ze=M(v,"P",{"data-svelte-h":!0}),T(Ze)!=="svelte-sltwn0"&&(Ze.textContent=ks),Ms=p(v),je=M(v,"P",{"data-svelte-h":!0}),T(je)!=="svelte-1lkeods"&&(je.innerHTML=Vs),ys=p(v),H=M(v,"DIV",{class:!0});var X=R(H);u(pe.$$.fragment,X),us=p(X),Ge=M(X,"P",{"data-svelte-h":!0}),T(Ge)!=="svelte-50j04k"&&(Ge.textContent=Cs),hs=p(X),u(E.$$.fragment,X),X.forEach(n),Js=p(v),$=M(v,"DIV",{class:!0});var Je=R($);u(me.$$.fragment,Je),gs=p(Je),Be=M(Je,"P",{"data-svelte-h":!0}),T(Be)!=="svelte-16q0ax1"&&(Be.textContent=Xs),Je.forEach(n),v.forEach(n),Ke=p(e),u(Me.$$.fragment,e),Oe=p(e),V=M(e,"DIV",{class:!0});var ts=R(V);u(ye.$$.fragment,ts),fs=p(ts),Ie=M(ts,"P",{"data-svelte-h":!0}),T(Ie)!=="svelte-5oeizl"&&(Ie.textContent=Rs),ts.forEach(n),es=p(e),u(ue.$$.fragment,e),ss=p(e),ve=M(e,"P",{}),R(ve).forEach(n),this.h()},h(){k(s,"name","hf:doc:metadata"),k(s,"content",nl),Ss(i,"float","right"),k(Y,"class","tip"),k(W,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),k(S,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),k(j,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),k(H,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),k($,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),k(G,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),k(V,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8")},m(e,t){U(document.head,s),r(e,d,t),r(e,l,t),r(e,a,t),r(e,i,t),r(e,b,t),h(Z,e,t),r(e,_,t),r(e,B,t),r(e,He,t),r(e,q,t),r(e,ke,t),r(e,D,t),r(e,Ve,t),r(e,A,t),r(e,Ce,t),r(e,Y,t),r(e,Xe,t),h(L,e,t),r(e,Re,t),r(e,K,t),r(e,Ye,t),h(x,e,t),r(e,xe,t),h(O,e,t),r(e,Qe,t),r(e,ee,t),r(e,Ne,t),h(Q,e,t),r(e,ze,t),h(se,e,t),r(e,Fe,t),r(e,le,t),r(e,Se,t),h(N,e,t),r(e,Ee,t),h(te,e,t),r(e,$e,t),r(e,ne,t),r(e,Pe,t),h(z,e,t),r(e,qe,t),h(ae,e,t),r(e,De,t),r(e,j,t),h(oe,j,null),U(j,as),U(j,be),U(j,os),U(j,we),U(j,is),U(j,W),h(ie,W,null),U(W,rs),U(W,Te),U(W,ds),h(F,W,null),U(j,cs),U(j,S),h(re,S,null),U(S,ps),U(S,_e),r(e,Ae,t),h(de,e,t),r(e,Le,t),r(e,G,t),h(ce,G,null),U(G,ms),U(G,Ze),U(G,Ms),U(G,je),U(G,ys),U(G,H),h(pe,H,null),U(H,us),U(H,Ge),U(H,hs),h(E,H,null),U(G,Js),U(G,$),h(me,$,null),U($,gs),U($,Be),r(e,Ke,t),h(Me,e,t),r(e,Oe,t),r(e,V,t),h(ye,V,null),U(V,fs),U(V,Ie),r(e,es,t),h(ue,e,t),r(e,ss,t),r(e,ve,t),ls=!0},p(e,[t]){const I={};t&2&&(I.$$scope={dirty:t,ctx:e}),x.$set(I);const C={};t&2&&(C.$$scope={dirty:t,ctx:e}),Q.$set(C);const he={};t&2&&(he.$$scope={dirty:t,ctx:e}),N.$set(he);const v={};t&2&&(v.$$scope={dirty:t,ctx:e}),z.$set(v);const X={};t&2&&(X.$$scope={dirty:t,ctx:e}),F.$set(X);const Je={};t&2&&(Je.$$scope={dirty:t,ctx:e}),E.$set(Je)},i(e){ls||(J(Z.$$.fragment,e),J(L.$$.fragment,e),J(x.$$.fragment,e),J(O.$$.fragment,e),J(Q.$$.fragment,e),J(se.$$.fragment,e),J(N.$$.fragment,e),J(te.$$.fragment,e),J(z.$$.fragment,e),J(ae.$$.fragment,e),J(oe.$$.fragment,e),J(ie.$$.fragment,e),J(F.$$.fragment,e),J(re.$$.fragment,e),J(de.$$.fragment,e),J(ce.$$.fragment,e),J(pe.$$.fragment,e),J(E.$$.fragment,e),J(me.$$.fragment,e),J(Me.$$.fragment,e),J(ye.$$.fragment,e),J(ue.$$.fragment,e),ls=!0)},o(e){g(Z.$$.fragment,e),g(L.$$.fragment,e),g(x.$$.fragment,e),g(O.$$.fragment,e),g(Q.$$.fragment,e),g(se.$$.fragment,e),g(N.$$.fragment,e),g(te.$$.fragment,e),g(z.$$.fragment,e),g(ae.$$.fragment,e),g(oe.$$.fragment,e),g(ie.$$.fragment,e),g(F.$$.fragment,e),g(re.$$.fragment,e),g(de.$$.fragment,e),g(ce.$$.fragment,e),g(pe.$$.fragment,e),g(E.$$.fragment,e),g(me.$$.fragment,e),g(Me.$$.fragment,e),g(ye.$$.fragment,e),g(ue.$$.fragment,e),ls=!1},d(e){e&&(n(d),n(l),n(a),n(i),n(b),n(_),n(B),n(He),n(q),n(ke),n(D),n(Ve),n(A),n(Ce),n(Y),n(Xe),n(Re),n(K),n(Ye),n(xe),n(Qe),n(ee),n(Ne),n(ze),n(Fe),n(le),n(Se),n(Ee),n($e),n(ne),n(Pe),n(qe),n(De),n(j),n(Ae),n(Le),n(G),n(Ke),n(Oe),n(V),n(es),n(ss),n(ve)),n(s),f(Z,e),f(L,e),f(x,e),f(O,e),f(Q,e),f(se,e),f(N,e),f(te,e),f(z,e),f(ae,e),f(oe),f(ie),f(F),f(re),f(de,e),f(ce),f(pe),f(E),f(me),f(Me,e),f(ye),f(ue,e)}}}const nl='{"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":"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 al(w){return Qs(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class Ml extends Ns{constructor(s){super(),zs(this,s,al,tl,xs,{})}}export{Ml as component};

Xet Storage Details

Size:
127 kB
·
Xet hash:
21d39a44a2d9f83ea2e21a4651a21d8d10c9c36748d481cc4f7c72587b76d86e

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