Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Geometeric Parameters #2

Closed
arosale4 opened this issue May 20, 2015 · 1 comment
Closed

Geometeric Parameters #2

arosale4 opened this issue May 20, 2015 · 1 comment

Comments

@arosale4
Copy link
Contributor

After trying to run a loop of a parameter optimization the following error was found, using the following input:
python loop.py -c " -d DIRECTORY -mh FILENAME" -r -d DIRECTOR -jhi FILENMAE" --ptypes ae

'unrecognized MM3* parameter label: {}' .format(param.mm3_label)
AssertionError: unrecognized MM* parameter label: a2

ericchansen added a commit that referenced this issue May 20, 2015
Each MM3* parameter has what I call a mm3_label. It is the 1st 2
characters of the line containing the values for a given parameter. In
your case, "a2" is the mm3_label. The "a" comes from geometric
dependence on when to use that parameter.

datatypes.py contains the MM3 force field class, and it has the methods
import_ff and export_ff, which do exactly what their names suggest. The
import_ff method worked with these geometry dependent parameters, but
export_ff failed to recognize them. I have since updated datatypes.py
to let it handle this sort of issue. I also added a short test script
to check parameter labels (this is my first of hopefully many tests
that will be implemented).

The MM3 class now has a number of methods that check mm3_label using
regex. I'm still unsure whether these methods are best located here,
but this at least works for now.
@ericchansen
Copy link
Owner

Each MM3* parameter has what I call a mm3_label. It is the 1st 2 characters of the line containing the values for a given parameter. In your case, "a2" is the mm3_label. The "a" comes from geometric dependence on when to use that parameter.

datatypes.py contains the MM3 force field class, and it has the methods import_ff and export_ff, which do exactly what their names suggest. The import_ff method worked with these geometry dependent parameters, but export_ff failed to recognize them. I have since updated datatypes.py to let it handle this sort of issue. I also added a short test script to check parameter labels (this is my first of hopefully many tests that will be implemented). Try pulling the iss2 branch, and then running the following code, but replace PATH_TO_MM3 with the right path.

from datatypes import *

PATH_TO_MM3 = "mm3.fld"

if __name__ == '__main__':
    ff = MM3(PATH_TO_MM3)
    ff.import_ff()
    ff.export_ff()

Alternatively, you could just run whatever command you were using before and see if that error goes away.

ericchansen added a commit that referenced this issue May 20, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants