wandnz / streamevmon

Framework and pipeline for time series anomaly detection
GNU General Public License v3.0
1 stars 1 forks source link

Global measurement -> value map function #13

Closed wandgitlabbot closed 3 years ago

wandgitlabbot commented 3 years ago

In GitLab, by Daniel Oosterwijk on 2019-12-09

Similar to the recently implemented isLossy, having a map function that can be called on generic objects would prevent a lot of code reuse. The only possible hangup is what to return for lossy values!

wandgitlabbot commented 3 years ago

In GitLab, by Daniel Oosterwijk on 2020-01-12

It's fine to just rip out ModeDetector's mapFunction, but the MapFunction used for the Changepoint detector adds the extra versatility that a default function doesn't quite allow.

An option is to make a child class (anonymous would be great, but might not be serialisable) of whatever measurement type we're passing into the detector at Flink-pipeline-construction time which just overrides the defaultValue function.

Another option is to make defaultValue a var. This would allow the end-user to rewrite the value however they desire. I like this one better, since the tiny bit of extra memory usage isn't really an issue at all.

wandgitlabbot commented 3 years ago

In GitLab, by Daniel Oosterwijk on 2020-01-13

5d3ab167 closes this.