Class DelphinIDClassifier
java.lang.Object
rawDeepLearningClassifier.dlClassification.StandardClassifierModel
rawDeepLearningClassifier.dlClassification.delphinID.DelphinIDClassifier
- All Implemented Interfaces:
PamSettings
,SettingsNameProvider
,DLClassiferModel
A classifier based on the delphinID method which uses whistle contours to predict
dolphin species.
- Author:
- Jamie Macaulay
-
Nested Class Summary
Nested classes/interfaces inherited from class rawDeepLearningClassifier.dlClassification.StandardClassifierModel
StandardClassifierModel.TaskThread
-
Field Summary
Fields inherited from class rawDeepLearningClassifier.dlClassification.StandardClassifierModel
dlControl
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGet the allowed data types for the model.The can be null in which case only data units with raw data are allowed.A settings object that can be saved.Get the sound spot worker.Get the sound spot worker.Get any UI components for the model.getName()
Get the name of the model.long
boolean
isDecision
(StandardPrediction modelResult, StandardModelParams modelParmas) Make a decision on whether a result passed a decisionboolean
isModelType
(URI model) Check whether a URI is compatible with a classification frameworkvoid
Prepare the model.boolean
restoreSettings
(PamControlledUnitSettings pamControlledUnitSettings) ArrayList
<? extends PredictionResult> runModel
(ArrayList<? extends PamDataUnit> groupedRawData) Run the deep learning model on a list of grouped raw data units and return a corresponding list of model results.void
setDLParams
(DelphinIDParams params) Methods inherited from class rawDeepLearningClassifier.dlClassification.StandardClassifierModel
checkSettingsOK, closeModel, getClassNameIDs, getClassNames, getDLControl, getModelStatus, getNumClasses, getRawSettingsPane, isModelExtensions, millis2Samples, newResult, setModel
-
Constructor Details
-
Method Details
-
isModelType
Description copied from interface:DLClassiferModel
Check whether a URI is compatible with a classification framework- Parameters:
model
- - the URI to the model- Returns:
- true if the model is compatible.
-
prepModel
public void prepModel()Description copied from interface:DLClassiferModel
Prepare the model. This is called on PAMGuard start up and before processing in viewer mode.- Specified by:
prepModel
in interfaceDLClassiferModel
- Overrides:
prepModel
in classStandardClassifierModel
-
getName
Description copied from interface:DLClassiferModel
Get the name of the model.- Returns:
- the name of the model.
-
getModelUI
Description copied from interface:DLClassiferModel
Get any UI components for the model. Can be null.- Returns:
- UI components for the model.
-
getDLModelSettings
Description copied from interface:DLClassiferModel
A settings object that can be saved.- Returns:
- the settings object.
-
getUnitName
- Returns:
- A Name specific to this instance of the particular class, e.g. Sperm whale detector, Beaked whale detector, etc.
-
getUnitType
- Returns:
- A Name specific to the type, e.g. Click detector
-
getSettingsReference
- Returns:
- The serialisable object that will be stored
-
runModel
public ArrayList<? extends PredictionResult> runModel(ArrayList<? extends PamDataUnit> groupedRawData) Description copied from interface:DLClassiferModel
Run the deep learning model on a list of grouped raw data units and return a corresponding list of model results.Note the reason we use list is that often it is more efficient to get a model to predict a stacked group of inputs rather than one at a time.
- Specified by:
runModel
in interfaceDLClassiferModel
- Overrides:
runModel
in classStandardClassifierModel
- Returns:
- the deep learning model.
-
isDecision
Description copied from class:StandardClassifierModel
Make a decision on whether a result passed a decision- Overrides:
isDecision
in classStandardClassifierModel
- Parameters:
modelResult
- - the model result.modelParmas
- - the model parameters.- Returns:
- true if a threshold has been met.
-
getSettingsVersion
public long getSettingsVersion()- Returns:
- An integer version number for the settings
-
restoreSettings
- Parameters:
pamControlledUnitSettings
-- Returns:
- true if successful The object performs final checks (if needed) and then casts the settings data pamcontrolledunitSettings.settings into the correct type and uses as required
-
getDLWorker
Description copied from class:StandardClassifierModel
Get the sound spot worker.- Specified by:
getDLWorker
in classStandardClassifierModel
- Returns:
- the sound spot worker.
-
getDLParams
Description copied from class:StandardClassifierModel
Get the sound spot worker.- Specified by:
getDLParams
in classStandardClassifierModel
- Returns:
- the sound spot worker.
-
setDLParams
-
getAllowedDataTypes
Description copied from interface:DLClassiferModel
Get the allowed data types for the model.The can be null in which case only data units with raw data are allowed.- Specified by:
getAllowedDataTypes
in interfaceDLClassiferModel
- Overrides:
getAllowedDataTypes
in classStandardClassifierModel
- Returns:
- a list of the allowed data types.
-