Skip to content

How to speed-up feature extraction? #440

Answered by desh2608
desh2608 asked this question in Q&A
Discussion options

You must be logged in to vote

Answer by @pzelasko:

  1. (simplest) increase the number of jobs for feature extraction
  2. Use GPU to accelerate feature extraction; you will need to pip install kaldifeat for this though. See here for the relevant method + example in Lhotse: https://github.com/lhotse-speech/lhotse/blob/master/lhotse/cut.py#L3358
  3. You can use on-the-fly feature extraction. It might require a bit more IO but possibly increasing num_workers in DataLoader will offset that, if you notice a slow-down in training. All the changes you need to do are here:
    https://github.com/k2-fsa/icefall/blob/master/egs/librispeech/ASR/tdnn_lstm_ctc/asr_datamodule.py#L259:L267

Replies: 2 comments 1 reply

Comment options

desh2608
Nov 2, 2021
Collaborator Author

You must be logged in to vote
1 reply
@pzelasko
Comment options

Answer selected by desh2608
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants