Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddAndGetScore ¶
Types ¶
type LightLOF ¶
type LightLOF struct {
// contains filtered or unexported fields
}
LightLOF holds a model for anomaly detection.
func LoadLightLOF ¶
LoadLightLOF loads a LightLOF model.
func NewLightLOF ¶
func NewLightLOF(nnAlgo NNAlgorithm, hashNum, nnNum, rnnNum, maxSize int, seed int64) (*LightLOF, error)
NewLightLOF creates a LightLOF model.
func (*LightLOF) Add ¶
func (l *LightLOF) Add(v FeatureVector) (score float32, err error)
Add adds a feature vector to a LightLOF model and calculates its score.
func (*LightLOF) AddWithoutCalcScore ¶
func (l *LightLOF) AddWithoutCalcScore(v FeatureVector) error
AddWithoutCalcScore adds a feature vector to a LightLOF model.
type LightLOFStateCreator ¶
type LightLOFStateCreator struct { }
func (*LightLOFStateCreator) CreateState ¶
func (c *LightLOFStateCreator) CreateState(ctx *core.Context, params data.Map) (core.SharedState, error)
type NNAlgorithm ¶
type NNAlgorithm int
NNAlgorithm is an enum type which represents nearest neighbor algorithms.
const ( // InvalidNNAlgorithm represents an invalid nearest neighbor algorithm. InvalidNNAlgorithm NNAlgorithm = iota // LSH represents locality sensitive hashing. LSH // Minhash represents minhash. Minhash // EuclidLSH represents locality sensitive hashing with euclidean distance. EuclidLSH )
Click to show internal directories.
Click to hide internal directories.