-
Notifications
You must be signed in to change notification settings - Fork 536
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
Implementation of Direct Scale Transform Feature #1434
base: master
Are you sure you want to change the base?
Conversation
- Added parameters in header file - Added configure function - Added first order difference and matrix multiplication code Signed-off-by: Anmol Mishra <[email protected]>
Add the following tests: - Invalid Parameters Test - Invalid Inputs Test - Zero Input Test - Regression Test to compare with original Python implementation Signed-off-by: Anmol Mishra <[email protected]>
Let's replace the |
#include "directscaletransform.h" | ||
#include "essentiamath.h" | ||
|
||
#define FOR(i,l,r) for(int i=l; i<r; i++) |
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.
Let's avoid using this define for clarify.
"This code was derived from the original DST paper:\n" | ||
"[1] Williams, W. J., and E. J. Zalubas. Helicopter transmission fault detection via " | ||
"time-frequency, scale and spectral methods. Mechanical systems and signal processing" | ||
"14.4 (2000): 545-559."); |
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.
Is there some reference implementation we could additionally cite here?
std::complex<Real> zi = std::complex<Real>(0, 1); | ||
Real step = M_PI/log(N+1); | ||
int num_rows = _C/step+1; // Number of rows. +1 because need to include the first row which is the 0th multiple of step | ||
int P = matrix[0].size(); |
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.
There's no guarantee on the consistency of the size of inner vectors, because we are using vector of vectors. Therefore, this should be checked.
[feat] Complete Implementation of Direct Scale Transform
[feat] Add tests for Direct Scale Transform
Add the following tests: