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
Sometimes, the simulators may return larger arrays than we want to use in our networks, so it would be great to have some subsetting adapter transforms.
We need:
Subsetting within an axis (taking only some elements) while keeping the number of axes the same. This is essentially the np.take functionality so we might want to call this transform take. In contrast to np.take, I would make axis a mandatory arguments or default it to the last axis. Example: adapter.take("x", 1:3, axis = -1)
Subsetting using a random set of indices (of user-specified size) within an axis. We might call this subsample. Internally it would call take after sampling the indices. Example: adapter.subsample("x", size = 3, axis = -1)
Removing an axis of length one. Following numpy, I would call this transform squeeze: Example: adapter.squeeze("x", axis = 1)
The text was updated successfully, but these errors were encountered:
Sometimes, the simulators may return larger arrays than we want to use in our networks, so it would be great to have some subsetting adapter transforms.
We need:
np.take
functionality so we might want to call this transformtake
. In contrast tonp.take
, I would makeaxis
a mandatory arguments or default it to the last axis. Example:adapter.take("x", 1:3, axis = -1)
subsample
. Internally it would calltake
after sampling the indices. Example:adapter.subsample("x", size = 3, axis = -1)
squeeze
: Example:adapter.squeeze("x", axis = 1)
The text was updated successfully, but these errors were encountered: