[NumPy-Tickets] [NumPy] #1668: Masked array calculations memory leak
NumPy Trac
numpy-tickets@scipy....
Tue Nov 9 03:38:29 CST 2010
#1668: Masked array calculations memory leak
-------------------------+--------------------------------------------------
Reporter: storpipfugl | Owner: somebody
Type: defect | Status: new
Priority: normal | Milestone: 2.0.0
Component: Other | Version: 1.5.0
Keywords: |
-------------------------+--------------------------------------------------
Test code: [[BR]]
--- [[BR]]
mem_leak_ma.py[[BR]]
---
Description:[[BR]]
Use mem_leak_ma.py. At the raw_input('check_mem') line the array
data_array and masked array cal_data_array are the only arrays in scope.
Base memory consumption before calculation is 95 MB. Expected memory
consumption at end of test program: 3712**2*(8*2 + 1)/10**6 + 95 = 329 MB.
Readout from /proc/<pid>/status at line raw_input('check_mem'):
{{{
VmPeak: 848092 kB
VmSize: 484768 kB
}}}
This leaves 156 MB unaccounted for (VmSize).
Expected behavior:
The memory usage at the end of the test program is expected to be
comparable to the corresponding example with a regular ndarray plus memory
usage for the mask.
Working code:[[BR]]
---[[BR]]
mem_leak.py[[BR]]
---
Use mem_leak.py. Readout from /proc/<pid>/status at line
raw_input('check_mem'):
{{{
VmPeak: 417416 kB
VmSize: 309768 kB
}}}
as expected (VmSize).
System:[[BR]]
Ubuntu linux 10.04 64 bit[[BR]]
Python 2.6.5[[BR]]
Reproduced with numpy 1.3.0 and 1.5.0 [[BR]]
--
Ticket URL: <http://projects.scipy.org/numpy/ticket/1668>
NumPy <http://projects.scipy.org/numpy>
My example project
More information about the NumPy-Tickets
mailing list