Skip to content

Commit d35e7df

Browse files
committed
uv
1 parent a647682 commit d35e7df

File tree

1 file changed

+23
-9
lines changed

1 file changed

+23
-9
lines changed

docs/source/en/installation.md

Lines changed: 23 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -23,32 +23,46 @@ You should install 🤗 Diffusers in a [virtual environment](https://docs.python
2323
If you're unfamiliar with Python virtual environments, take a look at this [guide](https://packaging.python.org/guides/installing-using-pip-and-virtual-environments/).
2424
A virtual environment makes it easier to manage different projects and avoid compatibility issues between dependencies.
2525

26-
Start by creating a virtual environment in your project directory:
26+
Create a virtual environment with [uv](https://docs.astral.sh/uv/) (refer to [Installation](https://docs.astral.sh/uv/getting-started/installation/) for installation instructions), a fast Rust-based Python package and project manager.
2727

2828
```bash
29-
python -m venv .env
29+
uv venv my-env
30+
source my-env/bin/activate
3031
```
3132

32-
Activate the virtual environment:
33+
You should also install 🤗 Transformers because 🤗 Diffusers relies on its models.
34+
35+
36+
<frameworkcontent>
37+
<pt>
38+
39+
PyTorch only supports Python 3.8 - 3.11 on Windows. Install Diffusers with uv.
3340

3441
```bash
35-
source .env/bin/activate
42+
uv install diffusers["torch"] transformers
3643
```
3744

38-
You should also install 🤗 Transformers because 🤗 Diffusers relies on its models:
39-
45+
You can also install Diffusers with pip.
4046

41-
<frameworkcontent>
42-
<pt>
43-
Note - PyTorch only supports Python 3.8 - 3.11 on Windows.
4447
```bash
4548
pip install diffusers["torch"] transformers
4649
```
50+
4751
</pt>
4852
<jax>
53+
54+
Install Diffusers with uv.
55+
56+
```bash
57+
uv pip install diffusers["flax"] transformers
58+
```
59+
60+
You can also install Diffusers with pip.
61+
4962
```bash
5063
pip install diffusers["flax"] transformers
5164
```
65+
5266
</jax>
5367
</frameworkcontent>
5468

0 commit comments

Comments
 (0)