huggingface / huggingface/diffusers

Modular Pipeline: support for PixArtAlphaPipeline

Open
#13,301 3 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
34.5k
Forks
7.3k
Avg merge
3d 3h
Merged PRs (30d)
91

Description

### Model/Pipeline/Scheduler description

I would like to implement a modular version of the PixArt pipeline family, as discussed in [#13295](https://github.com/huggingface/diffusers/issues/13295#issuecomment-4103395537).

The initial scope includes the `PixArtAlphaPipeline` under [src/diffusers/pipelines/pixart_alpha/](https://github.com/huggingface/diffusers/tree/main/src/diffusers/pipelines/pixart_alpha). Currently, the focus is on PixArt-α only. The implementation would be structured so that `PixArtSigmaPipeline` support can be added later in a follow-up.

## Current plan:

Add a new modular PixArt package under `src/diffusers/modular_pipelines/`, following the structure of the existing built-in modular pipelines.
- `encoders` for prompt encoding
- `before_denoise` for input / latent preparation and timestep setup
- `denoise` for the main PixArt denoising loop
- `decoders` for VAE decoding and post-processing

I’m happy to implement this myself, and this would be my first contribution to Diffusers.

### Open source status

- [x] The model implementation is available.
- [x] The model weights are available (Only relevant if addition is not a scheduler).

### Provide useful links for the implementation

## Relevant references:
- Current Diffusers implementation:
- `src/diffusers/pipelines/pixart_alpha/pipeline_pixart_alpha.py`
- `src/diffusers/pipelines/pixart_alpha/pipeline_pixart_sigma.py`
- PixArt docs / weights:
- https://huggingface.co/docs/diffusers/api/pipelines/pixart
- https://huggingface.co/PixArt-alpha/PixArt-XL-2-1024-MS

Contributor guide

Open the contributing guide

Research direction

Start with src/diffusers/pipelines/pixart_alpha/pipeline_pixart_alpha.py and review the existing built-in modular pipeline structure. Organize a new package under src/diffusers/modular_pipelines/ with encoders, before_denoise, denoise, and decoders for PixArt-α. Done means PixArtAlphaPipeline has modular support while PixArtSigmaPipeline remains out of scope.

Written by the indexing model from the issue text.

Assessment

Tech stack
python, pytorch
Domain
machine-learning
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.