Class PeakDetector

java.lang.Object
PamguardMVC.PamProcess
whistleDetector.PeakDetector
All Implemented Interfaces:
PamObserver, ProcessAnnotator
Direct Known Subclasses:
BasicPeakDetector

public abstract class PeakDetector extends PamProcess
Author:
Doug Gillespie Detects whistle peaks from FFT data
  • Constructor Details

  • Method Details

    • prepareProcess

      public void prepareProcess()
      Description copied from class: PamProcess
      Called for each process before any of them receive the PamStart command
      Overrides:
      prepareProcess in class PamProcess
    • setSampleRate

      public void setSampleRate(float sampleRate, boolean notify)
      Description copied from interface: PamObserver
      New sample rate
      Specified by:
      setSampleRate in interface PamObserver
      Overrides:
      setSampleRate in class PamProcess
      Parameters:
      notify - Notify other PamObservers and PamObservables in the chain.
    • newData

      public void newData(PamObservable obs, PamDataUnit newUnit)
      Overrides:
      newData in class PamProcess
    • searchForPeaks

      public void searchForPeaks(PamObservable obs, FFTDataUnit newDataUnit)
      Parameters:
      obs - PamObservable - always a PamDataBlock
      newDataUnit - The latest PamDataUnit added to the PamDataBlock Takes a new block of FFT data and creates a series of peaks based on parts of the sectrum being above some threshold. Rather than add individual peaks to the output data block, the peaks are stored in a new ArrayList and the array list is added to the output block. This reduces the amount of traffic to the output blocks listeners and will make it easier for the process linking the peaks to navigate between successive peak slices.
    • getEqualisationConstants

      public double[] getEqualisationConstants()
    • pamStart

      public void pamStart()
      Description copied from class: PamProcess
      Called for each process to tell it to start (may not be necessary for processes which are listening for data anyway).
      Specified by:
      pamStart in class PamProcess
    • pamStop

      public void pamStop()
      Description copied from class: PamProcess
      Stops the process.
      Specified by:
      pamStop in class PamProcess
    • getPeakDataBlock

      public PamDataBlock<PeakDataUnit> getPeakDataBlock()
    • getGroupChannels

      public int getGroupChannels()
    • setGroupChannels

      public void setGroupChannels(int groupChannels)
    • getDetectionChannel

      public int getDetectionChannel()
    • getPeakDetectorName

      public abstract String getPeakDetectorName()