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

Pre-compute sequence-dim coordinates in prepare_target #90

Closed
rabernat opened this issue Apr 1, 2021 · 3 comments
Closed

Pre-compute sequence-dim coordinates in prepare_target #90

rabernat opened this issue Apr 1, 2021 · 3 comments

Comments

@rabernat
Copy link
Contributor

rabernat commented Apr 1, 2021

We currently build up the sequence-dim coordinate (usually time) one chunk at a time. As noted by @shoyer in #86 (comment), it may often be possible to pre-populate this information and write the entire chunk at once inside prepare_target.

An alternative would be to consolidate the sequence_dim chunks at the end, in finalize_target. That would likely be more robust to corner cases.

@martindurant
Copy link
Contributor

Is there a possibility of a post-process step to consolidate coordinate data? It could depend on some heuristic for chunk-size.

@rabernat
Copy link
Contributor Author

rabernat commented Apr 1, 2021

That is what finalize_target is for.

https://github.com/pangeo-forge/pangeo-forge/blob/3314162568f7d8fe3d6f06627b936cee55d99c9c/pangeo_forge/recipe.py#L316-L324

We could easily add consolidation of chunks to that step.

@rabernat
Copy link
Contributor Author

The post-write consolidation of coordinates has been implemented in #210. I'm going to close this for now. Thanks for the suggestions everyone.

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