def create_coords(self, curr_dir, dir_name, lig_morph, pdb_file, system, cmd1, cmd2, boxdims): """ """ mol2 = os.path.join(curr_dir, dir_name, const.MORPH_NAME + const.MOL2_EXT) util.write_mol2(lig_morph, mol2, False, self.zz_atoms) # we should now have a new MOL2 with updated coordinates for the ligand # these will have to be 'pasted' into the system and new crd/top be # prepared com = self.ff.Complex(pdb_file, mol2) com.box_dims = boxdims com.frcmod = self.frcmod com.ligand_fmt = 'mol2' com.prepare_top(gaff=self.gaff) com.create_top(boxtype='set', addcmd=cmd1 + cmd2) # FIXME: we do that already in setup but calling create_coords # from morph.py has not picked up on this lig_morph = finalise_morph(lig_morph, self.atoms_final, self.atom_map) patch_element(com.amber_top, lig_morph, self.lig_initial, self.lig_final, self.atom_map) com.lig_flex() if type(system) == self.ff.Complex: com.prot_flex()
def setup(self, curr_dir, lig_morph, cmd1, cmd2): patch_parms = [] if self.FE_sub_type[:8] == 'softcore': state0, state1 = amber.softcore(lig_morph, self.lig_final, self.atom_map) pert0_info, pert1_info = None, None elif self.FE_sub_type[:5] == 'dummy': state0 = lig_morph state1, pert0_info, pert1_info = \ amber.dummy(lig_morph, self.con_morph, self.lig_final, self.atom_map) else: raise NotImplementedError amber.write_mdin(self.atoms_initial, self.atoms_final, self.atom_map, 'pmemd', self.FE_sub_type, True) mol2_0 = os.path.join(curr_dir, const.MORPH_NAME + '0' + const.MOL2_EXT) util.write_mol2(state0, mol2_0, resname=const.LIGAND0_NAME) frcmod0 = os.path.join(curr_dir, const.MORPH_NAME + '0.frcmod') mol2_1 = os.path.join(curr_dir, const.MORPH_NAME + '1' + const.MOL2_EXT) util.write_mol2(state1, mol2_1, resname=const.LIGAND1_NAME) frcmod1 = os.path.join(curr_dir, const.MORPH_NAME + '1.frcmod') lig = self.ff.Ligand(const.MORPH_NAME, start_file=mol2_0, start_fmt='mol2', frcmod=frcmod0, gaff=self.gaff) lig.set_atomtype(self.gaff) lig._parmchk(mol2_0, 'mol2', frcmod0) lig._parmchk(mol2_1, 'mol2', frcmod1) if self.FE_sub_type == 'softcore' or self.FE_sub_type == 'dummy': lig._parm_overwrite = 'onestep' self.files_created.extend(('onestep.parm7', 'onestep.rst7')) if self.FE_sub_type == 'softcore3' or self.FE_sub_type == 'dummy3': lig._parm_overwrite = 'vdw' self.files_created.extend(('vdw.parm7', 'vdw.rst7')) if self.FE_sub_type == 'softcore' or self.FE_sub_type == 'softcore3' \ or self.FE_sub_type == 'dummy3': if pert0_info: pert0 = pert0_info else: pert0 = '' if pert1_info: pert1 = pert1_info else: pert1 = '' lig.prepare_top(pert=pert0) lig.leap.add_mol(mol2_1, 'mol2', [frcmod1], pert=pert1) lig.create_top(boxtype='', addcmd=cmd1 + cmd2) if self.FE_sub_type == 'softcore2' or self.FE_sub_type == 'dummy2': ow_add = '_int' if self.FE_sub_type == 'dummy2': f = True else: f = False int_state = util.transfer_charges(state0, state1, self.atom_map, f) mol2_int = os.path.join(curr_dir, const.MORPH_NAME + ow_add + const.MOL2_EXT) util.write_mol2(int_state, mol2_int, resname=const.INT_NAME) lig = self.ff.Ligand(const.MORPH_NAME, start_file=mol2_0, start_fmt='mol2', frcmod=frcmod0, gaff=self.gaff) lig.set_atomtype(self.gaff) if self.dummies0: lig._parm_overwrite = 'vdw' patch_parms.append( (lig._parm_overwrite, ':%s' % const.LIGAND0_NAME, ':%s' % const.INT_NAME)) else: lig._parm_overwrite = 'charge' lig.prepare_top(pert=pert0_info) # intermediate state does never have dummies lig.leap.add_mol(mol2_int, 'mol2', [frcmod1]) lig.create_top(boxtype='', addcmd=cmd1 + cmd2) lig = self.ff.Ligand(const.MORPH_NAME, start_file=mol2_int, start_fmt='mol2', frcmod=frcmod1, gaff=self.gaff) lig.set_atomtype(self.gaff) if self.dummies1: lig._parm_overwrite = 'vdw' patch_parms.append( (lig._parm_overwrite, ':%s' % const.INT_NAME, ':%s' % const.LIGAND1_NAME)) else: lig._parm_overwrite = 'charge' # intermediate state does never have dummies lig.prepare_top() lig.leap.add_mol(mol2_1, 'mol2', [frcmod0], pert=pert1_info) lig.create_top(boxtype='', addcmd=cmd1 + cmd2) self.files_created.extend( ('charge.parm7', 'charge.rst7', 'vdw.par7', 'vdw.rst7')) # FIXME: residue name will be both the same elif self.FE_sub_type == 'softcore3' or self.FE_sub_type == 'dummy3': lig = self.ff.Ligand(const.MORPH_NAME, start_file=mol2_0, start_fmt='mol2', frcmod=frcmod0, gaff=self.gaff) lig.set_atomtype(self.gaff) lig._parm_overwrite = 'decharge' patch_parms.append( (lig._parm_overwrite, ':%s' % const.LIGAND0_NAME, ':%s' % const.LIGAND1_NAME)) lig.prepare_top(pert=pert0) lig.leap.add_mol(mol2_0, 'mol2', [frcmod0], pert=pert0) lig.create_top(boxtype='', addcmd=cmd1 + cmd2) lig = self.ff.Ligand(const.MORPH_NAME, start_file=mol2_1, start_fmt='mol2', frcmod=frcmod1, gaff=self.gaff) lig.set_atomtype(self.gaff) lig._parm_overwrite = 'recharge' if pert1_info: pert = pert1_info else: pert = '' lig.prepare_top(pert=pert1) lig.leap.add_mol(mol2_1, 'mol2', [frcmod1], pert=pert1) lig.create_top(boxtype='', addcmd=cmd1 + cmd2) self.files_created.extend(('recharge.parm7', 'recharge.rst7', 'decharge.parm7', 'decharge.rst7')) elif self.FE_sub_type == 'dummy': lig.prepare_top(pert=pert0_info) lig.leap.add_mol(mol2_1, 'mol2', [frcmod1], pert=pert1_info) lig.create_top(boxtype='', addcmd=cmd1 + cmd2) self.frcmod0 = frcmod0 self.frcmod1 = frcmod1 if self.FE_sub_type[:5] == 'dummy': for prm in patch_parms: util.patch_parmtop(prm[0] + lig.TOP_EXT, "", prm[1], prm[2])
def create_coords(self, curr_dir, dir_name, lig_morph, pdb_file, system, cmd1, cmd2, boxdims): patch_parms = [] if self.FE_sub_type[:8] == 'softcore': state0, state1 = \ amber.softcore(lig_morph, self.lig_final, self.atom_map) pert0_info, pert1_info = None, None elif self.FE_sub_type[:5] == 'dummy': state0 = lig_morph state1, pert0_info, pert1_info = \ amber.dummy(lig_morph, self.con_morph, self.lig_final, self.atom_map) else: raise NotImplementedError amber.write_mdin(self.atoms_initial, self.atoms_final, self.atom_map, 'pmemd', self.FE_sub_type, False) mol2_0 = os.path.join(curr_dir, const.MORPH_NAME + '0' + const.MOL2_EXT) util.write_mol2(state0, mol2_0, resname=const.LIGAND0_NAME) mol2_1 = os.path.join(curr_dir, const.MORPH_NAME + '1' + const.MOL2_EXT) util.write_mol2(state1, mol2_1, resname=const.LIGAND1_NAME) com = self.ff.Complex(pdb_file, mol2_0) com.__class__.SSBONDS_OFFSET = 2 # FIXME: kludge com.box_dims = boxdims com.ligand_fmt = 'mol2' com.frcmod = self.frcmod0 if self.FE_sub_type == 'softcore' or self.FE_sub_type == 'dummy': com._parm_overwrite = 'onestep' if self.FE_sub_type == 'softcore3' or self.FE_sub_type == 'dummy3': com._parm_overwrite = 'vdw' if self.FE_sub_type == 'softcore' or self.FE_sub_type == 'softcore3' \ or self.FE_sub_type == 'dummy3': if pert0_info: pert0 = pert0_info else: pert0 = '' if pert1_info: pert1 = pert1_info else: pert1 = '' com.prepare_top(gaff=self.gaff, pert=pert0) com.leap.add_mol(mol2_1, 'mol2', [self.frcmod1], pert=pert1) com.create_top(boxtype='set', addcmd=cmd1 + cmd2) if self.FE_sub_type == 'softcore2' or self.FE_sub_type == 'dummy2': ow_add = '_int' if self.FE_sub_type == 'dummy2': f = True else: f = False int_state = util.transfer_charges(state0, state1, self.atom_map, f) mol2_int = os.path.join(curr_dir, const.MORPH_NAME + ow_add + const.MOL2_EXT) util.write_mol2(int_state, mol2_int, resname=const.INT_NAME) com = self.ff.Complex(pdb_file, mol2_0) com.__class__.SSBONDS_OFFSET = 2 # FIXME: kludge com.box_dims = boxdims com.ligand_fmt = 'mol2' com.frcmod = self.frcmod0 if self.dummies0: com._parm_overwrite = 'vdw' patch_parms.append( (com._parm_overwrite, ':%s' % const.LIGAND0_NAME, ':%s' % const.INT_NAME)) else: com._parm_overwrite = 'charge' com.prepare_top(gaff=self.gaff, pert=pert0_info) # intermediate state does never have dummies com.leap.add_mol(mol2_int, 'mol2', [self.frcmod1]) com.create_top(boxtype='set', addcmd=cmd1 + cmd2) com = self.ff.Complex(pdb_file, mol2_int) com.__class__.SSBONDS_OFFSET = 2 # FIXME: kludge com.box_dims = boxdims com.ligand_fmt = 'mol2' com.frcmod = self.frcmod1 if self.dummies1: com._parm_overwrite = 'vdw' patch_parms.append( (com._parm_overwrite, ':%s' % const.INT_NAME, ':%s' % const.LIGAND1_NAME)) else: com._parm_overwrite = 'charge' # intermediate state does never have dummies com.prepare_top(gaff=self.gaff) com.leap.add_mol(mol2_1, 'mol2', [self.frcmod0], pert=pert1_info) com.create_top(boxtype='set', addcmd=cmd1 + cmd2) # FIXME: residue name will be both the same elif self.FE_sub_type == 'softcore3' or self.FE_sub_type == 'dummy3': com = self.ff.Complex(pdb_file, mol2_0) com.__class__.SSBONDS_OFFSET = 2 # FIXME: kludge com.box_dims = boxdims com.ligand_fmt = 'mol2' com.frcmod = self.frcmod0 com._parm_overwrite = 'decharge' com.prepare_top(gaff=self.gaff, pert=pert0) com.leap.add_mol(mol2_0, 'mol2', [self.frcmod0], pert=pert0) com.create_top(boxtype='set', addcmd=cmd1 + cmd2) com = self.ff.Complex(pdb_file, mol2_1) com.__class__.SSBONDS_OFFSET = 2 # FIXME: kludge com.box_dims = boxdims com.ligand_fmt = 'mol2' com.frcmod = self.frcmod1 com._parm_overwrite = 'recharge' com.prepare_top(gaff=self.gaff, pert=pert1) com.leap.add_mol(mol2_1, 'mol2', [self.frcmod1], pert=pert1) com.create_top(boxtype='set', addcmd=cmd1 + cmd2) elif self.FE_sub_type == 'dummy': com.prepare_top(gaff=self.gaff, pert=pert0_info) com.leap.add_mol(mol2_1, 'mol2', [self.frcmod1], pert=pert1_info) com.create_top(boxtype='set', addcmd=cmd1 + cmd2) if self.FE_sub_type[:5] == 'dummy': for prm in patch_parms: util.patch_parmtop(prm[0] + com.TOP_EXT, "", prm[1], prm[2])
def setup(self, curr_dir, lig_morph, cmd1, cmd2): if self.FE_sub_type[:8] == 'softcore': state0, state1 = \ amber.softcore(lig_morph, self.lig_final, self.atom_map) pert0_info, pert1_info = None, None elif self.FE_sub_type[:5] == 'dummy': # also for Gromacs and CHARMM state0 = lig_morph state1, pert0_info, pert1_info = \ amber.dummy(lig_morph, self.con_morph, self.lig_final, self.atom_map) else: raise NotImplementedError if self.mdin: amber.write_mdin(self.atoms_initial, self.atoms_final, self.atom_map, 'sander', self.FE_sub_type, True) mol2_0 = os.path.join(curr_dir, const.MORPH_NAME + '0' + const.MOL2_EXT) util.write_mol2(state0, mol2_0) frcmod0 = os.path.join(curr_dir, const.MORPH_NAME + '0.frcmod') lig0 = self.ff.Ligand(const.MORPH_NAME, start_file=mol2_0, start_fmt='mol2', frcmod=frcmod0, gaff=self.gaff) lig0.set_atomtype(self.gaff) lig0._parmchk(mol2_0, 'mol2', frcmod0) lig0._parm_overwrite = 'state0' if pert0_info: lig0.prepare_top(pert=pert0_info) else: lig0.prepare_top() lig0.create_top(boxtype='', addcmd=cmd1 + cmd2) mol2_1 = os.path.join(curr_dir, const.MORPH_NAME + '1' + const.MOL2_EXT) util.write_mol2(state1, mol2_1) frcmod1 = os.path.join(curr_dir, const.MORPH_NAME + '1.frcmod') lig1 = self.ff.Ligand(const.MORPH_NAME, start_file=mol2_1, start_fmt='mol2', frcmod=frcmod1, gaff=self.gaff) lig1.set_atomtype(self.gaff) lig1._parmchk(mol2_1, 'mol2', frcmod1) lig1._parm_overwrite = 'state1' if pert1_info: lig1.prepare_top(pert=pert1_info) else: lig1.prepare_top() lig1.create_top(boxtype='', addcmd=cmd1 + cmd2) self.lig0 = lig0 self.lig1 = lig1 self.frcmod0 = frcmod0 self.frcmod1 = frcmod1 # NOTE: intermediate state assumed to not have dummies, so no # missing parameters fixed through patching! if self.FE_sub_type == 'softcore2' or self.FE_sub_type == 'dummy2': ow_add = '_int' if self.FE_sub_type == 'dummy2': f = True else: f = False int_state = util.transfer_charges(state0, state1, self.atom_map, f) mol2_int = os.path.join(curr_dir, const.MORPH_NAME + ow_add + const.MOL2_EXT) util.write_mol2(int_state, mol2_int, resname=const.INT_NAME) lig = self.ff.Ligand(const.MORPH_NAME, start_file=mol2_int, start_fmt='mol2', frcmod=frcmod0, gaff=self.gaff) lig.set_atomtype(self.gaff) lig._parm_overwrite = 'state_int' lig.prepare_top(add_frcmods=[frcmod1]) lig.create_top(boxtype='', addcmd=cmd1 + cmd2) if self.FE_sub_type == 'dummy' or self.FE_sub_type == 'dummy2': top0 = lig0._parm_overwrite + lig0.TOP_EXT top1 = lig1._parm_overwrite + lig1.TOP_EXT util.patch_parmtop(top0, top1, ':%s' % const.LIGAND_NAME, '') if self.FE_sub_type == 'dummy3': ow_add = '_int' int_mol = util.zero_charges(state1, self.atom_map) mol2_int = os.path.join(curr_dir, const.MORPH_NAME + ow_add + const.MOL2_EXT) util.write_mol2(int_mol, mol2_int, resname=const.LIGAND_NAME) lig = self.ff.Ligand(const.MORPH_NAME, start_file=mol2_int, start_fmt='mol2', frcmod=frcmod1, gaff=self.gaff) lig.set_atomtype(self.gaff) lig._parm_overwrite = 'state_int' lig.prepare_top(pert=pert1_info) lig.create_top(boxtype='') top0 = lig0._parm_overwrite + lig0.TOP_EXT int_name = lig._parm_overwrite + lig.TOP_EXT top1 = lig1._parm_overwrite + lig1.TOP_EXT util.patch_parmtop(top0, int_name, ':%s' % const.LIGAND_NAME, '') util.patch_parmtop(int_name, top1, ':%s' % const.LIGAND_NAME, '') self.int_state = lig
def create_coords(self, curr_dir, dir_name, lig_morph, pdb_file, system, cmd1, cmd2, boxdims): if self.FE_sub_type[:8] == 'softcore': state0, state1 = \ amber.softcore(lig_morph, self.lig_final, self.atom_map) pert0_info, pert1_info = None, None elif self.FE_sub_type[:5] == 'dummy': # also for Gromacs and CHARMM state0 = lig_morph state1, pert0_info, pert1_info = \ amber.dummy(lig_morph, self.con_morph, self.lig_final, self.atom_map) leap_extra = 'source "%s"\n' else: raise NotImplementedError if self.mdin: amber.write_mdin(self.atoms_initial, self.atoms_final, self.atom_map, 'sander', self.FE_sub_type, False) mol2_0 = os.path.join(curr_dir, const.MORPH_NAME + '0' + const.MOL2_EXT) util.write_mol2(state0, mol2_0) com0 = self.ff.Complex(pdb_file, mol2_0) com0.box_dims = boxdims com0.ligand_fmt = 'mol2' com0.frcmod = self.frcmod0 com0._parm_overwrite = 'state0' com0.ligand_fmt = 'mol2' if pert0_info: com0.prepare_top(gaff=self.gaff, pert=pert0_info) else: com0.prepare_top(gaff=self.gaff) com0.create_top(boxtype='set', addcmd=cmd1 + cmd2) mol2_1 = os.path.join(curr_dir, const.MORPH_NAME + '1' + const.MOL2_EXT) util.write_mol2(state1, mol2_1) com1 = self.ff.Complex(pdb_file, mol2_1) com1.box_dims = boxdims com1.ligand_fmt = 'mol2' com1.frcmod = self.frcmod1 com1._parm_overwrite = 'state1' if pert1_info: com1.prepare_top(gaff=self.gaff, pert=pert1_info) else: com1.prepare_top(gaff=self.gaff) com1.create_top(boxtype='set', addcmd=cmd1 + cmd2) if self.FE_sub_type == 'softcore2' or self.FE_sub_type == 'dummy2': ow_add = '_int' if self.FE_sub_type == 'dummy2': f = True else: f = False int_state = util.transfer_charges(state0, state1, self.atom_map, f) mol2_int = os.path.join(curr_dir, const.MORPH_NAME + ow_add + const.MOL2_EXT) util.write_mol2(int_state, mol2_int, resname=const.INT_NAME) com = self.ff.Complex(pdb_file, mol2_int) com.box_dims = boxdims com.ligand_fmt = 'mol2' com.frcmod = self.frcmod1 com._parm_overwrite = 'state_int' com.prepare_top(add_frcmods=[self.frcmod0]) com.create_top(boxtype='set', addcmd=cmd1 + cmd2) if self.FE_sub_type == 'dummy' or self.FE_sub_type == 'dummy2': top0 = com0._parm_overwrite + com0.TOP_EXT top1 = com1._parm_overwrite + com1.TOP_EXT util.patch_parmtop(top0, top1, ':%s' % const.LIGAND_NAME, '') self.parmtop = top0 self.inpcrd = com0._parm_overwrite + com0.RST_EXT if self.FE_sub_type == 'dummy3': # for GROMACS and CHARMM ow_add = '_int' int_mol = util.zero_charges(state1, self.atom_map) mol2_int = os.path.join(curr_dir, const.MORPH_NAME + ow_add + const.MOL2_EXT) util.write_mol2(int_mol, mol2_int, resname=const.LIGAND_NAME) com = self.ff.Complex(pdb_file, mol2_int) com.box_dims = boxdims com.ligand_fmt = 'mol2' com.frcmod = self.frcmod1 com._parm_overwrite = 'state_int' if pert1_info: com.prepare_top(gaff=self.gaff, pert=pert1_info) else: com.prepare_top(gaff=self.gaff) com.create_top(boxtype='set') top0 = com0._parm_overwrite + com0.TOP_EXT int_name = com._parm_overwrite + com.TOP_EXT top1 = com1._parm_overwrite + com1.TOP_EXT util.patch_parmtop(top0, int_name, ':%s' % const.LIGAND_NAME, '') util.patch_parmtop(int_name, top1, ':%s' % const.LIGAND_NAME, '') self.parmtop0 = top0 self.inpcrd0 = com0._parm_overwrite + com0.RST_EXT self.parmtop1 = top1 self.inpcrd1 = com1._parm_overwrite + com1.RST_EXT self.int_state = com
def setup(self, curr_dir, lig_morph, cmd1, cmd2): """ """ mol2 = os.path.join(curr_dir, const.MORPH_NAME + const.MOL2_EXT) util.write_mol2(lig_morph, mol2, False, self.zz_atoms) # create a new Ligand from the MOL2 self.frcmod = os.path.join(curr_dir, const.MORPH_NAME + '.frcmod') # FIXME: Ligand class needs some redesign! lig = self.ff.Ligand(const.MORPH_NAME, start_file=mol2, start_fmt='mol2', frcmod=self.frcmod, gaff=self.gaff) # prevent antechamber from running over the MOL2 file lig.set_atomtype(self.gaff) lig._parmchk(mol2, 'mol2', self.frcmod) lig.prepare_top() lig.create_top(boxtype='', addcmd=cmd1 + cmd2) lig.flex() # To get the bonded parameters we reload the morph topolgy because # lig_morph does not have the "amberparameters" property. Would it be # possible to create those? We assume the ligand is the first molecule. top, crd = lig.amber_top, lig.amber_crd try: molecules = Sire.IO.Amber().readCrdTop(crd, top)[0] except UserWarning as error: raise errors.SetupError('error opening %s/%s: %s' % (crd, top, error)) new_morph = molecules.first().molecule() lig_morph = finalise_morph(lig_morph, self.atoms_final, self.atom_map) # FIXME: adapt for step protocols if self.FE_sub_type == 'dummy': make_pert_file(lig_morph, new_morph, 'onestep', 'initial_charge', 'final_charge', 'initial_LJ', 'final_LJ', 'initial_ambertype', 'final_ambertype', self.lig_initial, self.lig_final, self.atoms_final, self.atom_map, self.reverse_atom_map, self.zz_atoms, False) self.files_created.extend( ('onestep.parm7', 'onestep.rst7', const.MORPH_NAME + os.extsep + 'onestep' + os.extsep + 'pert')) elif self.FE_sub_type == 'dummy2': if self.dummies0: make_pert_file(lig_morph, new_morph, 'charge', 'initial_charge', 'final_charge', 'final_LJ', 'final_LJ', 'final_ambertype', 'final_ambertype', self.lig_initial, self.lig_final, self.atoms_final, self.atom_map, self.reverse_atom_map, self.zz_atoms, True) make_pert_file(lig_morph, new_morph, 'vdw', 'initial_charge', 'initial_charge', 'initial_LJ', 'final_LJ', 'initial_ambertype', 'final_ambertype', self.lig_initial, self.lig_final, self.atoms_final, self.atom_map, self.reverse_atom_map, self.zz_atoms, False) else: make_pert_file(lig_morph, new_morph, 'charge', 'initial_charge', 'final_charge', 'initial_LJ', 'initial_LJ', 'initial_ambertype', 'initial_ambertype', self.lig_initial, self.lig_final, self.atoms_final, self.atom_map, self.reverse_atom_map, self.zz_atoms, True) make_pert_file(lig_morph, new_morph, 'vdw', 'final_charge', 'final_charge', 'initial_LJ', 'final_LJ', 'initial_ambertype', 'final_ambertype', self.lig_initial, self.lig_final, self.atoms_final, self.atom_map, self.reverse_atom_map, self.zz_atoms, False) self.files_created.extend( ('charge.parm7', 'charge.rst7', const.MORPH_NAME + os.extsep + 'charge' + os.extsep + 'pert', 'vdw.parm7', 'vdw.rst7', const.MORPH_NAME + os.extsep + 'vdw' + os.extsep + 'pert')) elif self.FE_sub_type == 'dummy3': make_pert_file(lig_morph, new_morph, 'decharge', 'initial_charge', 'zero_all', 'initial_LJ', 'initial_LJ', 'initial_ambertype', 'initial_ambertype', self.lig_initial, self.lig_final, self.atoms_final, self.atom_map, self.reverse_atom_map, self.zz_atoms, False) make_pert_file(lig_morph, new_morph, 'vdw', 'zero_all', 'zero_all', 'initial_LJ', 'final_LJ', 'initial_ambertype', 'final_ambertype', self.lig_initial, self.lig_final, self.atoms_final, self.atom_map, self.reverse_atom_map, self.zz_atoms, False) make_pert_file(lig_morph, new_morph, 'recharge', 'zero_all', 'final_charge', 'final_LJ', 'final_LJ', 'final_ambertype', 'final_ambertype', self.lig_initial, self.lig_final, self.atoms_final, self.atom_map, self.reverse_atom_map, self.zz_atoms, False) self.files_created.extend( ('decharge.parm7', 'decharge.rst7', const.MORPH_NAME + os.extsep + 'decharge' + os.extsep + 'pert', 'vdw.parm7', 'vdw.rst7', const.MORPH_NAME + os.extsep + 'vdw' + os.extsep + 'pert', 'recharge.parm7', 'recharge.rst7', const.MORPH_NAME + os.extsep + 'recharge' + os.extsep + 'pert')) patch_element(lig.amber_top, lig_morph, self.lig_initial, self.lig_final, self.atom_map)