Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

apply (without concat) #39

Open
gavinmischler opened this issue Aug 9, 2022 · 3 comments
Open

apply (without concat) #39

gavinmischler opened this issue Aug 9, 2022 · 3 comments

Comments

@gavinmischler
Copy link
Collaborator

gavinmischler commented Aug 9, 2022

Expected Behavior

Add an apply method without concatenating for the array_ops module, because sometimes we don't want across-trial edge effects.

@gavinmischler gavinmischler changed the title apply (without concat apply (without concat) Aug 9, 2022
@gavinmischler
Copy link
Collaborator Author

Actually is there a use case for this that simple list-comprehension couldn't do?

outstruct['new'] = [function(x) for x in outstruct['old']]

@menoua
Copy link
Member

menoua commented Apr 8, 2023

I can only think of a use case where the data is too large and you want to modify a field in-place, trial-by-trial. But writing a for loop for that would be just 1-2 lines anyway. So, I would say not adding any new functionality.

@menoua
Copy link
Member

menoua commented Apr 8, 2023

This is connected to #102, which I also don't think is necessary. It would be easy to implement, but whatever the function is that is being applied, more than likely there's plenty of room for parallelization within that function (per trial) to not necessitate parallelizing over trials.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants