Bioperl: Memory leak in BLAST modules
Steve Chervitz
sac@neomorphic.com (Steve A. Chervitz)
Wed, 28 Oct 1998 13:03:25 -0800 (PST)
Lincoln,
I've been grappling with the memory leak for a while and have a new
version of Blast.pm that includes a fix for memory leaks when parsing
streams of reports. This is version 0.063 which you can get from:
http://genome-www.stanford.edu/perlOOP/bioperl/lib/Bio/Tools/Blast.pm
Memory use is still an issue, particularly if you are parsing huge
reports (on the order of 1 Mb or more) and not imposing significance
criteria. If you can include even a minimal cutoff (i.e., -signif =>
0.01), that should improve memory usage compared to using no cutoff.
Also, when creating individual Blast objects, it's a good idea to
explicitly destroy them when you're done processing each one
($blast_obj->destroy). Using a single $blast_obj variable and
re-assigning it should accomplish the same thing (but calling
destroy() makes me feel better ;).
If you (or others) have additional ideas for how to improve memory
usage, I'd be happy to hear them. Do you know of a good memory
management tool for Perl that can show reference counts etc. during
the course of an execution?
I haven't bundled the new version of Blast.pm into a distribution
package yet since there are other changes I want to include. But look
for it soon.
Steve
___________________________________________________
Steve A. Chervitz Neomorphic Software
sac@neomorphic.com 2612b 8th Street
http://www.neomorphic.com Berkeley, CA 94710
Lincoln Stein writes:
> Does anyone know of a memory leak in the Bio::Tools::Blast module?
> I've got a script that creates and destroys several thousands of these
> objects and it is definitely leaking. I don't want spend time
> debugging the thing if there's a known problem.
>
> Lincoln
>
> --
> ========================================================================
> Lincoln D. Stein Cold Spring Harbor Laboratory
> lstein@cshl.org Cold Spring Harbor, NY
> ========================================================================
> =========== Bioperl Project Mailing List Message Footer =======
> Project URL: http://bio.perl.org/
> For info about how to (un)subscribe, where messages are archived, etc:
> http://www.techfak.uni-bielefeld.de/bcd/Perl/Bio/vsns-bcd-perl.html
> ====================================================================
>
=========== Bioperl Project Mailing List Message Footer =======
Project URL: http://bio.perl.org/
For info about how to (un)subscribe, where messages are archived, etc:
http://www.techfak.uni-bielefeld.de/bcd/Perl/Bio/vsns-bcd-perl.html
====================================================================