Re: [AMBER] MMPBSA_API: AmberTools13 vs. 15

From: Jason Swails <>
Date: Tue, 23 Jun 2015 10:32:56 -0400

On Tue, Jun 23, 2015 at 9:49 AM, Gerald Monard <> wrote:

> Hello,
> In the same spirit as an earlier email. I'm trying to load
> results with the MMPBA API.
> My scripts, in the spirit of the Amber documentation (section 31.4),
> starts with:
> import os
> import sys
> sys.path.append(os.path.join(os.getenv('AMBERHOME'), 'bin'))

​This line is no longer necessary for AmberTools 15 (since
automatically puts these modules in PYTHONPATH).

> from MMPBSA_mods import API as MMPBSA_API
> results = MMPBSA_API.load_mmpbsa_info('_MMPBSA_info')
> In AmberTools13, no problem:
> >>> results = MMPBSA_API.load_mmpbsa_info('_MMPBSA_info')
> Loading and checking parameter files for compatibility...
> In AmberTools15:
> >>> results = MMPBSA_API.load_mmpbsa_info('_MMPBSA_info')
> Traceback (most recent call last):
> File "<stdin>", line 1, in <module>
> File
> "/opt/amber15-gnu/lib/python2.6/site-packages/MMPBSA_mods/", line
> 358, in load_mmpbsa_info
> app.parse_output_files()
> File
> "/opt/amber15-gnu/lib/python2.6/site-packages/MMPBSA_mods/", line
> 928, in parse_output_files
> self.using_chamber)}
> AttributeError: 'MMPBSA_App' object has no attribute 'using_chamber'

​Indeed, this issue was raised recently, and I issued a fix in update.1 for
AmberTools 15. The quick workaround for the time being is to add the line

using_chamber = False

somewhere in the _MMPBSA_info file (but not in the text of the input file
at the very end). Note that update.1 fixes the *creation* of _MMPBSA_info
to make sure this attribute is properly added, so update.1 won't make a
_MMPBSA_info file generated with an unpatched start working. You
need to actually add that variable. (As another note, obviously change
False to True if your prmtop files are chamber-style prmtops implementing
the CHARMM force field).

> I have checked the source code and could not see any definition of
> using_chamber in the python parts.
> Any idea?

​using_chamber was assigned when the prmtop files were parsed. AmberTools
13 parsed the prmtop files as part of the API, so this attribute
was properly set. However, none of the prmtop information is actually
*used* in the API, so it just slowed down the API significantly. Which is
why prmtop files *stopped* getting read in AmberTools 15 (the data is
populated almost immediately now rather than requiring up to tens of
seconds to parse).

All the best,

Jason M. Swails
Rutgers University
Postdoctoral Researcher
AMBER mailing list
Received on Tue Jun 23 2015 - 08:00:02 PDT
Custom Search