Stream-AD / MIDAS

Anomaly Detection on Dynamic (time-evolving) Graphs in Real-time and Streaming manner. Detecting intrusions (DoS and DDoS attacks), frauds, fake rating anomalies.
Apache License 2.0
762 stars 93 forks source link

What's the reason for the `m` value? #7

Closed scooter-dangle closed 4 years ago

scooter-dangle commented 4 years ago

https://github.com/bhatiasiddharth/MIDAS/blob/c1e4e6b316d007165907db44efcefab9fd8b02f8/anom.cpp#L50

Since we have no guarantee that the first and last values of the inputs are different (or, if they are different, that they differ by any particular magnitude), why not just supply m as an input to the program?

(I looked through the paper. Apologies if I missed an explanation there.)

bhatiasiddharth commented 4 years ago

max_element returns the iterator to the greatest element in the range [first, last) rather than maximum of first and last.

scooter-dangle commented 4 years ago

Ah, thanks for pointing that out—I'm not familiar with the C++ std lib.

So it's really just the max value of the domain. Is there any particular reason for that? Like, would it negatively affect the output to set it to just, say, 773 (the next prime after 769)?

scooter-dangle commented 4 years ago

Be tea dubs, I wrote a Rust version and Python bindings to it.

scooter-dangle commented 4 years ago

Additional questions:

bhatiasiddharth commented 4 years ago

Thanks, for the Rust version and Python bindings. They look nice! I have added links in the README. Also, I am fine with them being dual-licensed under MIT.

scooter-dangle commented 4 years ago

I have added links in the README. Also, I am fine with them being dual-licensed under MIT.

Thanks so much!