Instructions to use kpsss34/QwXL-EXP-1 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use kpsss34/QwXL-EXP-1 with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("kpsss34/QwXL-EXP-1", dtype=torch.bfloat16, device_map="cuda") prompt = "portrait of a man at a lake, looking at camera, d & d, nice outfit, long hair, intricate, elegant, stylish, realistic" image = pipe(prompt).images[0] - Notebooks
- Google Colab
- Kaggle
- Local Apps
- Draw Things
- DiffusionBee
QwXL v.1
I’ve been experimenting with and modifying an SDXL model by replacing both of its original text encoders with Qwen 0.5B. I always found the 77-token limit frustrating—it really takes the fun out of creating.
Using a smaller model like Qwen 0.5B might not match the original in terms of accuracy, but the trade-off is worth it: you can go beyond that 77-token limit, which opens up a lot more creative freedom.
import torch
from Q_pipeline import QPipeline
import os
MODEL_PATH = "model"
PROMPT = "portrait of a beautiful woman wearing a sundress at a lake, looking at camera, d & d, nice outfit, long hair, intricate, elegant, stylish, realistic"
NEGATIVE_PROMPT = "low quality, blurry"
OUTPUT_IMAGE_PATH = "1.png"
SEED = 42
def main():
if not torch.cuda.is_available():
raise RuntimeError("GPU is required.")
pipe = QPipeline.from_pretrained(
MODEL_PATH,
torch_dtype=torch.bfloat16,
device="cuda"
)
generator = torch.Generator(device="cuda").manual_seed(SEED)
result = pipe(
prompt=PROMPT,
negative_prompt=NEGATIVE_PROMPT,
num_inference_steps=40,
guidance_scale=7.5,
generator=generator,
width=1024,
height=1024,
)
result["images"][0].save(OUTPUT_IMAGE_PATH)
print(f"Saved to {OUTPUT_IMAGE_PATH}")
if __name__ == "__main__":
main()
- Downloads last month
- -
