Skip to content

Improve functionality of Hazard.from_raster_xarray#589

Merged
emanuel-schmid merged 8 commits intodevelopfrom
feature/update-hazard-from-raster-xarray
Jan 12, 2023
Merged

Improve functionality of Hazard.from_raster_xarray#589
emanuel-schmid merged 8 commits intodevelopfrom
feature/update-hazard-from-raster-xarray

Conversation

@peanutfun
Copy link
Copy Markdown
Member

@peanutfun peanutfun commented Nov 23, 2022

Changes proposed in this PR:

  • Repeat single-valued data
  • Set default fraction to None, which complies with the new __init__ signature
  • Update docs
  • Update tests

The changes of this PR help me implement my GloFAS river flood model, see CLIMADA-project/climada_petals#60

PR Author Checklist

PR Reviewer Checklist

* Repeat single-valued coordinates/attributes for the number of events
  loaded.
* Transform dates into ordinals instead of directly loading ordinals.
* Optionally repeat 'frequency' data.
* Set default 'fraction' to None, complying with the new __init__.
* Add tests for repeating single-valued data.
* Modify tests to check for correct fraction initialization.
@peanutfun peanutfun changed the base branch from main to develop November 23, 2022 15:35
@peanutfun peanutfun marked this pull request as ready for review November 23, 2022 15:37
@peanutfun
Copy link
Copy Markdown
Member Author

@emanuel-schmid I finished working on this, it's ready for review! 🙌

@emanuel-schmid emanuel-schmid merged commit 7560bcc into develop Jan 12, 2023
@emanuel-schmid emanuel-schmid deleted the feature/update-hazard-from-raster-xarray branch January 12, 2023 14:58
@peanutfun peanutfun mentioned this pull request Jan 13, 2023
11 tasks
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

Successfully merging this pull request may close these issues.

2 participants