/ Модель

Характеристики

Лицензия
OpenRAIL++
Опубликована
29 ноя 2023

PixArt-LCM-XL-2-1024-MS

Генерация изображенийТекст → изображение3 профессии

Быстрая диффузионная модель PixArt-α для генерации изображений 1024 пикселя по текстовому запросу с использованием дистилляции LCM.

93скачиваний за 30 дней66лайковвеса обновлены7 дек 2023

Бенчмарки

Как модель справилась с задачами пользователей ailist и что о ней публикуют открытые лидерборды

Тесты пользователейпока нет

Никто ещё не опубликовал тест этой модели. Соберите бенчмарк из своих задач — результат появится здесь.

  1. Добавьте модель в бенчмарк

    Вместе с другими моделями категории «Изображения» — сравнение идёт внутри одной категории.

  2. Опишите свои задачи

    Напишите запросы, при необходимости приложите файлы и эталонные ответы.

  3. Запустите и опубликуйте

    Модели сгенерируют результат по каждой задаче. Опубликованный тест появится на этой странице.

Публичные оценки

Из открытых лидербордов. Сравнивайте результаты одного теста при одинаковых условиях — отсутствие оценки не значит, что модель хуже.

В подключённых источниках результатов для этой модели пока нет.

Что умеет модель

Описание составлено по карточке модели и метаданным Hugging Face

PixArt-LCM-XL-2-1024-MS — модель генерации изображений по тексту, разработанная командами PixArt и LCM. Она основана на трансформерной латентной диффузии PixArt-α и использует дистилляцию LCM для быстрой генерации за небольшое число шагов. Модель принимает текстовые запросы и создаёт изображения разрешением 1024 пикселя; в карточке заявлено использование фиксированного предварительно обученного текстового кодировщика T5 и VAE.

Модель подходит для быстрого создания иллюстраций и концептов, творческих и образовательных инструментов, а также исследований генеративных моделей. В README приведены результаты генерации за четыре шага на разных GPU; фактическая скорость зависит от оборудования и конфигурации. Модель плохо справляется с фотореализмом, читаемым текстом, сложной композицией и деталями вроде пальцев; автоэнкодер вносит потери. Она не предназначена для создания достоверных изображений людей или событий. Лицензия в метаданных указана как OpenRAIL++; README называет CreativeML Open RAIL++-M, поэтому точные условия следует сверять с лицензией репозитория.

Сценарии применения

  • быстрое создание иллюстраций по описанию
  • генерация концептов для дизайна
  • создание изображений для творческих и образовательных инструментов
  • эксперименты с ускоренной генерацией изображений
  • исследование ограничений и смещений генеративных моделей

Ограничения

Модель может ошибаться в фотореализме, читаемом тексте, сложных пространственных композициях и деталях вроде пальцев; автоэнкодер вносит потери. Она не обучена создавать достоверные изображения людей или событий.

Для каких профессий подходит3

Разделы каталога профессий, в задачах которых используется эта модель

Все профессии

Карточка модели

README от автора на Hugging Face, как он его опубликовал

Открыть на Hugging Face

🐱 Pixart-LCM Model Card

🔥 Why Need PixArt-LCM

Following LCM LoRA, we illustrative of the generation speed we achieve on various computers. Let us stress again how liberating it is to explore image generation so easily with PixArt-LCM.

HardwarePixArt-LCM (4 steps)SDXL LoRA LCM (4 steps)PixArt standard (14 steps)SDXL standard (25 steps)
T4 (Google Colab Free Tier)3.3s8.4s16.0s26.5s
A100 (80 GB)0.51s1.2s2.2s3.8s
V100 (32 GB)0.8s1.2s5.5s7.7s

These tests were run with a batch size of 1 in all cases.

For cards with a lot of capacity, such as A100, performance increases significantly when generating multiple images at once, which is usually the case for production workloads.

Model

pipeline

Pixart-α consists of pure transformer blocks for latent diffusion: It can directly generate 1024px images from text prompts within a single sampling process.

LCMs is a diffusion distillation method which predict PF-ODE's solution directly in latent space, achieving super fast inference with few steps.

Source code of PixArt-LCM is available at https://github.com/PixArt-alpha/PixArt-alpha.

Model Description

  • Developed by: Pixart & LCM teams
  • Model type: Diffusion-Transformer-based text-to-image generative model
  • License: CreativeML Open RAIL++-M License
  • Model Description: This is a model that can be used to generate and modify images based on text prompts. It is a Transformer Latent Diffusion Model that uses one fixed, pretrained text encoders (T5) and one latent feature encoder (VAE).
  • Resources for more information: Check out our PixArt-α, LCM GitHub Repository and the Pixart-α, LCM reports on arXiv.

Model Sources

For research purposes, we recommend our generative-models Github repository (https://github.com/PixArt-alpha/PixArt-alpha), which is more suitable for developing both training and inference designs. Hugging Face provides free Pixart-LCM inference.

🧨 Diffusers

Make sure to upgrade diffusers to >= 0.23.0:

pip install -U diffusers --upgrade

In addition make sure to install transformers, safetensors, sentencepiece, and accelerate:

pip install transformers accelerate safetensors sentencepiece

To just use the base model, you can run:

import torch
from diffusers import PixArtAlphaPipeline

# only 1024-MS version is supported for now
pipe = PixArtAlphaPipeline.from_pretrained("PixArt-alpha/PixArt-LCM-XL-2-1024-MS", torch_dtype=torch.float16, use_safetensors=True)

# Enable memory optimizations.
pipe.enable_model_cpu_offload()

prompt = "A small cactus with a happy face in the Sahara desert."
image = pipe(prompt, guidance_scale=0., num_inference_steps=4).images[0]

When using torch >= 2.0, you can improve the inference speed by 20-30% with torch.compile. Simple wrap the unet with torch compile before running the pipeline:

pipe.transformer = torch.compile(pipe.transformer, mode="reduce-overhead", fullgraph=True)

If you are limited by GPU VRAM, you can enable cpu offloading by calling pipe.enable_model_cpu_offload instead of .to("cuda"):

- pipe.to("cuda")
+ pipe.enable_model_cpu_offload()

The diffusers use here is totally the same as the base-model PixArt-α. For more information on how to use Pixart-α with diffusers, please have a look at the Pixart-α Docs.

Uses

Direct Use

The model is intended for research purposes only. Possible research areas and tasks include

  • Generation of artworks and use in design and other artistic processes.

  • Applications in educational or creative tools.

  • Research on generative models.

  • Safe deployment of models which have the potential to generate harmful content.

  • Probing and understanding the limitations and biases of generative models.

Excluded uses are described below.

Out-of-Scope Use

The model was not trained to be factual or true representations of people or events, and therefore using the model to generate such content is out-of-scope for the abilities of this model.

Limitations and Bias

Limitations

  • The model does not achieve perfect photorealism
  • The model cannot render legible text
  • The model struggles with more difficult tasks which involve compositionality, such as rendering an image corresponding to “A red cube on top of a blue sphere”
  • fingers, .etc in general may not be generated properly.
  • The autoencoding part of the model is lossy.

Bias

While the capabilities of image generation models are impressive, they can also reinforce or exacerbate social biases.

Как запустить

На своей GPU в ailist. Цена — по текущим предложениям провайдеров

GPU в ailist

Универсальный рантайм

Можно запустить

Подбираем GPU…

Ревизия весов
e153060

0 моделей