stumpy icon indicating copy to clipboard operation
stumpy copied to clipboard

Fix #610

Open NimaSarajpoor opened this issue 2 years ago • 5 comments

This PR is a replacement for PR https://github.com/TDAmeritrade/stumpy/pull/668. This PR tries to resolve the loss of precision issue that might occur in cases where there are identical subsequences (in their z-normalized version) in a time series (see #610)

NimaSarajpoor avatar Aug 25 '23 02:08 NimaSarajpoor

Codecov Report

Patch coverage: 100.00% and no project coverage change.

Comparison is base (6663f5f) 98.93% compared to head (5b79efb) 98.93%. Report is 3 commits behind head on main.

:exclamation: Current head 5b79efb differs from pull request most recent head 1eb878d. Consider uploading reports for the commit 1eb878d to get more accurate results

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #907   +/-   ##
=======================================
  Coverage   98.93%   98.93%           
=======================================
  Files          84       84           
  Lines       14292    14307   +15     
=======================================
+ Hits        14140    14155   +15     
  Misses        152      152           
Files Changed Coverage Δ
tests/test_precision.py 100.00% <100.00%> (ø)

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

codecov[bot] avatar Aug 25 '23 02:08 codecov[bot]

Note: A TimeoutError occurred in here

NimaSarajpoor avatar Aug 25 '23 13:08 NimaSarajpoor

I re-ran the failed tests

seanlaw avatar Aug 26 '23 00:08 seanlaw

@seanlaw
Thank you for re-running the tests

We can see an assertion failure here. Note that this is coming from the test function in which the identical subsequences are scaled differently, and their values are not in the range of other subsequences. I will dig into it and provide an update.

NimaSarajpoor avatar Aug 26 '23 01:08 NimaSarajpoor

[Update] Note: The assertion failure is coming from the distance between two differently-scaled subsequences that have the same values in their z-norm space.

Note 1 : Removing njit decorators do not resolve the assertion failure. Note 2: Using the exact covariance instead of the rolling one resolves the assertion failure.

NimaSarajpoor avatar Aug 27 '23 19:08 NimaSarajpoor