Skip to content

Commit

Permalink
Merge pull request #177 from feifeibear/0809
Browse files Browse the repository at this point in the history
[hotfix] fix import error and specify accelerate version
  • Loading branch information
Eigensystem authored Aug 9, 2024
2 parents 738e972 + 222c9ba commit 8445902
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 7 deletions.
14 changes: 11 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -141,18 +141,26 @@ Here are the benchmark results for Pixart-Alpha using the 20-step DPM solver as

<h2 id="QuickStart">🚀 QuickStart</h2>

1. Install yunchang for sequence parallel.
### 1. Install from pip

```
pip install xfuser
```

### 2. Install from source

#### 2.1 Install yunchang for sequence parallel.

Install yunchang from [feifeibear/long-context-attention](https://github.com/feifeibear/long-context-attention).
Please note that it has a dependency on flash attention and specific GPU model requirements. We recommend installing yunchang from the source code rather than using `pip install yunchang==0.2.0`.

2. Install xDiT
#### 2.2 Install xDiT

```
python setup.py install
```

3. Usage
### 2. Usage

We provide examples demonstrating how to run models with xDiT in the [./examples/](./examples/) directory.
You can easily modify the model type, model directory, and parallel options in the [examples/run.sh](examples/run.sh) within the script to run some already supported DiT models.
Expand Down
Binary file removed dist/pipefusion-0.2-py3.11.egg
Binary file not shown.
4 changes: 2 additions & 2 deletions examples/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ elif [ "$MODEL_TYPE" = "Sd3" ]; then
export INFERENCE_STEP=20
elif [ "$MODEL_TYPE" = "Flux" ]; then
export SCRIPT=flux_example.py
export MODEL_ID="/cfs/dit/FLUX.1-schnell"
export MODEL_ID="/mnt/models/SD/FLUX.1-schnell"
export INFERENCE_STEP=4
# Flux does not apply cfg
export CFG_ARGS=""
Expand All @@ -44,7 +44,7 @@ else
exit 1
fi

export PYTHONAPTH=$PWD:$PYTHONPATH
# export PYTHONAPTH=$PWD:$PYTHONPATH

mkdir -p ./results

Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"diffusers>=0.30.0",
"transformers",
"sentencepiece",
"accelerate",
"accelerate==0.33.0",
"beautifulsoup4",
"distvae",
"ftfy",
Expand Down
2 changes: 1 addition & 1 deletion xfuser/__version__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "0.1"
__version__ = "0.2"
Empty file added xfuser/modules/__init__.py
Empty file.

0 comments on commit 8445902

Please sign in to comment.