Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions Contributing.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ See [Pull Request Recommendations](#pull-request-recommendations) for hints on m
Run these commands in each of your sandboxes to enable our pre-commit hooks and gitlint:

```sh
pip install -r requirements.dev.txt
pip install -e '.[dev]'
pre-commit install
gitlint install-hook
git submodule foreach 'pre-commit install'
Expand Down Expand Up @@ -61,11 +61,11 @@ All the pre-commit hooks are executed using a tool called
[pre-commit](https://pre-commit.com/). Once you enable pre-commit, it will run all the
hooks each time you try to commit anything in this repo.

We've listed all the developper dependencies for the project in
[requirements.dev.txt](requirements.dev.txt) to make them easy to install:
The developer dependencies are listed in the dev extra in [pyproject.toml](pyproject.toml)
to make them easy to install:

```sh
pip install -r requirements.dev.txt
pip install -e '.[dev]'
pre-commit install
```

Expand Down Expand Up @@ -132,12 +132,12 @@ commit-msg hook in Git.
Run this command in your sandbox to install and enable the commit-msg hook:

```sh
pip install -r requirements/requirements.dev.txt
pip install -e '.[dev]'
gitlint install-hook
```

- Now, next time you make a change and commit it, your commit log will be checked:
- `git commit -m'non-compliant commit log text'` outputs an error
- Now, your commit log will be checked:
- `git commit -m'non-compliant commit message'` outputs an error
- `git commit -m'fix(g2p): fixing a bug in g2p integration'` works

### Initializing submodules too
Expand Down
24 changes: 13 additions & 11 deletions docs/install.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ we maintain a script to automate the process and keep it reliable.
conda create --name EveryVoice python=3.12 ffmpeg
conda activate EveryVoice
conda install sox -c conda-forge
CUDA_TAG=cu121 pip install -r requirements.torch.txt --find-links https://download.pytorch.org/whl/torch_stable.html
CUDA_TAG=cu126 pip install -r requirements.torch.txt --find-links https://download.pytorch.org/whl/torch_stable.html
pip install -e '.[dev]'
```

Expand All @@ -99,8 +99,7 @@ we maintain a script to automate the process and keep it reliable.
```
uv venv -p 3.12 .venv
source .venv/bin/activate
uv pip install torch==2.3.1+cu121 torchaudio==2.3.1+cu121 --find-links https://download.pytorch.org/whl/torch_stable.html
uv pip install -e '.[dev]'
uv pip install -e '.[dev]' --torch-backend=cu126
```

### Option 2-b — Manual installation — Detailed
Expand Down Expand Up @@ -133,24 +132,25 @@ Create a new virtual environment and activate it:
Install our pytorch requirements from `requirements.torch.txt`:

```sh
CUDA_TAG=cu121 pip install -r requirements.torch.txt --find-links https://download.pytorch.org/whl/torch_stable.html
CUDA_TAG=cu126 pip install -r requirements.torch.txt --find-links https://download.pytorch.org/whl/torch_stable.html
```

=== "Using uv"

Install our pytorch requirements specified in `requirements.torch.txt`, but manually.
(Unfortunately, `uv` does not support the environment variable we use with pip and conda.)
Since version 0.6.9, `uv` has a `--torch-backend` option for automatically
fetching the right pre-compiled wheels given your CUDA driver, so add it when
you install everyvoice itself:

```sh
uv pip install torch==2.3.1+cu121 torchaudio==2.3.1+cu121 --find-links https://download.pytorch.org/whl/torch_stable.html
uv pip install . --torch-backend=cu126
```

Replace `cu121` above (for CUDA 12.1) by your actual CUDA version tag (cu118 or
cu121), or by `cpu` for a CPU-only installation.
Replace `cu126` above (for CUDA 12.1) by your actual CUDA version tag (cu118,
cu126 or cu128), or by `cpu` for a CPU-only installation.

Alternatively, you can follow the [PyTorch installation instructions](https://pytorch.org/get-started/locally/) relevant to your hardware.
Make sure you specify the version declared in `requirements.torch.txt`, which is 2.3.1 at the moment,
if you install EveryVoice from GitHub, but 2.1.0 if you install it from PyPI.
Make sure you specify the version declared in `requirements.torch.txt`, which was 2.7.1 when this
document was last updated.

#### Non-Python dependencies

Expand Down Expand Up @@ -196,6 +196,8 @@ Install EveryVoice locally from your cloned sandbox:
uv pip install -e .
```

(possibly with the optional `--torch-backend=cu126` option discussed above)

#### Dev dependencies

Before you can run the test suites, you'll also need to install the dev dependencies:
Expand Down
2 changes: 1 addition & 1 deletion everyvoice/model/feature_prediction/FastSpeech2_lightning
2 changes: 1 addition & 1 deletion everyvoice/model/vocoder/HiFiGAN_iSTFT_lightning
4 changes: 3 additions & 1 deletion make-everyvoice-env
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ else
else
echo "Warning: Mismatched CUDA version found. Specified: CUDA_VERSION=$CUDA_VERSION. Found:"
nvidia-smi | grep CUDA
echo "Please make sure the CUDA version available at runtime will match $CUDA_VERSION."
echo "Please make sure the CUDA version available at runtime will be compatible with $CUDA_VERSION."
fi
else
echo "Please make sure the CUDA version installed on your system matches CUDA_VERSION=$CUDA_VERSION."
Expand Down Expand Up @@ -217,6 +217,8 @@ if [[ $USE_UV ]]; then
r uv venv --python-preference=only-managed --python="$PYTHON_VERSION" "$ENV_PREFIX"
r source "$ENV_PREFIX"/*/activate

# Note, adding `--torch-backend=$CUDA_TAG` to `uv pip install` would replace this block
# for uv>=0.6.9, but let's maintain backward compatibility in this automated script!
if [[ $CUDA_TAG ]]; then
TEMP_REQS_DIR=$(mktemp -d ./torch-reqs.XXXXXX)
sed 's/\${CUDA_TAG}/'"$CUDA_TAG/" requirements.torch.txt > "$TEMP_REQS_DIR/requirements.torch.txt"
Expand Down
Loading