I've got a simple nested list comprehension but can't wrap my head around how I'm supposed to write that into clean numpy code. (Which I have to, for speed improvements)
Here is my list comprehension:
import numpy as np
all_as = np.arange(-1, 1+0.01, 0.01)
all_cs = np.arange(-1, 1+0.01, 0.01)
out = [(a,c) for c in all_cs for a in all_as]
out = np.array(out) # obviously not very efficient...
I'm sure there is a way to not first create a list, but I don't see how.
I know there've been a lot similar questions, but none of them really helped me.