RAII resource manager for the ARTn C library with global synchronization. More...
Namespaces | |
| namespace | config |
| namespace | detail |
| namespace | dynlib |
| Cross-platform dynamic library loading abstraction. | |
| namespace | EpiCenters |
| namespace | geometry |
| namespace | helpers |
| namespace | io |
| namespace | log |
| namespace | neb |
| namespace | params_ssot |
| namespace | pbc |
| namespace | pot |
| namespace | Prefactor |
| namespace | rng |
| namespace | safemath |
Classes | |
| class | ARTnResource |
| class | ARTnSaddleSearch |
| Saddle search method using the Activation-Relaxation Technique nouveau. More... | |
| class | AtomicGPDimer |
| class | BasinHoppingJob |
| class | BasinHoppingSaddleSearch |
| class | BiasedGradientSquaredDescent |
| class | BondBoost |
| Functionality relying on the conjugate gradients algorithm. More... | |
| class | CollectiveIDPPObjectiveFunction |
| class | ConjugateGradients |
| Decleration of the Conjugate Gradients optimizer. More... | |
| class | Davidson |
| Davidson method for the lowest Hessian curvature mode (min-mode). More... | |
| class | Dimer |
| Classic dimer method to find the lowest curvature mode. More... | |
| class | DimerModeLostException |
| class | DimerModeRestoredException |
| struct | DimerRotationResult |
| Result of a non-classical dimer rotation backend (mode estimate only). More... | |
| class | Dynamics |
| struct | DynamicsConfig |
| Configuration extracted from Parameters for Dynamics. More... | |
| class | DynamicsJob |
| class | DynamicsSaddleSearch |
| class | FiniteDifferenceJob |
| class | FIRE |
| class | ForceCallTimer |
| RAII wrapper for tracking force calls over a scope. More... | |
| class | FPEHandler |
| class | GleThermostat |
| Colored-noise (generalized Langevin) thermostat. More... | |
| class | GlobalOptimization |
| class | GlobalOptimizationJob |
| class | GPSurrogateJob |
| class | Hessian |
| class | HessianJob |
| class | Hyperdynamics |
| class | IDPPObjectiveFunction |
| class | ImprovedDimer |
| class | IRACompare |
| C++ wrapper for the IRA (Iterative Rotations and Assignments) library. More... | |
| class | IRAResource |
| class | Job |
| Declaration of job class. More... | |
| class | LammpsLoader |
| class | Lanczos |
| class | LBFGS |
| class | LORRotation |
| class | LowestEigenmode |
| Base for eigenmode solvers. More... | |
| class | Matter |
| class | MetatomicDynPot |
| class | MetatomicLoader |
| class | MinimizationJob |
| class | MinModeSaddleSearch |
| class | MonteCarlo |
| class | MonteCarloJob |
| class | NEBObjectiveFunction |
| class | NudgedElasticBand |
| class | NudgedElasticBandJob |
| class | ObjectiveFunction |
| class | OHTSTJob |
| class | Optimizer |
| struct | OptimizerConfig |
| Declaration of the optimizer class. More... | |
| class | ParallelReplicaJob |
| class | Parameters |
| class | PluginLoader |
| class | PointJob |
| class | Potential |
| class | PotRegistry |
| class | PrefactorJob |
| class | ProcessSearchJob |
| Declaration of the Process Search job. More... | |
| class | Quickmin |
| class | ReplicaDynamicsJob |
| Base class for replica dynamics jobs (TAD, SafeHyper). More... | |
| class | ReplicaExchangeJob |
| class | SaddleSearchJob |
| Declaration of the Saddle Search job. More... | |
| class | SaddleSearchMethod |
| class | SafeHyperJob |
| struct | ServeEndpoint |
| Configuration for a single serve endpoint. More... | |
| class | SteepestDescent |
| class | StructureComparisonJob |
| class | SurrogatePotential |
| class | TADJob |
| class | TestJob |
| class | VesinNeighbors |
| RAII wrapper around vesin_neighbors for Matter-style boxes (double[9] row-major 3×3 cell, same layout as Matter::cell). More... | |
| class | ZBLRepulsiveIDPPObjective |
Typedefs | |
| using | EigenmodeStrategy = std::variant<Dimer, ImprovedDimer, Lanczos, Davidson> |
| using | ForceCallback |
| Callback type for potential energy/force evaluation. | |
Functions | |
| int | getBundleSize () |
| int | strchrcount (const char *haystack, char needle) |
| std::vector< std::string > | unbundle (int number) |
| void | deleteUnbundledFiles (const std::vector< std::string > &unbundledFilenames) |
| void | bundle (int number, const std::vector< std::string > &filenames, std::vector< std::string > *bundledFilenames) |
| void | commandLine (int argc, char **argv) |
| static void | fpe_signal_handler (int sig, siginfo_t *sip, void *scp) |
| void | enableFPE () |
| void | disableFPE () |
| bool | atomListMeansAll (const std::string &atomList) |
| Whether atomList means "every free atom" (empty, "all", case-insensitive). | |
| VectorXi | freeAtomIndices (const Matter *matter) |
| Free (unfixed) atom indices in ascending order. | |
| VectorXi | resolveMobileAtoms (const Matter *matter, const std::string &atomList) |
| PHVA-class mobile set for FD Hessian and matrix-free Krylov (Lanczos / Davidson). | |
| VectorXi | resolveMobileAtoms (const Matter *matter, const VectorXi &candidates) |
| Explicit candidate indices, intersected with free flags (order preserved, duplicates dropped). | |
| VectorXd | packMobileRows (const AtomMatrix &full, const VectorXi &mobile) |
| Pack full (n_atoms,3) rows of mobile atoms into a 3*n_mobile vector. | |
| void | unpackMobileRows (const VectorXd &packed, const VectorXi &mobile, AtomMatrix &full) |
| Write a 3*n_mobile vector into full AtomMatrix rows (other rows unchanged). | |
| VectorXd | mobileForces (Matter *matter, const VectorXi &mobile) |
| Force components on mobile atoms after Matter has a valid force cache (calls getForces under the hood if needed via the non-const Matter API). | |
| static EonMtaConfig | config_from_params (const Parameters ¶ms) |
| void | serveMode (const Parameters ¶ms, const std::string &host, uint16_t port) |
| Start a single rgpot-compatible Cap'n Proto RPC server. | |
| void | serveMultiple (const std::vector< ServeEndpoint > &endpoints, const Parameters ¶ms) |
| Serve multiple potentials concurrently on different ports. | |
| void | serveReplicated (const Parameters ¶ms, const std::string &host, uint16_t base_port, size_t replicas) |
| Serve N replicas of the same potential across sequential ports. | |
| void | serveGateway (const Parameters ¶ms, const std::string &host, uint16_t port, size_t pool_size) |
| Start a gateway server backed by a pool of potential instances. | |
| void | serveFromConfig (const Parameters ¶ms) |
| Start serve mode from config-file parameters. | |
| std::vector< ServeEndpoint > | parseServeSpec (const std::string &spec) |
| Parse a serve configuration string into endpoints. | |
| constexpr bool | usesAlternativeRotation (DimerRotationBackend backend) noexcept |
| std::optional< DimerRotationResult > | runAlternativeRotation (DimerRotationBackend backend, const std::shared_ptr< Matter > &matter, const Parameters ¶ms, const std::shared_ptr< Potential > &pot, const AtomMatrix &initialDirection, quill::Logger *log=nullptr) |
| Run Lanczos, Davidson, or LOR. | |
| AtomMatrix | from_fortran_layout_vector (const std::vector< double > &flat_colmajor, int nat) |
| Reconstruct AtomMatrix from a flat column-major vector (e.g. | |
| std::shared_ptr< EigenmodeStrategy > | buildEigenmodeStrategy (std::shared_ptr< Matter > matter, const Parameters ¶ms, std::shared_ptr< Potential > pot) |
| Build the eigenmode solver from parameters. | |
| void | eigenmodeCompute (EigenmodeStrategy &s, std::shared_ptr< Matter > matter, AtomMatrix direction) |
| Dispatch compute() to the active variant. | |
| double | eigenmodeGetEigenvalue (EigenmodeStrategy &s) |
| Dispatch getEigenvalue() to the active variant. | |
| AtomMatrix | eigenmodeGetEigenvector (EigenmodeStrategy &s) |
| Dispatch getEigenvector() to the active variant. | |
| ImprovedDimer * | asImprovedDimer (EigenmodeStrategy &s) |
| Access ImprovedDimer-specific features. | |
| long | eigenmodeTotalForceCalls (EigenmodeStrategy &s) |
| Read stats from any variant (all inherit LowestEigenmode stats fields). | |
| double | eigenmodeStatsTorque (EigenmodeStrategy &s) |
| double | eigenmodeStatsAngle (EigenmodeStrategy &s) |
| long | eigenmodeStatsRotations (EigenmodeStrategy &s) |
| long | eigenmodeTotalIterations (EigenmodeStrategy &s) |
| ARTnResource & | get_artn_resource () |
| Global access to thread-safe ARTn resource. | |
| IRAResource & | get_ira_resource () |
| Global access to thread-safe IRA resource. | |
| void | ensure_interpreter () |
| void | startRpcServer (ForceCallback callback, const std::string &host, uint16_t port) |
| Start a blocking Cap'n Proto RPC server using a force callback. | |
| void | startPooledRpcServer (std::vector< ForceCallback > pool, const std::string &host, uint16_t port) |
| Start a blocking Cap'n Proto RPC server backed by a pool of force callbacks dispatched round-robin. | |
Variables | |
| static constexpr unsigned | MXCSR_MASK_IM = 1u << 7 |
| static constexpr unsigned | MXCSR_MASK_ZM = 1u << 9 |
| static constexpr unsigned | MXCSR_MASK_OM = 1u << 10 |
| constexpr double | IM = 2147483647.0 |
| constexpr double | AM = 1.0 / IM |
| constexpr int | NTAB = 32 |
| constexpr int | NDIV = 1 + (IM / NTAB) |
| constexpr double | EPS = 1.2e-7 |
| constexpr double | RNMX = 1.0 - EPS |
| constexpr long | IM1 = 2147483563 |
| constexpr long | IM2 = 2147483399 |
| constexpr long | IMM1 = IM1 - 1 |
| constexpr long | IA1 = 40014 |
| constexpr long | IA2 = 40692 |
| constexpr long | IQ1 = 53668 |
| constexpr long | IQ2 = 52774 |
| constexpr long | IR1 = 12211 |
| constexpr long | IR2 = 3791 |
RAII resource manager for the ARTn C library with global synchronization.
Runtime loader for engine plugin shared libraries.
Runtime loader for the LAMMPS C library.
Contains all runtime parameters and results.
RAII resource manager for the IRA C library with global synchronization.
Uses dlopen (POSIX) or LoadLibrary (Windows) to load libartn at runtime. Implements global mutex to ensure thread-safety when multiple threads access the Fortran backend which has shared global state.
WARNING: Due to the non-thread-safe Fortran backend, all ARTn operations are serialized through a global mutex. Multiple threads calling ARTn simultaneously will execute sequentially, potentially creating a significant performance bottleneck in multi-threaded contexts. Consider process-level parallelism if true concurrent ARTn operations are required.
Uses dlopen (POSIX) or LoadLibrary (Windows) to load libira at runtime. Implements global mutex to ensure thread-safety when multiple threads access the Fortran backend which has shared global state.
WARNING: Due to the non-thread-safe Fortran backend, all IRA operations are serialized through a global mutex. Multiple threads calling IRA simultaneously will execute sequentially, potentially creating a significant performance bottleneck in multi-threaded contexts. Consider process-level parallelism if true concurrent IRA operations are required.
No functionality just bookkeeping.
Uses dlopen (POSIX) or LoadLibrary (Windows) to load liblammps at runtime rather than requiring it at compile time. This allows a single eOn binary to optionally use LAMMPS potentials if the library is installed.
Engines that ship as their own shared objects (the rgpot metatomic and xtb backends) are found by base name across a search path rather than by an absolute path, so a build, a wheel, and a conda prefix can each place them differently.
Uses dlopen (POSIX) or LoadLibrary (Windows) to load Fortran potential libraries at runtime. The search order is:
Call add_config_paths() once at startup (before any potential constructor) to inject config-file paths into the singleton.
| using eonc::EigenmodeStrategy = std::variant<Dimer, ImprovedDimer, Lanczos, Davidson> |
Definition at line 32 of file EigenmodeStrategy.h.
| using eonc::ForceCallback |
Callback type for potential energy/force evaluation.
Flat-array interface that avoids any AtomMatrix type dependency, preventing collisions between eOn's Eigen-based AtomMatrix and rgpot's custom AtomMatrix.
| nAtoms | Number of atoms. |
| positions | Flat array [x1,y1,z1, x2,y2,z2, ...] (nAtoms*3). |
| atomicNrs | Atomic numbers [Z1, Z2, ...] (nAtoms). |
| forces | Output forces [Fx1,Fy1,Fz1, ...] (nAtoms*3). |
| energy | Output energy (single double). |
| box | Simulation cell flat 3x3 row-major (9 doubles). |
Definition at line 36 of file ServeRpcServer.h.
|
strong |
|
strong |
Definition at line 73 of file BaseStructures.h.
|
strong |
| Enumerator | |
|---|---|
| LINEAR | |
| IDPP | |
| IDPP_COLLECTIVE | |
| SIDPP | |
| SIDPP_ZBL | |
| FILE | |
Definition at line 109 of file BaseStructures.h.
|
strong |
|
strong |
| Enumerator | |
|---|---|
| Legacy | |
| MinimumImage | |
|
strong |
Definition at line 36 of file BaseStructures.h.
|
strong |
| Enumerator | |
|---|---|
| GOOD | |
| FAIL_MAX_ITERATIONS | |
| FAIL_POTENTIAL_FAILED | |
Definition at line 111 of file BaseStructures.h.
|
inline |
Access ImprovedDimer-specific features.
Returns nullptr if not ImprovedDimer.
Definition at line 93 of file EigenmodeStrategy.h.
| bool eonc::atomListMeansAll | ( | const std::string & | atomList | ) |
Whether atomList means "every free atom" (empty, "all", case-insensitive).
Definition at line 21 of file MobileAtoms.cpp.
|
inline |
Build the eigenmode solver from parameters.
min_mode_method: dimer (rotation CG) | lanczos | davidson | gprdimer
Definition at line 38 of file EigenmodeStrategy.h.
| void eonc::bundle | ( | int | number, |
| const std::vector< std::string > & | filenames, | ||
| std::vector< std::string > * | bundledFilenames ) |
Definition at line 175 of file Bundling.cpp.
| void eonc::commandLine | ( | int | argc, |
| char ** | argv ) |
Definition at line 93 of file CommandLine.cpp.
|
static |
Definition at line 15 of file MetatomicDynPot.cpp.
| void eonc::deleteUnbundledFiles | ( | const std::vector< std::string > & | unbundledFilenames | ) |
Definition at line 140 of file Bundling.cpp.
| void eonc::disableFPE | ( | ) |
Definition at line 229 of file fpe_handler.cpp.
|
inline |
Dispatch compute() to the active variant.
Definition at line 75 of file EigenmodeStrategy.h.
|
inline |
Dispatch getEigenvalue() to the active variant.
Definition at line 82 of file EigenmodeStrategy.h.
|
inline |
Dispatch getEigenvector() to the active variant.
Definition at line 87 of file EigenmodeStrategy.h.
|
inline |
Definition at line 106 of file EigenmodeStrategy.h.
|
inline |
Definition at line 110 of file EigenmodeStrategy.h.
|
inline |
Definition at line 102 of file EigenmodeStrategy.h.
|
inline |
Read stats from any variant (all inherit LowestEigenmode stats fields).
Definition at line 98 of file EigenmodeStrategy.h.
|
inline |
Definition at line 114 of file EigenmodeStrategy.h.
| void eonc::enableFPE | ( | ) |
Definition at line 193 of file fpe_handler.cpp.
|
inline |
|
static |
Definition at line 94 of file fpe_handler.cpp.
| VectorXi eonc::freeAtomIndices | ( | const Matter * | matter | ) |
Free (unfixed) atom indices in ascending order.
Definition at line 48 of file MobileAtoms.cpp.
|
inline |
Reconstruct AtomMatrix from a flat column-major vector (e.g.
from Fortran). RowMajor(N,3) and ColMajor(3,N) share the same contiguous memory layout, so this is effectively a reinterpretation of the flat data.
Definition at line 61 of file Eigen.h.
|
inline |
|
inline |
| int eonc::getBundleSize | ( | ) |
Definition at line 28 of file Bundling.cpp.
| VectorXd eonc::mobileForces | ( | Matter * | matter, |
| const VectorXi & | mobile ) |
Force components on mobile atoms after Matter has a valid force cache (calls getForces under the hood if needed via the non-const Matter API).
Definition at line 132 of file MobileAtoms.cpp.
| VectorXd eonc::packMobileRows | ( | const AtomMatrix & | full, |
| const VectorXi & | mobile ) |
Pack full (n_atoms,3) rows of mobile atoms into a 3*n_mobile vector.
Definition at line 117 of file MobileAtoms.cpp.
| std::vector< ServeEndpoint > eonc::parseServeSpec | ( | const std::string & | spec | ) |
Parse a serve configuration string into endpoints.
Accepts comma-separated entries of the form "potential:port" or "potential:host:port". Examples: "lj:12345" "metatomic:12345,lj:12346" "metatomic:0.0.0.0:12345"
| spec | The comma-separated endpoint specification. |
Definition at line 229 of file ServeMode.cpp.
| VectorXi eonc::resolveMobileAtoms | ( | const Matter * | matter, |
| const std::string & | atomList ) |
PHVA-class mobile set for FD Hessian and matrix-free Krylov (Lanczos / Davidson).
free/fixed on Matter is the optimizer mask. The mobile set is a (possibly proper) subset of free atoms: those that are displaced in finite-difference Hessian-vector products (Li & Jensen, Theor. Chem. Acc. 107, 211 (2002)).
atomList empty or "all" -> all free atoms (backward-compatible default). Otherwise comma/space-separated 0-based indices, intersected with free flags; order follows the list (duplicates dropped). Out-of-range and fixed indices are skipped.
Definition at line 64 of file MobileAtoms.cpp.
| VectorXi eonc::resolveMobileAtoms | ( | const Matter * | matter, |
| const VectorXi & | candidates ) |
Explicit candidate indices, intersected with free flags (order preserved, duplicates dropped).
Used by pyeonclient compute(..., atoms=...).
Definition at line 98 of file MobileAtoms.cpp.
|
inlinenodiscard |
Run Lanczos, Davidson, or LOR.
Classical returns nullopt (stock rotation loop).
Definition at line 70 of file DimerRotationDispatch.h.
| void eonc::serveFromConfig | ( | const Parameters & | params | ) |
Start serve mode from config-file parameters.
Reads serve_options from params and dispatches to the appropriate mode:
| params | The eOn parameters with serve_options populated. |
Definition at line 200 of file ServeMode.cpp.
| void eonc::serveGateway | ( | const Parameters & | params, |
| const std::string & | host, | ||
| uint16_t | port, | ||
| size_t | pool_size ) |
Start a gateway server backed by a pool of potential instances.
Creates pool_size instances of the configured potential and serves them behind a single gateway port. Incoming requests are dispatched round-robin across the pool. This gives clients a single endpoint while spreading load.
| params | The eOn parameters (potential_options.potential must be set). |
| host | The hostname to listen on. |
| port | The gateway port. |
| pool_size | Number of potential instances in the pool. |
Definition at line 167 of file ServeMode.cpp.
| void eonc::serveMode | ( | const Parameters & | params, |
| const std::string & | host, | ||
| uint16_t | port ) |
Start a single rgpot-compatible Cap'n Proto RPC server.
Wraps eOn's Potential::force() as an rgpot PotentialBase and serves it over Cap'n Proto RPC. Blocks until the server is killed.
| params | The eOn parameters (potential_options.potential must be set). |
| host | The hostname to listen on (e.g., "localhost" or "*"). |
| port | The TCP port to listen on. |
Definition at line 56 of file ServeMode.cpp.
| void eonc::serveMultiple | ( | const std::vector< ServeEndpoint > & | endpoints, |
| const Parameters & | params ) |
Serve multiple potentials concurrently on different ports.
Each endpoint gets its own thread, its own potential instance, and its own Cap'n Proto event loop. All threads block until SIGINT/SIGTERM.
| endpoints | List of {potential, host, port} configurations. |
| params | Base eOn parameters (potential type is overridden per endpoint). |
Definition at line 79 of file ServeMode.cpp.
| void eonc::serveReplicated | ( | const Parameters & | params, |
| const std::string & | host, | ||
| uint16_t | base_port, | ||
| size_t | replicas ) |
Serve N replicas of the same potential across sequential ports.
Starts replicas threads, each serving the same potential type on ports base_port, base_port+1, ..., base_port+replicas-1.
| params | The eOn parameters (potential_options.potential must be set). |
| host | The hostname to listen on. |
| base_port | The first port; replicas use base_port+0 .. base_port+N-1. |
| replicas | Number of concurrent server instances. |
Definition at line 133 of file ServeMode.cpp.
| void eonc::startPooledRpcServer | ( | std::vector< ForceCallback > | pool, |
| const std::string & | host, | ||
| uint16_t | port ) |
Start a blocking Cap'n Proto RPC server backed by a pool of force callbacks dispatched round-robin.
| pool | Vector of force callbacks (one per pool instance). |
| host | The hostname to listen on. |
| port | The TCP port to listen on. |
Definition at line 185 of file ServeRpcServer.cpp.
| void eonc::startRpcServer | ( | ForceCallback | callback, |
| const std::string & | host, | ||
| uint16_t | port ) |
Start a blocking Cap'n Proto RPC server using a force callback.
Defined in a separate translation unit to avoid naming collision between eOn's class Potential and the capnp-generated Potential interface.
| callback | Force evaluation function. |
| host | The hostname to listen on. |
| port | The TCP port to listen on. |
Definition at line 103 of file ServeRpcServer.cpp.
| int eonc::strchrcount | ( | const char * | haystack, |
| char | needle ) |
Definition at line 70 of file Bundling.cpp.
| std::vector< std::string > eonc::unbundle | ( | int | number | ) |
Definition at line 80 of file Bundling.cpp.
| void eonc::unpackMobileRows | ( | const VectorXd & | packed, |
| const VectorXi & | mobile, | ||
| AtomMatrix & | full ) |
Write a 3*n_mobile vector into full AtomMatrix rows (other rows unchanged).
Definition at line 125 of file MobileAtoms.cpp.
|
inlinenodiscardconstexprnoexcept |
Definition at line 41 of file DimerRotationDispatch.h.
|
constexpr |
Definition at line 18 of file RandomNumbers.h.
|
constexpr |
Definition at line 21 of file RandomNumbers.h.
|
constexpr |
Definition at line 26 of file RandomNumbers.h.
|
constexpr |
Definition at line 27 of file RandomNumbers.h.
|
constexpr |
Definition at line 17 of file RandomNumbers.h.
|
constexpr |
Definition at line 23 of file RandomNumbers.h.
|
constexpr |
Definition at line 24 of file RandomNumbers.h.
|
constexpr |
Definition at line 25 of file RandomNumbers.h.
|
constexpr |
Definition at line 28 of file RandomNumbers.h.
|
constexpr |
Definition at line 29 of file RandomNumbers.h.
|
constexpr |
Definition at line 30 of file RandomNumbers.h.
|
constexpr |
Definition at line 31 of file RandomNumbers.h.
|
staticconstexpr |
Definition at line 90 of file fpe_handler.cpp.
|
staticconstexpr |
Definition at line 92 of file fpe_handler.cpp.
|
staticconstexpr |
Definition at line 91 of file fpe_handler.cpp.
Definition at line 20 of file RandomNumbers.h.
|
constexpr |
Definition at line 19 of file RandomNumbers.h.
|
constexpr |
Definition at line 22 of file RandomNumbers.h.