Fixed #34 Customizing scipy's oaconvolve - #35
Conversation
|
Review these changes at https://app.gitnotebooks.com/stumpy-dev/sliding_dot_product/pull/35 |
The challenger is the customized version of scipy's oaconvolve.
Observations:
For me, the important one is the first bullet point. Of the four optimization opportunities mentioned in this comment, I've addressed 1, 2, and 3 in this PR. The last item, which is about adjusting the number of multiplication for real-valued arrays, can be explored next. |
|
As a gentle reminder, even if we can do things faster, we will never (??) remove the public |
|
Good reminder. It makes sense!! |
|
|
||
|
|
||
| def test_oaconvolve_sdp_blocksize(): | ||
| from sdp.challenger_sdp import sliding_dot_product |
There was a problem hiding this comment.
This line needs to be modified if, at a later time, we decide to move the proposal to a new file (module).
@seanlaw |
There was a problem hiding this comment.
@NimaSarajpoor I've left some comments but would still like another pass after you've cleaned things up further
I do agree that, for the most part, things look clean. I think it still lacks clarity as to what is happening or why the logic is coded in this way
|
@seanlaw (1) I intentionally left a few things to be addressed in a different PR later for the function (2) I thought about refactoring '_pocketfft_circular_convolve_block' (in challenger_sdp.py) and '_pocketfft_valid_convolve' (in the changed file pocketfft_r2c_c2r_sdp.py). However, I couldn't find a clean way to do it. Maybe we need to create a new function and those both functions need to call that common function (??) |
@NimaSarajpoor Was there anything in particular that you wanted me to focus on. Frankly, I don't have enough details or context to follow most/all the oaconvolve/block size logic. It feels like I can only attempt to spot issues with programming logic but not issues with algorithmic logic (not unless you can spell out the problem in clear detail).
I'll try to take a look but it's not clear to me what this is currently referencing as I do not have sufficient context |
|
@seanlaw Perhaps I should add some more context to this PR (?) For example, I can create a notebook that walks through the overlap-add approach mathematically and shows why, in our particular case, it produces the same result as the direct valid convolution. Would something like that make the algorithmic logic easier to review? Or is there another kind of context that you think would be more useful? |
|
@NimaSarajpoor Yes, I think a notebook would be valuable. In most/all of the matrix profile work, we nearly always had a published paper to reference (and their code) and so it was easier to start from the same shared context and then we could evolve from there together. Here, I'm purely following you and the context that you give me. So, I think a detailed notebook (even with naive code snippets) would be quite helpful especially to "see" where the hard problem(s) are that need to be solved |


This PR is to address #34.