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

Error message when doing huge operation doesn't give a good suggestion for making operation less huge #915

Open
abulatek opened this issue Jun 20, 2024 · 2 comments

Comments

@abulatek
Copy link

When doing cube.median(axis=0), I get the following error message:

ValueError: This function (<function BaseSpectralCube._apply_everywhere at 0x14f675092790>) requires loading the entire cube into memory, and the cube is large (503316480 pixels), so by default we disable this operation. To enable the operation, set `cube.allow_huge_operations=True` and try again.  Alternatively, you may want to consider using an approach that does not load the whole cube into memory by specifying how='slice' or how='ray'.  See https://spectral-cube.readthedocs.io/en/latest/big_data.html for details.

The suggestion to use how='ray' gives the same error message, as does using iterate_rays=True (which is not suggested by the error message). Adam said this is due to some missing logic cases.

@SpacialTree
Copy link
Contributor

Hey Alyssa!

What version of spectral-cube are you using? The most recent dev version?

@abulatek
Copy link
Author

The last version I pulled was this one, which was designed to fix this issue: https://github.com/radio-astro-tools/spectral-cube/pull/916/files. It looks like it probably does fix this issue, but I was using dask spectral cubes, which don't take these keywords anyway.

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

2 participants