You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Similar to #3256 and #3257, another function that could help ML users is one that turns a ragged array into a simple Python list of tensors. Although the aggr functions in PyTorch-Geometric can use ak.parents_index from #3256 to do a segmented aggregation in one Python call, tools like PyTorch Cluster expect an explicit Python loop over each variable-sized list (e.g. a Python loop over events, calling a vectorized function to process each collection of particles in that event: they're "batched by event.")
Perhaps ak.Array → list[torch.Tensor]? Or → DataLoader (batched by lists in the ragged array)?
Description of new feature
Similar to #3256 and #3257, another function that could help ML users is one that turns a ragged array into a simple Python list of tensors. Although the
aggr
functions in PyTorch-Geometric can useak.parents_index
from #3256 to do a segmented aggregation in one Python call, tools like PyTorch Cluster expect an explicit Python loop over each variable-sized list (e.g. a Python loop over events, calling a vectorized function to process each collection of particles in that event: they're "batched by event.")Perhaps
ak.Array
→list[torch.Tensor]
? Or →DataLoader
(batched by lists in the ragged array)?Cc: @livaage, @GageDeZoort, @maxymnaumchyk, @ianna
The text was updated successfully, but these errors were encountered: