From: Peter Freddolino (petefred_at_ks.uiuc.edu)
Date: Mon Jun 15 2009 - 09:22:49 CDT

Hi Kumar,
the most likely cause of such an error is that you make an atom
selection in a loop that is not deleted, causing a memory leak. You
should make sure that if you have to make an atom selection during each
iteration of the loop, you also delete it during each iteration.
Best,
Peter

kumar prashanth wrote:
>
> I am working with a trajectory of around 150 frames of a bilayer lipid
> system. The script intends the following.
>
> Makes a fitting of a lipid molecule to some reference lipid and gets the
> atom coordinates of some atoms,which gets printed out.
> And this fitting scheme is generalized over a region by the selection
> "lipid within --- of protein" using a for loop.
>
> I have tried running the script and it crashes after working for a short
> time.
> and it gives a std::bad alloc message.
>
> I guess the problem is with the memory allocation. COuld anyone suggest
> a solution..
> Probably,freeing some memory space could be one. PLease let me know
> about this..
>
>