Class TrainingDataSet

java.lang.Object
whistleClassifier.TrainingDataSet
All Implemented Interfaces:
Serializable

public class TrainingDataSet extends Object implements Serializable
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 Details

  • Constructor Details

    • TrainingDataSet

      public TrainingDataSet(Class sourceDataClass, String species, float sampleRate, int fftLength, int ffthop)
  • Method Details

    • toString

      public String toString()
      Overrides:
      toString in class Object
    • addContour

      public int addContour(double[] t, double[] f)
    • getSpecies

      public String getSpecies()
    • getTrainingTime

      public long getTrainingTime()
    • getSourceDataType

      public String getSourceDataType()
    • getTrainingContours

      public ArrayList<TrainingContour> getTrainingContours()
    • setSpecies

      public void setSpecies(String species)
    • 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, int fragLen)
      Get the number of fragments based on the fragment length
      Parameters:
      fragLen - length of each fragment
      Returns:
      number of fragments.
    • getStorageSource

      public String getStorageSource()
    • setStorageSource

      public void setStorageSource(String storageSource)