[AMBER] Memory footprint goes on increasing: pytraj traj.iterchunk used, distances between bonds calculation

From: SHAILESH KUMAR <shaile27_sit.jnu.ac.in>
Date: Sun, 12 Mar 2017 21:17:30 +0100

Dear all,

I am trying to process a big trajectory which can not fit in memory my
computer. So, I tried using Iterating over the full trajectory using
iterchunk method in pytraj. In each iteration bond lengths are calculated
for the frames in chunk, and can be written to a file (which currently is
disable for memory profiling purpose) for further analysis because memory
footprint of the process keeps on growing.

Its pseudo code can be as follows:

traj = ptraj.iterload(trajfile, prmtopfile, frame_slice=slice_info)

for chunk in traj.iterchunk(chunk_size, start=0, start=-1):
     bnd_vals = pt.distance(chunk, bnd_list, dtype='ndarray')
     # do process bnd_vals() ## curently disabled
     gc.collect()

But on memory profiling it was observed that memory keeps on increasing in
ievery iteration of chunks. Which indicates memory leak in
bnd_vals = pt.distance(chunk, bnd_list, dtype='ndarray')
but why is not clear to me. May be I am doing something wrong and not able
to spot it, or there is memory leak somewhere (may be in api).


Now I ask for help, if any one can help me to sort it out, it would be a
great favor. For reproduciblity i am attaching simplified code, with
necessary input files except trajectory, i can share it using dropbox when
needed. This test dataset corresponds to a small molecule. Actual problem
is to do similar for actual protein molecules.


_______________________________________________
AMBER mailing list
AMBER.ambermd.org
http://lists.ambermd.org/mailman/listinfo/amber

Received on Sun Mar 12 2017 - 13:30:03 PDT
Custom Search