Package org.tribuo.anomaly
Class MutableAnomalyInfo
java.lang.Object
org.tribuo.anomaly.AnomalyInfo
org.tribuo.anomaly.MutableAnomalyInfo
- All Implemented Interfaces:
Serializable
,MutableOutputInfo<Event>
,OutputInfo<Event>
An
MutableOutputInfo
object for Event
s.
Counts the number of Event.EventType.ANOMALOUS
, Event.EventType.EXPECTED
and Event.EventType.UNKNOWN
outputs observed. The unknown output is invalid
at training time, and used as a prediction time sentinel (similarly to other Tribuo
prediction tasks).
Anomaly detection has a fixed domain, so it will throw IllegalArgumentException
if you somehow modify the Event.EventType
enum to add a new value.
- See Also:
-
Field Summary
Fields inherited from class org.tribuo.anomaly.AnomalyInfo
anomalyCount, expectedCount, unknownCount
-
Method Summary
Methods inherited from class org.tribuo.anomaly.AnomalyInfo
generateImmutableOutputInfo, generateMutableOutputInfo, getAnomalyCount, getDomain, getEventCount, getExpectedCount, getUnknownCount, outputCountsIterable, size, toReadableString, toString
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.tribuo.OutputInfo
generateImmutableOutputInfo, generateMutableOutputInfo, getDomain, getUnknownCount, outputCountsIterable, size, toReadableString
-
Method Details
-
observe
Description copied from interface:MutableOutputInfo
Records an output value or statistics thereof.- Specified by:
observe
in interfaceMutableOutputInfo<Event>
- Parameters:
output
- The observed output.
-
clear
public void clear()Description copied from interface:MutableOutputInfo
Clears the OutputInfo, removing all things it's observed.- Specified by:
clear
in interfaceMutableOutputInfo<Event>
-
copy
Description copied from interface:OutputInfo
Generates a copy of this OutputInfo, including it's mutability.- Specified by:
copy
in interfaceOutputInfo<Event>
- Specified by:
copy
in classAnomalyInfo
- Returns:
- A copy of the OutputInfo.
-