Skip to content

Error message when running Scales function #82

Description

@ivan-marroquin

Hi,

Thanks for such great package!

I am using Python 3.12.0 on a Windows 10 laptop with fcwt 0.1.18. I get the following error message:

File "C:\Temp\python_fun\GPR_USA\test_fcwt.py", line 39, in
scales_red_channel= fcwt.Scales(wav, fcwt.FCWT_LINFREQS, fs, f0, f1, fn)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Temp\python_3.12.0\Lib\site-packages\fcwt\fcwt.py", line 119, in init
_fcwt.Scales_swiginit(self, _fcwt.new_Scales(pwav, st, fs, f0, f1, fn))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: in method 'new_Scales', argument 3 of type 'int'

Here is the code:

import numpy as np
import fcwt

dt= 4.8146e-11 # sec
fs= 1 / dt # Hz

central_frequency= 6000 # Hz

f0, f1= float(central_frequency - 100), float(central_frequency + 100)
freqs_red_channel= np.arange(f0, f1, 10)
fn= float(len(freqs_red_channel))

wav= fcwt.Morlet(bandwidth= 2.0)

scales_red_channel= fcwt.Scales(wav, fcwt.FCWT_LINFREQS, fs, f0, f1, fn)

Thanks,
Ivan

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions