Nexus: add example for specifying estimators#5214
Conversation
prckent
left a comment
There was a problem hiding this comment.
Please add the pseudopotential files so that this can eventually be automated and success/failure tracked.
|
Pseudos now added. |
|
Note: I tested that spin-density, 1RDM, and energy-density runs in the batched code with the above Nexus inputs. However, the |
|
I think we decided that since the spindensity estimator was a superset of the density estimator then we didn't need both. However, the error message suggests that is not what is going on here (?). At the very least the error message needs improving. There are other estimators that are close to duplicates of functionality, e.g. the various structure factors. |
|
Looking at |
|
This is good. Thanks Gani! If you have time, can you also add the momentum distribution? This is the other one that should have support in the batched drivers already. |
|
Will add the momentum distribution sometime today. |
|
Added a minimal input for momentum distribution |
|
I agree on the note about blocks. Best to also add a comment to explain, e.g., "Large numbers (100+) of blocks are preferred for effective statistical analysis. In production runs, more steps per block than specified here are additionally preferred for computational efficiency due to the I/O cost of estimators." |
|
It looks good to me now. Feel free to push to my branch directly if you think the included comments need refinining. |
| #skip_submit = True, | ||
| identifier = 'qmc', | ||
| path = basepath + 'qmc', | ||
| job = job(cores=12,threads=4,app='qmcpack'), |
There was a problem hiding this comment.
Noticed you are using 12 cores here but 16 elsewhere. Any specific reason?
There was a problem hiding this comment.
Now changed to 16 as well. I must've copied that section from another example.
prckent
left a comment
There was a problem hiding this comment.
I ran this workflow after changing generate_only to 0. The QMC run with the estimators failed. I will poke more later, but did it work for you? If so, which QMCPACK git hash/version?
Fatal Error. Aborting at EstimatorManager input:unparsable <estimator> node, name: edcell type: energydensity in Estimators input.
relevant input section
<estimators>
<estimator type="spindensity" name="SpinDensity">
<parameter name="dr">
0.05 0.05 0.05
</parameter>
</estimator>
<estimator type="EnergyDensity" name="EDcell" dynamic="e" static="ion0">
<spacegrid coord="cartesian">
<origin p1="zero"/>
<axis p1="a1" scale=".5" label="x" grid="-1 (100) 1"/>
<axis p1="a2" scale=".5" label="y" grid="-1 (100) 1"/>
<axis p1="a3" scale=".5" label="z" grid="-1 (100) 1"/>
</spacegrid>
</estimator>
<estimator type="MomentumDistribution" name="nofk" samples="40" kmax="8.0"/>
<estimator type="OneBodyDensityMatrices" name="DensityMatrices">
<parameter name="energy_matrix" > no </parameter>
<parameter name="integrator" > density </parameter>
<parameter name="basis" >
spo_dm
</parameter>
<parameter name="evaluator" > matrix </parameter>
<parameter name="check_overlap" > no </parameter>
<parameter name="samples" > 10 </parameter>
</estimator>
</estimators>
|
EnergyDensity was working for me with the same Nexus estimator definition on another system. Maybe there is something I missed. I will investigate today. |
|
Working now after an update & rebuild. |
|
Thanks. I also did a short VMC run on this system and it runs with the latest develop. The stat.h5 has all the included estimators: PS. The new DFT+U input style using QE v7.4 also works. |
|
Test this please |
Proposed changes
As discussed previously in persion, a comprehensive example was needed for Nexus that demonstrates how to specify various estimators. Here, I have included Density, SpinDenstiy, EnergyDensity, and 1RDM observables in a single Nexus workflow. The goal is to add all the other estimators too as they mature.
In addition, I added a
scripts_postprocdirectory here that includes some post-processing tools. Currently, I included the 1RDM retrieval and plotting tools adapted from discussions in #1052. For now I think it will be helpful to users, at least as a starting point. Let me know if it's not well-suited for here and I will remove it.For long run, there should be a centralized place for post-processing tools that analyze the estimators in the stat.h5 file. Whether it should be one large tool that is one-fits-all, or multiple specialized smaller tools could also be discussed. Currently, it seems to be not well handled - for instance, I see that
qdensbreaks if 1RDM or energy density is present in the same stat.h5 file. I will create an issue for this if the fix is not straightforward.What type(s) of changes does this code introduce?
Does this introduce a breaking change?
What systems has this change been tested on?
Local machine
Checklist