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

Nexus: fixing sizing problem in some single atom workflows #3553

Merged
merged 3 commits into from
Oct 22, 2021

Conversation

jtkrogel
Copy link
Contributor

Proposed changes

Bugfix for single atom pyscf->qmcpack workflow. In this case, positions of a single atom are read in as [0 0 0], whereas a collection of positions are expected (i.e. [[0 0 0 ]]).

This fix is needed for the workshop examples.

What type(s) of changes does this code introduce?

  • Bugfix

Does this introduce a breaking change?

  • No

What systems has this change been tested on?

Laptop

Checklist

Update the following with a yes where the items apply. If you're unsure about any of them, don't hesitate to ask. This is
simply a reminder of what we are going to look for before merging your code.

  • Yes. This PR is up to date with current the current state of 'develop'

@qmc-robot
Copy link

Can one of the admins verify this patch?

Comment on lines +3991 to +3994
pos = np.asarray(pos)
if len(pos.flatten())==3:
pos.shape = (1,3)
#end if
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you add a comment describing the special case being handled here.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

Copy link
Contributor

@markdewing markdewing left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@ye-luo
Copy link
Contributor

ye-luo commented Oct 22, 2021

Test this please

@ye-luo ye-luo enabled auto-merge October 22, 2021 19:09
@ye-luo ye-luo merged commit c92934d into QMCPACK:develop Oct 22, 2021
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

Successfully merging this pull request may close these issues.

4 participants