> For AI agents: the complete documentation index is available at /llms.txt, the full documentation bundle is available at /llms-full.txt.

# InstructPixToPix条件（InstructPixToPixConditioning）

<div class="node-meta"><code>InstructPixToPixConditioning</code><span>model/conditioning/instructpix2pix</span><span>角色：图像编码</span></div>

InstructPixToPixConditioning 节点通过将正向和负向文本提示与图像数据相结合，为 InstructPix2Pix 图像编辑准备条件数据。它通过 VAE 将输入图像编码为潜在表示，并将该潜在表示附加到正向和负向条件数据上，同时返回一个匹配的空潜在表示。图像尺寸会自动裁剪为 8 像素的倍数，以便 VAE 能够处理它们。

## 参数

| 参数         | 类型                | 默认 / 范围 | 说明                                           |
| ---------- | ----------------- | ------- | -------------------------------------------- |
| `positive` | CONDITIONING · 条件 | —（连线输入） | 已附加编码图像潜在表示（作为 `concat_latent_image`）的正向条件数据 |
| `negative` | CONDITIONING · 条件 | —（连线输入） | 已附加编码图像潜在表示（作为 `concat_latent_image`）的负向条件数据 |
| `vae`      | VAE · 自编码器        | —（连线输入） | 用于将输入图像编码为潜在表示的 VAE 模型                       |
| `pixels`   | IMAGE · 图像        | —（连线输入） | IMAGE。                                       |

## 输出

| 输出       | 类型           | 说明  |
| -------- | ------------ | --- |
| positive | CONDITIONING | 条件  |
| negative | CONDITIONING | 条件  |
| latent   | LATENT       | 潜空间 |

## 怎么接

- **上游**：CLIPTextEncode / 条件节点
- **下游**：KSampler.positive / negative
- **接线**：把 LoadImage / VAEDecode 出来的 IMAGE 接到 `image`，同家族 VAE 接到 `vae`；输出 LATENT 送进 KSampler 的 `latent_image`——配合 0.4-0.7 的降噪强度就是图生图，先接 SetLatentNoiseMask 则变成局部重绘。

## 使用案例

属于「图像编码」类节点，向下游提供条件，最终进采样器的 positive 或 negative。从 `positive`、`negative`、`vae` 开始填就能跑起来。典型接法：`CLIPTextEncode` → 本节点 → `KSampler.positive`。注意：图生图记得把降噪强度调低于 1，否则等于完全重绘。

## 端口与连线示意

![InstructPixToPixConditioning 端口与连线示意](/svg/InstructPixToPixConditioning.svg)

## 实战提示

- 图生图记得把降噪强度调低于 1，否则等于完全重绘。
