-
Notifications
You must be signed in to change notification settings - Fork 1
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
An error occurred when using wavelet ezmsg.sigproc.wavelets.cwt #41
Comments
Hi @RuolingWu , I hope you don't mind that I edited your post to make the formatting a little easier to read -- I didn't change any content other than add some backticks. I would need to know what your pipeline is preceding the CWT node. It seems like the signal coming into the node already has a freq axis which maybe suggests a misunderstanding of what the CWT node is intended for. |
Hi Chad, Thanks for changing the format. I checked my code and realised I forgot to delete the node for calculating band power. But after I deleted that node, I got a new error in CWT: I checked the Linear-phase FIR filter coefficients (h) in And here is the entire pipeline:
|
Sorry, what do you mean by "I checked"? Does this mean that you tried running the exact same line of code and it worked for you, so it's only ezmsg that's failing? I've encountered this problem myself and I was forced to use a different wavelet type when doing a minphase CWT. (Note: minphase may or may not be important depending on your task and how much you care about your lower frequency wavelets' delay.) |
Sorry for the confusion. I just put a break point in that line to see the actual value of h. But thank you for your suggestion! And I will run another test on scipy.signal.minimum_phase.minimum_phase(h, method='homomorphic') to figure out if this is an ezmsg problem or a scipy problem. |
I came across the following error when I used ezmsg.sigproc.wavelets.CWT to do wavelet transform:
The error occurred in line 109-119, wavelets.py (https://github.com/ezmsg-org/ezmsg-sigproc/blob/main/src/ezmsg/sigproc/wavelets.py)
I checked the value of
dims=msg_in.dims[:ax_idx] + msg_in.dims[ax_idx + 1 :] + ["freq", axis]
. The result I got is ['freq', ‘ch', ‘freq', ‘time']. It seems that the two ‘freq’ caused the error.And here’s the node I created for the wavelet transform:
"GET_WAVELETS": CWT(scales=scales, wavelet="cmor3.0-0.5", min_phase=MinPhaseMode.HOMOMORPHIC, axis='time')
Environment information:
Python version: 3.12
Conda version: conda 24.4.0
Os: MacOs
The text was updated successfully, but these errors were encountered: