Installation#
Basics#
First install Python >= 3.10, PyTorch >=v.2.0.0, git and conda. We tested the latest JoeyS2T with
python 3.11
torch 2.1.2
torchaudio 2.1.2
cuda 12.1
Create and activate a conda virtual environment to install the package into:
$ conda -n js2t python=3.11
$ conda activate js2t
Cloning#
Then clone JoeyS2T from GitHub and switch to its root directory:
(js2t)$ git clone https://github.com/may-/joeys2t.git
(js2t)$ cd joeys2t
Note
For Windows users, we recommend to doublecheck whether txt files (i.e. test/data/toy/*
) have utf-8 encoding.
Installing JoeyNMT#
Install JoeyNMT and its requirements:
(js2t)$ python -m pip install -e .
Run the unit tests to make sure your installation is working:
(js2t)$ python -m unittest
Important
When running on GPU you need to manually install the suitable PyTorch version for your CUDA version. For example, you can install PyTorch 2.1.2 with CUDA v12.1 as follows:
$ python -m pip install --upgrade torch==2.1.2 --index-url https://download.pytorch.org/whl/cu121
This is described in the PyTorch installation instructions.
Note
You may need to install extra dependencies (torchaudio backends): ffmpeg, sox, soundfile, etc. Please refer torchaudio documentation for details.
You’re ready to go!