You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Clarification on documentation: does stumpy.match rely on MPDist? #798
I would like to understand better how the methods stumpy.match and stumpy.mass compute the distance under the hood to find the best matches. I assume it relies on the measure MPDist but it is not explicitly mention in the documentation which distance measure it uses. Could you clarify?
Hi @patrickfleith! Welcome to the STUMPY community and thank you for your question.
I would like to understand better how the methods stumpy.match and stumpy.mass compute the distance under the hood to find the best matches. I assume it relies on the measure MPDist but it is not explicitly mention in the documentation which distance measure it uses. Could you clarify?
No, stumpy.match uses stumpy.mass to compute the distance under the hood. For all intents and purposes, stumpy.mass is just a fast way (leveraging FFT) to compute the sliding window dot product between the query subsequence, Q, and all subsequences within your time series, T. Once the dot products are computed, it is trivial to compute the correspodning (z-normalized) Euclidean distance(s). I recommend looking at this paper to better understand the inner workings. At the end of the day, it computes the (z-normalized) Euclidean distance and that is all you should need to care about.
To be explicit, stumpy.match and stumpy.mass do not use MPdist and is mostly unrelated. I hope that helps.
Great, many thanks. And from what I observe there is no other routine which search for the best matching based on MPDsit, right? One would have to come up with his.her own search function?
Great, many thanks. And from what I observe there is no other routine which search for the best matching based on MPDsit, right? One would have to come up with his.her own search function?
That is correct. At the end of the day, you are computing a "distance" and then it is up to you to set a distance threshold that decides whether something is "significant" or not.
@patrickfleith In the future, would you mind posting usage questions to our Github Discussions? This way, others may chime in and provide their perspective too.
Activity
seanlaw commentedon Mar 1, 2023
Hi @patrickfleith! Welcome to the STUMPY community and thank you for your question.
No,
stumpy.matchusesstumpy.massto compute the distance under the hood. For all intents and purposes,stumpy.massis just a fast way (leveraging FFT) to compute the sliding window dot product between the query subsequence,Q, and all subsequences within your time series,T. Once the dot products are computed, it is trivial to compute the correspodning (z-normalized) Euclidean distance(s). I recommend looking at this paper to better understand the inner workings. At the end of the day, it computes the (z-normalized) Euclidean distance and that is all you should need to care about.To be explicit,
stumpy.matchandstumpy.massdo not useMPdistand is mostly unrelated. I hope that helps.patrickfleith commentedon Mar 1, 2023
Great, many thanks. And from what I observe there is no other routine which search for the best matching based on MPDsit, right? One would have to come up with his.her own search function?
seanlaw commentedon Mar 1, 2023
That is correct. At the end of the day, you are computing a "distance" and then it is up to you to set a distance threshold that decides whether something is "significant" or not.
patrickfleith commentedon Mar 1, 2023
Ok great thanks I close the issue
seanlaw commentedon Mar 1, 2023
@patrickfleith In the future, would you mind posting usage questions to our Github Discussions? This way, others may chime in and provide their perspective too.