mptensor v0.6.0
Parallel Library for Tensor Network Methods
Loading...
Searching...
No Matches
mptensor::internal Namespace Reference

Library-internal helpers and types. More...

Classes

struct  is_unscoped_enum
 
struct  is_unscoped_enum< I, true >
 
struct  normalized_t
 

Typedefs

using UIndex = BasicIndex< std::size_t >
 
using UAxes = UIndex
 
using UShape = UIndex
 

Functions

template<typename T , typename I >
T checked_index_cast (I value)
 
size_t normalize_value (std::ptrdiff_t v, size_t n, bool end_inclusive, const char *kind, std::ptrdiff_t position, const char *position_name="position")
 
UAxes identity_axes (size_t n)
 
std::pair< size_t, size_t > normalize_slice_range (std::ptrdiff_t begin, std::ptrdiff_t end, size_t n, size_t axis)
 
void normalize_slice_ranges (const Index &begin, const Index &end, const UShape &shape, UIndex &ubegin, UIndex &uend)
 
template<typename MatrixType >
Tensor< MatrixType > transpose_impl (const Tensor< MatrixType > &a, const UAxes &axes, size_t urank_new)
 
template<typename MatrixType >
Tensor< MatrixType > reshape_impl (const Tensor< MatrixType > &a, const UShape &shape_new)
 

Variables

template<typename I >
constexpr bool is_index_value_v
 
constexpr normalized_t normalized {}
 

Detailed Description

Library-internal helpers and types.

Warning
Not part of the public API. These names may change or be removed without notice, and user code should not use them.