{"action":"closed","issue":{"url":"https://api.github.com/repos/ParmEd/ParmEd/issues/912","repository_url":"https://api.github.com/repos/ParmEd/ParmEd","labels_url":"https://api.github.com/repos/ParmEd/ParmEd/issues/912/labels{/name}","comments_url":"https://api.github.com/repos/ParmEd/ParmEd/issues/912/comments","events_url":"https://api.github.com/repos/ParmEd/ParmEd/issues/912/events","html_url":"https://github.com/ParmEd/ParmEd/issues/912","id":270979842,"number":912,"title":"Dihedral types sorted or not?","user":{"login":"stefdoerr","id":7935362,"avatar_url":"https://avatars3.githubusercontent.com/u/7935362?v=4","gravatar_id":"","url":"https://api.github.com/users/stefdoerr","html_url":"https://github.com/stefdoerr","followers_url":"https://api.github.com/users/stefdoerr/followers","following_url":"https://api.github.com/users/stefdoerr/following{/other_user}","gists_url":"https://api.github.com/users/stefdoerr/gists{/gist_id}","starred_url":"https://api.github.com/users/stefdoerr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stefdoerr/subscriptions","organizations_url":"https://api.github.com/users/stefdoerr/orgs","repos_url":"https://api.github.com/users/stefdoerr/repos","events_url":"https://api.github.com/users/stefdoerr/events{/privacy}","received_events_url":"https://api.github.com/users/stefdoerr/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":8,"created_at":"2017-11-03T13:35:23Z","updated_at":"2017-11-23T19:42:22Z","closed_at":"2017-11-23T19:42:22Z","author_association":"NONE","body":"I was under the impression that dihedral types were sorted in parmed as per: https://github.com/swails/ParmEd/blob/a79adc8541d3156e099ba996febda1babddd3338/parmed/charmm/psf.py#L614 for PSFs\r\nHowever if I read a prmtop like this:\r\n```python\r\nstruct = parmed.load_file(prmtop)\r\nprm = parmed.amber.AmberParameterSet.from_structure(struct)\r\n```\r\nThey seem unsorted\r\n\r\n```\r\nipdb> prm.improper_periodic_types\r\nOrderedDict([(('CX', 'N', 'C', 'O'), <DihedralType; phi_k=10.500, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('CA', 'CA', 'CA', 'CT'), <DihedralType; phi_k=1.100, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('2C', 'O2', 'CO', 'O2'), <DihedralType; phi_k=10.500, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('2C', 'N', 'C', 'O'), <DihedralType; phi_k=10.500, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('N2', 'N2', 'CA', 'N2'), <DihedralType; phi_k=10.500, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('CA', 'CA', 'C', 'OH'), <DihedralType; phi_k=1.100, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('C', 'CT', 'N', 'CX'), <DihedralType; phi_k=1.000, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('CT', 'CV', 'CC', 'NA'), <DihedralType; phi_k=1.100, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('CB', 'CT', 'C*', 'CW'), <DihedralType; phi_k=1.100, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('2C', 'O', 'C', 'OH'), <DihedralType; phi_k=10.500, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('CX', 'O2', 'C', 'O2'), <DihedralType; phi_k=10.500, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('C', 'CX', 'N', 'H'), <DihedralType; phi_k=1.100, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('CA', 'CA', 'CA', 'HA'), <DihedralType; phi_k=1.100, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('C', 'H', 'N', 'H'), <DihedralType; phi_k=1.000, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('CA', 'H', 'N2', 'H'), <DihedralType; phi_k=1.000, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('C8', 'CA', 'N2', 'H'), <DihedralType; phi_k=1.000, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('C', 'CA', 'CA', 'HA'), <DihedralType; phi_k=1.100, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('CA', 'C', 'CA', 'HA'), <DihedralType; phi_k=1.100, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('CC', 'NB', 'CV', 'H4'), <DihedralType; phi_k=1.100, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('NA', 'NB', 'CR', 'H5'), <DihedralType; phi_k=1.100, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('CC', 'CR', 'NA', 'H'), <DihedralType; phi_k=1.000, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('CA', 'CB', 'CA', 'HA'), <DihedralType; phi_k=1.100, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('CN', 'CA', 'CA', 'HA'), <DihedralType; phi_k=1.100, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('CW', 'CN', 'NA', 'H'), <DihedralType; phi_k=1.000, per=2, phase=180.000,  scee=0.000, scnb=0.000>), (('C*', 'NA', 'CW', 'H4'), <DihedralType; phi_k=1.100, per=2, phase=180.000,  scee=0.000, scnb=0.000>)])\r\n```\r\n\r\nIs this a bug or intended behaviour? (or am I misunderstanding something?)"}}
{"actor":{"display_login":"stefdoerr"}}