Update README.md
Browse files
README.md
CHANGED
|
@@ -55,15 +55,15 @@ We use `torch.hub` to make loading the model easy -- no cloning of the repo need
|
|
| 55 |
1. **Install pip dependencies**: we have 3 inference dependencies only `torch`, `torchaudio`, `librosa`, `vocos`, and `encodec`. Python must be at version 3.10 or greater, and torch must be v2.0 or greater.
|
| 56 |
|
| 57 |
```bash
|
| 58 |
-
pip install --upgrade torch torchaudio librosa vocos encodec
|
| 59 |
```
|
| 60 |
|
| 61 |
-
2. **Load models**: load the Mars 5 AR and NAR model from
|
| 62 |
|
| 63 |
```python
|
| 64 |
-
import
|
| 65 |
-
|
| 66 |
-
mars5
|
| 67 |
# The `mars5` contains the AR and NAR model, as well as inference code.
|
| 68 |
# The `config_class` contains tunable inference config settings like temperature.
|
| 69 |
```
|
|
|
|
| 55 |
1. **Install pip dependencies**: we have 3 inference dependencies only `torch`, `torchaudio`, `librosa`, `vocos`, and `encodec`. Python must be at version 3.10 or greater, and torch must be v2.0 or greater.
|
| 56 |
|
| 57 |
```bash
|
| 58 |
+
pip install --upgrade torch torchaudio librosa vocos encodec huggingface_hub
|
| 59 |
```
|
| 60 |
|
| 61 |
+
2. **Load models**: load the Mars 5 AR and NAR model from the huggingface hub:
|
| 62 |
|
| 63 |
```python
|
| 64 |
+
from inference import Mars5TTS, InferenceConfig as config_class
|
| 65 |
+
import librosa
|
| 66 |
+
mars5 = Mars5TTS.from_pretrained("CAMB-AI/MARS5-TTS")
|
| 67 |
# The `mars5` contains the AR and NAR model, as well as inference code.
|
| 68 |
# The `config_class` contains tunable inference config settings like temperature.
|
| 69 |
```
|