xtensor_adaptor

template <class EC, std::size_t N>
class xt::xtensor_adaptor

Dense multidimensional container adaptor with tensor semantic and fixed dimension.

The xtensor_adaptor class implements a dense multidimensional container adaptor with tensor semantic and fixed dimension. It is used to provide a multidimensional container semantic and a tensor semantic to stl-like containers.

Template Parameters
  • EC: The container type to adapt.
  • N: The dimension of the adaptor.

Inherits from xt::xstrided_container< xtensor_adaptor< EC, N > >, xt::xadaptor_semantic< xtensor_adaptor< EC, N > >

Constructors

xtensor_adaptor(container_type &data)

Constructs an xtensor_adaptor of the given stl-like container.

Parameters
  • data: the container to adapt

xtensor_adaptor(container_type &data, const shape_type &shape, layout l = layout::row_major)

Constructs an xtensor_adaptor of the given stl-like container, with the specified shape and layout.

Parameters

xtensor_adaptor(container_type &data, const shape_type &shape, const strides_type &strides)

Constructs an xtensor_adaptor of the given stl-like container, with the specified shape and strides.

Parameters

Extended copy semantic

template <class E>
auto operator=(const xexpression<E> &e)

The extended assignment operator.