DASDAE / dascore

A python library for distributed fiber optic sensing
Other
71 stars 16 forks source link

Aggregates, patch broadcasting, and refactoring #375

Closed d-chambers closed 2 months ago

d-chambers commented 3 months ago

Description

This is a large PR which implements a few significant changes/improvements:

  1. Adds shortcuts for common patch aggregations (min, max, std, etc.)
  2. Implements patch broadcasting and sub-selection when applying operations
    • Operations can now be applied to patches of different shapes but shared, or broadcastable, dimensions
  3. Support for non-coordinate dimensions
  4. Adds the ability to use arrays in Patch.select
  5. A new method Patch.order which behaves like dataframe.loc
  6. Fixed a few small deprecations from external libraries and bugs with the time utils.

TODO

Checklist

I have (if applicable):

codecov[bot] commented 3 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 99.83%. Comparing base (e206fc2) to head (d39605e).

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #375 +/- ## ========================================== + Coverage 99.60% 99.83% +0.23% ========================================== Files 105 106 +1 Lines 8050 8625 +575 ========================================== + Hits 8018 8611 +593 + Misses 32 14 -18 ``` | [Flag](https://app.codecov.io/gh/DASDAE/dascore/pull/375/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=DASDAE) | Coverage Δ | | |---|---|---| | [unittests](https://app.codecov.io/gh/DASDAE/dascore/pull/375/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=DASDAE) | `99.83% <100.00%> (+0.23%)` | :arrow_up: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=DASDAE#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.