﻿# InstructPix2Pix dual guidance: stronger source attachment can resist the edit

Interpret InstructPix2Pix text and image guidance as separate influences, and diagnose weak editing versus lost source details with controlled comparisons.

Author: Retrivium editorial team
Updated: 2026-11-04
Canonical URL: https://retrivium.ai/journal/fg2-instructpix2pix-image-text-guidance-balance/
Language: en

## Treat the prompt as an instruction

The [InstructPix2Pix paper](https://arxiv.org/abs/2211.09800) trains a model to transform an input image according to a written editing instruction. The text describes an operation, rather than merely captioning a desired standalone picture. This distinction matters when an application automatically replaces a short command with a detailed scene description. A description of the target can omit what should remain unchanged or how it relates to the supplied source, changing the task the model receives.

## Separate the guidance influences

The [pipeline interface](https://huggingface.co/docs/diffusers/api/pipelines/pix2pix) exposes guidance_scale for the text influence and image_guidance_scale for attachment to the input. Raising image guidance can preserve the source while resisting substantial edits; raising text guidance can favor the requested transformation while losing source details. These are competing influences within the editing computation, not independent quality multipliers. Increasing both does not establish that the result will satisfy both requirements better.

## Diagnose insufficient change

Imagine changing a daylight street photograph into a snowy scene while preserving its buildings. If almost nothing changes, inspect image guidance alongside the text setting. The [official implementation's guidance notes](https://github.com/timothybrooks/instruct-pix2pix) describe this balance and recommend investigating both controls. First vary one influence while holding the prepared source, instruction, random seed, and scheduler fixed. Otherwise a changed crop or new noise sample can obscure whether guidance caused the observed difference.

## Diagnose excessive replacement

If the model produces a snowy street with different buildings, the transformation succeeded only partially. Compare layout and identifiable source structures separately from the new weather. A stronger image influence may help preserve content, but the appropriate balance depends on how much change the instruction requires. Local recoloring and substantial object transformation should not share an unquestioned universal setting. Include examples requiring both small and large edits when validating an application's defaults.

## Record the tradeoff explicitly

Keep the source, prepared image, editing instruction, both guidance values, sampling configuration, and result. Evaluate instruction fulfillment and source preservation with separate evidence, including regions expected to remain stable. Existing guides on [image preprocessing coordinates](/journal/data-guide-image-exif-box-coordinate/) and [diffusion prediction targets](/journal/diffusion-forward-noise-training-target/) provide context. InstructPix2Pix's distinctive control problem is balancing source attachment against an instruction-driven change; an attractive edited image alone cannot demonstrate that the original scene survived as intended.
