import{s as We,o as Be,n as ze}from"../chunks/scheduler.8c3d61f6.js";import{S as Re,i as Ae,g as l,s as a,r as _,A as Se,h as p,f as n,c as i,j as H,u,x as I,k as J,y as s,a as r,v as f,d as h,t as b,w as y}from"../chunks/index.da70eac4.js";import{T as qe}from"../chunks/Tip.1d9b8c37.js";import{D as O}from"../chunks/Docstring.f5e3af6d.js";import{C as Oe}from"../chunks/CodeBlock.a9c4becf.js";import{E as Xe}from"../chunks/ExampleCodeBlock.21e67bb6.js";import{H as ve,E as Qe}from"../chunks/getInferenceSnippets.07305897.js";function Ye(X){let o,$='Make sure to check out the Schedulers <a href="../../using-diffusers/schedulers">guide</a> to learn how to explore the tradeoff between scheduler speed and quality, and see the <a href="../../using-diffusers/loading#reuse-a-pipeline">reuse components across pipelines</a> section to learn how to efficiently load the same components into multiple pipelines.';return{c(){o=l("p"),o.innerHTML=$},l(c){o=p(c,"P",{"data-svelte-h":!0}),I(o)!=="svelte-1qn15hi"&&(o.innerHTML=$)},m(c,v){r(c,o,v)},p:ze,d(c){c&&n(o)}}}function Ke(X){let o,$="Examples:",c,v,w;return v=new Oe({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwdHJhbnNmb3JtZXJzJTIwaW1wb3J0JTIwQXV0b1Rva2VuaXplciUyQyUyMExsYW1hRm9yQ2F1c2FsTE0lMEFmcm9tJTIwZGlmZnVzZXJzJTIwaW1wb3J0JTIwSGlEcmVhbUltYWdlUGlwZWxpbmUlMEElMEElMEF0b2tlbml6ZXJfNCUyMCUzRCUyMEF1dG9Ub2tlbml6ZXIuZnJvbV9wcmV0cmFpbmVkKCUyMm1ldGEtbGxhbWElMkZNZXRhLUxsYW1hLTMuMS04Qi1JbnN0cnVjdCUyMiklMEF0ZXh0X2VuY29kZXJfNCUyMCUzRCUyMExsYW1hRm9yQ2F1c2FsTE0uZnJvbV9wcmV0cmFpbmVkKCUwQSUyMCUyMCUyMCUyMCUyMm1ldGEtbGxhbWElMkZNZXRhLUxsYW1hLTMuMS04Qi1JbnN0cnVjdCUyMiUyQyUwQSUyMCUyMCUyMCUyMG91dHB1dF9oaWRkZW5fc3RhdGVzJTNEVHJ1ZSUyQyUwQSUyMCUyMCUyMCUyMG91dHB1dF9hdHRlbnRpb25zJTNEVHJ1ZSUyQyUwQSUyMCUyMCUyMCUyMHRvcmNoX2R0eXBlJTNEdG9yY2guYmZsb2F0MTYlMkMlMEEpJTBBJTBBcGlwZSUyMCUzRCUyMEhpRHJlYW1JbWFnZVBpcGVsaW5lLmZyb21fcHJldHJhaW5lZCglMEElMjAlMjAlMjAlMjAlMjJIaURyZWFtLWFpJTJGSGlEcmVhbS1JMS1GdWxsJTIyJTJDJTBBJTIwJTIwJTIwJTIwdG9rZW5pemVyXzQlM0R0b2tlbml6ZXJfNCUyQyUwQSUyMCUyMCUyMCUyMHRleHRfZW5jb2Rlcl80JTNEdGV4dF9lbmNvZGVyXzQlMkMlMEElMjAlMjAlMjAlMjB0b3JjaF9kdHlwZSUzRHRvcmNoLmJmbG9hdDE2JTJDJTBBKSUwQXBpcGUuZW5hYmxlX21vZGVsX2NwdV9vZmZsb2FkKCklMEElMEFpbWFnZSUyMCUzRCUyMHBpcGUoJTBBJTIwJTIwJTIwJTIwJ0ElMjBjYXQlMjBob2xkaW5nJTIwYSUyMHNpZ24lMjB0aGF0JTIwc2F5cyUyMCUyMkhpLURyZWFtcy5haSUyMi4nJTJDJTBBJTIwJTIwJTIwJTIwaGVpZ2h0JTNEMTAyNCUyQyUwQSUyMCUyMCUyMCUyMHdpZHRoJTNEMTAyNCUyQyUwQSUyMCUyMCUyMCUyMGd1aWRhbmNlX3NjYWxlJTNENS4wJTJDJTBBJTIwJTIwJTIwJTIwbnVtX2luZmVyZW5jZV9zdGVwcyUzRDUwJTJDJTBBJTIwJTIwJTIwJTIwZ2VuZXJhdG9yJTNEdG9yY2guR2VuZXJhdG9yKCUyMmN1ZGElMjIpLm1hbnVhbF9zZWVkKDApJTJDJTBBKS5pbWFnZXMlNUIwJTVEJTBBaW1hZ2Uuc2F2ZSglMjJvdXRwdXQucG5nJTIyKQ==",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> transformers <span class="hljs-keyword">import</span> AutoTokenizer, LlamaForCausalLM
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> diffusers <span class="hljs-keyword">import</span> HiDreamImagePipeline


<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer_4 = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;meta-llama/Meta-Llama-3.1-8B-Instruct&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>text_encoder_4 = LlamaForCausalLM.from_pretrained(
<span class="hljs-meta">... </span>    <span class="hljs-string">&quot;meta-llama/Meta-Llama-3.1-8B-Instruct&quot;</span>,
<span class="hljs-meta">... </span>    output_hidden_states=<span class="hljs-literal">True</span>,
<span class="hljs-meta">... </span>    output_attentions=<span class="hljs-literal">True</span>,
<span class="hljs-meta">... </span>    torch_dtype=torch.bfloat16,
<span class="hljs-meta">... </span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>pipe = HiDreamImagePipeline.from_pretrained(
<span class="hljs-meta">... </span>    <span class="hljs-string">&quot;HiDream-ai/HiDream-I1-Full&quot;</span>,
<span class="hljs-meta">... </span>    tokenizer_4=tokenizer_4,
<span class="hljs-meta">... </span>    text_encoder_4=text_encoder_4,
<span class="hljs-meta">... </span>    torch_dtype=torch.bfloat16,
<span class="hljs-meta">... </span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>pipe.enable_model_cpu_offload()

<span class="hljs-meta">&gt;&gt;&gt; </span>image = pipe(
<span class="hljs-meta">... </span>    <span class="hljs-string">&#x27;A cat holding a sign that says &quot;Hi-Dreams.ai&quot;.&#x27;</span>,
<span class="hljs-meta">... </span>    height=<span class="hljs-number">1024</span>,
<span class="hljs-meta">... </span>    width=<span class="hljs-number">1024</span>,
<span class="hljs-meta">... </span>    guidance_scale=<span class="hljs-number">5.0</span>,
<span class="hljs-meta">... </span>    num_inference_steps=<span class="hljs-number">50</span>,
<span class="hljs-meta">... </span>    generator=torch.Generator(<span class="hljs-string">&quot;cuda&quot;</span>).manual_seed(<span class="hljs-number">0</span>),
<span class="hljs-meta">... </span>).images[<span class="hljs-number">0</span>]
<span class="hljs-meta">&gt;&gt;&gt; </span>image.save(<span class="hljs-string">&quot;output.png&quot;</span>)`,wrap:!1}}),{c(){o=l("p"),o.textContent=$,c=a(),_(v.$$.fragment)},l(m){o=p(m,"P",{"data-svelte-h":!0}),I(o)!=="svelte-kvfsh7"&&(o.textContent=$),c=i(m),u(v.$$.fragment,m)},m(m,T){r(m,o,T),r(m,c,T),f(v,m,T),w=!0},p:ze,i(m){w||(h(v.$$.fragment,m),w=!0)},o(m){b(v.$$.fragment,m),w=!1},d(m){m&&(n(o),n(c)),y(v,m)}}}function et(X){let o,$,c,v,w,m,T,ke='<a href="https://huggingface.co/HiDream-ai" rel="nofollow">HiDream-I1</a> by HiDream.ai',ie,U,oe,E,se,N,Le='The following models are available for the <a href="text-to-image"><code>HiDreamImagePipeline</code></a> pipeline:',re,F,je='<thead><tr><th align="left">Model name</th> <th align="left">Description</th></tr></thead> <tbody><tr><td align="left"><a href="https://huggingface.co/HiDream-ai/HiDream-I1-Full" rel="nofollow"><code>HiDream-ai/HiDream-I1-Full</code></a></td> <td align="left">-</td></tr> <tr><td align="left"><a href="https://huggingface.co/HiDream-ai/HiDream-I1-Dev" rel="nofollow"><code>HiDream-ai/HiDream-I1-Dev</code></a></td> <td align="left">-</td></tr> <tr><td align="left"><a href="https://huggingface.co/HiDream-ai/HiDream-I1-Fast" rel="nofollow"><code>HiDream-ai/HiDream-I1-Fast</code></a></td> <td align="left">-</td></tr></tbody>',le,Z,pe,d,V,we,x,G,Te,Q,Ee="Function invoked when calling the pipeline for generation.",Ie,P,$e,C,z,xe,Y,Ne=`Disable sliced VAE decoding. If <code>enable_vae_slicing</code> was previously enabled, this method will go back to
computing decoding in one step.`,Me,k,W,De,K,Fe=`Disable tiled VAE decoding. If <code>enable_vae_tiling</code> was previously enabled, this method will go back to
computing decoding in one step.`,He,L,B,Je,ee,Ze=`Enable sliced VAE decoding. When this option is enabled, the VAE will split the input tensor in slices to
compute decoding in several steps. This is useful to save some memory and allow larger batch sizes.`,Ue,j,R,Pe,te,Ve=`Enable tiled VAE decoding. When this option is enabled, the VAE will split the input tensor into tiles to
compute decoding and encoding in several steps. This is useful for saving a large amount of memory and to allow
processing larger images.`,me,A,de,M,S,Ce,ne,Ge="Output class for HiDreamImage pipelines.",ce,q,ge,ae,_e;return w=new ve({props:{title:"HiDreamImage",local:"hidreamimage",headingTag:"h1"}}),U=new qe({props:{$$slots:{default:[Ye]},$$scope:{ctx:X}}}),E=new ve({props:{title:"Available models",local:"available-models",headingTag:"h2"}}),Z=new ve({props:{title:"HiDreamImagePipeline",local:"diffusers.HiDreamImagePipeline",headingTag:"h2"}}),V=new O({props:{name:"class diffusers.HiDreamImagePipeline",anchor:"diffusers.HiDreamImagePipeline",parameters:[{name:"scheduler",val:": FlowMatchEulerDiscreteScheduler"},{name:"vae",val:": AutoencoderKL"},{name:"text_encoder",val:": CLIPTextModelWithProjection"},{name:"tokenizer",val:": CLIPTokenizer"},{name:"text_encoder_2",val:": CLIPTextModelWithProjection"},{name:"tokenizer_2",val:": CLIPTokenizer"},{name:"text_encoder_3",val:": T5EncoderModel"},{name:"tokenizer_3",val:": T5Tokenizer"},{name:"text_encoder_4",val:": LlamaForCausalLM"},{name:"tokenizer_4",val:": PreTrainedTokenizerFast"},{name:"transformer",val:": HiDreamImageTransformer2DModel"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/pipelines/hidream_image/pipeline_hidream_image.py#L146"}}),G=new O({props:{name:"__call__",anchor:"diffusers.HiDreamImagePipeline.__call__",parameters:[{name:"prompt",val:": typing.Union[str, typing.List[str]] = None"},{name:"prompt_2",val:": typing.Union[str, typing.List[str], NoneType] = None"},{name:"prompt_3",val:": typing.Union[str, typing.List[str], NoneType] = None"},{name:"prompt_4",val:": typing.Union[str, typing.List[str], NoneType] = None"},{name:"height",val:": typing.Optional[int] = None"},{name:"width",val:": typing.Optional[int] = None"},{name:"num_inference_steps",val:": int = 50"},{name:"sigmas",val:": typing.Optional[typing.List[float]] = None"},{name:"guidance_scale",val:": float = 5.0"},{name:"negative_prompt",val:": typing.Union[str, typing.List[str], NoneType] = None"},{name:"negative_prompt_2",val:": typing.Union[str, typing.List[str], NoneType] = None"},{name:"negative_prompt_3",val:": typing.Union[str, typing.List[str], NoneType] = None"},{name:"negative_prompt_4",val:": typing.Union[str, typing.List[str], NoneType] = None"},{name:"num_images_per_prompt",val:": typing.Optional[int] = 1"},{name:"generator",val:": typing.Union[torch._C.Generator, typing.List[torch._C.Generator], NoneType] = None"},{name:"latents",val:": typing.Optional[torch.FloatTensor] = None"},{name:"prompt_embeds_t5",val:": typing.Optional[torch.FloatTensor] = None"},{name:"prompt_embeds_llama3",val:": typing.Optional[torch.FloatTensor] = None"},{name:"negative_prompt_embeds_t5",val:": typing.Optional[torch.FloatTensor] = None"},{name:"negative_prompt_embeds_llama3",val:": typing.Optional[torch.FloatTensor] = None"},{name:"pooled_prompt_embeds",val:": typing.Optional[torch.FloatTensor] = None"},{name:"negative_pooled_prompt_embeds",val:": typing.Optional[torch.FloatTensor] = None"},{name:"output_type",val:": typing.Optional[str] = 'pil'"},{name:"return_dict",val:": bool = True"},{name:"attention_kwargs",val:": typing.Optional[typing.Dict[str, typing.Any]] = None"},{name:"callback_on_step_end",val:": typing.Optional[typing.Callable[[int, int, typing.Dict], NoneType]] = None"},{name:"callback_on_step_end_tensor_inputs",val:": typing.List[str] = ['latents']"},{name:"max_sequence_length",val:": int = 128"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"diffusers.HiDreamImagePipeline.__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, one has to pass <code>prompt_embeds</code>.
instead.`,name:"prompt"},{anchor:"diffusers.HiDreamImagePipeline.__call__.prompt_2",description:`<strong>prompt_2</strong> (<code>str</code> or <code>List[str]</code>, <em>optional</em>) &#x2014;
The prompt or prompts to be sent to <code>tokenizer_2</code> and <code>text_encoder_2</code>. If not defined, <code>prompt</code> is
will be used instead.`,name:"prompt_2"},{anchor:"diffusers.HiDreamImagePipeline.__call__.prompt_3",description:`<strong>prompt_3</strong> (<code>str</code> or <code>List[str]</code>, <em>optional</em>) &#x2014;
The prompt or prompts to be sent to <code>tokenizer_3</code> and <code>text_encoder_3</code>. If not defined, <code>prompt</code> is
will be used instead.`,name:"prompt_3"},{anchor:"diffusers.HiDreamImagePipeline.__call__.prompt_4",description:`<strong>prompt_4</strong> (<code>str</code> or <code>List[str]</code>, <em>optional</em>) &#x2014;
The prompt or prompts to be sent to <code>tokenizer_4</code> and <code>text_encoder_4</code>. If not defined, <code>prompt</code> is
will be used instead.`,name:"prompt_4"},{anchor:"diffusers.HiDreamImagePipeline.__call__.height",description:`<strong>height</strong> (<code>int</code>, <em>optional</em>, defaults to self.unet.config.sample_size * self.vae_scale_factor) &#x2014;
The height in pixels of the generated image. This is set to 1024 by default for the best results.`,name:"height"},{anchor:"diffusers.HiDreamImagePipeline.__call__.width",description:`<strong>width</strong> (<code>int</code>, <em>optional</em>, defaults to self.unet.config.sample_size * self.vae_scale_factor) &#x2014;
The width in pixels of the generated image. This is set to 1024 by default for the best results.`,name:"width"},{anchor:"diffusers.HiDreamImagePipeline.__call__.num_inference_steps",description:`<strong>num_inference_steps</strong> (<code>int</code>, <em>optional</em>, defaults to 50) &#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.HiDreamImagePipeline.__call__.sigmas",description:`<strong>sigmas</strong> (<code>List[float]</code>, <em>optional</em>) &#x2014;
Custom sigmas to use for the denoising process with schedulers which support a <code>sigmas</code> argument in
their <code>set_timesteps</code> method. If not defined, the default behavior when <code>num_inference_steps</code> is passed
will be used.`,name:"sigmas"},{anchor:"diffusers.HiDreamImagePipeline.__call__.guidance_scale",description:`<strong>guidance_scale</strong> (<code>float</code>, <em>optional</em>, defaults to 3.5) &#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.HiDreamImagePipeline.__call__.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>true_cfg_scale</code> is
not greater than <code>1</code>).`,name:"negative_prompt"},{anchor:"diffusers.HiDreamImagePipeline.__call__.negative_prompt_2",description:`<strong>negative_prompt_2</strong> (<code>str</code> or <code>List[str]</code>, <em>optional</em>) &#x2014;
The prompt or prompts not to guide the image generation to be sent to <code>tokenizer_2</code> and
<code>text_encoder_2</code>. If not defined, <code>negative_prompt</code> is used in all the text-encoders.`,name:"negative_prompt_2"},{anchor:"diffusers.HiDreamImagePipeline.__call__.negative_prompt_3",description:`<strong>negative_prompt_3</strong> (<code>str</code> or <code>List[str]</code>, <em>optional</em>) &#x2014;
The prompt or prompts not to guide the image generation to be sent to <code>tokenizer_3</code> and
<code>text_encoder_3</code>. If not defined, <code>negative_prompt</code> is used in all the text-encoders.`,name:"negative_prompt_3"},{anchor:"diffusers.HiDreamImagePipeline.__call__.negative_prompt_4",description:`<strong>negative_prompt_4</strong> (<code>str</code> or <code>List[str]</code>, <em>optional</em>) &#x2014;
The prompt or prompts not to guide the image generation to be sent to <code>tokenizer_4</code> and
<code>text_encoder_4</code>. If not defined, <code>negative_prompt</code> is used in all the text-encoders.`,name:"negative_prompt_4"},{anchor:"diffusers.HiDreamImagePipeline.__call__.num_images_per_prompt",description:`<strong>num_images_per_prompt</strong> (<code>int</code>, <em>optional</em>, defaults to 1) &#x2014;
The number of images to generate per prompt.`,name:"num_images_per_prompt"},{anchor:"diffusers.HiDreamImagePipeline.__call__.generator",description:`<strong>generator</strong> (<code>torch.Generator</code> or <code>List[torch.Generator]</code>, <em>optional</em>) &#x2014;
One or a list of <a href="https://pytorch.org/docs/stable/generated/torch.Generator.html" rel="nofollow">torch generator(s)</a>
to make generation deterministic.`,name:"generator"},{anchor:"diffusers.HiDreamImagePipeline.__call__.latents",description:`<strong>latents</strong> (<code>torch.FloatTensor</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 will ge generated by sampling using the supplied random <code>generator</code>.`,name:"latents"},{anchor:"diffusers.HiDreamImagePipeline.__call__.prompt_embeds",description:`<strong>prompt_embeds</strong> (<code>torch.FloatTensor</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.HiDreamImagePipeline.__call__.negative_prompt_embeds",description:`<strong>negative_prompt_embeds</strong> (<code>torch.FloatTensor</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.HiDreamImagePipeline.__call__.pooled_prompt_embeds",description:`<strong>pooled_prompt_embeds</strong> (<code>torch.FloatTensor</code>, <em>optional</em>) &#x2014;
Pre-generated pooled text embeddings. Can be used to easily tweak text inputs, <em>e.g.</em> prompt weighting.
If not provided, pooled text embeddings will be generated from <code>prompt</code> input argument.`,name:"pooled_prompt_embeds"},{anchor:"diffusers.HiDreamImagePipeline.__call__.negative_pooled_prompt_embeds",description:`<strong>negative_pooled_prompt_embeds</strong> (<code>torch.FloatTensor</code>, <em>optional</em>) &#x2014;
Pre-generated negative pooled text embeddings. Can be used to easily tweak text inputs, <em>e.g.</em> prompt
weighting. If not provided, pooled negative_prompt_embeds will be generated from <code>negative_prompt</code>
input argument.`,name:"negative_pooled_prompt_embeds"},{anchor:"diffusers.HiDreamImagePipeline.__call__.output_type",description:`<strong>output_type</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;pil&quot;</code>) &#x2014;
The output format of the generate image. Choose between
<a href="https://pillow.readthedocs.io/en/stable/" rel="nofollow">PIL</a>: <code>PIL.Image.Image</code> or <code>np.array</code>.`,name:"output_type"},{anchor:"diffusers.HiDreamImagePipeline.__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>~pipelines.flux.FluxPipelineOutput</code> instead of a plain tuple.`,name:"return_dict"},{anchor:"diffusers.HiDreamImagePipeline.__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.HiDreamImagePipeline.__call__.callback_on_step_end",description:`<strong>callback_on_step_end</strong> (<code>Callable</code>, <em>optional</em>) &#x2014;
A function that calls at the end of each denoising steps during the inference. The function is called
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.HiDreamImagePipeline.__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.HiDreamImagePipeline.__call__.max_sequence_length",description:"<strong>max_sequence_length</strong> (<code>int</code> defaults to 128) &#x2014; Maximum sequence length to use with the <code>prompt</code>.",name:"max_sequence_length"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/pipelines/hidream_image/pipeline_hidream_image.py#L690",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>


<p><code>~pipelines.hidream_image.HiDreamImagePipelineOutput</code> if <code>return_dict</code> is True, otherwise a <code>tuple</code>. When
returning a tuple, the first element is a list with the generated. images.</p>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>


<p><code>~pipelines.hidream_image.HiDreamImagePipelineOutput</code> or <code>tuple</code></p>
`}}),P=new Xe({props:{anchor:"diffusers.HiDreamImagePipeline.__call__.example",$$slots:{default:[Ke]},$$scope:{ctx:X}}}),z=new O({props:{name:"disable_vae_slicing",anchor:"diffusers.HiDreamImagePipeline.disable_vae_slicing",parameters:[],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/pipelines/hidream_image/pipeline_hidream_image.py#L513"}}),W=new O({props:{name:"disable_vae_tiling",anchor:"diffusers.HiDreamImagePipeline.disable_vae_tiling",parameters:[],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/pipelines/hidream_image/pipeline_hidream_image.py#L528"}}),B=new O({props:{name:"enable_vae_slicing",anchor:"diffusers.HiDreamImagePipeline.enable_vae_slicing",parameters:[],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/pipelines/hidream_image/pipeline_hidream_image.py#L506"}}),R=new O({props:{name:"enable_vae_tiling",anchor:"diffusers.HiDreamImagePipeline.enable_vae_tiling",parameters:[],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/pipelines/hidream_image/pipeline_hidream_image.py#L520"}}),A=new ve({props:{title:"HiDreamImagePipelineOutput",local:"diffusers.pipelines.hidream_image.pipeline_output.HiDreamImagePipelineOutput",headingTag:"h2"}}),S=new O({props:{name:"class diffusers.pipelines.hidream_image.pipeline_output.HiDreamImagePipelineOutput",anchor:"diffusers.pipelines.hidream_image.pipeline_output.HiDreamImagePipelineOutput",parameters:[{name:"images",val:": typing.Union[typing.List[PIL.Image.Image], numpy.ndarray]"}],parametersDescription:[{anchor:"diffusers.pipelines.hidream_image.pipeline_output.HiDreamImagePipelineOutput.images",description:`<strong>images</strong> (<code>List[PIL.Image.Image]</code> or <code>np.ndarray</code>) &#x2014;
List of denoised PIL images of length <code>batch_size</code> or numpy array of shape <code>(batch_size, height, width, num_channels)</code>. PIL images or numpy array present the denoised images of the diffusion pipeline.`,name:"images"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/pipelines/hidream_image/pipeline_output.py#L10"}}),q=new Qe({props:{source:"https://github.com/huggingface/diffusers/blob/main/docs/source/en/api/pipelines/hidream.md"}}),{c(){o=l("meta"),$=a(),c=l("p"),v=a(),_(w.$$.fragment),m=a(),T=l("p"),T.innerHTML=ke,ie=a(),_(U.$$.fragment),oe=a(),_(E.$$.fragment),se=a(),N=l("p"),N.innerHTML=Le,re=a(),F=l("table"),F.innerHTML=je,le=a(),_(Z.$$.fragment),pe=a(),d=l("div"),_(V.$$.fragment),we=a(),x=l("div"),_(G.$$.fragment),Te=a(),Q=l("p"),Q.textContent=Ee,Ie=a(),_(P.$$.fragment),$e=a(),C=l("div"),_(z.$$.fragment),xe=a(),Y=l("p"),Y.innerHTML=Ne,Me=a(),k=l("div"),_(W.$$.fragment),De=a(),K=l("p"),K.innerHTML=Fe,He=a(),L=l("div"),_(B.$$.fragment),Je=a(),ee=l("p"),ee.textContent=Ze,Ue=a(),j=l("div"),_(R.$$.fragment),Pe=a(),te=l("p"),te.textContent=Ve,me=a(),_(A.$$.fragment),de=a(),M=l("div"),_(S.$$.fragment),Ce=a(),ne=l("p"),ne.textContent=Ge,ce=a(),_(q.$$.fragment),ge=a(),ae=l("p"),this.h()},l(e){const t=Se("svelte-u9bgzb",document.head);o=p(t,"META",{name:!0,content:!0}),t.forEach(n),$=i(e),c=p(e,"P",{}),H(c).forEach(n),v=i(e),u(w.$$.fragment,e),m=i(e),T=p(e,"P",{"data-svelte-h":!0}),I(T)!=="svelte-1afylb8"&&(T.innerHTML=ke),ie=i(e),u(U.$$.fragment,e),oe=i(e),u(E.$$.fragment,e),se=i(e),N=p(e,"P",{"data-svelte-h":!0}),I(N)!=="svelte-nosn57"&&(N.innerHTML=Le),re=i(e),F=p(e,"TABLE",{"data-svelte-h":!0}),I(F)!=="svelte-1qjrcq9"&&(F.innerHTML=je),le=i(e),u(Z.$$.fragment,e),pe=i(e),d=p(e,"DIV",{class:!0});var g=H(d);u(V.$$.fragment,g),we=i(g),x=p(g,"DIV",{class:!0});var D=H(x);u(G.$$.fragment,D),Te=i(D),Q=p(D,"P",{"data-svelte-h":!0}),I(Q)!=="svelte-v78lg8"&&(Q.textContent=Ee),Ie=i(D),u(P.$$.fragment,D),D.forEach(n),$e=i(g),C=p(g,"DIV",{class:!0});var ue=H(C);u(z.$$.fragment,ue),xe=i(ue),Y=p(ue,"P",{"data-svelte-h":!0}),I(Y)!=="svelte-1s3c06i"&&(Y.innerHTML=Ne),ue.forEach(n),Me=i(g),k=p(g,"DIV",{class:!0});var fe=H(k);u(W.$$.fragment,fe),De=i(fe),K=p(fe,"P",{"data-svelte-h":!0}),I(K)!=="svelte-pkn4ui"&&(K.innerHTML=Fe),fe.forEach(n),He=i(g),L=p(g,"DIV",{class:!0});var he=H(L);u(B.$$.fragment,he),Je=i(he),ee=p(he,"P",{"data-svelte-h":!0}),I(ee)!=="svelte-14bnrb6"&&(ee.textContent=Ze),he.forEach(n),Ue=i(g),j=p(g,"DIV",{class:!0});var be=H(j);u(R.$$.fragment,be),Pe=i(be),te=p(be,"P",{"data-svelte-h":!0}),I(te)!=="svelte-1xwrf7t"&&(te.textContent=Ve),be.forEach(n),g.forEach(n),me=i(e),u(A.$$.fragment,e),de=i(e),M=p(e,"DIV",{class:!0});var ye=H(M);u(S.$$.fragment,ye),Ce=i(ye),ne=p(ye,"P",{"data-svelte-h":!0}),I(ne)!=="svelte-gyvvvk"&&(ne.textContent=Ge),ye.forEach(n),ce=i(e),u(q.$$.fragment,e),ge=i(e),ae=p(e,"P",{}),H(ae).forEach(n),this.h()},h(){J(o,"name","hf:doc:metadata"),J(o,"content",tt),J(x,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),J(C,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),J(k,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),J(L,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),J(j,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),J(d,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),J(M,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8")},m(e,t){s(document.head,o),r(e,$,t),r(e,c,t),r(e,v,t),f(w,e,t),r(e,m,t),r(e,T,t),r(e,ie,t),f(U,e,t),r(e,oe,t),f(E,e,t),r(e,se,t),r(e,N,t),r(e,re,t),r(e,F,t),r(e,le,t),f(Z,e,t),r(e,pe,t),r(e,d,t),f(V,d,null),s(d,we),s(d,x),f(G,x,null),s(x,Te),s(x,Q),s(x,Ie),f(P,x,null),s(d,$e),s(d,C),f(z,C,null),s(C,xe),s(C,Y),s(d,Me),s(d,k),f(W,k,null),s(k,De),s(k,K),s(d,He),s(d,L),f(B,L,null),s(L,Je),s(L,ee),s(d,Ue),s(d,j),f(R,j,null),s(j,Pe),s(j,te),r(e,me,t),f(A,e,t),r(e,de,t),r(e,M,t),f(S,M,null),s(M,Ce),s(M,ne),r(e,ce,t),f(q,e,t),r(e,ge,t),r(e,ae,t),_e=!0},p(e,[t]){const g={};t&2&&(g.$$scope={dirty:t,ctx:e}),U.$set(g);const D={};t&2&&(D.$$scope={dirty:t,ctx:e}),P.$set(D)},i(e){_e||(h(w.$$.fragment,e),h(U.$$.fragment,e),h(E.$$.fragment,e),h(Z.$$.fragment,e),h(V.$$.fragment,e),h(G.$$.fragment,e),h(P.$$.fragment,e),h(z.$$.fragment,e),h(W.$$.fragment,e),h(B.$$.fragment,e),h(R.$$.fragment,e),h(A.$$.fragment,e),h(S.$$.fragment,e),h(q.$$.fragment,e),_e=!0)},o(e){b(w.$$.fragment,e),b(U.$$.fragment,e),b(E.$$.fragment,e),b(Z.$$.fragment,e),b(V.$$.fragment,e),b(G.$$.fragment,e),b(P.$$.fragment,e),b(z.$$.fragment,e),b(W.$$.fragment,e),b(B.$$.fragment,e),b(R.$$.fragment,e),b(A.$$.fragment,e),b(S.$$.fragment,e),b(q.$$.fragment,e),_e=!1},d(e){e&&(n($),n(c),n(v),n(m),n(T),n(ie),n(oe),n(se),n(N),n(re),n(F),n(le),n(pe),n(d),n(me),n(de),n(M),n(ce),n(ge),n(ae)),n(o),y(w,e),y(U,e),y(E,e),y(Z,e),y(V),y(G),y(P),y(z),y(W),y(B),y(R),y(A,e),y(S),y(q,e)}}}const tt='{"title":"HiDreamImage","local":"hidreamimage","sections":[{"title":"Available models","local":"available-models","sections":[],"depth":2},{"title":"HiDreamImagePipeline","local":"diffusers.HiDreamImagePipeline","sections":[],"depth":2},{"title":"HiDreamImagePipelineOutput","local":"diffusers.pipelines.hidream_image.pipeline_output.HiDreamImagePipelineOutput","sections":[],"depth":2}],"depth":1}';function nt(X){return Be(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class mt extends Re{constructor(o){super(),Ae(this,o,nt,et,We,{})}}export{mt as component};
