Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
Add support for having non-displaced atoms in Phonopy routines #2110
Add support for having non-displaced atoms in Phonopy routines #2110
Changes from 13 commits
d2aa51a
24608c9
d6deffc
1f31546
a7b3a0c
38a4230
7430b8a
6939b90
54c4e5f
b7789d2
5536691
93a66a6
75b8f9f
56fc1ac
b98984e
15f4469
e715946
f39bf76
2225c9d
0d06540
8817af3
923ca89
2f3e943
1d710db
7329f9b
e102d40
98d0274
4f1027e
0dec274
5f99ce4
b87a8f7
5ff4044
626ab00
9bc911c
bf17288
495c99b
6c3fc90
5eac754
3c9bb51
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Out of curiosity, what is the motivation to have two separate
Atoms
objects rather than oneAtoms
objects for the full thing and specific indices to not displace? It seems like it might be a bit awkward if they are separateAtoms
objects because wouldn't the user have to split up theirAtoms
object into two before calling this function? I'm sure there's a reason for your suggestion --- just trying to pick up on what it is. We may have gone over this a long time ago.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In commit "24608c9" I left a comment.
I think we moved out of this approach to the "FixAtoms" approach, but that did not work as well so we ended up here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@tomdemeyere: Apologies if we're revisiting history here (it's been a while...). I'm not sure the commit shows the comment, but my question is mostly about what if we had an
Atoms
object as input with alist[int]
of indices to not displace. Was there an issue with that approach? If so, we can stick with what you have here.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like we lost a type hint.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a little bit problematic, another option is to send both displaced and non_displaced and optimise them and separate them again...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see. I mean, I guess we can ask if we really even need a relaxation step beforehand? Presumably one could just call
relax_job()
before calling the flow and it would be exactly the same (although without a tight force tolerance).If there's a desire to keep this though, then yeah I think the only route would be to relax
displaced_atoms+non_displaced_atoms
as a singlecombined_atoms
and then pass incombined_atoms[:len(displaced_atoms)]
etc. tophonon_subflow
. It does, admittedly, complicate things a bit because it seems weird to relax something that is called "non-displaced", but... 🤷