Qwen Image Edit 2511 Lightning
简介
核心亮点
- 精准的图生图编辑,支持局部快速修改
- Lightning 级别响应速度,大幅提升出图效率
- Apache-2.0 开源协议,企业级部署无压力
- 无需复杂指令,降低 AI 图像编辑上手难度
使用方法
# 安装 Hugging Face transformers
pip install transformers torch
# 使用 transformers 加载模型
from transformers import AutoModel, AutoTokenizer
model = AutoModel.from_pretrained("lightx2v/Qwen-Image-Edit-2511-Lightning")
tokenizer = AutoTokenizer.from_pretrained("lightx2v/Qwen-Image-Edit-2511-Lightning")
Hugging Face 下载
我们推荐使用命令行或者 Hugging Face Hub SDK 来进行模型的下载。
操作指引:在下载前,请先通过如下命令安装 huggingface_hub:
pip install -U huggingface_hub
命令行下载
下载完整模型库
huggingface-cli download lightx2v/Qwen-Image-Edit-2511-Lightning
下载单个文件到指定本地文件夹(以下载 config.json 到当前路径下 ./dir 目录为例)
huggingface-cli download lightx2v/Qwen-Image-Edit-2511-Lightning config.json --local-dir ./dir
SDK 下载
# 模型下载
from huggingface_hub import snapshot_download
model_dir = snapshot_download('lightx2v/Qwen-Image-Edit-2511-Lightning')
Git 下载
请确保 lfs 已经被正确安装
git lfs install
git clone https://huggingface.co/lightx2v/Qwen-Image-Edit-2511-Lightning
如果您希望跳过 lfs 大文件下载,可以使用如下命令
GIT_LFS_SKIP_SMUDGE=1 git clone https://huggingface.co/lightx2v/Qwen-Image-Edit-2511-Lightning
模型文件托管在 Hugging Face Hub,使用 HF CLI / SDK / Git 直接下载,不经过本站。
PyTorch / Transformers 使用
安装 Transformers
pip install -U transformers torch
模型加载和推理
from transformers import AutoModelForCausalLM, AutoTokenizer
model = AutoModelForCausalLM.from_pretrained('lightx2v/Qwen-Image-Edit-2511-Lightning')
tokenizer = AutoTokenizer.from_pretrained('lightx2v/Qwen-Image-Edit-2511-Lightning')
模型下载
我们推荐使用命令行或者 ModelScope SDK 来进行模型的下载。
操作指引:在下载前,请先通过如下命令安装 ModelScope:
pip install modelscope
命令行下载
下载完整模型库
modelscope download --model lightx2v/Qwen-Image-Edit-2511-Lightning
下载单个文件到指定本地文件夹(以下载 README.md 到当前路径下 dir 目录为例)
modelscope download --model lightx2v/Qwen-Image-Edit-2511-Lightning README.md --local_dir ./dir
SDK 下载
# 模型下载
from modelscope import snapshot_download
model_dir = snapshot_download('lightx2v/Qwen-Image-Edit-2511-Lightning')
Git 下载
请确保 lfs 已经被正确安装
git lfs install
git clone https://www.modelscope.cn/lightx2v/Qwen-Image-Edit-2511-Lightning.git
如果您希望跳过 lfs 大文件下载,可以使用如下命令
GIT_LFS_SKIP_SMUDGE=1 git clone https://www.modelscope.cn/lightx2v/Qwen-Image-Edit-2511-Lightning.git
ModelScope 模型页直接下载模型文件;无需将模型文件放在本站服务器。
Notebook 快速开发
下载并安装 ModelScope library
pip install "modelscope[audio,cv,nlp,multi-modal,science]" -f https://modelscope.oss-cn-beijing.aliyuncs.com/releases/repo.html
模型加载和推理
from modelscope.pipelines import pipeline
from modelscope.utils.constant import Tasks
p = pipeline('text-generation', 'lightx2v/Qwen-Image-Edit-2511-Lightning')
完整文档
---
license: apache-2.0
tags:
- diffusion-single-file
- comfyui
- distillation
- LoRA
- lora
- Qwen-Image
- Qwen-Image-Edit
base_model:
- Qwen/Qwen-Image-Edit-2511
pipeline_tags:
- image-to-image
- text-to-image
library_name: diffusers
pipeline_tag: image-to-image
---
Qwen-Image-Edit-2511-Lightning
Model Overview
Qwen-Image-Edit-2511-Lightning is a collection of optimized models tailored for image editing tasks, leveraging step distillation and quantization techniques to deliver high-efficiency inference performance. This repository hosts three core model files with distinct characteristics:| Model File Name | Type | Key Features |
|-----------------|------|--------------|
| Qwen-Image-Edit-2511-Lightning-4steps-V1.0-bf16.safetensors | 4-step Distilled LoRA | BF16 precision, lightweight, 4-step inference |
| Qwen-Image-Edit-2511-Lightning-4steps-V1.0-fp32.safetensors | 4-step Distilled LoRA | FP32 precision, high accuracy, 4-step inference |
| qwen_image_edit_2511_fp8_e4m3fn_scaled_lightning.safetensors | FP8 Quantized | FP8 (e4m3fn scaled) precision, fused with 4-step distilled LoRA, optimized for low-memory deployment |
Usage Instructions
This model suite supports two mainstream usage frameworks, with detailed guides provided below:1. Qwen-Image-Lightning Framework
For full documentation on model usage within the Qwen-Image-Lightning ecosystem (including environment setup, inference pipelines, and customization), please refer to: Qwen-Image-Lightning GitHub Repository2. LightX2V Framework
The models are fully compatible with the LightX2V lightweight video/image generation inference framework. For step-by-step usage examples, configuration templates, and performance optimization tips, see: LightX2V Qwen Image Edit DocumentationKey Optimizations
- Step Distillation: The LoRA models reduce the original inference steps to just 4 steps, achieving significant speedup (≈10x faster than standard 40-step inference) while preserving image editing quality.
- FP8 Quantization: The quantized base model balances performance and resource efficiency, reducing GPU memory usage by ~50% compared to FP32 while maintaining editing fidelity.
Support
For technical issues, feature requests, or integration questions:- Open an issue in the Qwen-Image-Lightning repo (for Qwen framework-specific questions)
- Open an issue in the LightX2V repo (for LightX2V integration questions)