cppyabm  1.0.17
An agent-based library to integrate C++ and Python
Public Types | Static Public Member Functions | Static Public Attributes | List of all members
EigenProps< Type_ > Struct Template Reference

#include <eigen.h>

Public Types

using Type = Type_
 
using Scalar = typename Type::Scalar
 
using StrideType = typename eigen_extract_stride< Type >::type
 
template<EigenIndex i, EigenIndex ifzero>
using if_zero = std::integral_constant< EigenIndex, i==0 ? ifzero :i >
 

Static Public Member Functions

static EigenConformable< row_majorconformable (const array &a)
 

Static Public Attributes

static constexpr EigenIndex rows = Type::RowsAtCompileTime
 
static constexpr EigenIndex cols = Type::ColsAtCompileTime
 
static constexpr EigenIndex size = Type::SizeAtCompileTime
 
static constexpr bool row_major = Type::IsRowMajor
 
static constexpr bool vector = Type::IsVectorAtCompileTime
 
static constexpr bool fixed_rows = rows != Eigen::Dynamic
 
static constexpr bool fixed_cols = cols != Eigen::Dynamic
 
static constexpr bool fixed = size != Eigen::Dynamic
 
static constexpr bool dynamic = !fixed_rows && !fixed_cols
 
static constexpr EigenIndex inner_stride = if_zero<StrideType::InnerStrideAtCompileTime, 1>::value
 
static constexpr EigenIndex outer_stride
 
static constexpr bool dynamic_stride = inner_stride == Eigen::Dynamic && outer_stride == Eigen::Dynamic
 
static constexpr bool requires_row_major = !dynamic_stride && !vector && (row_major ? inner_stride : outer_stride) == 1
 
static constexpr bool requires_col_major = !dynamic_stride && !vector && (row_major ? outer_stride : inner_stride) == 1
 
static constexpr bool show_writeable = is_eigen_dense_map<Type>::value && is_eigen_mutable_map<Type>::value
 
static constexpr bool show_order = is_eigen_dense_map<Type>::value
 
static constexpr bool show_c_contiguous = show_order && requires_row_major
 
static constexpr bool show_f_contiguous = !show_c_contiguous && show_order && requires_col_major
 
static constexpr auto descriptor
 

Detailed Description

template<typename Type_>
struct EigenProps< Type_ >

Definition at line 117 of file eigen.h.

Member Typedef Documentation

◆ if_zero

template<typename Type_ >
template<EigenIndex i, EigenIndex ifzero>
using EigenProps< Type_ >::if_zero = std::integral_constant<EigenIndex, i == 0 ? ifzero : i>

Definition at line 133 of file eigen.h.

◆ Scalar

template<typename Type_ >
using EigenProps< Type_ >::Scalar = typename Type::Scalar

Definition at line 119 of file eigen.h.

◆ StrideType

template<typename Type_ >
using EigenProps< Type_ >::StrideType = typename eigen_extract_stride<Type>::type

Definition at line 120 of file eigen.h.

◆ Type

template<typename Type_ >
using EigenProps< Type_ >::Type = Type_

Definition at line 118 of file eigen.h.

Member Function Documentation

◆ conformable()

template<typename Type_ >
static EigenConformable<row_major> EigenProps< Type_ >::conformable ( const array a)
inlinestatic

Definition at line 144 of file eigen.h.

Member Data Documentation

◆ cols

template<typename Type_ >
constexpr EigenIndex EigenProps< Type_ >::cols = Type::ColsAtCompileTime
static

Definition at line 123 of file eigen.h.

◆ descriptor

template<typename Type_ >
constexpr auto EigenProps< Type_ >::descriptor
staticconstexpr
Initial value:
=
_("numpy.ndarray[") + npy_format_descriptor<Scalar>::name +
_("[") + _<fixed_rows>(_<(size_t) rows>(), _("m")) +
_(", ") + _<fixed_cols>(_<(size_t) cols>(), _("n")) +
_("]") +
_<show_writeable>(", flags.writeable", "") +
_<show_c_contiguous>(", flags.c_contiguous", "") +
_<show_f_contiguous>(", flags.f_contiguous", "") +
_("]")

Definition at line 194 of file eigen.h.

◆ dynamic

template<typename Type_ >
constexpr bool EigenProps< Type_ >::dynamic = !fixed_rows && !fixed_cols
static

Definition at line 131 of file eigen.h.

◆ dynamic_stride

template<typename Type_ >
constexpr bool EigenProps< Type_ >::dynamic_stride = inner_stride == Eigen::Dynamic && outer_stride == Eigen::Dynamic
staticconstexpr

Definition at line 137 of file eigen.h.

◆ fixed

template<typename Type_ >
constexpr bool EigenProps< Type_ >::fixed = size != Eigen::Dynamic
static

Definition at line 130 of file eigen.h.

◆ fixed_cols

template<typename Type_ >
constexpr bool EigenProps< Type_ >::fixed_cols = cols != Eigen::Dynamic
static

Definition at line 129 of file eigen.h.

◆ fixed_rows

template<typename Type_ >
constexpr bool EigenProps< Type_ >::fixed_rows = rows != Eigen::Dynamic
static

Definition at line 128 of file eigen.h.

◆ inner_stride

template<typename Type_ >
constexpr EigenIndex EigenProps< Type_ >::inner_stride = if_zero<StrideType::InnerStrideAtCompileTime, 1>::value
staticconstexpr

Definition at line 134 of file eigen.h.

◆ outer_stride

template<typename Type_ >
constexpr EigenIndex EigenProps< Type_ >::outer_stride
static
Initial value:
= if_zero<StrideType::OuterStrideAtCompileTime,

Definition at line 135 of file eigen.h.

◆ requires_col_major

template<typename Type_ >
constexpr bool EigenProps< Type_ >::requires_col_major = !dynamic_stride && !vector && (row_major ? outer_stride : inner_stride) == 1
staticconstexpr

Definition at line 139 of file eigen.h.

◆ requires_row_major

template<typename Type_ >
constexpr bool EigenProps< Type_ >::requires_row_major = !dynamic_stride && !vector && (row_major ? inner_stride : outer_stride) == 1
staticconstexpr

Definition at line 138 of file eigen.h.

◆ row_major

template<typename Type_ >
constexpr bool EigenProps< Type_ >::row_major = Type::IsRowMajor
staticconstexpr

Definition at line 126 of file eigen.h.

◆ rows

template<typename Type_ >
constexpr EigenIndex EigenProps< Type_ >::rows = Type::RowsAtCompileTime
staticconstexpr

Definition at line 122 of file eigen.h.

◆ show_c_contiguous

template<typename Type_ >
constexpr bool EigenProps< Type_ >::show_c_contiguous = show_order && requires_row_major
staticconstexpr

Definition at line 191 of file eigen.h.

◆ show_f_contiguous

template<typename Type_ >
constexpr bool EigenProps< Type_ >::show_f_contiguous = !show_c_contiguous && show_order && requires_col_major
staticconstexpr

Definition at line 192 of file eigen.h.

◆ show_order

template<typename Type_ >
constexpr bool EigenProps< Type_ >::show_order = is_eigen_dense_map<Type>::value
staticconstexpr

Definition at line 190 of file eigen.h.

◆ show_writeable

template<typename Type_ >
constexpr bool EigenProps< Type_ >::show_writeable = is_eigen_dense_map<Type>::value && is_eigen_mutable_map<Type>::value
staticconstexpr

Definition at line 189 of file eigen.h.

◆ size

template<typename Type_ >
constexpr EigenIndex EigenProps< Type_ >::size = Type::SizeAtCompileTime
static

Definition at line 124 of file eigen.h.

◆ vector

template<typename Type_ >
constexpr bool EigenProps< Type_ >::vector = Type::IsVectorAtCompileTime
static

Definition at line 127 of file eigen.h.


The documentation for this struct was generated from the following file:
npy_format_descriptor
Definition: numpy.h:1159
EigenProps::rows
static constexpr EigenIndex rows
Definition: eigen.h:122
EigenProps::size
static constexpr EigenIndex size
Definition: eigen.h:124
EigenProps::if_zero
std::integral_constant< EigenIndex, i==0 ? ifzero :i > if_zero
Definition: eigen.h:133
_
constexpr descr< N - 1 > _(char const(&text)[N])
Definition: descr.h:54
EigenProps::row_major
static constexpr bool row_major
Definition: eigen.h:126
EigenProps::vector
static constexpr bool vector
Definition: eigen.h:127
EigenProps::cols
static constexpr EigenIndex cols
Definition: eigen.h:123
test_callbacks.value
value
Definition: test_callbacks.py:126