16 #ifndef OPENKALMAN_EIGEN_TRAITS_TENSORREDUCTIONOP_HPP 17 #define OPENKALMAN_EIGEN_TRAITS_TENSORREDUCTIONOP_HPP 22 template<
typename Op,
typename Dims,
typename XprType,
template<
typename>
typename MakePointer>
26 template<
typename Arg,
typename N>
27 static constexpr
auto get_index_descriptor(
const Arg& arg, N n)
29 if constexpr (values::fixed<N>)
32 return static_cast<std::size_t
>(arg.dimension[n]);
35 template<std::
size_t i,
typename Arg>
36 static decltype(
auto) get_nested_object(Arg&& arg)
39 return std::forward<Arg>(arg).expression();
41 return std::forward<Arg>(arg).reducer();
42 static_assert(i <= 1);
46 template<
typename Arg>
54 static constexpr
bool is_writable =
false;
64 #endif //OPENKALMAN_EIGEN_TRAITS_TENSORREDUCTIONOP_HPP Definition: indexible_object_traits.hpp:36
Definition: basics.hpp:41
static constexpr auto get_constant(const Arg &arg)
Definition: TensorReductionOp.hpp:47
Definition: eigen-comma-initializers.hpp:20
Trait object providing get and set routines for Eigen tensors.
Definition: eigen-tensor-forward-declarations.hpp:114
constexpr bool value
T is numerical value or is reducible to a numerical value.
Definition: value.hpp:31
The constant associated with T, assuming T is a constant_matrix.
Definition: constant_coefficient.hpp:36