Skip to content

Latest commit

 

History

History
110 lines (89 loc) · 2.65 KB

INSTALL.md

File metadata and controls

110 lines (89 loc) · 2.65 KB

Installation

  1. Head to server
ssh server_name
  1. Go to your own directory or make a new one in scratch
cd /disk/scratch/UUN
  1. Clone repo
git clone https://github.com/NVIDIA/DeepLearningExamples.git

Alternative with SSH:

cd ~/.ssh && ssh-keygen -o && cat ~/.ssh/id_rsa.pub && cd /disk/scratch1/UUN
# add the ssh key here: https://github.com/settings/ssh/new
git clone [email protected]:evdv/FastPitches.git
  1. Install miniconda
  wget https://repo.anaconda.com/miniconda/Miniconda3-py39_4.9.2-Linux-x86_64.sh
  echo "Change install location to /disk/scratch..."
  ./Miniconda3-py39_4.9.2-Linux-x86_64.sh
  source ~/.bashrc
  1. Activate conda
source miniconda3/bin/activate
  1. Create conda environment
conda create -n fastpitch_server python=3.8 
source activate fastpitch_server
  1. Install GCC
## Get a version of gcc > 5.0. The current anaconda default (June 2021) is 9.3 which seems to work (so far!)
conda install gcc_linux-64 gxx_linux-64
## make these the default C and C++ compilers (you could also set CC and CXX environment variabes)
## but aliasing seems to work well enough
alias gcc=x86_64-conda_cos6-linux-gnu-cc
alias g++=x86_64-conda_cos6-linux-gnu-c++
  1. Install PyTorch with CUDA
export CUDA_HOME=/opt/cuda-10.2.89_440_33
conda install pytorch torchvision cudatoolkit=10.2 -c pytorch 

So something is wrong with having gcc9, so we uninstall pytorch

conda uninstall pytorch

Then we reinstall and this for some reason downgrades the gcc to 7 and then installing apex works/
```bash
conda install pytorch torchvision cudatoolkit=10.2 -c pytorch 
  1. Install Apex
cd FastPitches/PyTorch/SpeechSynthesis/FastPitch/
git clone https://github.com/NVIDIA/apex
pip install -v --disable-pip-version-check --no-cache-dir --global-option="--cpp_ext" --global-option="--cuda_ext" ./
  1. Install additional Python requirements
pip install -r requirements.txt
pip install tqdm tensorboard 
pip install librosa
pip install llvmlite==0.35.0 
pip install numba==0.49.1
pip install wandb  # for train logging
  1. Prepare LJ dataset
bash scripts/download_dataset.sh
bash scripts/prepare_dataset.sh
  1. Test installation
export CUDA_VISIBLE_DEVICES=1
mkdir output
python inference.py --cuda   --fastpitch pretrained_models/fastpitch/nvidia_fastpitch_210824.pt   --waveglow pretrained_models/waveglow/nvidia_waveglow256pyt_fp16.pt   --wn-channels 256   -i phrases/devset10.tsv   -o output/wavs_devset10
  1. Weights and Biases login

Create account at: https://app.wandb.ai/login?signup=true

wandb login