1d light curve collation utility function#951
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #951 +/- ##
==========================================
+ Coverage 63.80% 63.87% +0.07%
==========================================
Files 74 75 +1
Lines 7689 7704 +15
==========================================
+ Hits 4906 4921 +15
Misses 2783 2783 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
|
Generally this seems alright to merge. I worry that it is not generic enough to be generally useful (but perhaps I simply haven't been part of the discussions here) I'm lightly suggesting that we try to talk to folks who would use these collation utilities and try to generalize this, add documentation and examples so we get the full value here. I think a lot of this is human conversational/requirements gathering work, likely leading to a relatively small amount of new code. Not sure if we're on that path yet, but it seems like one we should consider. |
drewoldag
left a comment
There was a problem hiding this comment.
Seems fine to me. I can imagine that users might want to be able to specify a max length as well. To either truncate all light curves with length greater than X, or to ensure that all light curves have length X even if the max in the batch is <X.
Regardless this is a nice jumping off point for people.
| dict | ||
| Contains three keys: `<field>`, `<field>_length`, and `<field>_mask` | ||
| `field` - float32 array (batch, max_len) containing the padded light curves | ||
| `<field>_length` - int64 array (batch) of true light curve lengths |
There was a problem hiding this comment.
| `<field>_length` - int64 array (batch) of true light curve lengths | |
| `<field>_lengths` - int64 array (batch) of true light curve lengths |
Introduces
collate_utils.pyto put utility functions for collation. Adds one such utility function which can be used to pad and mask raw 1D light curves, along with a test for this function.