Example script for Attention Processor

  • Clone this repository
git clone https://github.com/shunk031/diffusers-attention-processor-example /path/to/your/dir
cd /path/to/your/dir
  • Create a virtual environment with pyenv/pyenv-virtualenv and activate it
pyenv virtualenv 3.10.11 diffusers-attention-processor-example
pyenv local diffusers-attention-processor-example
  • Install dependencies with poetry
pip install -U pip setuptools wheel poetry
poetry install
  • Run the example wity pytest
pytest --log-cli-level info -vs tests/shape_store_attn_processor_pipeline_test.py
pytest --log-cli-level info -vs tests/attention_store_attn_processor_pipeline_test.py

Acknowledgements