#17 Install Icefall

Icefall Installation

Followed tutorial here: https://icefall.readthedocs.io/en/latest/installation/index.html

mkdir code
cd code/
git clone https://github.com/k2-fsa/icefall
cd icefall/
pip install -r requirements.txt
export PYTHONPATH=/home/np/code/icefall:$PYTHONPATH

But when I ran prepare.sh the script couldn’t locate k2 and other packages. The script was looking in system python not in anaconda python. Also the version mismatch happened with pytorch torchaudio. Few days ago my k2 installation was working but today it wasn’t. Not sure what I did to cause it. The fix basically was to make script call anaconda packages not local python. I modified .bashrc file by adding alias.

.bashrc lines that was added:

alias python3='/home/np/anaconda3/bin/python'

Last line probably not needed. I now don’t remember what exactly was added here this time.

export PATH=$PATH:/home/np/anaconda3/bin:/usr/local/cuda/bin
export PYTHONPATH=/home/np/code/icefall:$PYTHONPATH
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/cuda/lib64

Creating virtual environment:

Couldn’t create virtual environment as tutorial says

np@np-INTEL:~$ virtualenv -p python3.8  test-icefall
ModuleNotFoundError: No module named 'virtualenv.seed.via_app_data'

Worked as below on my desktop

np@np-INTEL:~$ python -m virtualenv -p python3.8 test-icefall
created virtual environment CPython3.8.13.final.0-64 in 113ms

History

 2025  mkdir code
 2026  ls
 2027  cd code/
 2028  ls
 2029  clear
 2030  ls
 2031  git clone https://github.com/k2-fsa/icefall
 2032  ls
 2033  cd icefall/
 2034  ls
 2035  pip install -r requirements.txt
 2036  pwd
 2037  export PYTHONPATH=/home/np/code/icefall:$PYTHONPATH
 2038  pico .bashrc
 2039  pico ./bashrc
 2040  pico .bashrc
 2041  cd ~
 2042  pico .bashrc
 2043  virtualenv -p python3.8  test-icefall
 2044  which virtualenv
 2045  /home/np/.local/bin/virtualenv
 2046  ls -l /home/np/.local/bin/virtualenv
 2047  date
 2048  ls -l ~/.local
 2049  less  /home/np/.local/bin/virtualenv
 2050  python -m virtualenv
 2051  python --version
 2052  python -m virtualenv python3.8 test-icefall
 2053  python -m virtualenv -p python3.8 test-icefall
 2054  source test-icefall/bin/activate
 2055  deactivate
 2056  cd code/
 2057  ls
 2058  cd icefall/
 2059  ls
 2060  cd egs/yesno/ASR/
 2061  ./prepare.sh 
 2062  python3 --version k2
 2063  less prepare.sh
 2064  which lhotse
 2065  lhotse --help
 2066  less $(which lhotse)
 2067  nano $(which lhotse)
 2068  lhotse --help
 2069  ./prepare.sh
 2070  less prepare.sh
 2071  less local/compute_fbank_yesno.py 
 2072  alias python3
 2073  less local/compute_fbank_yesno.py 
 2074  python
 2075  ~/anaconda3/bin/python
 2076  +
 2077  
 2078  ls -l ~/.local/lib/python3.8/site-packages/torch
 2079  date
 2080  k
 2081  pip3 remove torch --user
 2082  pip3 delete torch --user
 2083  pip3 --help
 2084  pip3 uninstall torch --user
 2085  pip3 uninstall torch 
 2086  python
 2087  ./prepare.sh 
 2088  python3
 2089  pip3 uninstall lhotse
 2090  python -m pip3 install lhotse
 2091  python -m pip install lhotse
 2092  which python
 2093  which pip3
 2094  /home/np/.local/bin/pip3
 2095  more /home/np/.local/bin/pip3
 2096  ./prepare.sh 
 2097  less local/compute_fbank_yesno.py 
 2098  less prepare.sh 
 2099  alias python3
 2100  python3
 2101  jobs
 2102  less local/compute_fbank_yesno.py 
 2103  echo $PATH
 2104  cd
 2105  cd .local
 2106  cd bin
 2107  ls -l
 2108  which python
 2109  ln -s $(which python) python3
 2110  ls -l python3
 2111  popd
 2112  cd -
 2113  cd
 2114  cd test-icefall/
 2115  cd ..
 2116  /home/np/.local/bin/pip3
 2117  cd ~/code/icefall/egs/yesno/ASR
 2118  ./prepare.sh
 2119  echo $LD_LIBRARY_PATH
 2120  echo $PATH
 2121  ls /usr/local/cuda
 2122  ls /usr/local/cuda/lib64/
 2123  emacs -nw ~/.bashrc
 2124  nano ~/.bashrc
 2125  . ~/.bashrc
 2126  ./prepare.sh
 2127  ls -l /usr/local/cuda/lib64
 2128  ls -l /usr/local/cuda/lib64/libcudart.so.10.2
 2129  find ~/anaconda3 -name 'libcudart*'
 2130  python
 2131  anaconda install -c pytorch torchaudio
 2132  conda install -c pytorch torchaudio
 2133  conda uninstall -c pytorch torchaudio
 2134  conda install -c pytorch torchaudio
 2135  python
 2136  conda install -c pytorch torchaudio cudatoolkit=11.1 pytorch=1.8.1
 2137  conda uninstall -c pytorch torchaudio
 2138  python
 2139  pip3 uninstall torchaudio
 2140  conda install -c pytorch torchaudio cudatoolkit=11.1 pytorch=1.8.1
 2141  python
 2142  jobs
 2143  ./prepare.sh
 2144  export CUDA_VISIBLE_DEVICES=""
 2145  ./tdnn/train.py
 2146  ./tdnn/decode.py
 2147  pico tdnn/exp/recogs-test_set.txt
 2148  history > install_icefall.txt
np@np-INTEL:~/code/icefall/egs/yesno/ASR$

Output

np@np-INTEL:~/code$ ls
np@np-INTEL:~/code$ git clone https://github.com/k2-fsa/icefall
Cloning into 'icefall'...
remote: Enumerating objects: 5700, done.
remote: Counting objects: 100% (310/310), done.
remote: Compressing objects: 100% (189/189), done.
remote: Total 5700 (delta 164), reused 186 (delta 87), pack-reused 5390
Receiving objects: 100% (5700/5700), 4.40 MiB | 3.38 MiB/s, done.
Resolving deltas: 100% (3651/3651), done.
np@np-INTEL:~/code$ ls
icefall
np@np-INTEL:~/code$ cd icefall/
np@np-INTEL:~/code/icefall$ ls
contributing.md  docs  icefall  pyproject.toml  requirements-ci.txt  setup.py
docker           egs   LICENSE  README.md       requirements.txt     test
np@np-INTEL:~/code/icefall$ pip install -r requirements.txt
Defaulting to user installation because normal site-packages is not writeable
Collecting kaldilm
  Downloading kaldilm-1.13.tar.gz (46 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 46.2/46.2 kB 2.8 MB/s eta 0:00:00
  Preparing metadata (setup.py) ... done
Collecting kaldialign
  Downloading kaldialign-0.2.tar.gz (39 kB)
  Preparing metadata (setup.py) ... done
Collecting sentencepiece>=0.1.96
  Downloading sentencepiece-0.1.96-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.2 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.2/1.2 MB 16.2 MB/s eta 0:00:00
Collecting tensorboard
  Downloading tensorboard-2.9.1-py3-none-any.whl (5.8 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 5.8/5.8 MB 26.5 MB/s eta 0:00:00
Collecting typeguard
  Downloading typeguard-2.13.3-py3-none-any.whl (17 kB)
Collecting protobuf<3.20,>=3.9.2
  Downloading protobuf-3.19.4-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.1 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.1/1.1 MB 29.2 MB/s eta 0:00:00
Collecting werkzeug>=1.0.1
  Downloading Werkzeug-2.1.2-py3-none-any.whl (224 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 224.9/224.9 kB 41.7 MB/s eta 0:00:00
Collecting grpcio>=1.24.3
  Downloading grpcio-1.47.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (4.5 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 4.5/4.5 MB 40.0 MB/s eta 0:00:00
Collecting google-auth<3,>=1.6.3
  Downloading google_auth-2.9.0-py2.py3-none-any.whl (167 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 167.8/167.8 kB 20.9 MB/s eta 0:00:00
Collecting absl-py>=0.4
  Downloading absl_py-1.1.0-py3-none-any.whl (123 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 123.7/123.7 kB 25.0 MB/s eta 0:00:00
Collecting tensorboard-data-server<0.7.0,>=0.6.0
  Downloading tensorboard_data_server-0.6.1-py3-none-manylinux2010_x86_64.whl (4.9 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 4.9/4.9 MB 54.8 MB/s eta 0:00:00
Requirement already satisfied: wheel>=0.26 in /usr/lib/python3/dist-packages (from tensorboard->-r requirements.txt (line 4)) (0.34.2)
Requirement already satisfied: numpy>=1.12.0 in /home/np/.local/lib/python3.8/site-packages (from tensorboard->-r requirements.txt (line 4)) (1.22.4)
Requirement already satisfied: setuptools>=41.0.0 in /usr/lib/python3/dist-packages (from tensorboard->-r requirements.txt (line 4)) (45.2.0)
Collecting google-auth-oauthlib<0.5,>=0.4.1
  Downloading google_auth_oauthlib-0.4.6-py2.py3-none-any.whl (18 kB)
Collecting tensorboard-plugin-wit>=1.6.0
  Downloading tensorboard_plugin_wit-1.8.1-py3-none-any.whl (781 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 781.3/781.3 kB 58.7 MB/s eta 0:00:00
Requirement already satisfied: requests<3,>=2.21.0 in /usr/lib/python3/dist-packages (from tensorboard->-r requirements.txt (line 4)) (2.22.0)
Collecting markdown>=2.6.8
  Downloading Markdown-3.3.7-py3-none-any.whl (97 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 97.8/97.8 kB 20.1 MB/s eta 0:00:00
Requirement already satisfied: six>=1.9.0 in /usr/lib/python3/dist-packages (from google-auth<3,>=1.6.3->tensorboard->-r requirements.txt (line 4)) (1.14.0)
Requirement already satisfied: cachetools<6.0,>=2.0.0 in /home/np/.local/lib/python3.8/site-packages (from google-auth<3,>=1.6.3->tensorboard->-r requirements.txt (line 4)) (5.2.0)
Collecting rsa<5,>=3.1.4
  Using cached rsa-4.8-py3-none-any.whl (39 kB)
Requirement already satisfied: pyasn1-modules>=0.2.1 in /usr/lib/python3/dist-packages (from google-auth<3,>=1.6.3->tensorboard->-r requirements.txt (line 4)) (0.2.1)
Collecting requests-oauthlib>=0.7.0
  Using cached requests_oauthlib-1.3.1-py2.py3-none-any.whl (23 kB)
Requirement already satisfied: importlib-metadata>=4.4 in /home/np/.local/lib/python3.8/site-packages (from markdown>=2.6.8->tensorboard->-r requirements.txt (line 4)) (4.12.0)
Requirement already satisfied: zipp>=0.5 in /home/np/.local/lib/python3.8/site-packages (from importlib-metadata>=4.4->markdown>=2.6.8->tensorboard->-r requirements.txt (line 4)) (3.8.0)
Requirement already satisfied: oauthlib>=3.0.0 in /usr/lib/python3/dist-packages (from requests-oauthlib>=0.7.0->google-auth-oauthlib<0.5,>=0.4.1->tensorboard->-r requirements.txt (line 4)) (3.1.0)
Requirement already satisfied: pyasn1>=0.1.3 in /usr/lib/python3/dist-packages (from rsa<5,>=3.1.4->google-auth<3,>=1.6.3->tensorboard->-r requirements.txt (line 4)) (0.4.2)
Building wheels for collected packages: kaldilm, kaldialign
  Building wheel for kaldilm (setup.py) ... done
  Created wheel for kaldilm: filename=kaldilm-1.13-cp38-cp38-linux_x86_64.whl size=924402 sha256=32984ad8aef7cf8ae3b9021c7d11d4536abd1db1a299d28ff24657af04081c42
  Stored in directory: /home/np/.cache/pip/wheels/ea/08/70/99aceed1961403b6a36295889ec3e38d227a13b1e74fdd9207
  Building wheel for kaldialign (setup.py) ... done
  Created wheel for kaldialign: filename=kaldialign-0.2-cp38-cp38-linux_x86_64.whl size=187846 sha256=1dd90d06f13454d35ee7a47dce10c9615fd976646ef4e86636aedad57b8e2904
  Stored in directory: /home/np/.cache/pip/wheels/cc/4e/da/ffc64af1d09024d85fa5231680b357945ad1461b3885aa4b93
Successfully built kaldilm kaldialign
Installing collected packages: tensorboard-plugin-wit, sentencepiece, kaldilm, kaldialign, werkzeug, typeguard, tensorboard-data-server, rsa, requests-oauthlib, protobuf, grpcio, absl-py, markdown, google-auth, google-auth-oauthlib, tensorboard
  Attempting uninstall: protobuf
    Found existing installation: protobuf 3.20.1
    Uninstalling protobuf-3.20.1:
      Successfully uninstalled protobuf-3.20.1
Successfully installed absl-py-1.1.0 google-auth-2.9.0 google-auth-oauthlib-0.4.6 grpcio-1.47.0 kaldialign-0.2 kaldilm-1.13 markdown-3.3.7 protobuf-3.19.4 requests-oauthlib-1.3.1 rsa-4.8 sentencepiece-0.1.96 tensorboard-2.9.1 tensorboard-data-server-0.6.1 tensorboard-plugin-wit-1.8.1 typeguard-2.13.3 werkzeug-2.1.2
np@np-INTEL:~/code/icefall$ pwd
/home/np/code/icefall
np@np-INTEL:~/code/icefall$ export PYTHONPATH=/home/np/code/icefall:$PYTHONPATH
np@np-INTEL:~/code/icefall$ pico .bashrc
np@np-INTEL:~/code/icefall$ pico ./bashrc
np@np-INTEL:~/code/icefall$ pico .bashrc
np@np-INTEL:~/code/icefall$ cd ~
np@np-INTEL:~$ pico .bashrc
np@np-INTEL:~$ pico .bashrc
np@np-INTEL:~$ virtualenv -p python3.8  test-icefall
ModuleNotFoundError: No module named 'virtualenv.seed.via_app_data'
np@np-INTEL:~$ which virtualenv
/home/np/.local/bin/virtualenv
np@np-INTEL:~$ /home/np/.local/bin/virtualenv
ModuleNotFoundError: No module named 'virtualenv.seed.via_app_data'
np@np-INTEL:~$ ls -l /home/np/.local/bin/virtualenv
-rwxrwxr-x 1 np np 238 Jun 30 20:05 /home/np/.local/bin/virtualenv
np@np-INTEL:~$ date
Wed 06 Jul 2022 10:21:18 PM PDT
np@np-INTEL:~$ ls -l ~/.local
total 16
drwxrwxr-x  2 np np 4096 Jul  6 22:14 bin
drwxrwxr-x  3 np np 4096 Jun 30 19:54 etc
drwxrwxr-x  3 np np 4096 Jun 30 19:54 lib
drwxr-xr-x 24 np np 4096 Jul  6 22:20 share
np@np-INTEL:~$ ls ~/anaconda3/bin/
Display all 538 possibilities? (y or n)
2to3                                h5import                            pyhtmlizer
2to3-3.8                            h5jam                               pyjson5
acountry                            h5ls                                pylint
activate                            h5mkgrp                             pylsp
adig                                h5perf_serial                       pylupdate5
aec                                 h5redeploy                          pyrcc5
ahost                               h5repack                            pyreverse
anaconda                            h5repart                            pyrsa-decrypt
anaconda-navigator                  h5stat                              pyrsa-encrypt
anaconda-project                    h5unjam                             pyrsa-keygen
asn1Coding                          h5watch                             pyrsa-priv2pub
asn1Decoding                        holoviews                           pyrsa-sign
asn1Parser                          hydra_nameserver                    pyrsa-verify
assistant                           hydra_persist                       py.test
automat-visualize                   hydra_pmi_proxy                     pytest
autopep8                            iconv                               python
binstar                             icu-config                          python3
black                               icuinfo                             python3.8
blackd                              idle3                               python3.8-config
bokeh                               idle3.8                             python3-config
brotli                              idn2                                pyuic5
bsdcat                              imagecodecs                         qcollectiongenerator
bsdcpio                             imageio_download_bin                qdarkstyle
bsdtar                              imageio_remove_bin                  qdarkstyle.example
bunzip2                             imcopy                              qdarkstyle.utils
bzcat                               img2webp                            qdbus
bzcmp                               infocmp                             qdbuscpp2xml
bzdiff                              infotocap                           qdbusviewer
bzegrep                             intake                              qdbusxml2cpp
bzfgrep                             intake-server                       qdoc
bzgrep                              ipython                             qgltf
bzip2                               ipython3                            qhelpconverter
bzip2recover                        isort                               qhelpgenerator
bzless                              isort-identify-imports              qlalr
bzmore                              isql                                qmake
np@np-INTEL:~$ less  /home/np/.local/bin/virtualenv
np@np-INTEL:~$ python -m virtualenv
usage: virtualenv [--version] [--with-traceback] [-v | -q] [--read-only-app-data] [--app-data APP_DATA] [--reset-app-data] [--upgrade-embed-wheels] [--discovery {builtin}] [-p py] [--try-first-with py_exe]
                  [--creator {builtin,cpython3-posix,venv}] [--seeder {app-data,pip}] [--no-seed] [--activators comma_sep_list] [--clear] [--no-vcs-ignore] [--system-site-packages] [--symlinks | --copies] [--no-download | --download]
                  [--extra-search-dir d [d ...]] [--pip version] [--setuptools version] [--wheel version] [--no-pip] [--no-setuptools] [--no-wheel] [--no-periodic-update] [--symlink-app-data] [--prompt prompt] [-h]
                  dest
virtualenv: error: the following arguments are required: dest
SystemExit: 2
np@np-INTEL:~$ python --version
Python 3.8.13
np@np-INTEL:~$ python -m virtualenv python3.8 test-icefall
usage: virtualenv [--version] [--with-traceback] [-v | -q] [--read-only-app-data] [--app-data APP_DATA] [--reset-app-data] [--upgrade-embed-wheels] [--discovery {builtin}] [-p py] [--try-first-with py_exe]
                  [--creator {builtin,cpython3-posix,venv}] [--seeder {app-data,pip}] [--no-seed] [--activators comma_sep_list] [--clear] [--no-vcs-ignore] [--system-site-packages] [--symlinks | --copies] [--no-download | --download]
                  [--extra-search-dir d [d ...]] [--pip version] [--setuptools version] [--wheel version] [--no-pip] [--no-setuptools] [--no-wheel] [--no-periodic-update] [--symlink-app-data] [--prompt prompt] [-h]
                  dest
virtualenv: error: unrecognized arguments: test-icefall
SystemExit: 2
np@np-INTEL:~$ 
np@np-INTEL:~$ python -m virtualenv -p python3.8 test-icefall
created virtual environment CPython3.8.13.final.0-64 in 113ms
  creator CPython3Posix(dest=/home/np/test-icefall, clear=False, no_vcs_ignore=False, global=False)
  seeder FromAppData(download=False, pip=bundle, setuptools=bundle, wheel=bundle, via=copy, app_data_dir=/home/np/.local/share/virtualenv)
    added seed packages: pip==22.1.2, setuptools==62.6.0, wheel==0.37.1
  activators BashActivator,CShellActivator,FishActivator,NushellActivator,PowerShellActivator,PythonActivator
np@np-INTEL:~$ source test-icefall/bin/activate
(test-icefall) np@np-INTEL:~$ deactivate
np@np-INTEL:~$ cd code/
np@np-INTEL:~/code$ ls
icefall
np@np-INTEL:~/code$ cd icefall/
np@np-INTEL:~/code/icefall$ ls
contributing.md  docs  icefall  pyproject.toml  requirements-ci.txt  setup.py
docker           egs   LICENSE  README.md       requirements.txt     test
np@np-INTEL:~/code/icefall$ cd egs/yesno/ASR/
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ./prepare.sh 
2022-07-06 22:26:27 (prepare.sh:24:main) dl_dir: /home/np/code/icefall/egs/yesno/ASR/download
2022-07-06 22:26:27 (prepare.sh:27:main) Stage 0: Download data
Downloading waves_yesno.tar.gz: 4.49MB [00:03, 1.34MB/s]                                                         
2022-07-06 22:26:32 (prepare.sh:36:main) Stage 1: Prepare yesno manifest
2022-07-06 22:26:32 (prepare.sh:42:main) Stage 2: Compute fbank for yesno
Traceback (most recent call last):
  File "./local/compute_fbank_yesno.py", line 18, in <module>
    from icefall.utils import get_executor
  File "/home/np/code/icefall/icefall/__init__.py", line 3, in <module>
    from . import (
  File "/home/np/code/icefall/icefall/decode.py", line 20, in <module>
    import k2
ModuleNotFoundError: No module named 'k2'
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ python3 --version k2
Python 3.8.13
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ less prepare.sh
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ which lhotse
/home/np/.local/bin/lhotse
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ lhotse --help
lUsage: lhotse [OPTIONS] COMMAND [ARGS]...

  The shell entry point to Lhotse, a tool and a library for audio data
  manipulation in high altitudes.

Options:
  -s, --seed INTEGER  Random seed.
  --help              Show this message and exit.

Commands:
  combine           Load MANIFESTS, combine them into a single one, and...
  copy              Load INPUT_MANIFEST and store it to OUTPUT_MANIFEST.
  copy-feats        Load INPUT_MANIFEST of type...
  cut               Group of commands used to create CutSets.
  download          Command group for download and extract data.
  feat              Feature extraction related commands.
  filter            Filter a MANIFEST according to the rule specified in...
  fix               Fix a pair of Lhotse RECORDINGS and SUPERVISIONS...
  install-sph2pipe  Install the sph2pipe program to handle sphere (.sph)...
  kaldi             Kaldi import/export related commands.
  prepare           Command group with data preparation recipes.
  split             Load MANIFEST, split it into NUM_SPLITS equal parts...
  split-lazy        Load MANIFEST (lazily if in JSONL format) and split...
  subset            Load MANIFEST, select the FIRST or LAST number of...
  validate          Validate a Lhotse manifest file.
  validate-pair     Validate a pair of Lhotse RECORDINGS and SUPERVISIONS...
enp@np-INTEL:~/code/icefall/egs/yesno/ASR$ less $(which lhotse)
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ nano $(which lhotse)
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ lhotse --help
Usage: lhotse [OPTIONS] COMMAND [ARGS]...

  The shell entry point to Lhotse, a tool and a library for audio data
  manipulation in high altitudes.

Options:
  -s, --seed INTEGER  Random seed.
  --help              Show this message and exit.

Commands:
  combine           Load MANIFESTS, combine them into a single one, and...
  copy              Load INPUT_MANIFEST and store it to OUTPUT_MANIFEST.
  copy-feats        Load INPUT_MANIFEST of type...
  cut               Group of commands used to create CutSets.
  download          Command group for download and extract data.
  feat              Feature extraction related commands.
  filter            Filter a MANIFEST according to the rule specified in...
  fix               Fix a pair of Lhotse RECORDINGS and SUPERVISIONS...
  install-sph2pipe  Install the sph2pipe program to handle sphere (.sph)...
  kaldi             Kaldi import/export related commands.
  prepare           Command group with data preparation recipes.
  split             Load MANIFEST, split it into NUM_SPLITS equal parts...
  split-lazy        Load MANIFEST (lazily if in JSONL format) and split...
  subset            Load MANIFEST, select the FIRST or LAST number of...
  validate          Validate a Lhotse manifest file.
  validate-pair     Validate a pair of Lhotse RECORDINGS and SUPERVISIONS...
np@np-INTEL:~/code/icefall/egs/yesno/ASR$  prepare.sh
prepare.sh: command not found
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ./prepare.sh
2022-07-06 22:29:23 (prepare.sh:24:main) dl_dir: /home/np/code/icefall/egs/yesno/ASR/download
2022-07-06 22:29:23 (prepare.sh:27:main) Stage 0: Download data
2022-07-06 22:29:23 (prepare.sh:36:main) Stage 1: Prepare yesno manifest
2022-07-06 22:29:23 (prepare.sh:42:main) Stage 2: Compute fbank for yesno
Traceback (most recent call last):
  File "./local/compute_fbank_yesno.py", line 18, in <module>
    from icefall.utils import get_executor
  File "/home/np/code/icefall/icefall/__init__.py", line 3, in <module>
    from . import (
  File "/home/np/code/icefall/icefall/decode.py", line 20, in <module>
    import k2
ModuleNotFoundError: No module named 'k2'
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ less prepare.sh
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ less local/comp
compile_hlg.py          compute_fbank_yesno.py  
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ less local/compute_fbank_yesno.py 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ kalias^Chich 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ^C
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ alias python3
alias python3='/home/np/anaconda3/bin/python'
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ less local/compute_fbank_yesno.py 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$  local/compute_fbank_yesno.py 
Traceback (most recent call last):
  File "local/compute_fbank_yesno.py", line 18, in <module>
    from icefall.utils import get_executor
  File "/home/np/code/icefall/icefall/__init__.py", line 3, in <module>
    from . import (
  File "/home/np/code/icefall/icefall/decode.py", line 20, in <module>
    import k2
ModuleNotFoundError: No module named 'k2'
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ python
Python 3.8.13 (default, Mar 28 2022, 11:38:47) 
[GCC 7.5.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import k2
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/np/anaconda3/lib/python3.8/site-packages/k2/__init__.py", line 6, in <module>
    raise ImportError(
ImportError: k2 was built using PyTorch 1.8.1
But you are using PyTorch 1.12.0+cu102 to run it
>>> 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ~/anaconda3/bin/python
Python 3.8.13 (default, Mar 28 2022, 11:38:47) 
[GCC 7.5.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import k2
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/np/anaconda3/lib/python3.8/site-packages/k2/__init__.py", line 6, in <module>
    raise ImportError(
ImportError: k2 was built using PyTorch 1.8.1
But you are using PyTorch 1.12.0+cu102 to run it
>>> 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ +
++: command not found
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$  conda install -c k2-fsa  k2 python=3.8 cudatoolkit=11.1 pytorch=1.8.1
Collecting package metadata (current_repodata.json): done
Solving environment: done

# All requested packages already installed.

np@np-INTEL:~/code/icefall/egs/yesno/ASR$ python
Python 3.8.13 (default, Mar 28 2022, 11:38:47) 
[GCC 7.5.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import k2
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/np/anaconda3/lib/python3.8/site-packages/k2/__init__.py", line 6, in <module>
    raise ImportError(
ImportError: k2 was built using PyTorch 1.8.1
But you are using PyTorch 1.12.0+cu102 to run it
>>> 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ python
Python 3.8.13 (default, Mar 28 2022, 11:38:47) 
[GCC 7.5.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import torch
tor>>> torch.__file__
'/home/np/.local/lib/python3.8/site-packages/torch/__init__.py'
>>> 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ls -l ~/.local/lib/python3.8/site-packages/torch
total 1456
drwxrwxr-x  3 np np   4096 Jul  5 17:43 amp
drwxrwxr-x  7 np np   4096 Jul  5 17:43 ao
-rw-rw-r--  1 np np  26245 Jul  5 17:43 _appdirs.py
drwxrwxr-x  4 np np   4096 Jul  5 17:43 autograd
drwxrwxr-x 13 np np   4096 Jul  5 17:43 backends
drwxrwxr-x  2 np np   4096 Jul  5 17:43 bin
drwxrwxr-x  2 np np   4096 Jul  5 17:43 _C
-rwxrwxr-x  1 np np  29296 Jul  5 17:43 _C.cpython-38-x86_64-linux-gnu.so
drwxrwxr-x  2 np np   4096 Jul  5 17:43 _C_flatbuffer
-rwxrwxr-x  1 np np  29320 Jul  5 17:43 _C_flatbuffer.cpython-38-x86_64-linux-gnu.so
-rw-rw-r--  1 np np   1717 Jul  5 17:43 _classes.py
-rw-rw-r--  1 np np    551 Jul  5 17:43 __config__.py
drwxrwxr-x  3 np np   4096 Jul  5 17:43 contrib
drwxrwxr-x  4 np np   4096 Jul  5 17:43 cpu
drwxrwxr-x  4 np np   4096 Jul  5 17:43 cuda
drwxrwxr-x  3 np np   4096 Jul  5 17:43 _decomp
-rw-rw-r--  1 np np   3461 Jul  5 17:43 _deploy.py
drwxrwxr-x 15 np np   4096 Jul  5 17:43 distributed
drwxrwxr-x  3 np np   4096 Jul  5 17:43 distributions
-rwxrwxr-x  1 np np  29832 Jul  5 17:43 _dl.cpython-38-x86_64-linux-gnu.so
drwxrwxr-x  3 np np   4096 Jul  5 17:43 fft
-rw-rw-r--  1 np np  72365 Jul  5 17:43 functional.py
-rw-rw-r--  1 np np    813 Jul  5 17:43 __future__.py
drwxrwxr-x  3 np np   4096 Jul  5 17:43 futures
drwxrwxr-x  5 np np   4096 Jul  5 17:43 fx
-rw-rw-r--  1 np np  30909 Jul  5 17:43 hub.py
drwxrwxr-x  9 np np   4096 Jul  5 17:43 include
-rw-rw-r--  1 np np  38255 Jul  5 17:43 __init__.py
drwxrwxr-x  5 np np   4096 Jul  5 17:43 jit
-rw-rw-r--  1 np np  47128 Jul  5 17:43 _jit_internal.py
drwxrwxr-x  3 np np   4096 Jul  5 17:43 _lazy
drwxrwxr-x  2 np np   4096 Jul  5 17:43 lib
-rw-rw-r--  1 np np   4048 Jul  5 17:43 library.py
drwxrwxr-x  3 np np   4096 Jul  5 17:43 linalg
-rw-rw-r--  1 np np   2712 Jul  5 17:43 _linalg_utils.py
-rw-rw-r--  1 np np  43759 Jul  5 17:43 _lobpcg.py
-rw-rw-r--  1 np np  10987 Jul  5 17:43 _lowrank.py
drwxrwxr-x  3 np np   4096 Jul  5 17:43 _masked
-rw-rw-r--  1 np np   5004 Jul  5 17:43 _meta_registrations.py
drwxrwxr-x  3 np np   4096 Jul  5 17:43 monitor
drwxrwxr-x  3 np np   4096 Jul  5 17:43 multiprocessing
-rw-rw-r--  1 np np   5351 Jul  5 17:43 _namedtensor_internals.py
drwxrwxr-x  3 np np   4096 Jul  5 17:43 nested
drwxrwxr-x 11 np np   4096 Jul  5 17:43 nn
drwxrwxr-x  3 np np   4096 Jul  5 17:43 onnx
-rw-rw-r--  1 np np  10811 Jul  5 17:43 _ops.py
drwxrwxr-x  4 np np   4096 Jul  5 17:43 optim
-rw-rw-r--  1 np np 101611 Jul  5 17:43 overrides.py
drwxrwxr-x  4 np np   4096 Jul  5 17:43 package
drwxrwxr-x  3 np np   4096 Jul  5 17:43 _prims
drwxrwxr-x  3 np np   4096 Jul  5 17:43 profiler
drwxrwxr-x  2 np np   4096 Jul  5 17:43 __pycache__
-rw-rw-r--  1 np np   6956 Jul  5 17:43 _python_dispatcher.py
-rw-rw-r--  1 np np      0 Jul  5 17:43 py.typed
drwxrwxr-x  4 np np   4096 Jul  5 17:43 quantization
-rw-rw-r--  1 np np   7489 Jul  5 17:43 quasirandom.py
-rw-rw-r--  1 np np   4828 Jul  5 17:43 random.py
drwxrwxr-x  5 np np   4096 Jul  5 17:43 _refs
-rw-rw-r--  1 np np   1025 Jul  5 17:43 return_types.py
-rw-rw-r--  1 np np  45129 Jul  5 17:43 serialization.py
drwxrwxr-x  3 np np   4096 Jul  5 17:43 share
-rw-rw-r--  1 np np   1786 Jul  5 17:43 _six.py
-rw-rw-r--  1 np np   3943 Jul  5 17:43 _sources.py
drwxrwxr-x  3 np np   4096 Jul  5 17:43 sparse
drwxrwxr-x  3 np np   4096 Jul  5 17:43 special
-rw-rw-r--  1 np np   1040 Jul  5 17:43 _storage_docs.py
-rw-rw-r--  1 np np  30641 Jul  5 17:43 storage.py
-rw-rw-r--  1 np np 123870 Jul  5 17:43 _tensor_docs.py
-rw-rw-r--  1 np np  54842 Jul  5 17:43 _tensor.py
-rw-rw-r--  1 np np  21453 Jul  5 17:43 _tensor_str.py
drwxrwxr-x  4 np np   4096 Jul  5 17:43 testing
-rw-rw-r--  1 np np 398841 Jul  5 17:43 _torch_docs.py
-rw-rw-r--  1 np np   3521 Jul  5 17:43 torch_version.py
-rw-rw-r--  1 np np   1958 Jul  5 17:43 types.py
drwxrwxr-x 10 np np   4096 Jul  5 17:43 utils
-rw-rw-r--  1 np np   1687 Jul  5 17:43 _utils_internal.py
-rw-rw-r--  1 np np  23920 Jul  5 17:43 _utils.py
-rw-rw-r--  1 np np    125 Jul  5 17:43 version.py
-rw-rw-r--  1 np np    656 Jul  5 17:43 _VF.py
-rw-rw-r--  1 np np  13926 Jul  5 17:43 _vmap_internals.py
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ date
Wed 06 Jul 2022 10:33:17 PM PDT
(failed reverse-i-search)`-c k2': lhotse -^Celp
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ^C
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ python  setup.py ^C
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ k
k: command not found
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ^C
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ pip3 remove torch --user
ERROR: unknown command "remove"
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ pip3 delete torch --user
ERROR: unknown command "delete"
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ pip3 --help

Usage:   
  pip3 <command> [options]

Commands:
  install                     Install packages.
  download                    Download packages.
  uninstall                   Uninstall packages.
  freeze                      Output installed packages in requirements format.
  list                        List installed packages.
  show                        Show information about installed packages.
  check                       Verify installed packages have compatible dependencies.
  config                      Manage local and global configuration.
  search                      Search PyPI for packages.
  cache                       Inspect and manage pip's wheel cache.
  index                       Inspect information available from package indexes.
  wheel                       Build wheels from your requirements.
  hash                        Compute hashes of package archives.
  completion                  A helper command used for command completion.
  debug                       Show information useful for debugging.
  help                        Show help for commands.

General Options:
  -h, --help                  Show help.
  --debug                     Let unhandled exceptions propagate outside the main subroutine, instead of
                              logging them to stderr.
  --isolated                  Run pip in an isolated mode, ignoring environment variables and user
                              configuration.
  --require-virtualenv        Allow pip to only run in a virtual environment; exit with an error otherwise.
  -v, --verbose               Give more output. Option is additive, and can be used up to 3 times.
  -V, --version               Show version and exit.
  -q, --quiet                 Give less output. Option is additive, and can be used up to 3 times
                              (corresponding to WARNING, ERROR, and CRITICAL logging levels).
  --log <path>                Path to a verbose appending log.
  --no-input                  Disable prompting for input.
  --proxy <proxy>             Specify a proxy in the form scheme://[user:passwd@]proxy.server:port.
  --retries <retries>         Maximum number of retries each connection should attempt (default 5 times).
  --timeout <sec>             Set the socket timeout (default 15 seconds).
  --exists-action <action>    Default action when a path already exists: (s)witch, (i)gnore, (w)ipe, (b)ackup,
                              (a)bort.
  --trusted-host <hostname>   Mark this host or host:port pair as trusted, even though it does not have valid
                              or any HTTPS.
  --cert <path>               Path to PEM-encoded CA certificate bundle. If provided, overrides the default.
                              See 'SSL Certificate Verification' in pip documentation for more information.
  --client-cert <path>        Path to SSL client certificate, a single file containing the private key and the
                              certificate in PEM format.
  --cache-dir <dir>           Store the cache data in <dir>.
  --no-cache-dir              Disable the cache.
  --disable-pip-version-check
                              Don't periodically check PyPI to determine whether a new version of pip is
                              available for download. Implied with --no-index.
  --no-color                  Suppress colored output.
  --no-python-version-warning
                              Silence deprecation warnings for upcoming unsupported Pythons.
  --use-feature <feature>     Enable new functionality, that may be backward incompatible.
  --use-deprecated <feature>  Enable deprecated functionality, that will be removed in the future.
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ^C
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ pip3 uninstall torch --user

Usage:   
  pip3 uninstall [options] <package> ...
  pip3 uninstall [options] -r <requirements file> ...

no such option: --user
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ pip3 uninstall torch 
Found existing installation: torch 1.12.0
Uninstalling torch-1.12.0:
  Would remove:
    /home/np/.local/bin/convert-caffe2-to-onnx
    /home/np/.local/bin/convert-onnx-to-caffe2
    /home/np/.local/bin/torchrun
    /home/np/.local/lib/python3.8/site-packages/caffe2/*
    /home/np/.local/lib/python3.8/site-packages/torch-1.12.0.dist-info/*
    /home/np/.local/lib/python3.8/site-packages/torch/*
    /home/np/.local/lib/python3.8/site-packages/torchgen/*
Proceed (Y/n)? y
  Successfully uninstalled torch-1.12.0
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ python
Python 3.8.13 (default, Mar 28 2022, 11:38:47) 
[GCC 7.5.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import torch
>>> torch.__version__
'1.8.1'
>>> 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ python
Python 3.8.13 (default, Mar 28 2022, 11:38:47) 
[GCC 7.5.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import k2
 >>>  
>>> 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ./prepare.sh 
2022-07-06 22:35:02 (prepare.sh:24:main) dl_dir: /home/np/code/icefall/egs/yesno/ASR/download
2022-07-06 22:35:02 (prepare.sh:27:main) Stage 0: Download data
2022-07-06 22:35:02 (prepare.sh:36:main) Stage 1: Prepare yesno manifest
Traceback (most recent call last):
  File "/home/np/.local/bin/lhotse", line 5, in <module>
    from lhotse.bin.lhotse import cli
  File "/home/np/.local/lib/python3.8/site-packages/lhotse/__init__.py", line 1, in <module>
    from .audio import (
  File "/home/np/.local/lib/python3.8/site-packages/lhotse/audio.py", line 30, in <module>
    import torch
ModuleNotFoundError: No module named 'torch'
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ python3
Python 3.8.13 (default, Mar 28 2022, 11:38:47) 
[GCC 7.5.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import torch
>>> 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ pip3 uninstall lhotse
Found existing installation: lhotse 1.4.0.dev0+git.f0600d1.clean
Uninstalling lhotse-1.4.0.dev0+git.f0600d1.clean:
  Would remove:
    /home/np/.local/bin/lhotse
    /home/np/.local/lib/python3.8/site-packages/lhotse-1.4.0.dev0+git.f0600d1.clean.dist-info/*
    /home/np/.local/lib/python3.8/site-packages/lhotse/*
Proceed (Y/n)? y 
  Successfully uninstalled lhotse-1.4.0.dev0+git.f0600d1.clean
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ python -m pip3 install lhotse
/home/np/anaconda3/bin/python: No module named pip3
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ python -m pip install lhotse
Collecting lhotse
  Downloading lhotse-1.4.0-py3-none-any.whl (489 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 489.8/489.8 kB 5.8 MB/s eta 0:00:00
Requirement already satisfied: numpy>=1.18.1 in /home/np/.local/lib/python3.8/site-packages (from lhotse) (1.22.4)
Requirement already satisfied: click>=7.1.1 in /home/np/.local/lib/python3.8/site-packages (from lhotse) (8.1.3)
Requirement already satisfied: lilcom>=1.1.0 in /home/np/.local/lib/python3.8/site-packages/lilcom-1.2.1-py3.8-linux-x86_64.egg (from lhotse) (1.2.1)
Requirement already satisfied: pyyaml>=5.3.1 in /home/np/anaconda3/lib/python3.8/site-packages (from lhotse) (6.0)
Requirement already satisfied: dataclasses in /home/np/.local/lib/python3.8/site-packages (from lhotse) (0.6)
Requirement already satisfied: intervaltree>=3.1.0 in /home/np/.local/lib/python3.8/site-packages (from lhotse) (3.1.0)
Requirement already satisfied: SoundFile>=0.10 in /home/np/.local/lib/python3.8/site-packages (from lhotse) (0.10.3.post1)
Requirement already satisfied: packaging in /home/np/.local/lib/python3.8/site-packages (from lhotse) (21.3)
Requirement already satisfied: tqdm in /home/np/.local/lib/python3.8/site-packages (from lhotse) (4.64.0)
Requirement already satisfied: cytoolz>=0.10.1 in /home/np/.local/lib/python3.8/site-packages (from lhotse) (0.11.2)
Requirement already satisfied: audioread>=2.1.9 in /home/np/.local/lib/python3.8/site-packages (from lhotse) (2.1.9)
Requirement already satisfied: toolz>=0.8.0 in /home/np/.local/lib/python3.8/site-packages (from cytoolz>=0.10.1->lhotse) (0.11.2)
Requirement already satisfied: sortedcontainers<3.0,>=2.0 in /home/np/.local/lib/python3.8/site-packages (from intervaltree>=3.1.0->lhotse) (2.4.0)
Requirement already satisfied: cffi>=1.0 in /home/np/.local/lib/python3.8/site-packages (from SoundFile>=0.10->lhotse) (1.15.1)
Requirement already satisfied: pyparsing!=3.0.5,>=2.0.2 in /home/np/.local/lib/python3.8/site-packages (from packaging->lhotse) (3.0.9)
Requirement already satisfied: pycparser in /home/np/.local/lib/python3.8/site-packages (from cffi>=1.0->SoundFile>=0.10->lhotse) (2.21)
Installing collected packages: lhotse
Successfully installed lhotse-1.4.0
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ which python
/home/np/anaconda3/bin/python
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ which pip3
/home/np/.local/bin/pip3
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ /home/np/.local/bin/pip3

Usage:   
  pip3 <command> [options]

Commands:
  install                     Install packages.
  download                    Download packages.
  uninstall                   Uninstall packages.
  freeze                      Output installed packages in requirements format.
  list                        List installed packages.
  show                        Show information about installed packages.
  check                       Verify installed packages have compatible dependencies.
  config                      Manage local and global configuration.
  search                      Search PyPI for packages.
  cache                       Inspect and manage pip's wheel cache.
  index                       Inspect information available from package indexes.
  wheel                       Build wheels from your requirements.
  hash                        Compute hashes of package archives.
  completion                  A helper command used for command completion.
  debug                       Show information useful for debugging.
  help                        Show help for commands.

General Options:
  -h, --help                  Show help.
  --debug                     Let unhandled exceptions propagate outside the main subroutine, instead of
                              logging them to stderr.
  --isolated                  Run pip in an isolated mode, ignoring environment variables and user
                              configuration.
  --require-virtualenv        Allow pip to only run in a virtual environment; exit with an error otherwise.
  -v, --verbose               Give more output. Option is additive, and can be used up to 3 times.
  -V, --version               Show version and exit.
  -q, --quiet                 Give less output. Option is additive, and can be used up to 3 times
                              (corresponding to WARNING, ERROR, and CRITICAL logging levels).
  --log <path>                Path to a verbose appending log.
  --no-input                  Disable prompting for input.
  --proxy <proxy>             Specify a proxy in the form scheme://[user:passwd@]proxy.server:port.
  --retries <retries>         Maximum number of retries each connection should attempt (default 5 times).
  --timeout <sec>             Set the socket timeout (default 15 seconds).
  --exists-action <action>    Default action when a path already exists: (s)witch, (i)gnore, (w)ipe, (b)ackup,
                              (a)bort.
  --trusted-host <hostname>   Mark this host or host:port pair as trusted, even though it does not have valid
                              or any HTTPS.
  --cert <path>               Path to PEM-encoded CA certificate bundle. If provided, overrides the default.
                              See 'SSL Certificate Verification' in pip documentation for more information.
  --client-cert <path>        Path to SSL client certificate, a single file containing the private key and the
                              certificate in PEM format.
  --cache-dir <dir>           Store the cache data in <dir>.
  --no-cache-dir              Disable the cache.
  --disable-pip-version-check
                              Don't periodically check PyPI to determine whether a new version of pip is
                              available for download. Implied with --no-index.
  --no-color                  Suppress colored output.
  --no-python-version-warning
                              Silence deprecation warnings for upcoming unsupported Pythons.
  --use-feature <feature>     Enable new functionality, that may be backward incompatible.
  --use-deprecated <feature>  Enable deprecated functionality, that will be removed in the future.
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ more /home/np/.local/bin/pip3
#!/usr/bin/python3
# -*- coding: utf-8 -*-
import re
import sys
from pip._internal.cli.main import main
if __name__ == '__main__':
    sys.argv[0] = re.sub(r'(-script\.pyw|\.exe)?$', '', sys.argv[0])
    sys.exit(main())
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ./prepare.sh 
2022-07-06 22:36:17 (prepare.sh:24:main) dl_dir: /home/np/code/icefall/egs/yesno/ASR/download
2022-07-06 22:36:17 (prepare.sh:27:main) Stage 0: Download data
2022-07-06 22:36:17 (prepare.sh:36:main) Stage 1: Prepare yesno manifest
2022-07-06 22:36:18 (prepare.sh:42:main) Stage 2: Compute fbank for yesno
Traceback (most recent call last):
  File "./local/compute_fbank_yesno.py", line 14, in <module>
    import torch
ModuleNotFoundError: No module named 'torch'
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ less local/compute_fbank_yesno.py 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ less prepare.sh 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ alias python3
alias python3='/home/np/anaconda3/bin/python'
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ python3
Python 3.8.13 (default, Mar 28 2022, 11:38:47) 
[GCC 7.5.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import torch
>>> 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ jobs
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ less local/compute_fbank_yesno.py 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ echo $PATH
/home/np/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/home/np/anaconda3/bin:/usr/local/cuda/bin
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ cd
np@np-INTEL:~$ cd .local
np@np-INTEL:~/.local$ cd bin
np@np-INTEL:~/.local/bin$ ls -l
total 184
-rwxrwxr-x 1 np np 215 Jun 30 19:54 cmark
-rwxrwxr-x 1 np np 962 Jul  5 20:51 f2py
-rwxrwxr-x 1 np np 964 Jul  5 20:51 f2py3
-rwxrwxr-x 1 np np 968 Jul  5 20:51 f2py3.8
-rwxrwxr-x 1 np np 233 Jul  6 22:14 google-oauthlib-tool
-rwxrwxr-x 1 np np 224 Jun 30 19:54 ipython
-rwxrwxr-x 1 np np 224 Jun 30 19:54 ipython3
-rwxrwxr-x 1 np np 213 Jun 30 19:54 jsonschema
-rwxrwxr-x 1 np np 219 Jun 30 19:54 jupyter
-rwxrwxr-x 1 np np 233 Jun 30 19:54 jupyter-bundlerextension
-rwxrwxr-x 1 np np 235 Jun 30 19:54 jupyter-dejavu
-rwxrwxr-x 1 np np 211 Jun 30 19:54 jupyter-execute
-rwxrwxr-x 1 np np 223 Jun 30 19:54 jupyter-kernel
-rwxrwxr-x 1 np np 261 Jun 30 19:54 jupyter-kernelspec
-rwxrwxr-x 1 np np 219 Jun 30 19:54 jupyter-migrate
-rwxrwxr-x 1 np np 221 Jun 30 19:54 jupyter-nbconvert
-rwxrwxr-x 1 np np 220 Jun 30 19:54 jupyter-nbextension
-rwxrwxr-x 1 np np 219 Jun 30 19:54 jupyter-notebook
-rwxrwxr-x 1 np np 240 Jun 30 19:54 jupyter-run
-rwxrwxr-x 1 np np 224 Jun 30 19:54 jupyter-serverextension
-rwxrwxr-x 1 np np 224 Jun 30 19:54 jupyter-troubleshoot
-rwxrwxr-x 1 np np 252 Jun 30 19:54 jupyter-trust
-rwxrwxr-x 1 np np 214 Jul  6 22:14 markdown_py
-rwxrwxr-x 1 np np 221 Jun 30 20:05 pip
-rwxrwxr-x 1 np np 221 Jun 30 20:05 pip3
-rwxrwxr-x 1 np np 221 Jun 30 20:05 pip3.10
-rwxrwxr-x 1 np np 221 Jun 30 20:05 pip3.8
-rwxrwxr-x 1 np np 203 Jun 30 20:05 pipenv
-rwxrwxr-x 1 np np 214 Jun 30 20:05 pipenv-resolver
-rwxrwxr-x 1 np np 248 Jun 30 19:54 plasma_store
-rwxrwxr-x 1 np np 215 Jun 30 19:54 pygmentize
-rwxrwxr-x 1 np np 212 Jul  6 22:14 pyrsa-decrypt
-rwxrwxr-x 1 np np 212 Jul  6 22:14 pyrsa-encrypt
-rwxrwxr-x 1 np np 210 Jul  6 22:14 pyrsa-keygen
-rwxrwxr-x 1 np np 233 Jul  6 22:14 pyrsa-priv2pub
-rwxrwxr-x 1 np np 206 Jul  6 22:14 pyrsa-sign
-rwxrwxr-x 1 np np 210 Jul  6 22:14 pyrsa-verify
-rwxrwxr-x 1 np np 205 Jun 30 19:54 pysemver
-rwxrwxr-x 1 np np 218 Jun 30 19:54 send2trash
-rwxrwxr-x 1 np np 212 Jun 30 20:17 streamlit
-rwxrwxr-x 1 np np  33 Jun 30 20:17 streamlit.cmd
-rwxrwxr-x 1 np np 223 Jul  6 22:14 tensorboard
-rwxrwxr-x 1 np np 207 Jul  5 17:43 tqdm
-rwxrwxr-x 1 np np 238 Jun 30 20:05 virtualenv
-rwxrwxr-x 1 np np 214 Jun 30 20:05 virtualenv-clone
-rwxrwxr-x 1 np np 217 Jun 30 19:54 watchmedo
np@np-INTEL:~/.local/bin$ ls -l py
pygmentize      pyrsa-encrypt   pyrsa-priv2pub  pyrsa-verify    
pyrsa-decrypt   pyrsa-keygen    pyrsa-sign      pysemver        
np@np-INTEL:~/.local/bin$ ls -l py
pygmentize      pyrsa-encrypt   pyrsa-priv2pub  pyrsa-verify    
pyrsa-decrypt   pyrsa-keygen    pyrsa-sign      pysemver        
np@np-INTEL:~/.local/bin$ which python
/home/np/anaconda3/bin/python
np@np-INTEL:~/.local/bin$ ln -s $(which python) python3
np@np-INTEL:~/.local/bin$ ls -l python3
lrwxrwxrwx 1 np np 29 Jul  6 22:38 python3 -> /home/np/anaconda3/bin/python
np@np-INTEL:~/.local/bin$ popd
bash: popd: directory stack empty
np@np-INTEL:~/.local/bin$ cd -
/home/np/.local
np@np-INTEL:~/.local$ cd -
/home/np/.local/bin
np@np-INTEL:~/.local/bin$ cd -
/home/np/.local
np@np-INTEL:~/.local$ cd
np@np-INTEL:~$ cd test-icefall/
np@np-INTEL:~/test-icefall$ cd 
bin/ lib/ 
np@np-INTEL:~/test-icefall$ cd 
bin/ lib/ 
np@np-INTEL:~/test-icefall$ ^C
np@np-INTEL:~/test-icefall$ cd ..
np@np-INTEL:~$ /home/np/.local/bin/pip3

Usage:   
  pip3 <command> [options]

Commands:
  install                     Install packages.
  download                    Download packages.
  uninstall                   Uninstall packages.
  freeze                      Output installed packages in requirements format.
  list                        List installed packages.
  show                        Show information about installed packages.
  check                       Verify installed packages have compatible dependencies.
  config                      Manage local and global configuration.
  search                      Search PyPI for packages.
  cache                       Inspect and manage pip's wheel cache.
  index                       Inspect information available from package indexes.
  wheel                       Build wheels from your requirements.
  hash                        Compute hashes of package archives.
  completion                  A helper command used for command completion.
  debug                       Show information useful for debugging.
  help                        Show help for commands.

General Options:
  -h, --help                  Show help.
  --debug                     Let unhandled exceptions propagate outside the main subroutine, instead of
                              logging them to stderr.
  --isolated                  Run pip in an isolated mode, ignoring environment variables and user
                              configuration.
  --require-virtualenv        Allow pip to only run in a virtual environment; exit with an error otherwise.
  -v, --verbose               Give more output. Option is additive, and can be used up to 3 times.
  -V, --version               Show version and exit.
  -q, --quiet                 Give less output. Option is additive, and can be used up to 3 times
                              (corresponding to WARNING, ERROR, and CRITICAL logging levels).
  --log <path>                Path to a verbose appending log.
  --no-input                  Disable prompting for input.
  --proxy <proxy>             Specify a proxy in the form scheme://[user:passwd@]proxy.server:port.
  --retries <retries>         Maximum number of retries each connection should attempt (default 5 times).
  --timeout <sec>             Set the socket timeout (default 15 seconds).
  --exists-action <action>    Default action when a path already exists: (s)witch, (i)gnore, (w)ipe, (b)ackup,
                              (a)bort.
  --trusted-host <hostname>   Mark this host or host:port pair as trusted, even though it does not have valid
                              or any HTTPS.
  --cert <path>               Path to PEM-encoded CA certificate bundle. If provided, overrides the default.
                              See 'SSL Certificate Verification' in pip documentation for more information.
  --client-cert <path>        Path to SSL client certificate, a single file containing the private key and the
                              certificate in PEM format.
  --cache-dir <dir>           Store the cache data in <dir>.
  --no-cache-dir              Disable the cache.
  --disable-pip-version-check
                              Don't periodically check PyPI to determine whether a new version of pip is
                              available for download. Implied with --no-index.
  --no-color                  Suppress colored output.
  --no-python-version-warning
                              Silence deprecation warnings for upcoming unsupported Pythons.
  --use-feature <feature>     Enable new functionality, that may be backward incompatible.
  --use-deprecated <feature>  Enable deprecated functionality, that will be removed in the future.
np@np-INTEL:~$ /home/np/.local/bin/pip3

Usage:   
  pip3 <command> [options]

Commands:
  install                     Install packages.
  download                    Download packages.
  uninstall                   Uninstall packages.
  freeze                      Output installed packages in requirements format.
  list                        List installed packages.
  show                        Show information about installed packages.
  check                       Verify installed packages have compatible dependencies.
  config                      Manage local and global configuration.
  search                      Search PyPI for packages.
  cache                       Inspect and manage pip's wheel cache.
  index                       Inspect information available from package indexes.
  wheel                       Build wheels from your requirements.
  hash                        Compute hashes of package archives.
  completion                  A helper command used for command completion.
  debug                       Show information useful for debugging.
  help                        Show help for commands.

General Options:
  -h, --help                  Show help.
  --debug                     Let unhandled exceptions propagate outside the main subroutine, instead of
                              logging them to stderr.
  --isolated                  Run pip in an isolated mode, ignoring environment variables and user
                              configuration.
  --require-virtualenv        Allow pip to only run in a virtual environment; exit with an error otherwise.
  -v, --verbose               Give more output. Option is additive, and can be used up to 3 times.
  -V, --version               Show version and exit.
  -q, --quiet                 Give less output. Option is additive, and can be used up to 3 times
                              (corresponding to WARNING, ERROR, and CRITICAL logging levels).
  --log <path>                Path to a verbose appending log.
  --no-input                  Disable prompting for input.
  --proxy <proxy>             Specify a proxy in the form scheme://[user:passwd@]proxy.server:port.
  --retries <retries>         Maximum number of retries each connection should attempt (default 5 times).
  --timeout <sec>             Set the socket timeout (default 15 seconds).
  --exists-action <action>    Default action when a path already exists: (s)witch, (i)gnore, (w)ipe, (b)ackup,
                              (a)bort.
  --trusted-host <hostname>   Mark this host or host:port pair as trusted, even though it does not have valid
                              or any HTTPS.
  --cert <path>               Path to PEM-encoded CA certificate bundle. If provided, overrides the default.
                              See 'SSL Certificate Verification' in pip documentation for more information.
  --client-cert <path>        Path to SSL client certificate, a single file containing the private key and the
                              certificate in PEM format.
  --cache-dir <dir>           Store the cache data in <dir>.
  --no-cache-dir              Disable the cache.
  --disable-pip-version-check
                              Don't periodically check PyPI to determine whether a new version of pip is
                              available for download. Implied with --no-index.
  --no-color                  Suppress colored output.
  --no-python-version-warning
                              Silence deprecation warnings for upcoming unsupported Pythons.
  --use-feature <feature>     Enable new functionality, that may be backward incompatible.
  --use-deprecated <feature>  Enable deprecated functionality, that will be removed in the future.
np@np-INTEL:~$ ^C
np@np-INTEL:~$ cd ~/code/icefall/egs/yesno/ASR
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ./prepare.sh
2022-07-06 22:38:59 (prepare.sh:24:main) dl_dir: /home/np/code/icefall/egs/yesno/ASR/download
2022-07-06 22:38:59 (prepare.sh:27:main) Stage 0: Download data
2022-07-06 22:38:59 (prepare.sh:36:main) Stage 1: Prepare yesno manifest
2022-07-06 22:39:00 (prepare.sh:42:main) Stage 2: Compute fbank for yesno
Traceback (most recent call last):
  File "./local/compute_fbank_yesno.py", line 89, in <module>
    compute_fbank_yesno()
  File "./local/compute_fbank_yesno.py", line 50, in compute_fbank_yesno
    extractor = Fbank(
  File "/home/np/anaconda3/lib/python3.8/site-packages/lhotse/features/kaldi/extractors.py", line 55, in __init__
    self.extractor = Wav2LogFilterBank(**self.config.to_dict()).eval()
  File "/home/np/anaconda3/lib/python3.8/site-packages/lhotse/features/kaldi/layers.py", line 548, in __init__
    from torchaudio.compliance.kaldi import get_mel_banks
  File "/home/np/.local/lib/python3.8/site-packages/torchaudio/__init__.py", line 1, in <module>
    from torchaudio import (  # noqa: F401
  File "/home/np/.local/lib/python3.8/site-packages/torchaudio/_extension.py", line 103, in <module>
    _init_extension()
  File "/home/np/.local/lib/python3.8/site-packages/torchaudio/_extension.py", line 88, in _init_extension
    _load_lib("libtorchaudio")
  File "/home/np/.local/lib/python3.8/site-packages/torchaudio/_extension.py", line 51, in _load_lib
    torch.ops.load_library(path)
  File "/home/np/anaconda3/lib/python3.8/site-packages/torch/_ops.py", line 104, in load_library
    ctypes.CDLL(path)
  File "/home/np/anaconda3/lib/python3.8/ctypes/__init__.py", line 373, in __init__
    self._handle = _dlopen(self._name, mode)
OSError: libcudart.so.10.2: cannot open shared object file: No such file or directory
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ echo $LD_LIBRARY_PATH

np@np-INTEL:~/code/icefall/egs/yesno/ASR$ echo $PATH
/home/np/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/home/np/anaconda3/bin:/usr/local/cuda/bin
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ls /usr/local/cuda
bin                doc   EULA.txt  gds      lib64    nsightee_plugins  nvvm    samples  src      tools
compute-sanitizer  DOCS  extras    include  libnvvp  nvml              README  share    targets  version.json
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ls /usr/local/cuda/lib64/
cmake                         libcufile_static.a           libnppial.so.11.6.3.9   libnpps.so
libaccinj64.so                libcufilt.a                  libnppial_static.a      libnpps.so.11
libaccinj64.so.11.6           libcuinj64.so                libnppicc.so            libnpps.so.11.6.3.9
libaccinj64.so.11.6.124       libcuinj64.so.11.6           libnppicc.so.11         libnpps_static.a
libcheckpoint.so              libcuinj64.so.11.6.124       libnppicc.so.11.6.3.9   libnvblas.so
libcublasLt.so                libculibos.a                 libnppicc_static.a      libnvblas.so.11
libcublasLt.so.11             libcupti.so                  libnppidei.so           libnvblas.so.11.9.2.110
libcublasLt.so.11.9.2.110     libcupti.so.11.6             libnppidei.so.11        libnvjpeg.so
libcublasLt_static.a          libcupti.so.2022.1.1         libnppidei.so.11.6.3.9  libnvjpeg.so.11
libcublas.so                  libcupti_static.a            libnppidei_static.a     libnvjpeg.so.11.6.2.8
libcublas.so.11               libcurand.so                 libnppif.so             libnvjpeg_static.a
libcublas.so.11.9.2.110       libcurand.so.10              libnppif.so.11          libnvperf_host.so
libcublas_static.a            libcurand.so.10.2.9.124      libnppif.so.11.6.3.9    libnvperf_host_static.a
libcudadevrt.a                libcurand_static.a           libnppif_static.a       libnvperf_target.so
libcudart.so                  libcusolver_lapack_static.a  libnppig.so             libnvptxcompiler_static.a
libcudart.so.11.0             libcusolverMg.so             libnppig.so.11          libnvrtc-builtins.so
libcudart.so.11.6.55          libcusolverMg.so.11          libnppig.so.11.6.3.9    libnvrtc-builtins.so.11.6
libcudart_static.a            libcusolverMg.so.11.3.4.124  libnppig_static.a       libnvrtc-builtins.so.11.6.124
libcufft.so                   libcusolver.so               libnppim.so             libnvrtc-builtins_static.a
libcufft.so.10                libcusolver.so.11            libnppim.so.11          libnvrtc.so
libcufft.so.10.7.2.124        libcusolver.so.11.3.4.124    libnppim.so.11.6.3.9    libnvrtc.so.11.2
libcufft_static.a             libcusolver_static.a         libnppim_static.a       libnvrtc.so.11.6.124
libcufft_static_nocallback.a  libcusparse.so               libnppist.so            libnvrtc_static.a
libcufftw.so                  libcusparse.so.11            libnppist.so.11         libnvToolsExt.so
libcufftw.so.10               libcusparse.so.11.7.2.124    libnppist.so.11.6.3.9   libnvToolsExt.so.1
libcufftw.so.10.7.2.124       libcusparse_static.a         libnppist_static.a      libnvToolsExt.so.1.0.0
libcufftw_static.a            liblapack_static.a           libnppisu.so            libOpenCL.so
libcufile_rdma.so             libmetis_static.a            libnppisu.so.11         libOpenCL.so.1
libcufile_rdma.so.1           libnppc.so                   libnppisu.so.11.6.3.9   libOpenCL.so.1.0
libcufile_rdma.so.1.2.1       libnppc.so.11                libnppisu_static.a      libOpenCL.so.1.0.0
libcufile_rdma_static.a       libnppc.so.11.6.3.9          libnppitc.so            libpcsamplingutil.so
libcufile.so                  libnppc_static.a             libnppitc.so.11         stubs
libcufile.so.0                libnppial.so                 libnppitc.so.11.6.3.9
libcufile.so.1.2.1            libnppial.so.11              libnppitc_static.a
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ls /usr/local/cuda/lib64/libcuda
libcudadevrt.a        libcudart.so          libcudart.so.11.0     libcudart.so.11.6.55  libcudart_static.a
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ emacs -nw ~/.bashrc

Command 'emacs' not found, but can be installed with:

sudo snap install emacs        # version 28.1, or
sudo apt  install e3           # version 1:2.71-2
sudo apt  install emacs-gtk    # version 1:26.3+1-1ubuntu2
sudo apt  install emacs-lucid  # version 1:26.3+1-1ubuntu2
sudo apt  install emacs-nox    # version 1:26.3+1-1ubuntu2
sudo apt  install jove         # version 4.17.2.7-1

See 'snap info emacs' for additional versions.

np@np-INTEL:~/code/icefall/egs/yesno/ASR$ nano ~/.bashrc
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ . ~/.bashrc
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ./prepare.sh
2022-07-06 22:40:23 (prepare.sh:24:main) dl_dir: /home/np/code/icefall/egs/yesno/ASR/download
2022-07-06 22:40:23 (prepare.sh:27:main) Stage 0: Download data
2022-07-06 22:40:23 (prepare.sh:36:main) Stage 1: Prepare yesno manifest
2022-07-06 22:40:24 (prepare.sh:42:main) Stage 2: Compute fbank for yesno
Traceback (most recent call last):
  File "./local/compute_fbank_yesno.py", line 89, in <module>
    compute_fbank_yesno()
  File "./local/compute_fbank_yesno.py", line 50, in compute_fbank_yesno
    extractor = Fbank(
  File "/home/np/anaconda3/lib/python3.8/site-packages/lhotse/features/kaldi/extractors.py", line 55, in __init__
    self.extractor = Wav2LogFilterBank(**self.config.to_dict()).eval()
  File "/home/np/anaconda3/lib/python3.8/site-packages/lhotse/features/kaldi/layers.py", line 548, in __init__
    from torchaudio.compliance.kaldi import get_mel_banks
  File "/home/np/.local/lib/python3.8/site-packages/torchaudio/__init__.py", line 1, in <module>
    from torchaudio import (  # noqa: F401
  File "/home/np/.local/lib/python3.8/site-packages/torchaudio/_extension.py", line 103, in <module>
    _init_extension()
  File "/home/np/.local/lib/python3.8/site-packages/torchaudio/_extension.py", line 88, in _init_extension
    _load_lib("libtorchaudio")
  File "/home/np/.local/lib/python3.8/site-packages/torchaudio/_extension.py", line 51, in _load_lib
    torch.ops.load_library(path)
  File "/home/np/anaconda3/lib/python3.8/site-packages/torch/_ops.py", line 104, in load_library
    ctypes.CDLL(path)
  File "/home/np/anaconda3/lib/python3.8/ctypes/__init__.py", line 373, in __init__
    self._handle = _dlopen(self._name, mode)
OSError: libcudart.so.10.2: cannot open shared object file: No such file or directory
np@np-INTEL:~/code/icefall/egs/yesno/ASR$  echo $LD_LIBRARY_PATH
:/usr/local/cuda/lib64
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ls -l /usr/local/cuda/lib64
lrwxrwxrwx 1 root root 24 Dec 17  2021 /usr/local/cuda/lib64 -> targets/x86_64-linux/lib
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ls -l /usr/local/cuda/lib64/libcudart.so.10.2
ls: cannot access '/usr/local/cuda/lib64/libcudart.so.10.2': No such file or directory
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ls -l /usr/local/cuda/lib64/libcudart.so
libcudart.so          libcudart.so.11.0     libcudart.so.11.6.55  
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ls -l /usr/local/cuda/lib64/libcudart.so
libcudart.so          libcudart.so.11.0     libcudart.so.11.6.55  
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ find ~/anaconda3 -name 'libcudart*'
/home/np/anaconda3/pkgs/cudatoolkit-11.1.1-h6406543_8/lib/libcudart.so.11.1.74
/home/np/anaconda3/pkgs/cudatoolkit-11.1.1-h6406543_8/lib/libcudart.so.11.0
/home/np/anaconda3/pkgs/cudatoolkit-11.1.1-h6406543_8/lib/libcudart.so
/home/np/anaconda3/pkgs/cudatoolkit-11.3.1-h2bc3f7f_2/lib/libcudart.so.11.0
/home/np/anaconda3/pkgs/cudatoolkit-11.3.1-h2bc3f7f_2/lib/libcudart.so.11.3.109
/home/np/anaconda3/pkgs/cudatoolkit-11.3.1-h2bc3f7f_2/lib/libcudart.so
/home/np/anaconda3/lib/libcudart.so.11.1.74
/home/np/anaconda3/lib/libcudart.so.11.0
/home/np/anaconda3/lib/libcudart.so
(reverse-i-search)`': ^C
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ^C
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ python
Python 3.8.13 (default, Mar 28 2022, 11:38:47) 
[GCC 7.5.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import torch
tor>>> torch.__version__
'1.8.1'
>>> torch.version()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
TypeError: 'module' object is not callable
>>> torch.version
torch.version
>>> torch.version
<module 'torch.version' from '/home/np/anaconda3/lib/python3.8/site-packages/torch/version.py'>
>>> dir(torch.version)
['__builtins__', '__cached__', '__doc__', '__file__', '__loader__', '__name__', '__package__', '__spec__', '__version__', 'cuda', 'debug', 'git_version', 'hip']
>>> torch.version.__spec__
ModuleSpec(name='torch.version', loader=<_frozen_importlib_external.SourceFileLoader object at 0x7fa871fdd220>, origin='/home/np/anaconda3/lib/python3.8/site-packages/torch/version.py')
>>> torch.version.cuda
'11.1'
>>> import torchaudio
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/np/.local/lib/python3.8/site-packages/torchaudio/__init__.py", line 1, in <module>
    from torchaudio import (  # noqa: F401
  File "/home/np/.local/lib/python3.8/site-packages/torchaudio/_extension.py", line 103, in <module>
    _init_extension()
  File "/home/np/.local/lib/python3.8/site-packages/torchaudio/_extension.py", line 88, in _init_extension
    _load_lib("libtorchaudio")
  File "/home/np/.local/lib/python3.8/site-packages/torchaudio/_extension.py", line 51, in _load_lib
    torch.ops.load_library(path)
  File "/home/np/anaconda3/lib/python3.8/site-packages/torch/_ops.py", line 104, in load_library
    ctypes.CDLL(path)
  File "/home/np/anaconda3/lib/python3.8/ctypes/__init__.py", line 373, in __init__
    self._handle = _dlopen(self._name, mode)
OSError: libcudart.so.10.2: cannot open shared object file: No such file or directory
>>> 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ anaconda install -c pytorch torchaudio
usage: anaconda [-h] [--disable-ssl-warnings] [--show-traceback] [-v] [-q] [-V] [-t TOKEN] [-s SITE]  ...
anaconda: error: argument : invalid choice: 'install' (choose from 'auth', 'label', 'channel', 'config', 'copy', 'download', 'groups', 'login', 'logout', 'move', 'notebook', 'package', 'remove', 'search', 'show', 'update', 'upload', 'whoami')
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ conda install -c pytorch torchaudio
Collecting package metadata (current_repodata.json): done
Solving environment: done

# All requested packages already installed.

np@np-INTEL:~/code/icefall/egs/yesno/ASR$ conda uninstall -c pytorch torchaudio
Collecting package metadata (repodata.json): / 
/ 
done
Solving environment: done



## Package Plan ##

  environment location: /home/np/anaconda3

  removed specs:
    - torchaudio


The following packages will be downloaded:

    package                    |            build
    ---------------------------|-----------------
    conda-package-handling-1.8.1|   py38h7f8727e_0         885 KB
    ------------------------------------------------------------
                                           Total:         885 KB

The following packages will be REMOVED:

  ffmpeg-4.3-hf484d3e_0
  gnutls-3.6.15-he1e5248_0
  lame-3.100-h7b6447c_0
  libiconv-1.16-h7f8727e_2
  libtasn1-4.16.0-h27cfd23_0
  nettle-3.7.3-hbbd107a_1
  openh264-2.1.1-h4ff587b_0
  torchaudio-0.8.1-py38
  tzdata-2022a-hda174b7_0

The following packages will be UPDATED:

  conda-package-han~ conda-forge::conda-package-handling-1~ --> pkgs/main::conda-package-handling-1.8.1-py38h7f8727e_0


Proceed ([y]/n)? 

Downloading and Extracting Packages
conda-package-handli | 885 KB    | ###################################################################### | 100% 
Preparing transaction: done
Verifying transaction: done
Executing transaction: done
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ conda install -c pytorch torchaudio
Collecting package metadata (current_repodata.json): done
Solving environment: done

## Package Plan ##

  environment location: /home/np/anaconda3

  added / updated specs:
    - torchaudio


The following NEW packages will be INSTALLED:

  torchaudio         pytorch/linux-64::torchaudio-0.8.1-py38


Proceed ([y]/n)? y

Preparing transaction: done
Verifying transaction: done
Executing transaction: done
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ python
Python 3.8.13 (default, Mar 28 2022, 11:38:47) 
[GCC 7.5.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import torchaudio
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/np/.local/lib/python3.8/site-packages/torchaudio/__init__.py", line 1, in <module>
    from torchaudio import (  # noqa: F401
  File "/home/np/.local/lib/python3.8/site-packages/torchaudio/_extension.py", line 103, in <module>
    _init_extension()
  File "/home/np/.local/lib/python3.8/site-packages/torchaudio/_extension.py", line 88, in _init_extension
    _load_lib("libtorchaudio")
  File "/home/np/.local/lib/python3.8/site-packages/torchaudio/_extension.py", line 51, in _load_lib
    torch.ops.load_library(path)
  File "/home/np/anaconda3/lib/python3.8/site-packages/torch/_ops.py", line 104, in load_library
    ctypes.CDLL(path)
  File "/home/np/anaconda3/lib/python3.8/ctypes/__init__.py", line 373, in __init__
    self._handle = _dlopen(self._name, mode)
OSError: libcudart.so.10.2: cannot open shared object file: No such file or directory
>>> 
>>> 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ conda install -c pytorch torchaudio cudatoolkit=11.1 pytorch=1.8.1
Collecting package metadata (current_repodata.json): done
Solving environment: done

# All requested packages already installed.

np@np-INTEL:~/code/icefall/egs/yesno/ASR$ conda uninstall -c pytorch torchaudio
Collecting package metadata (repodata.json): done
Solving environment: - \ - 
done


## Package Plan ##

  environment location: /home/np/anaconda3

  removed specs:
    - torchaudio


The following packages will be REMOVED:

  torchaudio-0.8.1-py38


Proceed ([y]/n)? Invalid choice: 
Proceed ([y]/n)? 
Preparing transaction: done
Verifying transaction: done
Executing transaction: done
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ python
Python 3.8.13 (default, Mar 28 2022, 11:38:47) 
[GCC 7.5.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import torchaudio
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/np/.local/lib/python3.8/site-packages/torchaudio/__init__.py", line 1, in <module>
    from torchaudio import (  # noqa: F401
  File "/home/np/.local/lib/python3.8/site-packages/torchaudio/_extension.py", line 103, in <module>
    _init_extension()
  File "/home/np/.local/lib/python3.8/site-packages/torchaudio/_extension.py", line 88, in _init_extension
    _load_lib("libtorchaudio")
  File "/home/np/.local/lib/python3.8/site-packages/torchaudio/_extension.py", line 51, in _load_lib
    torch.ops.load_library(path)
  File "/home/np/anaconda3/lib/python3.8/site-packages/torch/_ops.py", line 104, in load_library
    ctypes.CDLL(path)
  File "/home/np/anaconda3/lib/python3.8/ctypes/__init__.py", line 373, in __init__
    self._handle = _dlopen(self._name, mode)
OSError: libcudart.so.10.2: cannot open shared object file: No such file or directory
>>> 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ pip3 uninstall torchaudio
Found existing installation: torchaudio 0.12.0
Uninstalling torchaudio-0.12.0:
  Would remove:
    /home/np/.local/lib/python3.8/site-packages/torchaudio-0.12.0.dist-info/*
    /home/np/.local/lib/python3.8/site-packages/torchaudio/*
Proceed (Y/n)? y
  Successfully uninstalled torchaudio-0.12.0
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ^C
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ^C
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ conda install -c pytorch torchaudio cudatoolkit=11.1 pytorch=1.8.1
Collecting package metadata (current_repodata.json): done
Solving environment: done

## Package Plan ##

  environment location: /home/np/anaconda3

  added / updated specs:
    - cudatoolkit=11.1
    - pytorch=1.8.1
    - torchaudio


The following NEW packages will be INSTALLED:

  torchaudio         pytorch/linux-64::torchaudio-0.8.1-py38


Proceed ([y]/n)? y

Preparing transaction: done
Verifying transaction: done
Executing transaction: done
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ python
Python 3.8.13 (default, Mar 28 2022, 11:38:47) 
[GCC 7.5.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import torchaudio
>>> 
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ jobs
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ./prepare.sh
2022-07-06 22:47:13 (prepare.sh:24:main) dl_dir: /home/np/code/icefall/egs/yesno/ASR/download
2022-07-06 22:47:13 (prepare.sh:27:main) Stage 0: Download data
2022-07-06 22:47:13 (prepare.sh:36:main) Stage 1: Prepare yesno manifest
2022-07-06 22:47:14 (prepare.sh:42:main) Stage 2: Compute fbank for yesno
2022-07-06 22:47:15,561 INFO [compute_fbank_yesno.py:60] Processing train
Extracting and storing features: 100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 90/90 [00:00<00:00, 283.01it/s]
2022-07-06 22:47:15,896 INFO [compute_fbank_yesno.py:60] Processing test
Extracting and storing features: 100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 30/30 [00:00<00:00, 427.35it/s]
2022-07-06 22:47:16 (prepare.sh:48:main) Stage 3: Prepare lang
2022-07-06 22:47:17 (prepare.sh:60:main) Stage 4: Prepare G
/tmp/pip-install-j6dhjg47/kaldilm_74148b2738ab40148b530837cf874916/kaldilm/csrc/arpa_file_parser.cc:void kaldilm::ArpaFileParser::Read(std::istream&):79
[I] Reading \data\ section.
/tmp/pip-install-j6dhjg47/kaldilm_74148b2738ab40148b530837cf874916/kaldilm/csrc/arpa_file_parser.cc:void kaldilm::ArpaFileParser::Read(std::istream&):140
[I] Reading \1-grams: section.
2022-07-06 22:47:17 (prepare.sh:86:main) Stage 5: Compile HLG
2022-07-06 22:47:18,177 INFO [compile_hlg.py:123] Processing data/lang_phone
2022-07-06 22:47:18,177 INFO [lexicon.py:179] Converting L.pt to Linv.pt
2022-07-06 22:47:18,179 INFO [compile_hlg.py:48] Building ctc_topo. max_token_id: 3
2022-07-06 22:47:18,179 INFO [compile_hlg.py:52] Loading G.fst.txt
2022-07-06 22:47:18,185 INFO [compile_hlg.py:62] Intersecting L and G
2022-07-06 22:47:18,186 INFO [compile_hlg.py:64] LG shape: (4, None)
2022-07-06 22:47:18,186 INFO [compile_hlg.py:66] Connecting LG
2022-07-06 22:47:18,186 INFO [compile_hlg.py:68] LG shape after k2.connect: (4, None)
2022-07-06 22:47:18,186 INFO [compile_hlg.py:70] <class 'torch.Tensor'>
2022-07-06 22:47:18,186 INFO [compile_hlg.py:71] Determinizing LG
2022-07-06 22:47:18,189 INFO [compile_hlg.py:74] <class '_k2.ragged.RaggedTensor'>
2022-07-06 22:47:18,189 INFO [compile_hlg.py:76] Connecting LG after k2.determinize
2022-07-06 22:47:18,189 INFO [compile_hlg.py:79] Removing disambiguation symbols on LG
2022-07-06 22:47:18,190 INFO [compile_hlg.py:90] LG shape after k2.remove_epsilon: (6, None)
2022-07-06 22:47:18,190 INFO [compile_hlg.py:95] Arc sorting LG
2022-07-06 22:47:18,190 INFO [compile_hlg.py:98] Composing H and LG
2022-07-06 22:47:18,191 INFO [compile_hlg.py:105] Connecting LG
2022-07-06 22:47:18,191 INFO [compile_hlg.py:108] Arc sorting LG
2022-07-06 22:47:18,191 INFO [compile_hlg.py:110] HLG.shape: (8, None)
2022-07-06 22:47:18,191 INFO [compile_hlg.py:126] Saving HLG.pt to data/lang_phone
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ export CUDA_VISIBLE_DEVICES=""
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ./tdnn/train.py
2022-07-06 22:48:29,292 INFO [train.py:483] Training started
2022-07-06 22:48:29,292 INFO [train.py:484] {'exp_dir': PosixPath('tdnn/exp'), 'lang_dir': PosixPath('data/lang_phone'), 'lr': 0.01, 'feature_dim': 23, 'weight_decay': 1e-06, 'start_epoch': 0, 'best_train_loss': inf, 'best_valid_loss': inf, 'best_train_epoch': -1, 'best_valid_epoch': -1, 'batch_idx_train': 0, 'log_interval': 10, 'reset_interval': 20, 'valid_interval': 10, 'beam_size': 10, 'reduction': 'sum', 'use_double_scores': True, 'world_size': 1, 'master_port': 12354, 'tensorboard': True, 'num_epochs': 15, 'seed': 42, 'feature_dir': PosixPath('data/fbank'), 'max_duration': 30.0, 'bucketing_sampler': False, 'num_buckets': 10, 'concatenate_cuts': False, 'duration_factor': 1.0, 'gap': 1.0, 'on_the_fly_feats': False, 'shuffle': True, 'return_cuts': True, 'num_workers': 2, 'env_info': {'k2-version': '1.15.1', 'k2-build-type': 'Release', 'k2-with-cuda': True, 'k2-git-sha1': 'b173c11ba379e2da0056281fe6b2d56f081419be', 'k2-git-date': 'Mon Apr 18 16:10:45 2022', 'lhotse-version': '1.4.0', 'torch-version': '1.8.1', 'torch-cuda-available': False, 'torch-cuda-version': '11.1', 'python-version': '3.8', 'icefall-git-branch': 'master', 'icefall-git-sha1': '8e0b7ea-clean', 'icefall-git-date': 'Sun Jul 3 20:59:37 2022', 'icefall-path': '/home/np/code/icefall', 'k2-path': '/home/np/anaconda3/lib/python3.8/site-packages/k2/__init__.py', 'lhotse-path': '/home/np/anaconda3/lib/python3.8/site-packages/lhotse/__init__.py', 'hostname': 'np-INTEL', 'IP address': '127.0.1.1'}}
2022-07-06 22:48:29,293 INFO [lexicon.py:176] Loading pre-compiled data/lang_phone/Linv.pt
2022-07-06 22:48:29,294 INFO [train.py:497] device: cpu
2022-07-06 22:48:29,296 INFO [asr_datamodule.py:146] About to get train cuts
2022-07-06 22:48:29,296 INFO [asr_datamodule.py:244] About to get train cuts
2022-07-06 22:48:29,332 INFO [asr_datamodule.py:149] About to create train dataset
2022-07-06 22:48:29,332 INFO [asr_datamodule.py:199] Using SingleCutSampler.
2022-07-06 22:48:29,332 INFO [asr_datamodule.py:205] About to create train dataloader
2022-07-06 22:48:29,332 INFO [asr_datamodule.py:218] About to get test cuts
2022-07-06 22:48:29,332 INFO [asr_datamodule.py:252] About to get test cuts
2022-07-06 22:48:29,412 INFO [train.py:422] Epoch 0, batch 0, loss[loss=1.069, over 2392.00 frames.], tot_loss[loss=1.069, over 2392.00 frames.], batch size: 4
2022-07-06 22:48:29,575 INFO [train.py:422] Epoch 0, batch 10, loss[loss=0.5428, over 2644.00 frames.], tot_loss[loss=0.7374, over 22307.41 frames.], batch size: 4
2022-07-06 22:48:29,831 INFO [train.py:446] Epoch 0, validation loss=0.9023, over 18067.00 frames.
2022-07-06 22:48:29,988 INFO [train.py:422] Epoch 0, batch 20, loss[loss=0.2635, over 2536.00 frames.], tot_loss[loss=0.5025, over 34017.92 frames.], batch size: 4
2022-07-06 22:48:30,167 INFO [train.py:446] Epoch 0, validation loss=0.4273, over 18067.00 frames.
2022-07-06 22:48:30,203 INFO [checkpoint.py:75] Saving checkpoint to tdnn/exp/epoch-0.pt
2022-07-06 22:48:30,274 INFO [train.py:422] Epoch 1, batch 0, loss[loss=0.1921, over 2504.00 frames.], tot_loss[loss=0.1921, over 2504.00 frames.], batch size: 4
2022-07-06 22:48:30,430 INFO [train.py:422] Epoch 1, batch 10, loss[loss=0.114, over 2524.00 frames.], tot_loss[loss=0.1537, over 22674.16 frames.], batch size: 4
2022-07-06 22:48:30,549 INFO [train.py:446] Epoch 1, validation loss=0.1307, over 18067.00 frames.
2022-07-06 22:48:30,674 INFO [train.py:422] Epoch 1, batch 20, loss[loss=0.07784, over 2528.00 frames.], tot_loss[loss=0.114, over 34578.41 frames.], batch size: 4
2022-07-06 22:48:30,837 INFO [train.py:446] Epoch 1, validation loss=0.0737, over 18067.00 frames.
2022-07-06 22:48:30,873 INFO [checkpoint.py:75] Saving checkpoint to tdnn/exp/epoch-1.pt
2022-07-06 22:48:30,950 INFO [train.py:422] Epoch 2, batch 0, loss[loss=0.06599, over 2892.00 frames.], tot_loss[loss=0.06599, over 2892.00 frames.], batch size: 4
2022-07-06 22:48:31,060 INFO [train.py:422] Epoch 2, batch 10, loss[loss=0.04536, over 2524.00 frames.], tot_loss[loss=0.05296, over 22785.48 frames.], batch size: 4
2022-07-06 22:48:31,188 INFO [train.py:446] Epoch 2, validation loss=0.04246, over 18067.00 frames.
2022-07-06 22:48:31,305 INFO [train.py:422] Epoch 2, batch 20, loss[loss=0.03477, over 2632.00 frames.], tot_loss[loss=0.0455, over 34398.54 frames.], batch size: 4
2022-07-06 22:48:31,428 INFO [train.py:446] Epoch 2, validation loss=0.03212, over 18067.00 frames.
2022-07-06 22:48:31,454 INFO [checkpoint.py:75] Saving checkpoint to tdnn/exp/epoch-2.pt
2022-07-06 22:48:31,528 INFO [train.py:422] Epoch 3, batch 0, loss[loss=0.04487, over 2592.00 frames.], tot_loss[loss=0.04487, over 2592.00 frames.], batch size: 4
2022-07-06 22:48:31,654 INFO [train.py:422] Epoch 3, batch 10, loss[loss=0.02686, over 2416.00 frames.], tot_loss[loss=0.02842, over 22740.75 frames.], batch size: 4
2022-07-06 22:48:31,767 INFO [train.py:446] Epoch 3, validation loss=0.02401, over 18067.00 frames.
2022-07-06 22:48:31,878 INFO [train.py:422] Epoch 3, batch 20, loss[loss=0.01985, over 2580.00 frames.], tot_loss[loss=0.02569, over 34481.27 frames.], batch size: 4
2022-07-06 22:48:32,010 INFO [train.py:446] Epoch 3, validation loss=0.02134, over 18067.00 frames.
2022-07-06 22:48:32,037 INFO [checkpoint.py:75] Saving checkpoint to tdnn/exp/epoch-3.pt
2022-07-06 22:48:32,106 INFO [train.py:422] Epoch 4, batch 0, loss[loss=0.02065, over 2600.00 frames.], tot_loss[loss=0.02065, over 2600.00 frames.], batch size: 4
2022-07-06 22:48:32,220 INFO [train.py:422] Epoch 4, batch 10, loss[loss=0.01717, over 2644.00 frames.], tot_loss[loss=0.01984, over 22414.43 frames.], batch size: 4
2022-07-06 22:48:32,343 INFO [train.py:446] Epoch 4, validation loss=0.0207, over 18067.00 frames.
2022-07-06 22:48:32,457 INFO [train.py:422] Epoch 4, batch 20, loss[loss=0.01604, over 2300.00 frames.], tot_loss[loss=0.01857, over 34060.19 frames.], batch size: 4
2022-07-06 22:48:32,584 INFO [train.py:446] Epoch 4, validation loss=0.01567, over 18067.00 frames.
2022-07-06 22:48:32,615 INFO [checkpoint.py:75] Saving checkpoint to tdnn/exp/epoch-4.pt
2022-07-06 22:48:32,706 INFO [train.py:422] Epoch 5, batch 0, loss[loss=0.01535, over 2392.00 frames.], tot_loss[loss=0.01535, over 2392.00 frames.], batch size: 4
2022-07-06 22:48:32,843 INFO [train.py:422] Epoch 5, batch 10, loss[loss=0.01363, over 2536.00 frames.], tot_loss[loss=0.01508, over 22236.91 frames.], batch size: 4
2022-07-06 22:48:32,970 INFO [train.py:446] Epoch 5, validation loss=0.0152, over 18067.00 frames.
2022-07-06 22:48:33,117 INFO [train.py:422] Epoch 5, batch 20, loss[loss=0.01413, over 2304.00 frames.], tot_loss[loss=0.01611, over 34467.85 frames.], batch size: 4
2022-07-06 22:48:33,240 INFO [train.py:446] Epoch 5, validation loss=0.01432, over 18067.00 frames.
2022-07-06 22:48:33,263 INFO [checkpoint.py:75] Saving checkpoint to tdnn/exp/epoch-5.pt
2022-07-06 22:48:33,340 INFO [train.py:422] Epoch 6, batch 0, loss[loss=0.01304, over 2536.00 frames.], tot_loss[loss=0.01304, over 2536.00 frames.], batch size: 4
2022-07-06 22:48:33,471 INFO [train.py:422] Epoch 6, batch 10, loss[loss=0.01342, over 2416.00 frames.], tot_loss[loss=0.01269, over 21806.70 frames.], batch size: 4
2022-07-06 22:48:33,626 INFO [train.py:446] Epoch 6, validation loss=0.01662, over 18067.00 frames.
2022-07-06 22:48:33,776 INFO [train.py:422] Epoch 6, batch 20, loss[loss=0.01362, over 2144.00 frames.], tot_loss[loss=0.01255, over 34105.27 frames.], batch size: 4
2022-07-06 22:48:33,911 INFO [train.py:446] Epoch 6, validation loss=0.01257, over 18067.00 frames.
2022-07-06 22:48:33,943 INFO [checkpoint.py:75] Saving checkpoint to tdnn/exp/epoch-6.pt
2022-07-06 22:48:34,018 INFO [train.py:422] Epoch 7, batch 0, loss[loss=0.01692, over 2424.00 frames.], tot_loss[loss=0.01692, over 2424.00 frames.], batch size: 4
2022-07-06 22:48:34,163 INFO [train.py:422] Epoch 7, batch 10, loss[loss=0.01133, over 2524.00 frames.], tot_loss[loss=0.01199, over 22057.11 frames.], batch size: 4
2022-07-06 22:48:34,301 INFO [train.py:446] Epoch 7, validation loss=0.01222, over 18067.00 frames.
2022-07-06 22:48:34,409 INFO [train.py:422] Epoch 7, batch 20, loss[loss=0.01104, over 2528.00 frames.], tot_loss[loss=0.01162, over 34003.68 frames.], batch size: 4
2022-07-06 22:48:34,535 INFO [train.py:446] Epoch 7, validation loss=0.01172, over 18067.00 frames.
2022-07-06 22:48:34,560 INFO [checkpoint.py:75] Saving checkpoint to tdnn/exp/epoch-7.pt
2022-07-06 22:48:34,648 INFO [train.py:422] Epoch 8, batch 0, loss[loss=0.01071, over 2644.00 frames.], tot_loss[loss=0.01071, over 2644.00 frames.], batch size: 4
2022-07-06 22:48:34,767 INFO [train.py:422] Epoch 8, batch 10, loss[loss=0.0107, over 2524.00 frames.], tot_loss[loss=0.01063, over 22531.14 frames.], batch size: 4
2022-07-06 22:48:34,901 INFO [train.py:446] Epoch 8, validation loss=0.01198, over 18067.00 frames.
2022-07-06 22:48:35,009 INFO [train.py:422] Epoch 8, batch 20, loss[loss=0.01053, over 2592.00 frames.], tot_loss[loss=0.01164, over 34397.64 frames.], batch size: 4
2022-07-06 22:48:35,142 INFO [train.py:446] Epoch 8, validation loss=0.01153, over 18067.00 frames.
2022-07-06 22:48:35,165 INFO [checkpoint.py:75] Saving checkpoint to tdnn/exp/epoch-8.pt
2022-07-06 22:48:35,238 INFO [train.py:422] Epoch 9, batch 0, loss[loss=0.01081, over 2572.00 frames.], tot_loss[loss=0.01081, over 2572.00 frames.], batch size: 4
2022-07-06 22:48:35,351 INFO [train.py:422] Epoch 9, batch 10, loss[loss=0.01019, over 2592.00 frames.], tot_loss[loss=0.01039, over 22631.11 frames.], batch size: 4
2022-07-06 22:48:35,473 INFO [train.py:446] Epoch 9, validation loss=0.01133, over 18067.00 frames.
2022-07-06 22:48:35,579 INFO [train.py:422] Epoch 9, batch 20, loss[loss=0.01095, over 2440.00 frames.], tot_loss[loss=0.01058, over 34246.94 frames.], batch size: 4
2022-07-06 22:48:35,709 INFO [train.py:446] Epoch 9, validation loss=0.01111, over 18067.00 frames.
2022-07-06 22:48:35,734 INFO [checkpoint.py:75] Saving checkpoint to tdnn/exp/epoch-9.pt
2022-07-06 22:48:35,824 INFO [train.py:422] Epoch 10, batch 0, loss[loss=0.009717, over 2704.00 frames.], tot_loss[loss=0.009717, over 2704.00 frames.], batch size: 4
2022-07-06 22:48:35,973 INFO [train.py:422] Epoch 10, batch 10, loss[loss=0.01047, over 2524.00 frames.], tot_loss[loss=0.01016, over 22901.82 frames.], batch size: 4
2022-07-06 22:48:36,137 INFO [train.py:446] Epoch 10, validation loss=0.01111, over 18067.00 frames.
2022-07-06 22:48:36,283 INFO [train.py:422] Epoch 10, batch 20, loss[loss=0.01065, over 2424.00 frames.], tot_loss[loss=0.01012, over 35008.46 frames.], batch size: 4
2022-07-06 22:48:36,448 INFO [train.py:446] Epoch 10, validation loss=0.01127, over 18067.00 frames.
2022-07-06 22:48:36,473 INFO [checkpoint.py:75] Saving checkpoint to tdnn/exp/epoch-10.pt
2022-07-06 22:48:36,552 INFO [train.py:422] Epoch 11, batch 0, loss[loss=0.01376, over 2704.00 frames.], tot_loss[loss=0.01376, over 2704.00 frames.], batch size: 4
2022-07-06 22:48:36,703 INFO [train.py:422] Epoch 11, batch 10, loss[loss=0.01022, over 2524.00 frames.], tot_loss[loss=0.01046, over 22058.21 frames.], batch size: 4
2022-07-06 22:48:36,818 INFO [train.py:446] Epoch 11, validation loss=0.01094, over 18067.00 frames.
2022-07-06 22:48:36,929 INFO [train.py:422] Epoch 11, batch 20, loss[loss=0.00992, over 2660.00 frames.], tot_loss[loss=0.01012, over 34177.29 frames.], batch size: 4
2022-07-06 22:48:37,053 INFO [train.py:446] Epoch 11, validation loss=0.01127, over 18067.00 frames.
2022-07-06 22:48:37,078 INFO [checkpoint.py:75] Saving checkpoint to tdnn/exp/epoch-11.pt
2022-07-06 22:48:37,161 INFO [train.py:422] Epoch 12, batch 0, loss[loss=0.009684, over 2668.00 frames.], tot_loss[loss=0.009684, over 2668.00 frames.], batch size: 4
2022-07-06 22:48:37,277 INFO [train.py:422] Epoch 12, batch 10, loss[loss=0.01019, over 2524.00 frames.], tot_loss[loss=0.00982, over 22554.82 frames.], batch size: 4
2022-07-06 22:48:37,440 INFO [train.py:446] Epoch 12, validation loss=0.01085, over 18067.00 frames.
2022-07-06 22:48:37,564 INFO [train.py:422] Epoch 12, batch 20, loss[loss=0.009592, over 2660.00 frames.], tot_loss[loss=0.009833, over 35043.59 frames.], batch size: 4
2022-07-06 22:48:37,699 INFO [train.py:446] Epoch 12, validation loss=0.01076, over 18067.00 frames.
2022-07-06 22:48:37,725 INFO [checkpoint.py:75] Saving checkpoint to tdnn/exp/epoch-12.pt
2022-07-06 22:48:37,816 INFO [train.py:422] Epoch 13, batch 0, loss[loss=0.009097, over 2828.00 frames.], tot_loss[loss=0.009097, over 2828.00 frames.], batch size: 4
2022-07-06 22:48:37,920 INFO [train.py:422] Epoch 13, batch 10, loss[loss=0.01001, over 2524.00 frames.], tot_loss[loss=0.009816, over 22373.10 frames.], batch size: 4
2022-07-06 22:48:38,051 INFO [train.py:446] Epoch 13, validation loss=0.01102, over 18067.00 frames.
2022-07-06 22:48:38,181 INFO [train.py:422] Epoch 13, batch 20, loss[loss=0.01059, over 2384.00 frames.], tot_loss[loss=0.009866, over 34602.75 frames.], batch size: 4
2022-07-06 22:48:38,308 INFO [train.py:446] Epoch 13, validation loss=0.01077, over 18067.00 frames.
2022-07-06 22:48:38,335 INFO [checkpoint.py:75] Saving checkpoint to tdnn/exp/epoch-13.pt
2022-07-06 22:48:38,430 INFO [train.py:422] Epoch 14, batch 0, loss[loss=0.009776, over 2592.00 frames.], tot_loss[loss=0.009776, over 2592.00 frames.], batch size: 4
2022-07-06 22:48:38,542 INFO [train.py:422] Epoch 14, batch 10, loss[loss=0.01099, over 2300.00 frames.], tot_loss[loss=0.009688, over 22613.10 frames.], batch size: 4
2022-07-06 22:48:38,669 INFO [train.py:446] Epoch 14, validation loss=0.01075, over 18067.00 frames.
2022-07-06 22:48:38,810 INFO [train.py:422] Epoch 14, batch 20, loss[loss=0.009934, over 2552.00 frames.], tot_loss[loss=0.009853, over 34097.70 frames.], batch size: 4
2022-07-06 22:48:38,939 INFO [train.py:446] Epoch 14, validation loss=0.01081, over 18067.00 frames.
2022-07-06 22:48:38,973 INFO [checkpoint.py:75] Saving checkpoint to tdnn/exp/epoch-14.pt
2022-07-06 22:48:38,974 INFO [train.py:557] Done!
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ ./tdnn/decode.py
2022-07-06 22:48:56,657 INFO [decode.py:263] Decoding started
2022-07-06 22:48:56,658 INFO [decode.py:264] {'exp_dir': PosixPath('tdnn/exp'), 'lang_dir': PosixPath('data/lang_phone'), 'lm_dir': PosixPath('data/lm'), 'feature_dim': 23, 'search_beam': 20, 'output_beam': 8, 'min_active_states': 30, 'max_active_states': 10000, 'use_double_scores': True, 'epoch': 14, 'avg': 2, 'export': False, 'feature_dir': PosixPath('data/fbank'), 'max_duration': 30.0, 'bucketing_sampler': False, 'num_buckets': 10, 'concatenate_cuts': False, 'duration_factor': 1.0, 'gap': 1.0, 'on_the_fly_feats': False, 'shuffle': True, 'return_cuts': True, 'num_workers': 2, 'env_info': {'k2-version': '1.15.1', 'k2-build-type': 'Release', 'k2-with-cuda': True, 'k2-git-sha1': 'b173c11ba379e2da0056281fe6b2d56f081419be', 'k2-git-date': 'Mon Apr 18 16:10:45 2022', 'lhotse-version': '1.4.0', 'torch-version': '1.8.1', 'torch-cuda-available': False, 'torch-cuda-version': '11.1', 'python-version': '3.8', 'icefall-git-branch': 'master', 'icefall-git-sha1': '8e0b7ea-clean', 'icefall-git-date': 'Sun Jul 3 20:59:37 2022', 'icefall-path': '/home/np/code/icefall', 'k2-path': '/home/np/anaconda3/lib/python3.8/site-packages/k2/__init__.py', 'lhotse-path': '/home/np/anaconda3/lib/python3.8/site-packages/lhotse/__init__.py', 'hostname': 'np-INTEL', 'IP address': '127.0.1.1'}}
2022-07-06 22:48:56,658 INFO [lexicon.py:176] Loading pre-compiled data/lang_phone/Linv.pt
2022-07-06 22:48:56,659 INFO [decode.py:273] device: cpu
2022-07-06 22:48:56,661 INFO [decode.py:293] averaging ['tdnn/exp/epoch-13.pt', 'tdnn/exp/epoch-14.pt']
2022-07-06 22:48:56,666 INFO [asr_datamodule.py:218] About to get test cuts
2022-07-06 22:48:56,666 INFO [asr_datamodule.py:252] About to get test cuts
2022-07-06 22:48:56,800 INFO [decode.py:203] batch 0/?, cuts processed until now is 4
2022-07-06 22:48:56,888 INFO [decode.py:241] The transcripts are stored in tdnn/exp/recogs-test_set.txt
2022-07-06 22:48:56,888 INFO [utils.py:420] [test_set] %WER 0.42% [1 / 240, 0 ins, 1 del, 0 sub ]
2022-07-06 22:48:56,889 INFO [decode.py:249] Wrote detailed error stats to tdnn/exp/errs-test_set.txt
2022-07-06 22:48:56,889 INFO [decode.py:320] Done!
np@np-INTEL:~/code/icefall/egs/yesno/ASR$ pico tdnn/exp/recogs-test_set.txt
np@np-INTEL:~/code/icefall/egs/yesno/ASR$

np@np-INTEL:~/code/icefall/egs/yesno/ASR$ pico tdnn/exp/recogs-test_set.txtnp@np-INTEL:~/code/icefall/egs/yesno/ASR$ pico tdnn/exp/recogs-test_set.txt

ref=['NO', 'YES', 'NO', 'NO', 'NO', 'YES', 'NO', 'NO']
hyp=['NO', 'YES', 'NO', 'NO', 'NO', 'YES', 'NO', 'NO']
ref=['YES', 'NO', 'NO', 'YES', 'NO', 'YES', 'YES', 'YES']
hyp=['YES', 'NO', 'NO', 'YES', 'NO', 'YES', 'YES', 'YES']
ref=['YES', 'YES', 'NO', 'NO', 'YES', 'NO', 'YES', 'YES']
hyp=['YES', 'YES', 'NO', 'NO', 'YES', 'NO', 'YES', 'YES']
ref=['YES', 'YES', 'NO', 'YES', 'YES', 'NO', 'NO', 'YES']
hyp=['YES', 'YES', 'NO', 'YES', 'YES', 'NO', 'NO', 'YES']
ref=['YES', 'NO', 'NO', 'NO', 'NO', 'NO', 'NO', 'NO']
hyp=['YES', 'NO', 'NO', 'NO', 'NO', 'NO', 'NO', 'NO']
ref=['YES', 'YES', 'YES', 'YES', 'YES', 'YES', 'YES', 'YES']
hyp=['YES', 'YES', 'YES', 'YES', 'YES', 'YES', 'YES', 'YES']
ref=['YES', 'NO', 'YES', 'YES', 'YES', 'YES', 'NO', 'YES']
hyp=['YES', 'NO', 'YES', 'YES', 'YES', 'YES', 'NO', 'YES']
ref=['NO', 'YES', 'YES', 'NO', 'NO', 'YES', 'YES', 'YES']
hyp=['NO', 'YES', 'YES', 'NO', 'NO', 'YES', 'YES', 'YES']
ref=['NO', 'YES', 'NO', 'NO', 'YES', 'NO', 'YES', 'NO']
hyp=['NO', 'YES', 'NO', 'NO', 'YES', 'NO', 'YES', 'NO']
ref=['NO', 'YES', 'NO', 'YES', 'NO', 'NO', 'NO', 'NO']
hyp=['NO', 'YES', 'NO', 'YES', 'NO', 'NO', 'NO']
ref=['YES', 'YES', 'NO', 'YES', 'NO', 'YES', 'NO', 'NO']
hyp=['YES', 'YES', 'NO', 'YES', 'NO', 'YES', 'NO', 'NO']
ref=['YES', 'YES', 'YES', 'YES', 'YES', 'NO', 'NO', 'NO']
hyp=['YES', 'YES', 'YES', 'YES', 'YES', 'NO', 'NO', 'NO']
ref=['NO', 'NO', 'NO', 'YES', 'NO', 'NO', 'NO', 'YES']
hyp=['NO', 'NO', 'NO', 'YES', 'NO', 'NO', 'NO', 'YES']
ref=['NO', 'NO', 'YES', 'NO', 'YES', 'NO', 'NO', 'YES']
hyp=['NO', 'NO', 'YES', 'NO', 'YES', 'NO', 'NO', 'YES']
ref=['YES', 'YES', 'YES', 'YES', 'NO', 'NO', 'YES', 'NO']
hyp=['YES', 'YES', 'YES', 'YES', 'NO', 'NO', 'YES', 'NO']
ref=['YES', 'YES', 'YES', 'NO', 'NO', 'YES', 'NO', 'YES']
hyp=['YES', 'YES', 'YES', 'NO', 'NO', 'YES', 'NO', 'YES']
ref=['NO', 'NO', 'YES', 'YES', 'YES', 'NO', 'NO', 'NO']
hyp=['NO', 'NO', 'YES', 'YES', 'YES', 'NO', 'NO', 'NO']
ref=['NO', 'NO', 'YES', 'NO', 'NO', 'YES', 'YES', 'YES']
hyp=['NO', 'NO', 'YES', 'NO', 'NO', 'YES', 'YES', 'YES']
ref=['NO', 'YES', 'NO', 'YES', 'YES', 'YES', 'NO', 'NO']
hyp=['NO', 'YES', 'NO', 'YES', 'YES', 'YES', 'NO', 'NO']
ref=['NO', 'NO', 'YES', 'YES', 'NO', 'YES', 'YES', 'NO']
hyp=['NO', 'NO', 'YES', 'YES', 'NO', 'YES', 'YES', 'NO']
ref=['NO', 'NO', 'YES', 'NO', 'NO', 'NO', 'YES', 'NO']
hyp=['NO', 'NO', 'YES', 'NO', 'NO', 'NO', 'YES', 'NO']
ref=['YES', 'YES', 'YES', 'NO', 'YES', 'NO', 'YES', 'NO']
hyp=['YES', 'YES', 'YES', 'NO', 'YES', 'NO', 'YES', 'NO']
ref=['NO', 'YES', 'YES', 'YES', 'NO', 'NO', 'YES', 'NO']
hyp=['NO', 'YES', 'YES', 'YES', 'NO', 'NO', 'YES', 'NO']
ref=['YES', 'NO', 'NO', 'NO', 'NO', 'NO', 'YES', 'YES']
hyp=['YES', 'NO', 'NO', 'NO', 'NO', 'NO', 'YES', 'YES']
ref=['YES', 'YES', 'NO', 'YES', 'YES', 'YES', 'YES', 'NO']
hyp=['YES', 'YES', 'NO', 'YES', 'YES', 'YES', 'YES', 'NO']
ref=['YES', 'YES', 'NO', 'NO', 'NO', 'YES', 'YES', 'YES']
hyp=['YES', 'YES', 'NO', 'NO', 'NO', 'YES', 'YES', 'YES']
ref=['NO', 'YES', 'YES', 'YES', 'YES', 'NO', 'YES', 'NO']
hyp=['NO', 'YES', 'YES', 'YES', 'YES', 'NO', 'YES', 'NO']
ref=['YES', 'NO', 'YES', 'YES', 'NO', 'YES', 'YES', 'YES']
hyp=['YES', 'NO', 'YES', 'YES', 'NO', 'YES', 'YES', 'YES']