bark
The project is compatible with CPU, allowing users running on Mac M1 platform without CUDA accelerating
Preparation
Create a new virtual environment, and activate it
1 | conda create bark; |
Installment
1 | pip install git+https://github.com/suno-ai/bark.git |
OR
1 | git clone https://github.com/suno-ai/bark |
Usage
Use package: ipython to key in rows of python commands
Install ipython:
1 | pip install ipython |
//ipython in wikipedia:
//IPython是一種基於Python的互動式直譯器。相較於原生的Python Shell,IPython提供了更為強大的編輯和互動功能。
Then use ipython to write python sentences:
1 | from bark import SAMPLE_RATE, generate_audio, preload_models |
This step is to download required models, input text and play text in notebook
1 | from scipy.io.wavfile import write as write_wav |
This step is to save the audio as a WAV file, mention that this file is in /path/to directory from above