27#include "neml2/models/Model.h"
46 std::vector<const Variable<T> *>
_from;
The wrapper (decorator) for cross-referencing unresolved values at parse time.
Definition CrossRef.h:56
Definition LinearCombination.h:33
LinearCombination(const OptionSet &options)
Definition LinearCombination.cxx:66
Variable< T > & _to
Sum of all the input variables.
Definition LinearCombination.h:43
std::vector< const Variable< T > * > _from
The input variables (to be summed)
Definition LinearCombination.h:46
const bool _coef_as_param
Whether to declare coefficients as parameters.
Definition LinearCombination.h:49
static OptionSet expected_options()
Definition LinearCombination.cxx:37
const Tensor & _coef
Scaling coefficient for each term.
Definition LinearCombination.h:52
void set_value(bool out, bool dout_din, bool d2out_din2) override
The map between input -> output, and optionally its derivatives.
Definition LinearCombination.cxx:88
The base class for all constitutive models.
Definition Model.h:55
const torch::TensorOptions & options() const
Storage tensor options.
Definition Model.h:111
A custom map-like data structure. The keys are strings, and the values can be nonhomogeneously typed.
Definition OptionSet.h:100
Definition CrossRef.cxx:30
LinearCombination< SR2 > SR2LinearCombination
Definition LinearCombination.h:60
LinearCombination< Vec > VecLinearCombination
Definition LinearCombination.h:59
LinearCombination< Scalar > ScalarLinearCombination
Definition LinearCombination.h:58