34 template <
typename T,
size_t D>
37 static_assert(D > 0,
"matrix dimensions must be positive");
44 typedef std::vector<T>
type;
47 template <
typename T,
size_t D>
63 template <
typename T,
size_t D>
80 auto shape = ndarray->getShape();
84 vec = AronVectorConverter::ConvertTo1DVector<T>(ndarray);
85 shape = {shape.empty() ? 0
86 : std::accumulate(std::begin(shape),
87 std::prev(std::end(shape)),
89 std::multiplies<int>())};
90 shape.push_back(
sizeof(
T));
92 data.insert(
data.end(), vec.begin(), vec.end());
102 data.push_back(
T(
a->getValue()));
111 data.push_back(
T(
a->getValue()));
120 data.push_back(
T(
a->getValue()));
129 data.push_back(
T(
a->getValue()));
138 data.push_back(
T(
a->getValue()));
155 auto shape = ndarray->getShape();
159 vec = AronVectorConverter::ConvertTo2DVector<T>(ndarray);
162 data.insert(
data.end(), vec.begin(), vec.end());