Package whistleClassifier.training
Class TrainingDataSet
java.lang.Object
whistleClassifier.training.TrainingDataSet
- All Implemented Interfaces:
 Serializable,ManagedParameters
Training contours from a single file, each contour representing
 one whistle. 
 
For each species, several of these will probably be held in a TrainingDataGroup
- Author:
 - Doug Gillespie
 - See Also:
 
- 
Field Summary
Fields - 
Constructor Summary
ConstructorsConstructorDescriptionTrainingDataSet(Class sourceDataClass, String species, float sampleRate, int fftLength, int ffthop)  - 
Method Summary
Modifier and TypeMethodDescriptionintaddContour(double[] t, double[] f) intaddContour(WhistleContour contour) intintintThis method was only added so that nContours would be included in the PamParameterSet when getParameterSet is calledintGet the number of contours in the data set.intgetNumFragments(WhistleFragmenter fragmenter, double minFreq, double maxFreq, int minContourLength) Get the number of fragments based on the fragment lengthGet a set of data that describes all of the parameters in a classfloatgetTrainingContour(int iContour) Get a specific training contourlongvoidsetFfthop(int ffthop) voidsetFftLength(int fftLength) voidsetSampleRate(float sampleRate) voidsetSpecies(String species) voidsetStorageSource(String storageSource) toString() 
- 
Field Details
- 
serialVersionUID
public static final long serialVersionUID- See Also:
 
 
 - 
 - 
Constructor Details
- 
TrainingDataSet
 
 - 
 - 
Method Details
- 
toString
 - 
addContour
 - 
addContour
public int addContour(double[] t, double[] f)  - 
getSpecies
 - 
getTrainingTime
public long getTrainingTime() - 
getSourceDataType
 - 
getTrainingContours
 - 
getTrainingContour
Get a specific training contour- Parameters:
 iContour- contour index- Returns:
 - contour
 
 - 
setSpecies
 - 
getFftLength
public int getFftLength() - 
setFftLength
public void setFftLength(int fftLength)  - 
getSampleRate
public float getSampleRate() - 
setSampleRate
public void setSampleRate(float sampleRate)  - 
getFfthop
public int getFfthop() - 
setFfthop
public void setFfthop(int ffthop)  - 
getNumContours
public int getNumContours()Get the number of contours in the data set.- Returns:
 - number of contours.
 
 - 
getNContours
public int getNContours()This method was only added so that nContours would be included in the PamParameterSet when getParameterSet is called- Returns:
 
 - 
getNumFragments
public int getNumFragments(WhistleFragmenter fragmenter, double minFreq, double maxFreq, int minContourLength) Get the number of fragments based on the fragment length- Parameters:
 fragLen- length of each fragment- Returns:
 - number of fragments.
 
 - 
getStorageSource
 - 
setStorageSource
 - 
getParameterSet
Description copied from interface:ManagedParametersGet a set of data that describes all of the parameters in a class- Specified by:
 getParameterSetin interfaceManagedParameters- Returns:
 - description of the parameters in a class.
 
 
 -