4 ms·
That's because with generic python code the values in a numpy array need to be boxed into python objects leading to extra memory allocations (whereas they would
by infinite8s 8y ago
That's because with generic python code the values in a numpy array need to be boxed into python objects leading to extra memory allocations (whereas they would already be boxed in the built-in list case).