inpro.features
Class PitchAndPowerDumper

java.lang.Object
  extended by inpro.features.PitchAndPowerDumper
All Implemented Interfaces:
edu.cmu.sphinx.instrumentation.Resetable, edu.cmu.sphinx.util.props.Configurable, SignalFeatureListener, java.util.EventListener

public class PitchAndPowerDumper
extends java.lang.Object
implements SignalFeatureListener


Field Summary
(package private)  int counter
           
(package private)  java.util.LinkedList<java.lang.Double> powList
           
(package private)  java.util.LinkedList<java.lang.Double> rbcList
           
 
Constructor Summary
PitchAndPowerDumper()
           
 
Method Summary
 void newProperties(edu.cmu.sphinx.util.props.PropertySheet ps)
           
 void newSignalFeatures(double logEnergy, boolean voicing, double pitch)
           
 void newSignalFeatures(int frame, double power, boolean voicing, double pitch)
          Method called when a new set of signal features is available
private static double percentileFilter(java.util.List<java.lang.Double> list)
           
 void reset()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

counter

int counter

powList

java.util.LinkedList<java.lang.Double> powList

rbcList

java.util.LinkedList<java.lang.Double> rbcList
Constructor Detail

PitchAndPowerDumper

public PitchAndPowerDumper()
Method Detail

newSignalFeatures

public void newSignalFeatures(double logEnergy,
                              boolean voicing,
                              double pitch)

percentileFilter

private static double percentileFilter(java.util.List<java.lang.Double> list)

newSignalFeatures

public void newSignalFeatures(int frame,
                              double power,
                              boolean voicing,
                              double pitch)
Description copied from interface: SignalFeatureListener
Method called when a new set of signal features is available

Specified by:
newSignalFeatures in interface SignalFeatureListener
Parameters:
frame - the frame number for this result
power - average power per sample in the frame param rbcpower average power per sample after filtering the frame with a revised B-curve filter
voicing - whether this frame is voiced
pitch - pitch for this frame in cent relative to 100 Hz

reset

public void reset()
Specified by:
reset in interface edu.cmu.sphinx.instrumentation.Resetable

newProperties

public void newProperties(edu.cmu.sphinx.util.props.PropertySheet ps)
                   throws edu.cmu.sphinx.util.props.PropertyException
Specified by:
newProperties in interface edu.cmu.sphinx.util.props.Configurable
Throws:
edu.cmu.sphinx.util.props.PropertyException