Skip to content

Nexus: Print warning for the Nexus user before pwscf rsync - #4984

Merged
ye-luo merged 3 commits into
QMCPACK:developfrom
aannabe:nxs_rsync
May 13, 2024
Merged

Nexus: Print warning for the Nexus user before pwscf rsync#4984
ye-luo merged 3 commits into
QMCPACK:developfrom
aannabe:nxs_rsync

Conversation

@aannabe

@aannabe aannabe commented May 10, 2024

Copy link
Copy Markdown
Contributor

Proposed changes

When a new NSCF is located on a different path than SCF, Nexus will rsync the SCF results into the new path. This is a great feature for submitting multiple NSCF calculations with various k-points. However, this can take quite a while and can give the false sense that Nexus is hanging when, in fact, it is silently rsync'ing the results. This has confused me a few times.

I simply put two print statements warning the user that this is happening. It only executes the first time when the directory does not exist. There is probably a better way to output this - let me know if there is and I will be happy to update.

Does this introduce a breaking change?

  • No

What systems has this change been tested on?

All Nexus tests pass on my laptop (Linux Mint 21.3), except for 61/69 qdens_radial.

Checklist

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

@aannabe aannabe added the nexus label May 10, 2024
@aannabe
aannabe requested a review from jtkrogel May 10, 2024 23:07
@prckent prckent changed the title Print warning for the Nexus user before pwscf rsync Nexus: Print warning for the Nexus user before pwscf rsync May 11, 2024
prckent
prckent previously approved these changes May 11, 2024

@prckent prckent left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Good idea

Comment thread nexus/lib/pwscf.py
command = 'rsync -av {0}/* {1}/'.format(result.outdir,outdir)
if not os.path.exists(outdir):
print('Running rsync for the {} directory. This might take a while.'.format(outdir))
os.makedirs(outdir)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Please add a paired printout indicating the completion of rysnc.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Done. Also moved the earlier print to just before the rsync. Makes more sense this way.

@ye-luo ye-luo May 13, 2024

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Please add back the printout before copy. They service distinct purpose and there is no harm to be verbose on the status of nexus. I misread your comment

@ye-luo

ye-luo commented May 13, 2024

Copy link
Copy Markdown
Contributor

Test this please

@ye-luo
ye-luo merged commit 1b8857d into QMCPACK:develop May 13, 2024
@aannabe
aannabe deleted the nxs_rsync branch May 13, 2024 15:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants