hillclimber 0.1.5a8__cp314-cp314-macosx_15_0_x86_64.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- hillclimber/__init__.py +39 -0
- hillclimber/actions.py +53 -0
- hillclimber/analysis.py +590 -0
- hillclimber/biases.py +293 -0
- hillclimber/calc.py +22 -0
- hillclimber/cvs.py +1065 -0
- hillclimber/interfaces.py +133 -0
- hillclimber/metadynamics.py +325 -0
- hillclimber/nodes.py +6 -0
- hillclimber/opes.py +359 -0
- hillclimber/selectors.py +230 -0
- hillclimber/virtual_atoms.py +341 -0
- hillclimber-0.1.5a8.dist-info/METADATA +209 -0
- hillclimber-0.1.5a8.dist-info/RECORD +469 -0
- hillclimber-0.1.5a8.dist-info/WHEEL +6 -0
- hillclimber-0.1.5a8.dist-info/entry_points.txt +8 -0
- hillclimber-0.1.5a8.dist-info/licenses/LICENSE +165 -0
- plumed/__init__.py +104 -0
- plumed/_lib/bin/plumed +0 -0
- plumed/_lib/bin/plumed-config +9 -0
- plumed/_lib/bin/plumed-patch +9 -0
- plumed/_lib/include/plumed/adjmat/AdjacencyMatrixBase.h +659 -0
- plumed/_lib/include/plumed/adjmat/ContactMatrix.h +59 -0
- plumed/_lib/include/plumed/asmjit/arch.h +228 -0
- plumed/_lib/include/plumed/asmjit/arm.h +43 -0
- plumed/_lib/include/plumed/asmjit/asmjit.h +69 -0
- plumed/_lib/include/plumed/asmjit/asmjit_apibegin.h +143 -0
- plumed/_lib/include/plumed/asmjit/asmjit_apiend.h +93 -0
- plumed/_lib/include/plumed/asmjit/asmjit_build.h +971 -0
- plumed/_lib/include/plumed/asmjit/assembler.h +183 -0
- plumed/_lib/include/plumed/asmjit/base.h +56 -0
- plumed/_lib/include/plumed/asmjit/codebuilder.h +944 -0
- plumed/_lib/include/plumed/asmjit/codecompiler.h +767 -0
- plumed/_lib/include/plumed/asmjit/codeemitter.h +528 -0
- plumed/_lib/include/plumed/asmjit/codeholder.h +777 -0
- plumed/_lib/include/plumed/asmjit/constpool.h +286 -0
- plumed/_lib/include/plumed/asmjit/cpuinfo.h +402 -0
- plumed/_lib/include/plumed/asmjit/func.h +1327 -0
- plumed/_lib/include/plumed/asmjit/globals.h +370 -0
- plumed/_lib/include/plumed/asmjit/inst.h +137 -0
- plumed/_lib/include/plumed/asmjit/logging.h +317 -0
- plumed/_lib/include/plumed/asmjit/misc_p.h +103 -0
- plumed/_lib/include/plumed/asmjit/moved_string.h +318 -0
- plumed/_lib/include/plumed/asmjit/operand.h +1599 -0
- plumed/_lib/include/plumed/asmjit/osutils.h +207 -0
- plumed/_lib/include/plumed/asmjit/regalloc_p.h +597 -0
- plumed/_lib/include/plumed/asmjit/runtime.h +227 -0
- plumed/_lib/include/plumed/asmjit/simdtypes.h +1104 -0
- plumed/_lib/include/plumed/asmjit/utils.h +1387 -0
- plumed/_lib/include/plumed/asmjit/vmem.h +183 -0
- plumed/_lib/include/plumed/asmjit/x86.h +45 -0
- plumed/_lib/include/plumed/asmjit/x86assembler.h +125 -0
- plumed/_lib/include/plumed/asmjit/x86builder.h +117 -0
- plumed/_lib/include/plumed/asmjit/x86compiler.h +322 -0
- plumed/_lib/include/plumed/asmjit/x86emitter.h +5149 -0
- plumed/_lib/include/plumed/asmjit/x86globals.h +535 -0
- plumed/_lib/include/plumed/asmjit/x86inst.h +2547 -0
- plumed/_lib/include/plumed/asmjit/x86instimpl_p.h +74 -0
- plumed/_lib/include/plumed/asmjit/x86internal_p.h +108 -0
- plumed/_lib/include/plumed/asmjit/x86logging_p.h +92 -0
- plumed/_lib/include/plumed/asmjit/x86misc.h +417 -0
- plumed/_lib/include/plumed/asmjit/x86operand.h +1133 -0
- plumed/_lib/include/plumed/asmjit/x86regalloc_p.h +734 -0
- plumed/_lib/include/plumed/asmjit/zone.h +1157 -0
- plumed/_lib/include/plumed/bias/Bias.h +82 -0
- plumed/_lib/include/plumed/bias/ReweightBase.h +58 -0
- plumed/_lib/include/plumed/blas/blas.h +253 -0
- plumed/_lib/include/plumed/blas/def_external.h +61 -0
- plumed/_lib/include/plumed/blas/def_internal.h +97 -0
- plumed/_lib/include/plumed/blas/real.h +49 -0
- plumed/_lib/include/plumed/cltools/CLTool.h +32 -0
- plumed/_lib/include/plumed/clusters/ClusteringBase.h +70 -0
- plumed/_lib/include/plumed/colvar/Colvar.h +32 -0
- plumed/_lib/include/plumed/colvar/ColvarInput.h +68 -0
- plumed/_lib/include/plumed/colvar/ColvarShortcut.h +81 -0
- plumed/_lib/include/plumed/colvar/CoordinationBase.h +52 -0
- plumed/_lib/include/plumed/colvar/MultiColvarTemplate.h +333 -0
- plumed/_lib/include/plumed/colvar/PathMSDBase.h +101 -0
- plumed/_lib/include/plumed/colvar/RMSDVector.h +78 -0
- plumed/_lib/include/plumed/config/Config.h +118 -0
- plumed/_lib/include/plumed/config/version.h +9 -0
- plumed/_lib/include/plumed/contour/ContourFindingObject.h +87 -0
- plumed/_lib/include/plumed/contour/DistanceFromContourBase.h +82 -0
- plumed/_lib/include/plumed/contour/FindContour.h +67 -0
- plumed/_lib/include/plumed/core/Action.h +540 -0
- plumed/_lib/include/plumed/core/ActionAnyorder.h +48 -0
- plumed/_lib/include/plumed/core/ActionAtomistic.h +343 -0
- plumed/_lib/include/plumed/core/ActionForInterface.h +99 -0
- plumed/_lib/include/plumed/core/ActionPilot.h +57 -0
- plumed/_lib/include/plumed/core/ActionRegister.h +124 -0
- plumed/_lib/include/plumed/core/ActionSet.h +163 -0
- plumed/_lib/include/plumed/core/ActionSetup.h +48 -0
- plumed/_lib/include/plumed/core/ActionShortcut.h +73 -0
- plumed/_lib/include/plumed/core/ActionToGetData.h +59 -0
- plumed/_lib/include/plumed/core/ActionToPutData.h +101 -0
- plumed/_lib/include/plumed/core/ActionWithArguments.h +140 -0
- plumed/_lib/include/plumed/core/ActionWithMatrix.h +87 -0
- plumed/_lib/include/plumed/core/ActionWithValue.h +258 -0
- plumed/_lib/include/plumed/core/ActionWithVector.h +94 -0
- plumed/_lib/include/plumed/core/ActionWithVirtualAtom.h +123 -0
- plumed/_lib/include/plumed/core/CLTool.h +177 -0
- plumed/_lib/include/plumed/core/CLToolMain.h +102 -0
- plumed/_lib/include/plumed/core/CLToolRegister.h +108 -0
- plumed/_lib/include/plumed/core/Colvar.h +115 -0
- plumed/_lib/include/plumed/core/DataPassingObject.h +94 -0
- plumed/_lib/include/plumed/core/DataPassingTools.h +54 -0
- plumed/_lib/include/plumed/core/DomainDecomposition.h +120 -0
- plumed/_lib/include/plumed/core/ExchangePatterns.h +47 -0
- plumed/_lib/include/plumed/core/FlexibleBin.h +63 -0
- plumed/_lib/include/plumed/core/GREX.h +61 -0
- plumed/_lib/include/plumed/core/GenericMolInfo.h +89 -0
- plumed/_lib/include/plumed/core/Group.h +41 -0
- plumed/_lib/include/plumed/core/ModuleMap.h +30 -0
- plumed/_lib/include/plumed/core/ParallelTaskManager.h +1023 -0
- plumed/_lib/include/plumed/core/PbcAction.h +61 -0
- plumed/_lib/include/plumed/core/PlumedMain.h +632 -0
- plumed/_lib/include/plumed/core/PlumedMainInitializer.h +118 -0
- plumed/_lib/include/plumed/core/RegisterBase.h +340 -0
- plumed/_lib/include/plumed/core/TargetDist.h +48 -0
- plumed/_lib/include/plumed/core/Value.h +547 -0
- plumed/_lib/include/plumed/core/WithCmd.h +93 -0
- plumed/_lib/include/plumed/dimred/SMACOF.h +55 -0
- plumed/_lib/include/plumed/drr/DRR.h +383 -0
- plumed/_lib/include/plumed/drr/colvar_UIestimator.h +777 -0
- plumed/_lib/include/plumed/fisst/legendre_rule_fast.h +44 -0
- plumed/_lib/include/plumed/function/Custom.h +54 -0
- plumed/_lib/include/plumed/function/Function.h +85 -0
- plumed/_lib/include/plumed/function/FunctionOfMatrix.h +368 -0
- plumed/_lib/include/plumed/function/FunctionOfScalar.h +135 -0
- plumed/_lib/include/plumed/function/FunctionOfVector.h +296 -0
- plumed/_lib/include/plumed/function/FunctionSetup.h +180 -0
- plumed/_lib/include/plumed/function/FunctionShortcut.h +130 -0
- plumed/_lib/include/plumed/function/FunctionWithSingleArgument.h +165 -0
- plumed/_lib/include/plumed/gridtools/ActionWithGrid.h +43 -0
- plumed/_lib/include/plumed/gridtools/EvaluateGridFunction.h +99 -0
- plumed/_lib/include/plumed/gridtools/FunctionOfGrid.h +295 -0
- plumed/_lib/include/plumed/gridtools/GridCoordinatesObject.h +179 -0
- plumed/_lib/include/plumed/gridtools/GridSearch.h +135 -0
- plumed/_lib/include/plumed/gridtools/Interpolator.h +45 -0
- plumed/_lib/include/plumed/gridtools/KDE.h +455 -0
- plumed/_lib/include/plumed/gridtools/RDF.h +40 -0
- plumed/_lib/include/plumed/gridtools/SumOfKernels.h +219 -0
- plumed/_lib/include/plumed/isdb/MetainferenceBase.h +398 -0
- plumed/_lib/include/plumed/lapack/def_external.h +207 -0
- plumed/_lib/include/plumed/lapack/def_internal.h +388 -0
- plumed/_lib/include/plumed/lapack/lapack.h +899 -0
- plumed/_lib/include/plumed/lapack/lapack_limits.h +79 -0
- plumed/_lib/include/plumed/lapack/real.h +50 -0
- plumed/_lib/include/plumed/lepton/CompiledExpression.h +164 -0
- plumed/_lib/include/plumed/lepton/CustomFunction.h +143 -0
- plumed/_lib/include/plumed/lepton/Exception.h +93 -0
- plumed/_lib/include/plumed/lepton/ExpressionProgram.h +137 -0
- plumed/_lib/include/plumed/lepton/ExpressionTreeNode.h +145 -0
- plumed/_lib/include/plumed/lepton/Lepton.h +85 -0
- plumed/_lib/include/plumed/lepton/MSVC_erfc.h +123 -0
- plumed/_lib/include/plumed/lepton/Operation.h +1302 -0
- plumed/_lib/include/plumed/lepton/ParsedExpression.h +165 -0
- plumed/_lib/include/plumed/lepton/Parser.h +111 -0
- plumed/_lib/include/plumed/lepton/windowsIncludes.h +73 -0
- plumed/_lib/include/plumed/mapping/Path.h +44 -0
- plumed/_lib/include/plumed/mapping/PathProjectionCalculator.h +57 -0
- plumed/_lib/include/plumed/matrixtools/MatrixOperationBase.h +54 -0
- plumed/_lib/include/plumed/matrixtools/MatrixTimesMatrix.h +309 -0
- plumed/_lib/include/plumed/matrixtools/MatrixTimesVectorBase.h +365 -0
- plumed/_lib/include/plumed/matrixtools/OuterProduct.h +238 -0
- plumed/_lib/include/plumed/maze/Core.h +65 -0
- plumed/_lib/include/plumed/maze/Loss.h +86 -0
- plumed/_lib/include/plumed/maze/Member.h +66 -0
- plumed/_lib/include/plumed/maze/Memetic.h +799 -0
- plumed/_lib/include/plumed/maze/Optimizer.h +357 -0
- plumed/_lib/include/plumed/maze/Random_MT.h +156 -0
- plumed/_lib/include/plumed/maze/Tools.h +183 -0
- plumed/_lib/include/plumed/metatomic/vesin.h +188 -0
- plumed/_lib/include/plumed/molfile/Gromacs.h +2013 -0
- plumed/_lib/include/plumed/molfile/endianswap.h +217 -0
- plumed/_lib/include/plumed/molfile/fastio.h +683 -0
- plumed/_lib/include/plumed/molfile/largefiles.h +78 -0
- plumed/_lib/include/plumed/molfile/libmolfile_plugin.h +77 -0
- plumed/_lib/include/plumed/molfile/molfile_plugin.h +1034 -0
- plumed/_lib/include/plumed/molfile/periodic_table.h +248 -0
- plumed/_lib/include/plumed/molfile/readpdb.h +447 -0
- plumed/_lib/include/plumed/molfile/vmdplugin.h +236 -0
- plumed/_lib/include/plumed/multicolvar/MultiColvarShortcuts.h +45 -0
- plumed/_lib/include/plumed/opes/ExpansionCVs.h +79 -0
- plumed/_lib/include/plumed/sasa/Sasa.h +32 -0
- plumed/_lib/include/plumed/secondarystructure/SecondaryStructureBase.h +372 -0
- plumed/_lib/include/plumed/setup/ActionSetup.h +25 -0
- plumed/_lib/include/plumed/small_vector/small_vector.h +6114 -0
- plumed/_lib/include/plumed/symfunc/CoordinationNumbers.h +41 -0
- plumed/_lib/include/plumed/tools/Angle.h +52 -0
- plumed/_lib/include/plumed/tools/AtomDistribution.h +138 -0
- plumed/_lib/include/plumed/tools/AtomNumber.h +152 -0
- plumed/_lib/include/plumed/tools/BiasRepresentation.h +106 -0
- plumed/_lib/include/plumed/tools/BitmaskEnum.h +167 -0
- plumed/_lib/include/plumed/tools/Brent1DRootSearch.h +159 -0
- plumed/_lib/include/plumed/tools/CheckInRange.h +44 -0
- plumed/_lib/include/plumed/tools/Citations.h +74 -0
- plumed/_lib/include/plumed/tools/ColvarOutput.h +118 -0
- plumed/_lib/include/plumed/tools/Communicator.h +316 -0
- plumed/_lib/include/plumed/tools/ConjugateGradient.h +80 -0
- plumed/_lib/include/plumed/tools/DLLoader.h +79 -0
- plumed/_lib/include/plumed/tools/ERMSD.h +73 -0
- plumed/_lib/include/plumed/tools/Exception.h +406 -0
- plumed/_lib/include/plumed/tools/File.h +28 -0
- plumed/_lib/include/plumed/tools/FileBase.h +153 -0
- plumed/_lib/include/plumed/tools/FileTools.h +37 -0
- plumed/_lib/include/plumed/tools/ForwardDecl.h +54 -0
- plumed/_lib/include/plumed/tools/Grid.h +638 -0
- plumed/_lib/include/plumed/tools/HistogramBead.h +136 -0
- plumed/_lib/include/plumed/tools/IFile.h +117 -0
- plumed/_lib/include/plumed/tools/KernelFunctions.h +113 -0
- plumed/_lib/include/plumed/tools/Keywords.h +380 -0
- plumed/_lib/include/plumed/tools/LatticeReduction.h +66 -0
- plumed/_lib/include/plumed/tools/LeptonCall.h +64 -0
- plumed/_lib/include/plumed/tools/LinkCells.h +126 -0
- plumed/_lib/include/plumed/tools/Log.h +41 -0
- plumed/_lib/include/plumed/tools/LoopUnroller.h +163 -0
- plumed/_lib/include/plumed/tools/Matrix.h +721 -0
- plumed/_lib/include/plumed/tools/MatrixSquareBracketsAccess.h +138 -0
- plumed/_lib/include/plumed/tools/MergeVectorTools.h +153 -0
- plumed/_lib/include/plumed/tools/Minimise1DBrent.h +244 -0
- plumed/_lib/include/plumed/tools/MinimiseBase.h +120 -0
- plumed/_lib/include/plumed/tools/MolDataClass.h +51 -0
- plumed/_lib/include/plumed/tools/NeighborList.h +112 -0
- plumed/_lib/include/plumed/tools/OFile.h +286 -0
- plumed/_lib/include/plumed/tools/OpenACC.h +180 -0
- plumed/_lib/include/plumed/tools/OpenMP.h +75 -0
- plumed/_lib/include/plumed/tools/PDB.h +154 -0
- plumed/_lib/include/plumed/tools/Pbc.h +139 -0
- plumed/_lib/include/plumed/tools/PlumedHandle.h +105 -0
- plumed/_lib/include/plumed/tools/RMSD.h +493 -0
- plumed/_lib/include/plumed/tools/Random.h +80 -0
- plumed/_lib/include/plumed/tools/RootFindingBase.h +79 -0
- plumed/_lib/include/plumed/tools/Stopwatch.h +475 -0
- plumed/_lib/include/plumed/tools/Subprocess.h +142 -0
- plumed/_lib/include/plumed/tools/SwitchingFunction.h +208 -0
- plumed/_lib/include/plumed/tools/Tensor.h +724 -0
- plumed/_lib/include/plumed/tools/TokenizedLine.h +123 -0
- plumed/_lib/include/plumed/tools/Tools.h +638 -0
- plumed/_lib/include/plumed/tools/Torsion.h +55 -0
- plumed/_lib/include/plumed/tools/TrajectoryParser.h +118 -0
- plumed/_lib/include/plumed/tools/Tree.h +61 -0
- plumed/_lib/include/plumed/tools/TypesafePtr.h +463 -0
- plumed/_lib/include/plumed/tools/Units.h +167 -0
- plumed/_lib/include/plumed/tools/Vector.h +433 -0
- plumed/_lib/include/plumed/tools/View.h +296 -0
- plumed/_lib/include/plumed/tools/View2D.h +100 -0
- plumed/_lib/include/plumed/tools/h36.h +39 -0
- plumed/_lib/include/plumed/vatom/ActionWithVirtualAtom.h +32 -0
- plumed/_lib/include/plumed/ves/BasisFunctions.h +380 -0
- plumed/_lib/include/plumed/ves/CoeffsBase.h +310 -0
- plumed/_lib/include/plumed/ves/CoeffsMatrix.h +220 -0
- plumed/_lib/include/plumed/ves/CoeffsVector.h +251 -0
- plumed/_lib/include/plumed/ves/FermiSwitchingFunction.h +74 -0
- plumed/_lib/include/plumed/ves/GridIntegrationWeights.h +50 -0
- plumed/_lib/include/plumed/ves/GridLinearInterpolation.h +81 -0
- plumed/_lib/include/plumed/ves/GridProjWeights.h +61 -0
- plumed/_lib/include/plumed/ves/LinearBasisSetExpansion.h +303 -0
- plumed/_lib/include/plumed/ves/Optimizer.h +444 -0
- plumed/_lib/include/plumed/ves/TargetDistModifer.h +53 -0
- plumed/_lib/include/plumed/ves/TargetDistribution.h +266 -0
- plumed/_lib/include/plumed/ves/VesBias.h +545 -0
- plumed/_lib/include/plumed/ves/VesTools.h +142 -0
- plumed/_lib/include/plumed/ves/WaveletGrid.h +75 -0
- plumed/_lib/include/plumed/volumes/ActionVolume.h +268 -0
- plumed/_lib/include/plumed/volumes/VolumeShortcut.h +147 -0
- plumed/_lib/include/plumed/wrapper/Plumed.h +5025 -0
- plumed/_lib/include/plumed/xdrfile/xdrfile.h +663 -0
- plumed/_lib/include/plumed/xdrfile/xdrfile_trr.h +89 -0
- plumed/_lib/include/plumed/xdrfile/xdrfile_xtc.h +90 -0
- plumed/_lib/lib/PythonCVInterface.dylib +0 -0
- plumed/_lib/lib/libplumed.dylib +0 -0
- plumed/_lib/lib/libplumedKernel.dylib +0 -0
- plumed/_lib/lib/libplumedWrapper.a +0 -0
- plumed/_lib/lib/pkgconfig/plumed.pc +13 -0
- plumed/_lib/lib/pkgconfig/plumedInternals.pc +13 -0
- plumed/_lib/lib/pkgconfig/plumedWrapper.pc +13 -0
- plumed/_lib/lib/plumed/fortran/plumed.f90 +879 -0
- plumed/_lib/lib/plumed/fortran/plumed_f08.f90 +2625 -0
- plumed/_lib/lib/plumed/modulefile +69 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.config +43 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/CMakeLists.txt +543 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/CMakeLists.txt.preplumed +540 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/mdlib/expanded.cpp +1628 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/mdlib/expanded.cpp.preplumed +1590 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/mdlib/expanded.h +103 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/mdlib/expanded.h.preplumed +99 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/mdlib/sim_util.cpp +2527 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/mdlib/sim_util.cpp.preplumed +2513 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/mdrun/legacymdrunoptions.cpp +208 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/mdrun/legacymdrunoptions.cpp.preplumed +175 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/mdrun/legacymdrunoptions.h +408 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/mdrun/legacymdrunoptions.h.preplumed +394 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/mdrun/md.cpp +2348 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/mdrun/md.cpp.preplumed +2091 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/mdrun/minimize.cpp +3573 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/mdrun/minimize.cpp.preplumed +3495 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/mdrun/replicaexchange.cpp +1506 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/mdrun/replicaexchange.cpp.preplumed +1402 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/mdrun/replicaexchange.h +114 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/mdrun/replicaexchange.h.preplumed +106 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/mdrun/rerun.cpp +997 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/mdrun/rerun.cpp.preplumed +906 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/mdrun/runner.cpp +2780 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/mdrun/runner.cpp.preplumed +2738 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/modularsimulator/expandedensembleelement.cpp +224 -0
- plumed/_lib/lib/plumed/patches/gromacs-2022.5.diff/src/gromacs/modularsimulator/expandedensembleelement.cpp.preplumed +222 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.config +43 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/CMakeLists.txt +549 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/CMakeLists.txt.preplumed +546 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/mdlib/expanded.cpp +1632 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/mdlib/expanded.cpp.preplumed +1594 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/mdlib/expanded.h +104 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/mdlib/expanded.h.preplumed +100 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/mdlib/sim_util.cpp +2624 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/mdlib/sim_util.cpp.preplumed +2610 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/mdrun/legacymdrunoptions.cpp +208 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/mdrun/legacymdrunoptions.cpp.preplumed +175 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/mdrun/legacymdrunoptions.h +409 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/mdrun/legacymdrunoptions.h.preplumed +395 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/mdrun/md.cpp +2419 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/mdrun/md.cpp.preplumed +2164 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/mdrun/minimize.cpp +3546 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/mdrun/minimize.cpp.preplumed +3468 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/mdrun/replicaexchange.cpp +1513 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/mdrun/replicaexchange.cpp.preplumed +1409 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/mdrun/replicaexchange.h +114 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/mdrun/replicaexchange.h.preplumed +106 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/mdrun/rerun.cpp +991 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/mdrun/rerun.cpp.preplumed +900 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/mdrun/runner.cpp +2895 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/mdrun/runner.cpp.preplumed +2849 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/modularsimulator/expandedensembleelement.cpp +224 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/modularsimulator/expandedensembleelement.cpp.preplumed +222 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/taskassignment/decidegpuusage.cpp +886 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/taskassignment/decidegpuusage.cpp.preplumed +880 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/taskassignment/include/gromacs/taskassignment/decidegpuusage.h +347 -0
- plumed/_lib/lib/plumed/patches/gromacs-2023.5.diff/src/gromacs/taskassignment/include/gromacs/taskassignment/decidegpuusage.h.preplumed +345 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.config +43 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/CMakeLists.txt +575 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/CMakeLists.txt.preplumed +572 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/mdlib/expanded.cpp +1632 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/mdlib/expanded.cpp.preplumed +1594 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/mdlib/expanded.h +104 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/mdlib/expanded.h.preplumed +100 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/mdlib/sim_util.cpp +2564 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/mdlib/sim_util.cpp.preplumed +2550 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/mdrun/legacymdrunoptions.cpp +208 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/mdrun/legacymdrunoptions.cpp.preplumed +175 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/mdrun/legacymdrunoptions.h +410 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/mdrun/legacymdrunoptions.h.preplumed +396 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/mdrun/md.cpp +2435 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/mdrun/md.cpp.preplumed +2187 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/mdrun/minimize.cpp +3592 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/mdrun/minimize.cpp.preplumed +3514 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/mdrun/replicaexchange.cpp +1513 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/mdrun/replicaexchange.cpp.preplumed +1409 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/mdrun/replicaexchange.h +114 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/mdrun/replicaexchange.h.preplumed +106 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/mdrun/rerun.cpp +958 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/mdrun/rerun.cpp.preplumed +929 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/mdrun/runner.cpp +2987 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/mdrun/runner.cpp.preplumed +2941 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/modularsimulator/expandedensembleelement.cpp +224 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/modularsimulator/expandedensembleelement.cpp.preplumed +222 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/taskassignment/decidegpuusage.cpp +904 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/taskassignment/decidegpuusage.cpp.preplumed +898 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/taskassignment/include/gromacs/taskassignment/decidegpuusage.h +353 -0
- plumed/_lib/lib/plumed/patches/gromacs-2024.3.diff/src/gromacs/taskassignment/include/gromacs/taskassignment/decidegpuusage.h.preplumed +351 -0
- plumed/_lib/lib/plumed/patches/gromacs-2025.0.config +39 -0
- plumed/_lib/lib/plumed/patches/gromacs-2025.0.diff/cmake/gmxManagePlumed.cmake +82 -0
- plumed/_lib/lib/plumed/patches/gromacs-2025.0.diff/cmake/gmxManagePlumed.cmake.preplumed +82 -0
- plumed/_lib/lib/plumed/patches/gromacs-2025.0.diff/src/gromacs/applied_forces/plumed/plumedMDModule.cpp +162 -0
- plumed/_lib/lib/plumed/patches/gromacs-2025.0.diff/src/gromacs/applied_forces/plumed/plumedMDModule.cpp.preplumed +154 -0
- plumed/_lib/lib/plumed/patches/gromacs-2025.0.diff/src/gromacs/applied_forces/plumed/plumedOptions.cpp +107 -0
- plumed/_lib/lib/plumed/patches/gromacs-2025.0.diff/src/gromacs/applied_forces/plumed/plumedOptions.cpp.preplumed +99 -0
- plumed/_lib/lib/plumed/patches/gromacs-2025.0.diff/src/gromacs/applied_forces/plumed/plumedOptions.h +120 -0
- plumed/_lib/lib/plumed/patches/gromacs-2025.0.diff/src/gromacs/applied_forces/plumed/plumedOptions.h.preplumed +111 -0
- plumed/_lib/lib/plumed/patches/gromacs-2025.0.diff/src/gromacs/applied_forces/plumed/plumedforceprovider.cpp +215 -0
- plumed/_lib/lib/plumed/patches/gromacs-2025.0.diff/src/gromacs/applied_forces/plumed/plumedforceprovider.cpp.preplumed +197 -0
- plumed/_lib/lib/plumed/patches/gromacs-2025.0.diff/src/gromacs/applied_forces/plumed/plumedforceprovider.h +87 -0
- plumed/_lib/lib/plumed/patches/gromacs-2025.0.diff/src/gromacs/applied_forces/plumed/plumedforceprovider.h.preplumed +86 -0
- plumed/_lib/lib/plumed/patches/gromacs-2025.0.diff/src/gromacs/mdrun/runner.cpp +2971 -0
- plumed/_lib/lib/plumed/patches/gromacs-2025.0.diff/src/gromacs/mdrun/runner.cpp.preplumed +2970 -0
- plumed/_lib/lib/plumed/patches/gromacs-2025.0.diff/src/gromacs/mdrunutility/mdmodulesnotifiers.h +430 -0
- plumed/_lib/lib/plumed/patches/gromacs-2025.0.diff/src/gromacs/mdrunutility/mdmodulesnotifiers.h.preplumed +429 -0
- plumed/_lib/lib/plumed/patches/namd-2.12.config +30 -0
- plumed/_lib/lib/plumed/patches/namd-2.12.diff +267 -0
- plumed/_lib/lib/plumed/patches/namd-2.13.config +30 -0
- plumed/_lib/lib/plumed/patches/namd-2.13.diff +267 -0
- plumed/_lib/lib/plumed/patches/namd-2.14.config +30 -0
- plumed/_lib/lib/plumed/patches/namd-2.14.diff +268 -0
- plumed/_lib/lib/plumed/patches/patch.sh +500 -0
- plumed/_lib/lib/plumed/patches/qespresso-5.0.2.config +25 -0
- plumed/_lib/lib/plumed/patches/qespresso-5.0.2.diff/PW/src/forces.f90 +368 -0
- plumed/_lib/lib/plumed/patches/qespresso-5.0.2.diff/PW/src/forces.f90.preplumed +366 -0
- plumed/_lib/lib/plumed/patches/qespresso-5.0.2.diff/PW/src/plugin_forces.f90 +71 -0
- plumed/_lib/lib/plumed/patches/qespresso-5.0.2.diff/PW/src/plugin_forces.f90.preplumed +24 -0
- plumed/_lib/lib/plumed/patches/qespresso-5.0.2.diff/PW/src/plugin_initialization.f90 +62 -0
- plumed/_lib/lib/plumed/patches/qespresso-5.0.2.diff/PW/src/plugin_initialization.f90.preplumed +21 -0
- plumed/_lib/lib/plumed/patches/qespresso-5.0.2.diff/PW/src/pwscf.f90 +189 -0
- plumed/_lib/lib/plumed/patches/qespresso-5.0.2.diff/PW/src/pwscf.f90.preplumed +185 -0
- plumed/_lib/lib/plumed/patches/qespresso-6.2.config +26 -0
- plumed/_lib/lib/plumed/patches/qespresso-6.2.diff/PW/src/forces.f90 +422 -0
- plumed/_lib/lib/plumed/patches/qespresso-6.2.diff/PW/src/forces.f90.preplumed +420 -0
- plumed/_lib/lib/plumed/patches/qespresso-6.2.diff/PW/src/plugin_ext_forces.f90 +70 -0
- plumed/_lib/lib/plumed/patches/qespresso-6.2.diff/PW/src/plugin_ext_forces.f90.preplumed +23 -0
- plumed/_lib/lib/plumed/patches/qespresso-6.2.diff/PW/src/plugin_initialization.f90 +62 -0
- plumed/_lib/lib/plumed/patches/qespresso-6.2.diff/PW/src/plugin_initialization.f90.preplumed +21 -0
- plumed/_lib/lib/plumed/patches/qespresso-6.2.diff/PW/src/run_pwscf.f90 +233 -0
- plumed/_lib/lib/plumed/patches/qespresso-6.2.diff/PW/src/run_pwscf.f90.preplumed +230 -0
- plumed/_lib/lib/plumed/patches/qespresso-7.0.config +28 -0
- plumed/_lib/lib/plumed/patches/qespresso-7.0.diff/Modules/Makefile +175 -0
- plumed/_lib/lib/plumed/patches/qespresso-7.0.diff/Modules/Makefile.preplumed +171 -0
- plumed/_lib/lib/plumed/patches/qespresso-7.0.diff/PW/src/forces.f90 +486 -0
- plumed/_lib/lib/plumed/patches/qespresso-7.0.diff/PW/src/forces.f90.preplumed +484 -0
- plumed/_lib/lib/plumed/patches/qespresso-7.0.diff/PW/src/plugin_ext_forces.f90 +74 -0
- plumed/_lib/lib/plumed/patches/qespresso-7.0.diff/PW/src/plugin_ext_forces.f90.preplumed +23 -0
- plumed/_lib/lib/plumed/patches/qespresso-7.0.diff/PW/src/plugin_initialization.f90 +64 -0
- plumed/_lib/lib/plumed/patches/qespresso-7.0.diff/PW/src/plugin_initialization.f90.preplumed +21 -0
- plumed/_lib/lib/plumed/patches/qespresso-7.0.diff/PW/src/run_pwscf.f90 +532 -0
- plumed/_lib/lib/plumed/patches/qespresso-7.0.diff/PW/src/run_pwscf.f90.preplumed +518 -0
- plumed/_lib/lib/plumed/patches/qespresso-7.2.config +28 -0
- plumed/_lib/lib/plumed/patches/qespresso-7.2.diff/Modules/Makefile +249 -0
- plumed/_lib/lib/plumed/patches/qespresso-7.2.diff/Modules/Makefile.preplumed +244 -0
- plumed/_lib/lib/plumed/patches/qespresso-7.2.diff/PW/src/forces.f90 +532 -0
- plumed/_lib/lib/plumed/patches/qespresso-7.2.diff/PW/src/forces.f90.preplumed +535 -0
- plumed/_lib/lib/plumed/patches/qespresso-7.2.diff/PW/src/plugin_ext_forces.f90 +74 -0
- plumed/_lib/lib/plumed/patches/qespresso-7.2.diff/PW/src/plugin_ext_forces.f90.preplumed +23 -0
- plumed/_lib/lib/plumed/patches/qespresso-7.2.diff/PW/src/plugin_initialization.f90 +64 -0
- plumed/_lib/lib/plumed/patches/qespresso-7.2.diff/PW/src/plugin_initialization.f90.preplumed +21 -0
- plumed/_lib/lib/plumed/patches/qespresso-7.2.diff/PW/src/run_pwscf.f90 +569 -0
- plumed/_lib/lib/plumed/patches/qespresso-7.2.diff/PW/src/run_pwscf.f90.preplumed +560 -0
- plumed/_lib/lib/plumed/plumed-config +9 -0
- plumed/_lib/lib/plumed/plumed-mklib +9 -0
- plumed/_lib/lib/plumed/plumed-newcv +9 -0
- plumed/_lib/lib/plumed/plumed-partial_tempering +9 -0
- plumed/_lib/lib/plumed/plumed-patch +9 -0
- plumed/_lib/lib/plumed/plumed-runtime +0 -0
- plumed/_lib/lib/plumed/plumed-selector +9 -0
- plumed/_lib/lib/plumed/plumed-vim2html +9 -0
- plumed/_lib/lib/plumed/scripts/config.sh +126 -0
- plumed/_lib/lib/plumed/scripts/mklib.sh +175 -0
- plumed/_lib/lib/plumed/scripts/newcv.sh +26 -0
- plumed/_lib/lib/plumed/scripts/partial_tempering.sh +319 -0
- plumed/_lib/lib/plumed/scripts/patch.sh +4 -0
- plumed/_lib/lib/plumed/scripts/selector.sh +234 -0
- plumed/_lib/lib/plumed/scripts/vim2html.sh +190 -0
- plumed/_lib/lib/plumed/src/colvar/Template.cpp +116 -0
- plumed/_lib/lib/plumed/src/config/compile_options.sh +3 -0
- plumed/_lib/lib/plumed/src/config/config.txt +181 -0
- plumed/_lib/lib/plumed/src/lib/Plumed.cmake +6 -0
- plumed/_lib/lib/plumed/src/lib/Plumed.cmake.runtime +5 -0
- plumed/_lib/lib/plumed/src/lib/Plumed.cmake.shared +5 -0
- plumed/_lib/lib/plumed/src/lib/Plumed.cmake.static +3 -0
- plumed/_lib/lib/plumed/src/lib/Plumed.inc +6 -0
- plumed/_lib/lib/plumed/src/lib/Plumed.inc.runtime +5 -0
- plumed/_lib/lib/plumed/src/lib/Plumed.inc.shared +5 -0
- plumed/_lib/lib/plumed/src/lib/Plumed.inc.static +3 -0
- plumed/_lib/lib/plumed/vim/scripts.vim +6 -0
- plumed/_plumed_core.cpython-311-darwin.so +0 -0
- plumed/_plumed_core.cpython-312-darwin.so +0 -0
- plumed/_plumed_core.cpython-313-darwin.so +0 -0
- plumed/_plumed_core.cpython-314-darwin.so +0 -0
- plumedCommunications.cpython-311-darwin.so +0 -0
- plumedCommunications.cpython-312-darwin.so +0 -0
- plumedCommunications.cpython-313-darwin.so +0 -0
- plumedCommunications.cpython-314-darwin.so +0 -0
- plumedCommunications.pyi +431 -0
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
/* +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
|
2
|
+
Copyright (c) 2012-2023 The plumed team
|
|
3
|
+
(see the PEOPLE file at the root of the distribution for a list of names)
|
|
4
|
+
|
|
5
|
+
See http://www.plumed.org for more information.
|
|
6
|
+
|
|
7
|
+
This file is part of plumed, version 2.
|
|
8
|
+
|
|
9
|
+
plumed is free software: you can redistribute it and/or modify
|
|
10
|
+
it under the terms of the GNU Lesser General Public License as published by
|
|
11
|
+
the Free Software Foundation, either version 3 of the License, or
|
|
12
|
+
(at your option) any later version.
|
|
13
|
+
|
|
14
|
+
plumed is distributed in the hope that it will be useful,
|
|
15
|
+
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
16
|
+
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
17
|
+
GNU Lesser General Public License for more details.
|
|
18
|
+
|
|
19
|
+
You should have received a copy of the GNU Lesser General Public License
|
|
20
|
+
along with plumed. If not, see <http://www.gnu.org/licenses/>.
|
|
21
|
+
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
|
|
22
|
+
#ifndef __PLUMED_core_CLToolMain_h
|
|
23
|
+
#define __PLUMED_core_CLToolMain_h
|
|
24
|
+
#include <cstdio>
|
|
25
|
+
#include <vector>
|
|
26
|
+
#include <string>
|
|
27
|
+
#include <string_view>
|
|
28
|
+
#include "WithCmd.h"
|
|
29
|
+
#include "../tools/ForwardDecl.h"
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
namespace PLMD {
|
|
33
|
+
|
|
34
|
+
class Communicator;
|
|
35
|
+
|
|
36
|
+
/**
|
|
37
|
+
Class providing cmd() access to command line tools.
|
|
38
|
+
|
|
39
|
+
This class provides an interface using the "cmd()" syntax to all the
|
|
40
|
+
command-line tools.
|
|
41
|
+
It is only accessed via the cmd() function, which can
|
|
42
|
+
be used to set the arguments, communicators and IO descriptors and
|
|
43
|
+
to run the tool.
|
|
44
|
+
It can run all the tools registered via the PLUMED_REGISTER_CLTOOL macro,
|
|
45
|
+
or the scripts which are located in PLUMED_ROOT/scripts.
|
|
46
|
+
|
|
47
|
+
A typical usage is:
|
|
48
|
+
\verbatim
|
|
49
|
+
#include "CLToolMain.h"
|
|
50
|
+
int main(int argc,char**argv){
|
|
51
|
+
PLMD::CLToolMain cltoolMain;
|
|
52
|
+
cltoolMain.cmd("setArgc",&argc);
|
|
53
|
+
cltoolMain.cmd("setArgv",argv);
|
|
54
|
+
int ret;
|
|
55
|
+
cltoolMain.cmd("run",&ret);
|
|
56
|
+
return ret;
|
|
57
|
+
}
|
|
58
|
+
\endverbatim
|
|
59
|
+
This will run the tool registered with name argv[1] with options argv[2]...argv[argc-1].
|
|
60
|
+
|
|
61
|
+
This class is also used in the \ref PlumedMain class to provide
|
|
62
|
+
the same functionalities through the external plumed interface, which
|
|
63
|
+
is available also for C and FORTRAN. Thus, the preferred approach is to do something like
|
|
64
|
+
\verbatim
|
|
65
|
+
#include "Plumed.h"
|
|
66
|
+
int main(int argc,char**argv){
|
|
67
|
+
PLMD::Plumed p;
|
|
68
|
+
p.cmd("CLTool setArgc",&argc);
|
|
69
|
+
p.cmd("CLTool setArgv",argv);
|
|
70
|
+
int ret;
|
|
71
|
+
p.cmd("CLTool run",&ret);
|
|
72
|
+
return ret;
|
|
73
|
+
}
|
|
74
|
+
\endverbatim
|
|
75
|
+
|
|
76
|
+
See the file \ref main.cpp for a similar example.
|
|
77
|
+
|
|
78
|
+
*/
|
|
79
|
+
class CLToolMain:
|
|
80
|
+
public WithCmd {
|
|
81
|
+
/// arguments for command-line mode:
|
|
82
|
+
int argc;
|
|
83
|
+
/// arguments for command-line mode:
|
|
84
|
+
std::vector<std::string> argv;
|
|
85
|
+
FILE*in;
|
|
86
|
+
FILE*out;
|
|
87
|
+
ForwardDecl<Communicator> comm_fwd;
|
|
88
|
+
Communicator&comm=*comm_fwd;
|
|
89
|
+
static int run(int argc, char **argv,FILE*in,FILE*out,Communicator&pc);
|
|
90
|
+
public:
|
|
91
|
+
CLToolMain();
|
|
92
|
+
~CLToolMain();
|
|
93
|
+
/**
|
|
94
|
+
Send messages to the CLToolMain.
|
|
95
|
+
*/
|
|
96
|
+
void cmd(std::string_view key,const TypesafePtr & val=nullptr) override;
|
|
97
|
+
};
|
|
98
|
+
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
|
|
102
|
+
#endif
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
/* +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
|
2
|
+
Copyright (c) 2012-2023 The plumed team
|
|
3
|
+
(see the PEOPLE file at the root of the distribution for a list of names)
|
|
4
|
+
|
|
5
|
+
See http://www.plumed.org for more information.
|
|
6
|
+
|
|
7
|
+
This file is part of plumed, version 2.
|
|
8
|
+
|
|
9
|
+
plumed is free software: you can redistribute it and/or modify
|
|
10
|
+
it under the terms of the GNU Lesser General Public License as published by
|
|
11
|
+
the Free Software Foundation, either version 3 of the License, or
|
|
12
|
+
(at your option) any later version.
|
|
13
|
+
|
|
14
|
+
plumed is distributed in the hope that it will be useful,
|
|
15
|
+
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
16
|
+
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
17
|
+
GNU Lesser General Public License for more details.
|
|
18
|
+
|
|
19
|
+
You should have received a copy of the GNU Lesser General Public License
|
|
20
|
+
along with plumed. If not, see <http://www.gnu.org/licenses/>.
|
|
21
|
+
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
|
|
22
|
+
#ifndef __PLUMED_core_CLToolRegister_h
|
|
23
|
+
#define __PLUMED_core_CLToolRegister_h
|
|
24
|
+
|
|
25
|
+
#include "RegisterBase.h"
|
|
26
|
+
#include "../tools/Keywords.h"
|
|
27
|
+
|
|
28
|
+
namespace PLMD {
|
|
29
|
+
|
|
30
|
+
class CLTool;
|
|
31
|
+
class CLToolOptions;
|
|
32
|
+
|
|
33
|
+
struct CLToolRegisterPointers {
|
|
34
|
+
/// Pointer to a function which, given the options, create an CLTool
|
|
35
|
+
typedef std::unique_ptr<CLTool>(*creator_pointer)(const CLToolOptions&);
|
|
36
|
+
/// Pointer to a function which, returns the keywords allowed
|
|
37
|
+
typedef void(*keywords_pointer)(Keywords&);
|
|
38
|
+
creator_pointer create;
|
|
39
|
+
Keywords keys;
|
|
40
|
+
};
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
/// Same as ActionRegister, but for CLTools
|
|
44
|
+
class CLToolRegister :
|
|
45
|
+
public RegisterBase<CLToolRegisterPointers> {
|
|
46
|
+
typedef CLToolRegisterPointers::creator_pointer creator_pointer;
|
|
47
|
+
typedef CLToolRegisterPointers::keywords_pointer keywords_pointer;
|
|
48
|
+
typedef CLToolRegisterPointers Pointers;
|
|
49
|
+
|
|
50
|
+
// this is necessary to avoid warnings on getKeys overload.
|
|
51
|
+
// notice that RegisterBase<CLToolRegisterPointers>::getKeys returns
|
|
52
|
+
// the list of keys (here: CLTools). conversely
|
|
53
|
+
// CLToolRegister::getKeys(std::string name) returns the options
|
|
54
|
+
// associated to CLTool name.
|
|
55
|
+
// We hide the former here, which is actually implemented by list()
|
|
56
|
+
// not to break existing code.
|
|
57
|
+
using RegisterBase<CLToolRegisterPointers>::getKeys;
|
|
58
|
+
|
|
59
|
+
public:
|
|
60
|
+
/// Register a new class.
|
|
61
|
+
/// \param key The name of the directive to be used in the input file
|
|
62
|
+
/// \param cp A pointer to a function which creates an object of that class
|
|
63
|
+
/// \param kp A pointer to a function which returns the allowed keywords
|
|
64
|
+
ID add(std::string key,creator_pointer cp,keywords_pointer kp);
|
|
65
|
+
/// Create an CLTool of the type indicated in the options
|
|
66
|
+
/// \param ao object containing information for initialization, such as the full input line, a pointer to PlumedMain, etc
|
|
67
|
+
std::unique_ptr<CLTool> create(const CLToolOptions&ao);
|
|
68
|
+
std::unique_ptr<CLTool> create(const std::vector<void*> & images,const CLToolOptions&ao);
|
|
69
|
+
/// Returns a list of the allowed CLTools
|
|
70
|
+
std::vector<std::string> list()const;
|
|
71
|
+
/// Print out the instructions for using the tool in html ready for input into the manual
|
|
72
|
+
bool printManual(const std::string& cltool,const bool& spelling);
|
|
73
|
+
/// Return all the keys of this cltool
|
|
74
|
+
std::vector<std::string> getKeys(const std::string& cltool)const;
|
|
75
|
+
};
|
|
76
|
+
|
|
77
|
+
/// Function returning a reference to the CLToolRegister.
|
|
78
|
+
/// \relates CLToolRegister
|
|
79
|
+
/// To avoid problems with order of initialization, this function contains
|
|
80
|
+
/// a static CLToolRegister which is built the first time the function is called.
|
|
81
|
+
/// In this manner, it is always initialized before it's used
|
|
82
|
+
CLToolRegister& cltoolRegister();
|
|
83
|
+
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
|
|
87
|
+
/// Shortcut for CLTool registration
|
|
88
|
+
/// \relates PLMD::CLToolRegister
|
|
89
|
+
/// For easier registration, this file also provides a macro PLUMED_REGISTER_CLTOOL.
|
|
90
|
+
/// \param classname the name of the class to be registered
|
|
91
|
+
/// \param directive a string containing the corresponding directive
|
|
92
|
+
/// This macro should be used in the .cpp file of the corresponding class
|
|
93
|
+
#define PLUMED_REGISTER_CLTOOL(classname,directive) \
|
|
94
|
+
namespace { class classname##RegisterMe{ \
|
|
95
|
+
CLToolRegister::ID id; \
|
|
96
|
+
static std::unique_ptr<CLTool> create(const CLToolOptions&ao) { \
|
|
97
|
+
return std::make_unique<classname>(ao); \
|
|
98
|
+
} \
|
|
99
|
+
public: \
|
|
100
|
+
classname##RegisterMe() : \
|
|
101
|
+
id(PLMD::cltoolRegister().add(directive,create,classname::registerKeywords)) \
|
|
102
|
+
{} \
|
|
103
|
+
~classname##RegisterMe(){PLMD::cltoolRegister().remove(id);} \
|
|
104
|
+
} classname##RegisterMeObject; }
|
|
105
|
+
|
|
106
|
+
|
|
107
|
+
#endif
|
|
108
|
+
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
/* +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
|
2
|
+
Copyright (c) 2011-2023 The plumed team
|
|
3
|
+
(see the PEOPLE file at the root of the distribution for a list of names)
|
|
4
|
+
|
|
5
|
+
See http://www.plumed.org for more information.
|
|
6
|
+
|
|
7
|
+
This file is part of plumed, version 2.
|
|
8
|
+
|
|
9
|
+
plumed is free software: you can redistribute it and/or modify
|
|
10
|
+
it under the terms of the GNU Lesser General Public License as published by
|
|
11
|
+
the Free Software Foundation, either version 3 of the License, or
|
|
12
|
+
(at your option) any later version.
|
|
13
|
+
|
|
14
|
+
plumed is distributed in the hope that it will be useful,
|
|
15
|
+
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
16
|
+
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
17
|
+
GNU Lesser General Public License for more details.
|
|
18
|
+
|
|
19
|
+
You should have received a copy of the GNU Lesser General Public License
|
|
20
|
+
along with plumed. If not, see <http://www.gnu.org/licenses/>.
|
|
21
|
+
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
|
|
22
|
+
#ifndef __PLUMED_core_Colvar_h
|
|
23
|
+
#define __PLUMED_core_Colvar_h
|
|
24
|
+
|
|
25
|
+
#include "ActionAtomistic.h"
|
|
26
|
+
#include "ActionWithValue.h"
|
|
27
|
+
#include "../tools/Matrix.h"
|
|
28
|
+
#include <vector>
|
|
29
|
+
|
|
30
|
+
#define PLUMED_COLVAR_INIT(ao) Action(ao),Colvar(ao)
|
|
31
|
+
|
|
32
|
+
namespace PLMD {
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
\ingroup INHERIT
|
|
36
|
+
This is the abstract base class to use for implementing new collective variables, within it there is
|
|
37
|
+
\ref AddingAColvar "information" as to how to go about implementing a new CV.
|
|
38
|
+
*/
|
|
39
|
+
|
|
40
|
+
class Colvar :
|
|
41
|
+
public ActionAtomistic,
|
|
42
|
+
public ActionWithValue {
|
|
43
|
+
private:
|
|
44
|
+
protected:
|
|
45
|
+
void requestAtoms(const std::vector<AtomNumber> & a);
|
|
46
|
+
// Set the derivatives for a particular atom equal to the input Vector
|
|
47
|
+
// This routine is called setAtomsDerivatives because not because you
|
|
48
|
+
// are setting the derivative of many atoms but because you are setting
|
|
49
|
+
// the derivatives of a particular atom. The s is an apostrophe s
|
|
50
|
+
// but you can't put apostrophes in function names
|
|
51
|
+
void setAtomsDerivatives(int,const Vector&);
|
|
52
|
+
void setAtomsDerivatives(Value*,int,const Vector&);
|
|
53
|
+
void setBoxDerivatives(const Tensor&);
|
|
54
|
+
void setBoxDerivatives(Value*,const Tensor&);
|
|
55
|
+
const Tensor & getBoxDerivatives()const;
|
|
56
|
+
const double & getForce()const;
|
|
57
|
+
void apply() override;
|
|
58
|
+
/// Set box derivatives automatically.
|
|
59
|
+
/// It should be called after the setAtomsDerivatives has been used for all
|
|
60
|
+
/// single atoms.
|
|
61
|
+
/// \warning It only works for collective variable NOT using PBCs!
|
|
62
|
+
void setBoxDerivativesNoPbc();
|
|
63
|
+
void setBoxDerivativesNoPbc(Value*);
|
|
64
|
+
public:
|
|
65
|
+
explicit Colvar(const ActionOptions&);
|
|
66
|
+
~Colvar() {}
|
|
67
|
+
static void registerKeywords( Keywords& keys );
|
|
68
|
+
unsigned getNumberOfDerivatives() override;
|
|
69
|
+
};
|
|
70
|
+
|
|
71
|
+
inline
|
|
72
|
+
void Colvar::setAtomsDerivatives(Value*v,int i,const Vector&d) {
|
|
73
|
+
v->addDerivative(3*i+0,d[0]);
|
|
74
|
+
v->addDerivative(3*i+1,d[1]);
|
|
75
|
+
v->addDerivative(3*i+2,d[2]);
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
|
|
79
|
+
inline
|
|
80
|
+
void Colvar::setBoxDerivatives(Value* v,const Tensor&d) {
|
|
81
|
+
unsigned nat=getNumberOfAtoms();
|
|
82
|
+
v->addDerivative(3*nat+0,d(0,0));
|
|
83
|
+
v->addDerivative(3*nat+1,d(0,1));
|
|
84
|
+
v->addDerivative(3*nat+2,d(0,2));
|
|
85
|
+
v->addDerivative(3*nat+3,d(1,0));
|
|
86
|
+
v->addDerivative(3*nat+4,d(1,1));
|
|
87
|
+
v->addDerivative(3*nat+5,d(1,2));
|
|
88
|
+
v->addDerivative(3*nat+6,d(2,0));
|
|
89
|
+
v->addDerivative(3*nat+7,d(2,1));
|
|
90
|
+
v->addDerivative(3*nat+8,d(2,2));
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
inline
|
|
94
|
+
void Colvar::setAtomsDerivatives(int i,const Vector&d) {
|
|
95
|
+
setAtomsDerivatives(getPntrToValue(),i,d);
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
inline
|
|
99
|
+
void Colvar::setBoxDerivatives(const Tensor&d) {
|
|
100
|
+
setBoxDerivatives(getPntrToValue(),d);
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
inline
|
|
104
|
+
void Colvar::setBoxDerivativesNoPbc() {
|
|
105
|
+
setBoxDerivativesNoPbc(getPntrToValue());
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
inline
|
|
109
|
+
unsigned Colvar::getNumberOfDerivatives() {
|
|
110
|
+
return 3*getNumberOfAtoms() + 9;
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
#endif
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
/* +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
|
2
|
+
Copyright (c) 2017-2023 The plumed team
|
|
3
|
+
(see the PEOPLE file at the root of the distribution for a list of names)
|
|
4
|
+
|
|
5
|
+
See http://www.plumed.org for more information.
|
|
6
|
+
|
|
7
|
+
This file is part of plumed, version 2.
|
|
8
|
+
|
|
9
|
+
plumed is free software: you can redistribute it and/or modify
|
|
10
|
+
it under the terms of the GNU Lesser General Public License as published by
|
|
11
|
+
the Free Software Foundation, either version 3 of the License, or
|
|
12
|
+
(at your option) any later version.
|
|
13
|
+
|
|
14
|
+
plumed is distributed in the hope that it will be useful,
|
|
15
|
+
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
16
|
+
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
17
|
+
GNU Lesser General Public License for more details.
|
|
18
|
+
|
|
19
|
+
You should have received a copy of the GNU Lesser General Public License
|
|
20
|
+
along with plumed. If not, see <http://www.gnu.org/licenses/>.
|
|
21
|
+
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
|
|
22
|
+
#ifndef __PLUMED_core_DataPassingObject_h
|
|
23
|
+
#define __PLUMED_core_DataPassingObject_h
|
|
24
|
+
|
|
25
|
+
#include <vector>
|
|
26
|
+
#include <memory>
|
|
27
|
+
#include <set>
|
|
28
|
+
#include "../tools/AtomNumber.h"
|
|
29
|
+
#include "../tools/TypesafePtr.h"
|
|
30
|
+
#include "Value.h"
|
|
31
|
+
|
|
32
|
+
namespace PLMD {
|
|
33
|
+
|
|
34
|
+
class DataPassingObject {
|
|
35
|
+
protected:
|
|
36
|
+
/// The start of the data in the input pointer
|
|
37
|
+
unsigned start;
|
|
38
|
+
/// The spacing between values in the input arrays
|
|
39
|
+
unsigned stride;
|
|
40
|
+
/// The units of the quantity
|
|
41
|
+
double unit;
|
|
42
|
+
/// The units of the force on this quantity
|
|
43
|
+
double funit;
|
|
44
|
+
/// The backup value of the quantity (used if the value is passed directly)
|
|
45
|
+
bool hasbackup;
|
|
46
|
+
double bvalue;
|
|
47
|
+
public:
|
|
48
|
+
static std::unique_ptr<DataPassingObject> create(unsigned n);
|
|
49
|
+
explicit DataPassingObject() : start(0), stride(1), unit(1), funit(1), hasbackup(false), bvalue(0) {}
|
|
50
|
+
/// Virtual destructor, just to allow inheritance.
|
|
51
|
+
virtual ~DataPassingObject() {}
|
|
52
|
+
/// Convert what comes from the MD code to a double
|
|
53
|
+
virtual double MD2double(const TypesafePtr & m) const=0;
|
|
54
|
+
///
|
|
55
|
+
void setStart( const unsigned& s ) {
|
|
56
|
+
start=s;
|
|
57
|
+
}
|
|
58
|
+
/// Set the stride to use when getting data from the input array
|
|
59
|
+
void setStride( const unsigned& s ) {
|
|
60
|
+
stride=s;
|
|
61
|
+
}
|
|
62
|
+
/// Set the unit for the value
|
|
63
|
+
void setUnit( const double& u ) {
|
|
64
|
+
unit=u;
|
|
65
|
+
}
|
|
66
|
+
/// Set the unit for the force
|
|
67
|
+
void setForceUnit( const double& u ) {
|
|
68
|
+
funit=u;
|
|
69
|
+
}
|
|
70
|
+
/// This is used when you want to save the passed object to a double variable in PLUMED rather than the pointer
|
|
71
|
+
/// this can be used even when you don't pass a pointer from the MD code
|
|
72
|
+
virtual void saveValueAsDouble( const TypesafePtr & val )=0;
|
|
73
|
+
/// Set the pointer to the value
|
|
74
|
+
virtual void setValuePointer( const TypesafePtr & val, const std::vector<std::size_t>& shape, const bool& isconst )=0;
|
|
75
|
+
/// Set the pointer to the force
|
|
76
|
+
virtual void setForcePointer( const TypesafePtr & val, const std::vector<std::size_t>& shape )=0;
|
|
77
|
+
/// This gets the data in the pointer and passes it to the output value
|
|
78
|
+
virtual void share_data( std::vector<double>& values ) const = 0;
|
|
79
|
+
/// Share the data and put it in the value from sequential data
|
|
80
|
+
virtual void share_data( const unsigned& j, const unsigned& k, Value* value )=0;
|
|
81
|
+
/// Share the data and put it in the value from a scattered data
|
|
82
|
+
virtual void share_data( const std::vector<AtomNumber>&index, const std::vector<unsigned>& i, Value* value )=0;
|
|
83
|
+
/// Pass the force from the value to the output value
|
|
84
|
+
virtual void add_force( Value* vv )=0;
|
|
85
|
+
virtual void add_force( const std::vector<int>& index, Value* value )=0;
|
|
86
|
+
virtual void add_force( const std::vector<AtomNumber>& index, const std::vector<unsigned>& i, Value* value )=0;
|
|
87
|
+
/// Rescale the forces that were passed
|
|
88
|
+
virtual void rescale_force( const unsigned& n, const double& factor, Value* value )=0;
|
|
89
|
+
/// This transfers everything to the output
|
|
90
|
+
virtual void setData( Value* value )=0;
|
|
91
|
+
};
|
|
92
|
+
|
|
93
|
+
}
|
|
94
|
+
#endif
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
/* +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
|
2
|
+
Copyright (c) 2017-2023 The plumed team
|
|
3
|
+
(see the PEOPLE file at the root of the distribution for a list of names)
|
|
4
|
+
|
|
5
|
+
See http://www.plumed.org for more information.
|
|
6
|
+
|
|
7
|
+
This file is part of plumed, version 2.
|
|
8
|
+
|
|
9
|
+
plumed is free software: you can redistribute it and/or modify
|
|
10
|
+
it under the terms of the GNU Lesser General Public License as published by
|
|
11
|
+
the Free Software Foundation, either version 3 of the License, or
|
|
12
|
+
(at your option) any later version.
|
|
13
|
+
|
|
14
|
+
plumed is distributed in the hope that it will be useful,
|
|
15
|
+
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
16
|
+
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
17
|
+
GNU Lesser General Public License for more details.
|
|
18
|
+
|
|
19
|
+
You should have received a copy of the GNU Lesser General Public License
|
|
20
|
+
along with plumed. If not, see <http://www.gnu.org/licenses/>.
|
|
21
|
+
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
|
|
22
|
+
#ifndef __PLUMED_core_DataPassingTools_h
|
|
23
|
+
#define __PLUMED_core_DataPassingTools_h
|
|
24
|
+
|
|
25
|
+
#include <string>
|
|
26
|
+
#include <memory>
|
|
27
|
+
#include <map>
|
|
28
|
+
#include "../tools/TypesafePtr.h"
|
|
29
|
+
#include "../tools/Units.h"
|
|
30
|
+
|
|
31
|
+
namespace PLMD {
|
|
32
|
+
|
|
33
|
+
class PlumedMain;
|
|
34
|
+
|
|
35
|
+
class DataPassingTools {
|
|
36
|
+
friend class PlumedMain;
|
|
37
|
+
private:
|
|
38
|
+
/// The units used in the MD code and PLUMED
|
|
39
|
+
Units units;
|
|
40
|
+
Units MDUnits;
|
|
41
|
+
/// Is the code using natural units
|
|
42
|
+
bool usingNaturalUnits;
|
|
43
|
+
public:
|
|
44
|
+
/// Virtual destructor, just to allow inheritance.
|
|
45
|
+
virtual ~DataPassingTools() {}
|
|
46
|
+
static std::unique_ptr<DataPassingTools> create(unsigned n);
|
|
47
|
+
virtual int getRealPrecision() const = 0;
|
|
48
|
+
double getUnitConversion( const std::string& unit ) const ;
|
|
49
|
+
virtual double MD2double(const TypesafePtr & m) const=0;
|
|
50
|
+
virtual void double2MD(const double&,const TypesafePtr & m) const=0;
|
|
51
|
+
};
|
|
52
|
+
|
|
53
|
+
}
|
|
54
|
+
#endif
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
/* +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
|
2
|
+
Copyright (c) 2017-2023 The plumed team
|
|
3
|
+
(see the PEOPLE file at the root of the distribution for a list of names)
|
|
4
|
+
|
|
5
|
+
See http://www.plumed.org for more information.
|
|
6
|
+
|
|
7
|
+
This file is part of plumed, version 2.
|
|
8
|
+
|
|
9
|
+
plumed is free software: you can redistribute it and/or modify
|
|
10
|
+
it under the terms of the GNU Lesser General Public License as published by
|
|
11
|
+
the Free Software Foundation, either version 3 of the License, or
|
|
12
|
+
(at your option) any later version.
|
|
13
|
+
|
|
14
|
+
plumed is distributed in the hope that it will be useful,
|
|
15
|
+
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
16
|
+
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
17
|
+
GNU Lesser General Public License for more details.
|
|
18
|
+
|
|
19
|
+
You should have received a copy of the GNU Lesser General Public License
|
|
20
|
+
along with plumed. If not, see <http://www.gnu.org/licenses/>.
|
|
21
|
+
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
|
|
22
|
+
#ifndef __PLUMED_core_DomainDecomposition_h
|
|
23
|
+
#define __PLUMED_core_DomainDecomposition_h
|
|
24
|
+
|
|
25
|
+
#include "ActionForInterface.h"
|
|
26
|
+
#include "../tools/Communicator.h"
|
|
27
|
+
|
|
28
|
+
namespace PLMD {
|
|
29
|
+
|
|
30
|
+
class ActionToPutData;
|
|
31
|
+
class ActionAtomistic;
|
|
32
|
+
|
|
33
|
+
class DomainDecomposition : public ActionForInterface {
|
|
34
|
+
private:
|
|
35
|
+
class DomainComms : public Communicator {
|
|
36
|
+
public:
|
|
37
|
+
bool on;
|
|
38
|
+
bool async;
|
|
39
|
+
|
|
40
|
+
std::vector<Communicator::Request> mpi_request_positions;
|
|
41
|
+
std::vector<Communicator::Request> mpi_request_index;
|
|
42
|
+
|
|
43
|
+
std::vector<double> positionsToBeSent;
|
|
44
|
+
std::vector<double> positionsToBeReceived;
|
|
45
|
+
std::vector<int> indexToBeSent;
|
|
46
|
+
std::vector<int> indexToBeReceived;
|
|
47
|
+
operator bool() const {
|
|
48
|
+
return on;
|
|
49
|
+
}
|
|
50
|
+
DomainComms(): on(false), async(false) {}
|
|
51
|
+
void enable(Communicator& c);
|
|
52
|
+
};
|
|
53
|
+
DomainComms dd;
|
|
54
|
+
long int ddStep;
|
|
55
|
+
|
|
56
|
+
std::vector<int> gatindex;
|
|
57
|
+
/// Map global indexes to local indexes
|
|
58
|
+
/// E.g. g2l[i] is the position of atom i in the array passed from the MD engine.
|
|
59
|
+
/// Called "global to local" since originally it was used to map global indexes to local
|
|
60
|
+
/// ones used in domain decomposition. However, it is now also used for the NAMD-like
|
|
61
|
+
/// interface, where only a small number of atoms is passed to plumed.
|
|
62
|
+
std::vector<int> g2l;
|
|
63
|
+
|
|
64
|
+
unsigned shuffledAtoms;
|
|
65
|
+
|
|
66
|
+
bool asyncSent;
|
|
67
|
+
bool unique_serial; // use unique in serial mode
|
|
68
|
+
/// This holds the list of unique atoms
|
|
69
|
+
std::vector<AtomNumber> unique;
|
|
70
|
+
std::vector<unsigned> uniq_index;
|
|
71
|
+
/// This holds the list of atoms that have a force on
|
|
72
|
+
std::vector<AtomNumber> forced_unique;
|
|
73
|
+
/// This holds the list of actions that are set from this action
|
|
74
|
+
std::vector<ActionToPutData*> inputs;
|
|
75
|
+
/// This holds all the actions that read atoms
|
|
76
|
+
std::vector<ActionAtomistic*> actions;
|
|
77
|
+
/// The list that holds all the atom indexes we need
|
|
78
|
+
std::vector<int> fullList;
|
|
79
|
+
/// This actually does the sharing of the data across the domains
|
|
80
|
+
void share(const std::vector<AtomNumber>& unique);
|
|
81
|
+
/// Get all the atoms in the input that are active at this time
|
|
82
|
+
void getAllActiveAtoms( std::vector<AtomNumber>& u );
|
|
83
|
+
public:
|
|
84
|
+
static void registerKeywords(Keywords& keys);
|
|
85
|
+
explicit DomainDecomposition(const ActionOptions&ao);
|
|
86
|
+
void setStart( const std::string& name, const unsigned& sss) override ;
|
|
87
|
+
void setStride( const std::string& name, const unsigned& sss) override ;
|
|
88
|
+
void resetForStepStart() override ;
|
|
89
|
+
bool setValuePointer( const std::string& name, const TypesafePtr & ) override ;
|
|
90
|
+
bool setForcePointer( const std::string& name, const TypesafePtr & ) override ;
|
|
91
|
+
unsigned getNumberOfForcesToRescale() const override ;
|
|
92
|
+
void share() override ;
|
|
93
|
+
void shareAll() override ;
|
|
94
|
+
void wait() override ;
|
|
95
|
+
void reset() override ;
|
|
96
|
+
void writeBinary(std::ostream&o) override ;
|
|
97
|
+
void readBinary(std::istream&i) override ;
|
|
98
|
+
void apply() override ;
|
|
99
|
+
void setAtomsNlocal(int n);
|
|
100
|
+
void setAtomsGatindex(const TypesafePtr & g,bool fortran);
|
|
101
|
+
void setAtomsContiguous(int start);
|
|
102
|
+
void Set_comm(Communicator& comm) override ;
|
|
103
|
+
void broadcastToDomains( Value* val );
|
|
104
|
+
void sumOverDomains( Value* val );
|
|
105
|
+
const long int& getDdStep() const ;
|
|
106
|
+
const std::vector<int>& getGatindex() const ;
|
|
107
|
+
void createFullList(const TypesafePtr & x);
|
|
108
|
+
void getFullList(const TypesafePtr & x);
|
|
109
|
+
void clearFullList();
|
|
110
|
+
bool onStep() const override {
|
|
111
|
+
return getNumberOfAtoms()>0;
|
|
112
|
+
}
|
|
113
|
+
unsigned getNumberOfAtoms() const;
|
|
114
|
+
DomainDecomposition* castToDomainDecomposition() noexcept final {
|
|
115
|
+
return this;
|
|
116
|
+
}
|
|
117
|
+
};
|
|
118
|
+
|
|
119
|
+
}
|
|
120
|
+
#endif
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
/* +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
|
2
|
+
Copyright (c) 2012-2023 The plumed team
|
|
3
|
+
(see the PEOPLE file at the root of the distribution for a list of names)
|
|
4
|
+
|
|
5
|
+
See http://www.plumed.org for more information.
|
|
6
|
+
|
|
7
|
+
This file is part of plumed, version 2.
|
|
8
|
+
|
|
9
|
+
plumed is free software: you can redistribute it and/or modify
|
|
10
|
+
it under the terms of the GNU Lesser General Public License as published by
|
|
11
|
+
the Free Software Foundation, either version 3 of the License, or
|
|
12
|
+
(at your option) any later version.
|
|
13
|
+
|
|
14
|
+
plumed is distributed in the hope that it will be useful,
|
|
15
|
+
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
16
|
+
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
17
|
+
GNU Lesser General Public License for more details.
|
|
18
|
+
|
|
19
|
+
You should have received a copy of the GNU Lesser General Public License
|
|
20
|
+
along with plumed. If not, see <http://www.gnu.org/licenses/>.
|
|
21
|
+
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
|
|
22
|
+
#ifndef __PLUMED_core_ExchangePatterns_h
|
|
23
|
+
#define __PLUMED_core_ExchangePatterns_h
|
|
24
|
+
|
|
25
|
+
#include "../tools/ForwardDecl.h"
|
|
26
|
+
#include "../tools/TypesafePtr.h"
|
|
27
|
+
|
|
28
|
+
namespace PLMD {
|
|
29
|
+
class Random;
|
|
30
|
+
|
|
31
|
+
class ExchangePatterns {
|
|
32
|
+
int PatternFlag;
|
|
33
|
+
int NumberOfReplicas;
|
|
34
|
+
ForwardDecl<Random> random_fwd;
|
|
35
|
+
Random& random=*random_fwd;
|
|
36
|
+
public:
|
|
37
|
+
ExchangePatterns();
|
|
38
|
+
~ExchangePatterns();
|
|
39
|
+
enum PatternFlags { NONE, RANDOM, NEIGHBOR, TOTAL };
|
|
40
|
+
void setNofR(const int);
|
|
41
|
+
void setSeed(const int);
|
|
42
|
+
void setFlag(const int);
|
|
43
|
+
void getList(const TypesafePtr & ind);
|
|
44
|
+
void getFlag(int&);
|
|
45
|
+
};
|
|
46
|
+
}
|
|
47
|
+
#endif
|