Skip to content
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

Memory error in lomb_scargle.py #282

Open
vberten opened this issue Jan 18, 2019 · 5 comments
Open

Memory error in lomb_scargle.py #282

vberten opened this issue Jan 18, 2019 · 5 comments
Assignees

Comments

@vberten
Copy link

vberten commented Jan 18, 2019

Hi there,

I've been using Cesium successfully since several months in Python 3.5, but I upgraded my system to 3.6 recently (and Cesium 0.9.9), and I can't make Cesium working anymore.

I got the following MemroyError :
[...]

/opt/anaconda3/envs/python36/lib/python3.6/site-packages/cesium/features/lomb_scargle.py in fit_lomb_scargle(time, signal, error, f0, df, numf, nharm, psdmin, detrend_order, freq_zoom, tone_control, lambda0, lambda0_range)
    171     hat_hat = np.zeros((npar,npar),dtype='float64')
    172     soln = np.zeros(npar,dtype='float64')
--> 173     psd = np.zeros(numf,dtype='float64')
    174 
    175     # Detrend the data and create the orthogonal detrending basis

MemoryError: 

By adding a "print(numf)" in lomb_scargle.py , I get "648648000000000000", which might explain the error (but I don't explain why I get now this number).

I'm using a "multi-channel" dataset, and some of my time series contain just zero's

I have this error even if I call featurize_time_series with features_to_use=["mean"]. I find a little bit weird that fit_lomb_scargle is called anyway.

Any clue ? Need more info ?

Thanks!

@stefanv
Copy link
Contributor

stefanv commented Jan 18, 2019

That number looks too big, for sure!

Can you try to produce a small, self-contained code snippet that triggers the error?

Also, which platform are you on (Mac, Linux, Win)?

@vberten
Copy link
Author

vberten commented Jan 22, 2019 via email

@stefanv
Copy link
Contributor

stefanv commented Jan 28, 2019

Thanks, @vberten, we will investigate. /cc @acrellin

@stefanv
Copy link
Contributor

stefanv commented Jun 26, 2022

I cannot reproduce; @vberten are you still experiencing this problem?

@stefanv
Copy link
Contributor

stefanv commented Jun 26, 2022

(Perhaps also try v0.10.1, just released, in which I have fixed a few memory allocation issues.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants