Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
tsoc
openmm
Commits
519d9deb
Commit
519d9deb
authored
Jan 01, 2016
by
John Chodera (MSKCC)
Browse files
Bugfixes in TestForceField
parent
c2dd9975
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
6 deletions
+6
-6
wrappers/python/tests/TestForceField.py
wrappers/python/tests/TestForceField.py
+6
-6
No files found.
wrappers/python/tests/TestForceField.py
View file @
519d9deb
...
@@ -270,21 +270,21 @@ class TestForceField(unittest.TestCase):
...
@@ -270,21 +270,21 @@ class TestForceField(unittest.TestCase):
}
}
forcefield
.
registerAtomType
(
parameters
)
forcefield
.
registerAtomType
(
parameters
)
# Create residue template.
# Create residue template.
residu
e
=
ForceField
.
_TemplateData
(
template_name
)
templat
e
=
ForceField
.
_TemplateData
(
template_name
)
for
atom
in
residue
.
atoms
():
for
atom
in
residue
.
atoms
():
typename
=
'%s-%s-%s'
%
(
template_name
,
residue
.
name
,
atom
.
name
)
typename
=
'%s-%s-%s'
%
(
template_name
,
residue
.
name
,
atom
.
name
)
atom_template
=
ForceField
.
_TemplateAtomData
(
atom
.
name
,
typename
,
atom
.
element
)
atom_template
=
ForceField
.
_TemplateAtomData
(
atom
.
name
,
typename
,
atom
.
element
)
residu
e
.
atoms
.
append
(
atom_template
)
templat
e
.
atoms
.
append
(
atom_template
)
for
(
atom1
,
atom2
)
in
residue
.
internal_bonds
():
for
(
atom1
,
atom2
)
in
residue
.
internal_bonds
():
residu
e
.
addBondByName
(
atom1
.
name
,
atom2
.
name
)
templat
e
.
addBondByName
(
atom1
.
name
,
atom2
.
name
)
residue_atoms
=
[
atom
for
atom
in
residue
.
atoms
()
]
residue_atoms
=
[
atom
for
atom
in
residue
.
atoms
()
]
for
(
atom1
,
atom2
)
in
residue
.
external_bonds
():
for
(
atom1
,
atom2
)
in
residue
.
external_bonds
():
if
atom1
in
residue_atoms
:
if
atom1
in
residue_atoms
:
residu
e
.
addExternalBondByName
(
atom1
.
name
)
templat
e
.
addExternalBondByName
(
atom1
.
name
)
elif
atom2
in
residue_atoms
:
elif
atom2
in
residue_atoms
:
residu
e
.
addExternalBondByName
(
atom2
.
name
)
templat
e
.
addExternalBondByName
(
atom2
.
name
)
# Register the template.
# Register the template.
forcefield
.
registerResidueTemplate
(
residu
e
)
forcefield
.
registerResidueTemplate
(
templat
e
)
# Signal that we have successfully parameterized the residue.
# Signal that we have successfully parameterized the residue.
return
True
return
True
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment