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

Loading data in memory vs out of memory: indication in show + conversion + option when opening dataset #447

Open
3 tasks
briochemc opened this issue Oct 4, 2024 · 5 comments
Labels
documentation Improvements or additions to documentation

Comments

@briochemc
Copy link
Contributor

I'm not sure if this had not been asked before or if I should ask elsewhere, but since I was using YAXArrays I thought I should ask here. Maybe this is already doable and I just don't know how. Anyway, here is a triple feature request:

  • It would be nice if the (very nice) show method also showed whether the parent data has been loaded in memory or not. Maybe a "(loaded lazily)/(loaded in memory)" or similar wording?

  • It would also be nice if the docs showed how to load the data in memory from a lazily loaded variable var. My understanding is that I should use modify(Array, var).

  • It may be worth having an option to load data in memory when "opening" a dataset, e.g., maybe with the syntax ds = open_dataset(...; in_memory = true), it would force the data to be loaded in memory? (With default in_memory = false I guess?)

@lazarusA
Copy link
Collaborator

lazarusA commented Oct 4, 2024

hey,

  1. loaded lazily)/(loaded in memory). I guess we could do that.
  2. see readcubedata. Better docs are needed for that one.
  3. maybe just combine with 2?

@felixcremer felixcremer added the documentation Improvements or additions to documentation label Oct 4, 2024
@rafaqz
Copy link
Contributor

rafaqz commented Oct 4, 2024

Rasters uses Base.read and DD forwards it on to the parent (have to check that). Maybe YAX could add that too?

@lazarusA
Copy link
Collaborator

lazarusA commented Oct 4, 2024

Yeah, don't know. open and save -> open_dataset, savecube and save_dataset, need some unification work.

@briochemc
Copy link
Contributor Author

Another one would be to be able to read en entire YAXArray Dataset in memory. Is it possible to do so at this stage or does one need to readdatacube for all vars separately?

@felixcremer
Copy link
Member

I implemented readcubedata for Datasets in #453 and I also added a hint to the data loading in the show method.
This should solve this issue.

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

No branches or pull requests

4 participants