Loading...
Searching...
No Matches
RgpotEngineCallbacks Struct Reference

Host callbacks for learning engines. More...

#include <engine_c_abi.h>

Public Attributes

void * ctx
int(* oracle )(void *ctx, long nAtoms, const double *positions, const int *atomicNrs, double *forces, double *energy, const double *box)
void(* on_acquire )(void *ctx, rgpot_engine_acquire_reason reason)
void(* on_model_update )(void *ctx, unsigned long long model_state)

Detailed Description

Host callbacks for learning engines.

oracle evaluates the ground truth (same conventions and three-valued return as rgpot_engine_force; variance is absent because the oracle is exact). on_acquire fires when the engine delegates a point; on_model_update fires after each incorporation with the new model-state value and marks the boundary at which history-based host state (quasi-Newton memory, cached factorizations) must be reset. Either notification pointer may be NULL.

Definition at line 183 of file engine_c_abi.h.

Member Data Documentation

◆ ctx

void* RgpotEngineCallbacks::ctx

Definition at line 184 of file engine_c_abi.h.

◆ on_acquire

void(* RgpotEngineCallbacks::on_acquire) (void *ctx, rgpot_engine_acquire_reason reason)

Definition at line 188 of file engine_c_abi.h.

◆ on_model_update

void(* RgpotEngineCallbacks::on_model_update) (void *ctx, unsigned long long model_state)

Definition at line 189 of file engine_c_abi.h.

◆ oracle

int(* RgpotEngineCallbacks::oracle) (void *ctx, long nAtoms, const double *positions, const int *atomicNrs, double *forces, double *energy, const double *box)

Definition at line 185 of file engine_c_abi.h.


The documentation for this struct was generated from the following file:
  • /home/runner/work/eOn/eOn/include/eon/potentials/Rgpot/engine_c_abi.h