Package rocca

Class RoccaContourDataBlock


public class RoccaContourDataBlock extends PamDataBlock<RoccaContourDataUnit>
Author:
Michael Oswald
  • Constructor Details Link icon

    • RoccaContourDataBlock Link icon

      public RoccaContourDataBlock(PamProcess parentProcess, int channelMap)
      Constructor. Set the natural lifetime to the maximum integer value possible so that the data is never deleted unless the
  • Method Details Link icon

    • calculateStatistics Link icon

      public void calculateStatistics()
      Once the Datablock is filled, this routine will calculate the statistics of the contour.
    • calculateClickStats Link icon

      public void calculateClickStats()
      Calculate the statistics specific to a click detection
    • createContourStatsHeader Link icon

      public String createContourStatsHeader()
      Creates the header line for the contour status summary file. Note that the individual species tree votes do not get labelled, as this may change if the user switches classifiers at some point. Instead, the species list is included at the end of each row 2014/09/09 added Encounter ID, Cruise ID, Data Provider and Known Species 2015/10/10 serialVersionUID=23 removed spaces and parenthesis from headers serialVersionUID=24 2016/08/10 added lat/long info
      Returns:
      the header string
    • createContourStatsString Link icon

      public String createContourStatsString()
      Method to create a string containing the current contour statistics. Also included in the string are the filename, detection number and encounter classification. This method sets the filename equal to the raw data source, and the detection count to 0
      Returns:
      a String containing the contour statistics
    • createContourStatsString Link icon

      public String createContourStatsString(String clipFile, int detectionCount)
      Method to create a string containing the current contour statistics. Also included in the string are the filename, date/time, detection count and encounter classification. This method sets the filename equal to the passed String clipFile.
      Parameters:
      clipFile - String to be saved in the 'filename' column
      detectionCount - integer specifying the detection count (the count starts at 1 when the first detection is captured)
      Returns:
      a String containing the contour statistics
    • createContourStatsString Link icon

      public String createContourStatsString(String clipFile, int detectionCount, String sightNum)
      Method to create a string containing the current contour statistics. Also included in the string are the filename, date/time, detection count and encounter classification. This method sets the filename equal to the passed String clipFile. 2015/10/10 serialVersionUID=23 removed spaces from columns serialVersionUID=24 2016/08/10 added lat/long info
      Parameters:
      clipFile - String to be saved in the 'filename' column
      detectionCount - integer specifying the detection count (the count starts at 1 when the first detection is captured)
      Returns:
      a String containing the contour statistics
    • getWavFilename Link icon

      public File getWavFilename()
      Get the filename of the original wav file
      Returns:
    • getClassifiedAs Link icon

      public String getClassifiedAs()
    • setClassifiedAs Link icon

      public void setClassifiedAs(String classifiedAs)
    • isStatsRun Link icon

      public boolean isStatsRun()
    • setStatsRun Link icon

      public void setStatsRun(boolean statsRun)
    • getTreeVotes Link icon

      public double[] getTreeVotes()
    • setTreeVotes Link icon

      public void setTreeVotes(double[] treeVotes)
    • getFirstUnitWithWhistle Link icon

      public int getFirstUnitWithWhistle()
    • setFirstUnitWithWhistle Link icon

      public void setFirstUnitWithWhistle(int firstUnitWithWhistle)
    • getLastUnitWithWhistle Link icon

      public int getLastUnitWithWhistle()
    • setLastUnitWithWhistle Link icon

      public void setLastUnitWithWhistle(int lastUnitWithWhistle)
    • getKeyNames Link icon

      public ArrayList<String> getKeyNames()
    • getContour Link icon

    • getRCS Link icon

      public RoccaContourStats getRCS()
    • getClickDetection Link icon

      public ClickDetection getClickDetection()
      Returns:
      the clickDetection
    • setClickDetection Link icon

      public void setClickDetection(ClickDetection clickDetection)
      Sets the clickDetection parameter. Also creates a RoccaContourDataUnit object and loads it with basic information from the clickDetection. This prevents errors later in the code where it is assumed that the RoccaContourDataBlock contains at least one data unit.
      Parameters:
      clickDetection - the clickDetection to set
    • getClickNoise Link icon

      public ClickDetection getClickNoise()
      Returns:
      the clickNoise
    • setClickNoise Link icon

      public void setClickNoise(ClickDetection clickNoise)
      Parameters:
      clickNoise - the clickNoise to set
    • getStartTime Link icon

      public double getStartTime()
      Returns:
      the startTime serialVersionUID=15 2014/11/12
    • setStartTime Link icon

      public void setStartTime(double startTime)
      Parameters:
      startTime - the startTime to set serialVersionUID=15 2014/11/12
    • getDuration Link icon

      public double getDuration()
      Returns:
      the duration serialVersionUID=22 2015/06/13
    • setDuration Link icon

      public void setDuration(double duration)
      Parameters:
      duration - the duration to set serialVersionUID=22 2015/06/13
    • isThisAWhistle Link icon

      public boolean isThisAWhistle()
      Test whether this data block is a whistle or not serialVersionUID=24 2016/08/10
      Returns:
      true=whistle, false=click
    • setAsAWhistle Link icon

      public void setAsAWhistle(boolean thisIsAWhistle)
      Sets whether this data block is a whistle or not. True=whistle, false=click serialVersionUID=24 2016/08/10
      Parameters:
      thisIsAWhistle -
    • getLatitude Link icon

      public double getLatitude()
    • setLatitude Link icon

      public void setLatitude(double latitude)
    • getLongitude Link icon

      public double getLongitude()
    • setLongitude Link icon

      public void setLongitude(double longitude)
    • setWavInfo Link icon

      public void setWavInfo(double[][] wavInfo)
    • getWavInfo Link icon

      public double[][] getWavInfo()