Removed `_in_stack` since it was slow.

- This was really slowing down the creating of large ensemble arrays, and maybe other things too.
- It's easy enough just to do it manually. This also fixes our problem of where to put the `_in_stack` function.