IMPORTANT: To view this page as Markdown, append `.md` to the URL (e.g. /max/get-started.md). For the complete documentation index, see llms.txt.
Skip to main content
For the complete documentation index, see llms.txt. Markdown versions of all pages are available by appending .md to any URL (e.g. /max/get-started.md).

Python class

ImageProviderOptions

ImageProviderOptions​

class max.pipelines.request.provider_options.ImageProviderOptions(*, negative_prompt=None, guidance_scale=3.5, true_cfg_scale=1.0, width=None, height=None, steps=None, cfg_normalization=False, cfg_truncation=1.0, flow_shift=None, response_format=GeneratedMediaResponseFormat.b64_json, secondary_prompt=None, secondary_negative_prompt=None, num_images=1, strength=0.6, output_format='jpeg')

source

Bases: PixelProviderOptionsBase

Options specific to image generation pipelines.

Inherits all generation options shared with other pixel modalities from PixelProviderOptionsBase; adds image-specific fields (secondary text-encoder prompts, num_images, strength, output_format) and tightens the dimension constraints to image-specific limits.

Parameters:

height​

height: int | None

source

model_config​

model_config: ClassVar[ConfigDict] = {'extra': 'forbid', 'frozen': True}

source

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

num_images​

num_images: int

source

output_format​

output_format: str

source

secondary_negative_prompt​

secondary_negative_prompt: str | None

source

secondary_prompt​

secondary_prompt: str | None

source

strength​

strength: float

source

width​

width: int | None

source