expelliarmus
expelliarmus copied to clipboard
Dynamic allocation of arrays
Right now, the files are read in advance to count the number of events. Then, this number is used to allocate a NumPy array on the Python side, that is then filled by the C code. We would like to use dynamic memory allocation to generate the array as we read the file and, then, generate a NumPy array from it.
This was the initial implementation but it was too dumb, leading to poor performance.