Class OrcaSpotModelResult
java.lang.Object
rawDeepLearningClassifier.dlClassification.orcaSpot.OrcaSpotModelResult
- All Implemented Interfaces:
PredictionResult
Stores results from an OrcaSpot classification
- Author:
- Jamie Macaulay
-
Field Summary
FieldsModifier and TypeFieldDescriptionbooleanDo we call this a yes/no classificationThe call type confidencefloat[]The detection confidenceDescription of the predicted classdoubleThe time in seconds. -
Constructor Summary
ConstructorsConstructorDescriptionOrcaSpotModelResult(Double detConf, Double time) Constructor for an OrcaSpot result if only a detection has occurred. -
Method Summary
Modifier and TypeMethodDescriptiondoubleGet the analysis time.short[]Get the class name IDs associated with this result.double[]Get frequency limits of the prediction resultfloat[]Get the detection confidence.String representation of the resultintGet duration in sample - this is the number of samples in the result.longGet the start sample - this is the sample number of the first sample in the result.longGet the time stamp.booleanCheck whether binary classification has passed.voidsetAnlaysisTime(double timeSeconds) Set the analysis time in seconds.voidsetBinaryClassification(boolean binaryClassification) Set whether the binary classification has passed.
-
Field Details
-
timeSeconds
public double timeSecondsThe time in seconds. -
detectionConfidence
public float[] detectionConfidenceThe detection confidence -
calltypeConfidence
The call type confidence -
binaryClassification
public boolean binaryClassificationDo we call this a yes/no classification -
predictedClass
Description of the predicted class
-
-
Constructor Details
-
OrcaSpotModelResult
Constructor for an OrcaSpot result if only a detection has occurred.- Parameters:
detConf- - the confidence.time- - the time in seconds.
-
OrcaSpotModelResult
public OrcaSpotModelResult()
-
-
Method Details
-
getPrediction
public float[] getPrediction()Get the detection confidence.- Specified by:
getPredictionin interfacePredictionResult- Returns:
- the detection confidence
-
isBinaryClassification
public boolean isBinaryClassification()Description copied from interface:PredictionResultCheck whether binary classification has passed.- Specified by:
isBinaryClassificationin interfacePredictionResult- Returns:
- true if binary classification has passed
-
setBinaryClassification
public void setBinaryClassification(boolean binaryClassification) Set whether the binary classification has passed.- Parameters:
binaryClassification- - true if the binary classification has passed.
-
getAnalysisTime
public double getAnalysisTime()Description copied from interface:PredictionResultGet the analysis time.- Specified by:
getAnalysisTimein interfacePredictionResult- Returns:
- the analysis time.
-
setAnlaysisTime
public void setAnlaysisTime(double timeSeconds) Set the analysis time in seconds.- Parameters:
timeSeconds- - the analysis time in seconds.
-
getResultString
Description copied from interface:PredictionResultString representation of the result- Specified by:
getResultStringin interfacePredictionResult- Returns:
- a string of the result.
-
getClassNames
public short[] getClassNames()Description copied from interface:PredictionResultGet the class name IDs associated with this result. Can be null. @see DLClassNameManager to get strings of class names.- Specified by:
getClassNamesin interfacePredictionResult- Returns:
- a list of the class name ID for the result. Can be null or an array the same length as getPrediciton();
-
getTimeMillis
public long getTimeMillis()Description copied from interface:PredictionResultGet the time stamp.- Specified by:
getTimeMillisin interfacePredictionResult- Returns:
- the millis datenumber.
-
getFreqLimits
public double[] getFreqLimits()Description copied from interface:PredictionResultGet frequency limits of the prediction result- Specified by:
getFreqLimitsin interfacePredictionResult- Returns:
- the frequency limits of the prediction result
-
getStartSample
public long getStartSample()Description copied from interface:PredictionResultGet the start sample - this is the sample number of the first sample in the result. * Note: required for object detection results where the start sample may not be same as the input data- Specified by:
getStartSamplein interfacePredictionResult- Returns:
- the start sample
-
getSampleDuration
public int getSampleDuration()Description copied from interface:PredictionResultGet duration in sample - this is the number of samples in the result. Note: required for object detection results where the duration is not the same as the input data- Specified by:
getSampleDurationin interfacePredictionResult- Returns:
- the duration of the result in samples.
-