How to write a CV splitter for ragged data? #31281
Unanswered
Jacob-Stevens-Haas
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I was writing a gridsearch experiment for interpolation/smoothing. I train on some regular interval of data points, and validate on some intermediate points, so here's my splitter:
If I have a list of trajectories of the same length, it should work to stack the data in shape (n_obs, n_trajectories). However, if the trajectories are different lengths, I can't stack them. The only solution I can think of is to pad with nans and stack, but that's a bad idea: it requires changes to the library's
model.fit()
,predict()
in order to implement a convention that only matters in client code.Would love any advice on how to write a splitter for ragged (list of list) data. Or more generally, how to write a splitter for custom containers.
Beta Was this translation helpful? Give feedback.
All reactions