# xchunked_array

group Xt_xchunked_array

  Chunked array container.

  Defined in `xtensor/xchunked_array.hpp`.

  Functions

  template<class T, layout_type L = ::xt::layout_type::row_major, class S>
  inline xchunked_array<xarray<xarray<T>>> chunked_array(S &&shape, S &&chunk_shape, layout_type chunk_memory_layout = ::xt::layout_type::row_major)

    Creates an in-memory chunked array.

    This function returns an uninitialized `xt::xchunked_array<xt::xarray<T>>`.

    Template Parameters:

      - T – The type of the elements (e.g. double)

      - L – The layout_type of the array

    Parameters:

      - shape – The shape of the array

      - chunk_shape – The shape of a chunk

      - chunk_memory_layout – The layout of each chunk (default: XTENSOR_DEFAULT_LAYOUT)

    Returns:

      returns a `xt::xchunked_array<xt::xarray<T>>` with the given shape, chunk shape and memory layout.

  template<layout_type L = ::xt::layout_type::row_major, class E, class S>
  inline xchunked_array<xarray<xarray<typename E::value_type>>> chunked_array(const xexpression<E> &e, S &&chunk_shape, layout_type chunk_memory_layout = ::xt::layout_type::row_major)

    Creates an in-memory chunked array.

    This function returns a `xt::xchunked_array<xt::xarray<T>>` initialized from an expression.

    Template Parameters:

      L – The layout_type of the array

    Parameters:

      - e – The expression to initialize the chunked array from

      - chunk_shape – The shape of a chunk

      - chunk_memory_layout – The layout of each chunk (default: XTENSOR_DEFAULT_LAYOUT)

    Returns:

      returns a `xt::xchunked_array<xt::xarray<T>>` from the given expression, with the given chunk shape and memory layout.

  template<layout_type L = ::xt::layout_type::row_major, class E>
  inline xchunked_array<xarray<xarray<typename E::value_type>>> chunked_array(const xexpression<E> &e, layout_type chunk_memory_layout = ::xt::layout_type::row_major)

    Creates an in-memory chunked array.

    This function returns a `xt::xchunked_array<xt::xarray<T>>` initialized from an expression.

    Template Parameters:

      L – The layout_type of the array

    Parameters:

      - e – The expression to initialize the chunked array from

      - chunk_memory_layout – The layout of each chunk (default: XTENSOR_DEFAULT_LAYOUT)

    Returns:

      returns a `xt::xchunked_array<xt::xarray<T>>` from the given expression, with the expression’s chunk shape and the given memory layout.