|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object de.lmu.ifi.dbs.elki.algorithm.outlier.OnlineLOF.LOFKNNListener
private class OnlineLOF.LOFKNNListener
Encapsulates a listener for changes of kNNs used in the online LOF algorithm.
Field Summary | |
---|---|
private KNNChangeEvent |
firstEventReceived
Holds the first event of one of the both preprocessors. |
private LOF.LOFResult<O,D> |
lofResult
Holds the result of a former run of the LOF algorithm. |
Constructor Summary | |
---|---|
OnlineLOF.LOFKNNListener(LOF.LOFResult<O,D> lofResult)
Constructs a listener for the LOF algorithm. |
Method Summary | |
---|---|
void |
kNNsChanged(KNNChangeEvent e)
Invoked after kNNs have been updated, inserted or removed in some way. |
private void |
kNNsChanged(KNNChangeEvent e1,
KNNChangeEvent e2)
Invoked after the events of both preprocessors have been received, i.e. |
private void |
kNNsInserted(DBIDs insertions,
DBIDs updates1,
DBIDs updates2,
LOF.LOFResult<O,D> lofResult)
Invoked after kNNs have been inserted and updated, updates the result. |
private void |
kNNsRemoved(DBIDs deletions,
DBIDs updates1,
DBIDs updates2,
LOF.LOFResult<O,D> lofResult)
Invoked after kNNs have been removed and updated, updates the result. |
private ArrayModifiableDBIDs |
mergeIDs(List<List<DistanceResultPair<D>>> queryResults,
DBIDs... ids)
Merges the ids of the query result with the specified ids. |
private void |
recomputeLOFs(DBIDs ids,
LOF.LOFResult<O,D> lofResult)
Recomputes the lofs of the specified ids. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private KNNChangeEvent firstEventReceived
private LOF.LOFResult<O,D extends NumberDistance<D,?>> lofResult
Constructor Detail |
---|
public OnlineLOF.LOFKNNListener(LOF.LOFResult<O,D> lofResult)
lofResult
- the result of a former run of the LOF algorithmMethod Detail |
---|
public void kNNsChanged(KNNChangeEvent e)
KNNListener
kNNsChanged
in interface KNNListener
e
- the change eventprivate void kNNsChanged(KNNChangeEvent e1, KNNChangeEvent e2)
e1
- the change event of the first preprocessore2
- the change event of the second preprocessorprivate void kNNsInserted(DBIDs insertions, DBIDs updates1, DBIDs updates2, LOF.LOFResult<O,D> lofResult)
insertions
- the ids of the newly inserted neighborhoodsupdates1
- the ids of the updated neighborhood w.r.t. the
neighborhood distance functionupdates2
- the ids of the updated neighborhood w.r.t. the
reachability distance functionlofResult
- the result of the former LOF runprivate void kNNsRemoved(DBIDs deletions, DBIDs updates1, DBIDs updates2, LOF.LOFResult<O,D> lofResult)
deletions
- the ids of the removed neighborhoodsupdates1
- the ids of the updated neighborhood w.r.t. the
neighborhood distance functionupdates2
- the ids of the updated neighborhood w.r.t. the
reachability distance functionlofResult
- the result of the former LOF runprivate ArrayModifiableDBIDs mergeIDs(List<List<DistanceResultPair<D>>> queryResults, DBIDs... ids)
queryResults
- the list of query resultsids
- the list of ids
private void recomputeLOFs(DBIDs ids, LOF.LOFResult<O,D> lofResult)
ids
- the ids of the lofs to be recomputedlofResult
- the result of the former LOF run
|
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |