Coder Social home page Coder Social logo

featxtra's Introduction

Featxtra

The featxtra toolbox lists a set of front-end tools and Signal Processing functions for Kaldi.

The toolbox includes:

  • feature extraction for speech signals
    • Gammatone Frequency Representation, Gammatone Frequency Cepstral Coefficients
    • Gabor Features
    • DCT features (apply on ltsv, voicing stream)
  • Voice Activity Detection
  • additional signal filter operations

List of Functions

featbin

  • featbin/compute-gtf-feats
    • extract Gammatone Frequency Representation (GTF)
    • extract Gammatone Frequency Cepstral Coefficients (GFCC)
  • featbin/compute-gabor-feats
    • extract Gabor Features (GBF)
  • featbin/compute-dct-feats
    • extract DCT Features from time domain signal
  • featbin/apply-arma
    • apply Auto-Regressive Moving Average (ARMA) filtering on a spectral representation (e.g GTF )
  • featbin/apply-ltsv
    • apply Long-Term Spectral Variabilityi (LTSV) stream on spectral representation (e.g GTF )
  • featbin/apply-vad
    • apply Voice Activity Detection (VAD) using voicing and LTSV probability
  • featbin/extract-dims
    • extract specified dimension range out of a feature matrix

feat

  • feat/feature-gtf
    • GTF and GFCC feature implementation code

transform

  • transform/featxtra-functions
    • additional signal processing functions

Instructions to run

  1. Modify the Makefile in directories feat, featbin, and transform as follow:
  • feat/Makefile should include feature-dctf.o feature-gtf.o feature-gabor.o under OBJFILES variable.
  • featbin/Makefile should include compute-dctf-feats compute-gtf-feats compute-gabor-feats apply-arma apply-ltsv apply-nccf-to-pov apply-vad-merged apply-vad extract-dims under the BINFILES variable.
  • transform/Makefile should include featxtra-functions.o under the OBJFILES variable.
  1. Add the following code in the src/feat/feature-window.cc file
void ExtractWaveformRemainder(const VectorBase<BaseFloat> &wave,
                              const FrameExtractionOptions &opts,
                              Vector<BaseFloat> *wave_remainder) {
  int32 frame_shift = opts.WindowShift();
  int32 num_frames = NumFrames(wave.Dim(), opts);
  // offset is the amount at the start that has been extracted.
  int32 offset = num_frames * frame_shift;
  KALDI_ASSERT(wave_remainder != NULL);
  int32 remaining_len = wave.Dim() - offset;
  wave_remainder->Resize(remaining_len);
  KALDI_ASSERT(remaining_len >= 0);
  if (remaining_len > 0)
    wave_remainder->CopyFromVec(SubVector<BaseFloat>(wave, offset, remaining_len));
}
  1. Add the following code in the src/featbin/feature-window.h file
// ExtractWaveformRemainder is useful if the waveform is coming in segments.
// It extracts the bit of the waveform at the end of this block that you
// would have to append the next bit of waveform to, if you wanted to have
// the same effect as everything being in one big block.
void ExtractWaveformRemainder(const VectorBase<BaseFloat> &wave,
                              const FrameExtractionOptions &opts,
                              Vector<BaseFloat> *wave_remainder);

Steps 2 and 3 are done because of this commit in the kaldi-asr project.

After these steps just run the make command again in the src directory to finally integrate these in your kaldi project.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.