-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add mass and findBestNOccurrences to the public API #114
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Take a look at the comments.
Good refactor with the internal functions!
* @brief Calculates the Mueen distance. | ||
* | ||
* The result has the following structure: | ||
* - 1st dimension contains the index of the subsequence in the tieme serie. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
time
* | ||
* The result has the following structure: | ||
* - 1st dimension correspond the nth best match. | ||
* - 2nd dimension conrrespond the numbef of queries. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
corresponds to the number
* @brief Calculates the N best matches of several queries in several time series. | ||
* | ||
* The result has the following structure: | ||
* - 1st dimension correspond the nth best match. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
corresponds to
* - 2nd dimension conrrespond the numbef of queries. | ||
* - 3rd dimension correspond the numbef of time series. | ||
* | ||
* For example, the distance in the position (1, 2, 3) correspond to the second best distance of the third query in the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
corresponds (applies to more lines as well)
* | ||
* The result has the following structure: | ||
* - 1st dimension contains the index of the subsequence in the tieme serie. | ||
* - 2nd dimension contains the numbef of queries. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
number
* The result has the following structure: | ||
* - 1st dimension contains the index of the subsequence in the tieme serie. | ||
* - 2nd dimension contains the numbef of queries. | ||
* - 3rd dimension contains the numbef of time series. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
number
* - 3rd dimension contains the numbef of time series. | ||
* | ||
* For example, the distance in the position (1, 2, 3) correspond to the distance of the third query to the fourth time | ||
* serie for the second subsequence in the time serie |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
series always ends with s
include/khiva/matrix.h
Outdated
* @brief Calculates the moving average and standard deviation of the time series 't'. | ||
* The result has the following structure: | ||
* - 1st dimension correspond the nth best match. | ||
* - 2nd dimension conrrespond the numbef of queries. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Apply the same comments, as this is copy pasted from the other, or viceversa
6acdb0e
to
d7b4c4b
Compare
Codecov Report
@@ Coverage Diff @@
## master #114 +/- ##
==========================================
- Coverage 97.75% 97.67% -0.08%
==========================================
Files 16 16
Lines 1694 1722 +28
==========================================
+ Hits 1656 1682 +26
- Misses 38 40 +2
Continue to review full report at Codecov.
|
include/khiva/matrix.h
Outdated
* @param index Position where the minimum is occurring. | ||
* @param q Array whose first dimension is the length of the query time series and the second dimension is the number of | ||
* queries. | ||
* @param t Array whose first dimension is the lenght of the time series and the second dimension is the number of time |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
length (check other copies of this doc)
@@ -45,6 +112,40 @@ bool tileIsFarFromDiagonal(long bandSize, long numRows, long row, long numColumn | |||
*/ | |||
af::array generateMask(long m, long numRows, long row, long numColumns, long column, long nTimeSeries = 1); | |||
|
|||
/** | |||
* @brief Calculates the Mueen distance. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change this to calculate the Mueen similarity search. See #107. When this PR gets merged, please close the mentioned issue.
Some refactor has been performed in order to publish in the API the mass function not requiring some intermediate computation as parameters. The function findBestNOccurrences has been also added to the API. The C and JNI bindings have been also included for these two functions The corresponding unit tests have been created.
d7b4c4b
to
a1f5daa
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Some refactor has been performed in order to publish in the API the mass
function not requiring some intermediate computation as parameters.
The function findBestNOccurrences has been also added to the API. The C
and JNI bindings have been also included for these two functions
The corresponding unit tests have been created.
Make sure you have checked all steps below.
Description
Tests
Benchmarks
Commits
License
Documentation