Skip to content

Commit

Permalink
Remove the parameters property before creating a partial molecule.
Browse files Browse the repository at this point in the history
  • Loading branch information
lohedges committed Apr 8, 2024
1 parent 044ad4a commit f1fb052
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
6 changes: 6 additions & 0 deletions python/BioSimSpace/Align/_merge.py
Original file line number Diff line number Diff line change
Expand Up @@ -1417,6 +1417,12 @@ def _removeDummies(molecule, is_lambda1):
is_lambda1=is_lambda1, generate_intrascale=True
)

# Remove the parameters property, if it exists.
if "parameters" in molecule._sire_object.propertyKeys():
molecule._sire_object = (
molecule._sire_object.edit().removeProperty("parameters").commit()
)

# Set the coordinates to those at lambda = 0
molecule._sire_object = (
molecule._sire_object.edit().setProperty("coordinates", coordinates).commit()
Expand Down
6 changes: 6 additions & 0 deletions python/BioSimSpace/Sandpit/Exscientia/Align/_merge.py
Original file line number Diff line number Diff line change
Expand Up @@ -1561,6 +1561,12 @@ def _removeDummies(molecule, is_lambda1):
is_lambda1=is_lambda1, generate_intrascale=True
)

# Remove the parameters property, if it exists.
if "parameters" in molecule._sire_object.propertyKeys():
molecule._sire_object = (
molecule._sire_object.edit().removeProperty("parameters").commit()
)

# Set the coordinates to those at lambda = 0
molecule._sire_object = (
molecule._sire_object.edit().setProperty("coordinates", coordinates).commit()
Expand Down

0 comments on commit f1fb052

Please sign in to comment.