memory leakage

Dear obspy users.

A student of mine uses the attached script to
- read miniSEED files
- decimate the traces
- merge traces
- correct instrument responses
- convert dtype

in a loop over many files. There is a memory leakage in this loop that disappears if the same file is read repeatedly. Any ideas of the cause and how to fix or circumvent?

The system is:
Python 2.7.3
IPython 0.13.1
obspy 0.9.2

Cheers
Christoph

test.py (2.38 KB)

Hi Christoph,

can you upload the data somewhere so we can reproduce the problem? Then I’ll have a look.

A recurring reason for memory leaks are unclosed matplotlib figures but that is not the case in the attached script.

Cheers!

Lion