Original Post
i have a function that declares a numpy array. it looks something like def foo(): A = some array ... the problem - whenever i call foo(), the memory usage gets bumped and pretty soon I'm getting a MemoryError exception. i tried putting del A at the end of the function, but it doesn't seem to help very much. at each run of foo() A may have different dimensions (depends on some other variables) so i cannot (i think?) declare it only once and use it afterwards. any ideas? thanks