Opened 6 years ago

Closed 6 years ago

#2555 closed defect (fixed)

Memory leak fitting volume in volume

Reported by: andrei@… Owned by: Tom Goddard
Priority: moderate Milestone:
Component: Volume Data Version:
Keywords: Cc:
Blocked By: Blocking:
Notify when closed: Platform: all
Project: ChimeraX

Description (last modified by Tom Goddard)

Begin forwarded message:

From: Andrei Istrate
Subject: ChimeraX memory problem
Date: November 8, 2019 at 6:06:58 AM PST
To: Tom Goddard

Dear Tom,

I am trying to ChimeraX for superimposing a large number of small maps and ran into a memory problem.
It seems that after each fitting an object is created for the results. This object seems to not be deleted after calling “close session” which leads to huge memory consumption after a large number of operations.
I have attached a toy script which can reproduce the problem. Could you please point me to a solution to this problem?
I was previously using chimera for this and had no problems.

Best wishes,
Andrei


Andrei Istrate, EMBL-EBI, Hinxton, UK
Scientific Programmer

Attachments (1)

test_chimerax.zip (138.0 KB ) - added by Tom Goddard 6 years ago.

Download all attachments as: .zip

Change History (4)

by Tom Goddard, 6 years ago

Attachment: test_chimerax.zip added

comment:1 by Tom Goddard, 6 years ago

It seems to increase 3 Mbytes per iteration with your small 0.5 Mbyte map example, but increases much faster ~200 Mbytes per iteration when I use 200 Mbyte map files. So apparently the fitting somehow holds onto a copy of all the data even after close. If I comment out the fitmap call, so only the two maps are opened then closed, then the memory leak does not occur (although some much smaller leak of < 0.5 Mbyte per iteration is visible).

comment:2 by Tom Goddard, 6 years ago

Description: modified (diff)

comment:3 by Tom Goddard, 6 years ago

Resolution: fixed
Status: assignedclosed

Fixed in tonight's ChimeraX builds.

There were two memory leaks. Closing a volume left a reference to the 3d array. Also fitting computed gradients at each grid point at each step and a reference counting error caused these to never delete. That same bug afflicted measuring solvent accessible area.

Also the fitmap calculation was being greatly slowed (a factor several) by excessive status messages, so I reduced the frequency of status messages from hundreds per second to a few per second.

Thanks for reporting the problem.

Note: See TracTickets for help on using tickets.