Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add energy decomposition (with PME) (#1109)
* Start EnergyDecomposer class * Update dependencies * Start init routine * Add mask and options print * Start energy decomp action * Start adding the enedecomp command, start initialization * Start doing setup * Bond setup * Setup output arrays * Print atoms that energy will be saved for * Just allocate an energy for each atom, will make bookkeeping easier * Fix up the dataset dimension labels. Add calculation * Add output file * Add angle term. Need to sum before accumulation * Decompose dihedrals * LJ 6-12 energy template * Create and use an LJ 6-12 template * Start adding the 1-4 energy * Add 1-4 elec * Add debug for the 1-4 terms * Start adding nonbond decomp * Only do 1-4 calculation for NORMAL dihedrals * Start trying to template the pairlist loop * Add wrapper around Erfc * Add Ewald adjust kernel * Finish initial incarnation of the Ewald pairlist nonbond kernel. Make ERFC non-const and put timing tracking directly into ErfcFxn * Some cleanup * Add code comments * Change name * Change class name * Reorder * Try as a separate class * Remove for now * Rename * Finish renaming * Remove unneeded depend. * Rip out the new framework. Its really not at all ready for further development until i come up with a plan * Start a separate class for decomposing ewald energies. Bring back ErfcFxn and LJswitch * Start splitting out the Ewald parameters * Update build files * Just make a function template again * Put in energy namespace and make erfc_func available * Put Erfc and switching functions through the EwaldParams class * Init class vars * Add params for PME * Second try for using pairlist template/engine model * Do some Ewald setup * Add routines to access Ewald parameters to the engine * Start PME calc wrapper * Add class for calculating long range VDW * Use long range VDW calc * PME calculation setup * Add PME recip calc wrapper class * Start using PME_Recip * Allow PME_Recip to be used for coulomb or LJ * Use COULOMB recip * Add self energy calc * Save recip coords in EwaldParams_PME so it can be used for multiple recip objects. Start the nonbonded calc * Finish up nonbonded pme calc with template * Remove separate EwaldDecomp for now * Add timing data * Report pairlist timing data * New test action for comparing the old and new PME methods * Enable the new pmetest action (hidden) * Ensure previous coords are cleared * Add unit cell vector check to recip part * Move LJ ewald coeff into a separate class * Add C6 param and LJ self energy calcs * Return the precalculated self energy * First pass at the LJPME engine * Use Ewald parameters * Remove unneeded typedef * Start the LJPME calc class * Use the right variables * Add Calc_LJPME to build * Add Init routine * Add Setup routine * Add nonbonded calc routine * Add timing routine * Need to pass C6 params to LJPME recip calc, not charges * Test new LJPME calc * Report LJ PME recip timing in addition to regular recip timing * Openmp parallelize the pairlist template loop * Add timer to check that the recip calc itself is what takes the majority of the time, not setup (and it does). Comment it out. * Rename * const correctness * Rename * Finish renaming * Start decomposable PME energy class * Placeholder for decomp ewald engine * Add engine placeholder * Do engine init * Add setup * Add decomposed self energy * Add to build * Start incorporating ene decomp * Self energy decomp seems to work * Put lattice check in a separate routine * Decomposable recip energy * Decompose direct elec, vdw, and adjust energies * Restore arrays needed for atom decomp of LR vdw correction * Decompose the long range correction * Actually save the energies back to EnergyDecomposer * Add timing data. Hide some debug info. * Put LJ PME vdw calc into a template * Add LJPME exclude adjust kernel * Remove old code * Add Ewald LJPME decomp * Create decomposed LJPME calc. Still need to do decomposed self6 energy. * Add decomposed self6 calc * Use decomposed self6 energies * Update depends * Doesnt appear like the recip term for the LJPME is working yet. * Use cutoff from EwaldOptions instead of the engine * Start Ecalc_Nonbond * Start implementation * Add pairlist setup * Add pairlist setup to nonbond calc * Start refactoring so that pairlist and exclusion array are not part of the class * Add .cpp.o rule so that subdir compile uses the correct flags * Abstract base class for Ewald calcs * Use abstract base class * Use EwaldCalc ABC * Add to build * Add a nonbond kernel * Add note about includes * Add calc init and setup, and simple nonbond calc * Use new nonbond calc * Report pairlist timing * Try adding a simple nonbond decomposable energy kernel * Start ewald decomp ABC * Fix includes * Convert to EwaldCalc_Decomp class * Convert decomposd LJPME to Ewald_Decomp class. Update depends * Add energy decomp to Ecalc_Nonbond * All ewald calcs need the pairlist * Use Ecalc_Nonbond to do the decomp * Start moving nfft and order to inside PME_Recip * New class to hold recip coords * Add routine to access coords array, update depends * Remove files * Move EwaldParams_PME Init, Setup, and coordsD routines to EwaldParams * Use new EwaldParams * Use EwaldParams * Have recip print opts right after init * Use new EwaldParams * Update for new EwaldParams and PME_Recip * Update depends * Use EwaldParams intead of EwaldParams_PME. Update depends * Start Ewald_Recip class * Make 1 / sqrt(PI) constant available * Add init and print routines * Add setup * Finish setup * Finish regular recip calc * Add timing * Update docs * No need to save ewald coeff, just calculate the factor in Init * Start regular Ewald calc class * Add setup * Finish regular ewald * Add EwaldCalc_Regular and Ewald_Recip to build * Add regular ewald to Ecalc_Nonbond * Add ability to test Ewald regular * Add missing init * Need to look for method == 4. Improve error message. Fix timing message. * Fix reduction pragma * Fix OpenMP compile * Introduce new constant COULOMBFACTOR to replace all separate instances of QFAC * Start adding ifdefs * Start splitting off the direct sum routines * Start removing old Ewald * These dont need to be separate yet * Make vars available for GIST PME * Use Ecalc_Nonbond * Start converting to use EwaldParams * Add PME_RecipParams class * Use PME_RecipParams class * Put PME_EwaldParams inside PME_Recip * Dont call print inside the init * Expose arrays needed by GIST_PME * Finish converting GIST_PME, add VDW long range, recip, and adjust stuff. * Add missing timing function * Fix non-openmp compile * Start adding LJPME OptType * Use IsPmeType where appropriate. Ensure GIST PME is only used with PME options for now. * Energy decomp with ljpme not yet allowed * Allow LJPME to be directly set * Remove debug message * Make options printout more clear * Make sure printed Ewald options line up * Make print private * Clean up printout of regular ewald recip opts * Since fftw3 is always on now by default, change -fftw3 to -pubfft in case user wants to force using pubfft. * PME recip needs LIBPME * Add include of base Ewald decomp class when no LIBPME since no decomp for regular Ewald yet. * Add files for enedecomp test * Enable enedecomp test * Remove all references to PairListLoop and associated files * Update dependencies * Add help text * Dont repeat the same timing data. Should clean that up eventually * Use Ecalc_Nonbond interal timer only when it is active * Hide some debug info * Remove old code * Hide some debug behind ifdef * Fix up info output * Hide debug info behind ifdef * Version 6.29.4. Revision bump for addition of the 'enedecomp' action and rewrite of the Ewald classes. * Add documentation on how to use the pairlist template * Add longer test * Add enedecomp to manual * Put functionality to reduce an array of Stats<T> into a separate class to be used by PairDist and EnergyDecomposer * Use Stats_Reduce * Ensure decomposed energy results are synced * Add citation to code docs * Update manual PDF and checksum * Fix non-MPI compile (oops) --------- Co-authored-by: Daniel R. Roe <daniel.roe@nih.gov>
- Loading branch information