Skip to content
This repository has been archived by the owner on Sep 25, 2023. It is now read-only.

[FEA]Discrete Wavelet Transform #327

Open
codesteller86 opened this issue Feb 24, 2021 · 5 comments
Open

[FEA]Discrete Wavelet Transform #327

codesteller86 opened this issue Feb 24, 2021 · 5 comments
Labels
? - Needs Triage Need team to review and classify feature request New feature or request inactive-30d inactive-90d

Comments

@codesteller86
Copy link

Is your feature request related to a problem? Please describe.
I wish I could use cuSignal to work on Discrete Wavelet Transforms in a way like I use PyWavelets
(cA, cD) = pywt.dwt(arr, 'db1',axis=-1)

Describe the solution you'd like
I would like to have a single api to take an array of data and the mother wavelets, which is GPU accelerated and produces output as in PyWavelets

Describe alternatives you've considered
cuSignal has CWT, but this does not work for our usecase. Also tried https://github.com/pierrepaleo/PDWT, but it does not work with variations in wavelets as input.

Additional context
A similar to PyWavelets
(cA, cD) = pywt.dwt(arr, 'db1',axis=-1)

@codesteller86 codesteller86 added ? - Needs Triage Need team to review and classify feature request New feature or request labels Feb 24, 2021
@grlee77
Copy link

grlee77 commented Feb 24, 2021

Hi @codesteller. It sounds like your use case is primarily for 1D signals?

I am a maintainer at PyWavelets and had worked on a new package for discrete wavelet transforms (and more general, overcomplete framelet transforms such as shearlets, dual-tree wavelets, etc) that have both NumPy and CuPy backends. This was done as a research project and is currently still in a private repository. A few years back, I had unsuccessfully applied for an academic grant to support its development and transition into a more mature open source package. I have since moved to a software development role at Quansight and no longer have an immediate research need for these transforms, but would like to see the past work I did be of benefit to others.

Although there are still some things in the API that were a bit experimental, I am interested in making it available. It is mainly a matter of finding time to do so.

One possibility would be extracting a minimal subset of features for inclusion here (maybe just traditional covering PyWavelets dwt, idwt, wavedec and waverec). This repository already has an upfirdn function that can be used for the core convolution operations in these transforms. If we want to reproduce all of the boundary modes from PyWavelets, though, those would need to adapt that code from another upfirdn implementation I previously published at https://github.com/mritools/fast_upfirdn.

A second possibility is publishing in a new PyFramelets repository under the PyWavelets organization. The main drawback of that approach is that we don't have CI infrastructure there for testing on GPUs and I suspect we will find it challenging to find resources to adequately maintain the package.

I am interested in hearing from cuSignal devs on the relative level of interest in wavelet transforms for cuSignal. In the past, I was most interested in use cases applying to 3D (or 3D + channels) medical imaging datasets, so the implementations I have are n-dimensional and have the general ability to select which axes the transform would be applied over.

cc @jakirkham , @quasiben , @rgommers for awareness

@awthomp
Copy link
Member

awthomp commented Feb 24, 2021

Hey @grlee77 -- always great hearing your perspective.

I'm completely supportive of having cuSignal be the home for your stripped-down implementations of dwt, idwt, and others and would even support changes to upfirdn to accommodate this added functionality.

That said, if you've been following my GitHub commit history, you can probably guess that I've been spending more time on the 'customer' side than the 'developer' side lately and would strongly rely on you and the broader community to build out these features in cuSignal. I'll contribute as much as I can!

I've designed cuSignal to be the "big tent" signal processing library focused on developer productivity, and I think wavelets make sense having a home here. I'm also okay if they're not totally optimized on GPU. Let's get features into the community's hands and see how fast they need to go.

@codesteller86
Copy link
Author

@grlee77 Thanks for your inputs and sorry for the delayed response. It is really great to look into your repo. It seems to be a good starting point for me to find a way of implementing this in my current work.
That said, I agree with @awthomp that it will be nice to have these algorithms available in cuSignal. I would gladly work with you and others interested in integrating or implementing these functionalities.

@github-actions
Copy link

github-actions bot commented Apr 3, 2021

This issue has been labeled inactive-30d due to no recent activity in the past 30 days. Please close this issue if no further response or action is needed. Otherwise, please respond with a comment indicating any updates or changes to the original issue and/or confirm this issue still needs to be addressed. This issue will be labeled inactive-90d if there is no activity in the next 60 days.

@github-actions
Copy link

This issue has been labeled inactive-90d due to no recent activity in the past 90 days. Please close this issue if no further response or action is needed. Otherwise, please respond with a comment indicating any updates or changes to the original issue and/or confirm this issue still needs to be addressed.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
? - Needs Triage Need team to review and classify feature request New feature or request inactive-30d inactive-90d
Projects
Status: No status
Development

No branches or pull requests

3 participants