I'm trying to use the Modeller class to add explicit waters to a protein. I have PDB and PSF files for the protein and topology and parameter files for CHARMM. The addSolvent() method seems inconsistent as to what topology and forcefield should be but I could just be confused.
Code: Select all
psf = CharmmPsfFile(...)
pdb = PDBFile(...)
params = CharmmParameterSet(...)
Code: Select all
system = psf.createSystem(params, nonbondedCutoff=CutoffNonPeriodic)
Code: Select all
modeller = Modeller(params, pdb.positions)
modeller.addSolvent(psf, boxSize=[5.0, 5.0, 5.0])
File "prepare-water-box.py", line 31, in create_system
modeller.addSolvent(psf, boxSize=[5.0, 5.0, 5.0])
File "/usr/lib64/python2.7/site-packages/simtk/openmm/app/modeller.py", line 337, in addSolvent
for chain in self.topology.chains():
AttributeError: 'CharmmParameterSet' object has no attribute 'chains'
Code: Select all
system = forcefield.createSystem(self.topology)