Package tritechgemini.detect
Class TwoThresholdDetector
java.lang.Object
tritechgemini.detect.TwoThresholdDetector
- All Implemented Interfaces:
RegionDetector
- Direct Known Subclasses:
DetectedRegion
Detector which searches for detected regions in data. Uses two thresholds, a "minimum maximum" (thHigh)
and a "minimum edge" thLow.
Should ideally be sent data after background subtraction, can also work with raw raw data.
- Author:
- Doug Gillespie
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondetectRegions(SonarImageRecordI denoisedRecord, byte[] recordData, int thHigh, int thLow, int nConnect) Search for regions using a different set of raw data, which should probably be a noise reduced version of what was in the original record.detectRegions(SonarImageRecordI rawGeminiRecord, SonarImageRecordI denoisedRecord, int thHigh, int thLow, int nConnect) Search for regions using the raw data within the recordstatic int[]Get types of available connectiondoubledoublevoidsetMaxObjectSize(double maxObjectSize) voidsetMinObjectSize(double minObjectSize)
-
Constructor Details
-
TwoThresholdDetector
public TwoThresholdDetector()
-
-
Method Details
-
getMinObjectSize
public double getMinObjectSize()- Returns:
- the minObjectSize
-
setMinObjectSize
public void setMinObjectSize(double minObjectSize) - Specified by:
setMinObjectSizein interfaceRegionDetector- Parameters:
minObjectSize- the minObjectSize to set
-
getMaxObjectSize
public double getMaxObjectSize()- Returns:
- the maxObjectSize
-
setMaxObjectSize
public void setMaxObjectSize(double maxObjectSize) - Specified by:
setMaxObjectSizein interfaceRegionDetector- Parameters:
maxObjectSize- the maxObjectSize to set
-
detectRegions
public ArrayList<DetectedRegion> detectRegions(SonarImageRecordI rawGeminiRecord, SonarImageRecordI denoisedRecord, int thHigh, int thLow, int nConnect) Search for regions using the raw data within the record- Specified by:
detectRegionsin interfaceRegionDetector- Parameters:
rawGeminiRecord- Raw data recorddenoisedRecord- Data with background removed.thHigh-thLow-geminiRecord-- Returns:
-
detectRegions
public ArrayList<DetectedRegion> detectRegions(SonarImageRecordI denoisedRecord, byte[] recordData, int thHigh, int thLow, int nConnect) Search for regions using a different set of raw data, which should probably be a noise reduced version of what was in the original record. Must be the same dimension as that in the original.- Parameters:
denoisedRecord-recordData-thHigh-thLow-- Returns:
-
getConnectionTypes
public static int[] getConnectionTypes()Get types of available connection- Returns:
- 4 and 8
-