Text to Image¶
Generate a PNG from a text prompt. The cheapest and most mature task to run end-to-end on OmniRT.
Minimal example¶
Key parameters¶
| Parameter | Type | Default | Notes |
|---|---|---|---|
prompt |
str |
required | text prompt |
negative_prompt |
str? |
None |
negative prompt; honored by SD / SDXL / SD3 |
width / height |
int? |
model default | output size; models enforce 8/16/32-multiple constraints |
preset |
fast / balanced / quality / low-vram |
balanced |
bundled steps / precision / guidance; see Presets |
num_inference_steps |
int? |
preset | explicit denoise step override |
guidance_scale |
float? |
preset | classifier-free guidance |
num_images_per_prompt |
int? |
1 |
batch images per prompt |
seed |
int? |
random | fix randomness for reproducibility |
scheduler |
str? |
model default | see Architecture → Scheduler layer |
dtype |
fp16 / bf16 / fp32 |
fp16 |
compute dtype; Ascend defaults to bf16 |
adapters |
list[AdapterRef]? |
[] |
LoRA / ControlNet adapters |
Supported models¶
Typical quality / speed tradeoffs:
- Highest quality:
flux2.dev(≥ 24 GB VRAM),sdxl-base-1.0+sdxl-refiner-1.0 - Balanced:
sdxl-base-1.0,sd3-medium,qwen-image - Low-resource:
sd15(12 GB OK),sd21
Full list: omnirt models or Supported Models.
Common recipes¶
Troubleshooting¶
Common issues
ValidationError: width must be multiple of 8— most SD-family models require multiples of 8; Flux2 is stricter (16 / 32)CUDA out of memory— switch to--preset low-vramor reducewidth/height; or setOMNIRT_DISABLE_COMPILE=1to skiptorch.compileadapter not supported for this model— checkomnirt models <model_id>'sadaptersfield; LoRA / ControlNet compatibility is declared inModelCapabilities
Running omnirt validate catches the first two without touching a GPU.