tile.h File Reference
#include <TiledArray/tensor/tensor_interface.h>
#include <TiledArray/tile_interface/cast.h>
#include <TiledArray/tile_interface/trace.h>
#include <memory>
Include dependency graph for tile.h:
This graph shows which files directly or indirectly include this file:
Classes | |
class | TiledArray::Tile< T > |
An N-dimensional shallow copy wrapper for tile objects. More... | |
struct | TiledArray::detail::TraceIsDefined< Tile< Arg >, enable_if_trace_is_defined_t< Arg > > |
Signals that we can take the trace of a Tile<Arg> if can trace Arg . More... | |
struct | TiledArray::Cast< TiledArray::Tensor< typename T::value_type, Allocator >, Tile< T >, std::void_t< decltype(std::declval< TiledArray::Cast< TiledArray::Tensor< typename T::value_type, Allocator >, T >>()(std::declval< const T & >()))> > |
Namespaces | |
madness | |
madness::archive | |
TiledArray | |
TiledArray::detail | |
Functions | |
template<typename T > | |
Tile< T > | TiledArray::detail::make_tile (T &&t) |
Factory function for tiles. More... | |
template<typename Arg > | |
Tile< Arg > | TiledArray::clone (const Tile< Arg > &arg) |
Create a copy of arg . More... | |
template<typename Arg > | |
bool | TiledArray::empty (const Tile< Arg > &arg) |
Check that arg is empty (no data) More... | |
template<typename Arg , typename Perm , typename = std::enable_if_t<detail::is_permutation_v<Perm>>> | |
decltype(auto) | TiledArray::permute (const Tile< Arg > &arg, const Perm &perm) |
Create a permuted copy of arg . More... | |
template<typename Arg , typename Index , typename = std::enable_if_t<detail::is_integral_range_v<Index>>> | |
decltype(auto) | TiledArray::shift (const Tile< Arg > &arg, const Index &range_shift) |
Shift the range of arg . More... | |
template<typename Arg , typename Index , typename = std::enable_if_t<std::is_integral_v<Index>>> | |
decltype(auto) | TiledArray::shift (const Tile< Arg > &arg, const std::initializer_list< Index > &range_shift) |
Shift the range of arg . More... | |
template<typename Arg , typename Index , typename = std::enable_if_t<detail::is_integral_range_v<Index>>> | |
Tile< Arg > & | TiledArray::shift_to (Tile< Arg > &arg, const Index &range_shift) |
Shift the range of arg in place. More... | |
template<typename Arg , typename Index , typename = std::enable_if_t<std::is_integral_v<Index>>> | |
Tile< Arg > & | TiledArray::shift_to (Tile< Arg > &arg, const std::initializer_list< Index > &range_shift) |
Shift the range of arg in place. More... | |
template<typename Left , typename Right > | |
decltype(auto) | TiledArray::add (const Tile< Left > &left, const Tile< Right > &right) |
Add tile arguments. More... | |
template<typename Left , typename Right , typename Scalar , typename std::enable_if< detail::is_numeric_v< Scalar >>::type * = nullptr> | |
decltype(auto) | TiledArray::add (const Tile< Left > &left, const Tile< Right > &right, const Scalar factor) |
Add and scale tile arguments. More... | |
template<typename Left , typename Right , typename Perm , typename = std::enable_if_t<detail::is_permutation_v<Perm>>> | |
decltype(auto) | TiledArray::add (const Tile< Left > &left, const Tile< Right > &right, const Perm &perm) |
Add and permute tile arguments. More... | |
template<typename Left , typename Right , typename Scalar , typename Perm , typename std::enable_if< detail::is_numeric_v< Scalar > &&detail::is_permutation_v< Perm >>::type * = nullptr> | |
decltype(auto) | TiledArray::add (const Tile< Left > &left, const Tile< Right > &right, const Scalar factor, const Perm &perm) |
Add, scale, and permute tile arguments. More... | |
template<typename Arg , typename Scalar , typename std::enable_if< detail::is_numeric_v< Scalar >>::type * = nullptr> | |
decltype(auto) | TiledArray::add (const Tile< Arg > &arg, const Scalar value) |
Add a constant scalar to tile argument. More... | |
template<typename Arg , typename Scalar , typename Perm , typename std::enable_if< detail::is_numeric_v< Scalar > &&detail::is_permutation_v< Perm >>::type * = nullptr> | |
decltype(auto) | TiledArray::add (const Tile< Arg > &arg, const Scalar value, const Perm &perm) |
Add a constant scalar and permute tile argument. More... | |
template<typename Result , typename Arg > | |
Tile< Result > & | TiledArray::add_to (Tile< Result > &result, const Tile< Arg > &arg) |
Add to the result tile. More... | |
template<typename Result , typename Arg , typename Scalar , typename std::enable_if< detail::is_numeric_v< Scalar >>::type * = nullptr> | |
Tile< Result > & | TiledArray::add_to (Tile< Result > &result, const Tile< Arg > &arg, const Scalar factor) |
Add and scale to the result tile. More... | |
template<typename Result , typename Scalar , typename std::enable_if< detail::is_numeric_v< Scalar >>::type * = nullptr> | |
Tile< Result > & | TiledArray::add_to (Tile< Result > &result, const Scalar value) |
Add constant scalar to the result tile. More... | |
template<typename Left , typename Right > | |
decltype(auto) | TiledArray::subt (const Tile< Left > &left, const Tile< Right > &right) |
Subtract tile arguments. More... | |
template<typename Left , typename Right , typename Scalar , typename std::enable_if< detail::is_numeric_v< Scalar >>::type * = nullptr> | |
decltype(auto) | TiledArray::subt (const Tile< Left > &left, const Tile< Right > &right, const Scalar factor) |
Subtract and scale tile arguments. More... | |
template<typename Left , typename Right , typename Perm , typename = std::enable_if_t<detail::is_permutation_v<Perm>>> | |
decltype(auto) | TiledArray::subt (const Tile< Left > &left, const Tile< Right > &right, const Perm &perm) |
Subtract and permute tile arguments. More... | |
template<typename Left , typename Right , typename Scalar , typename Perm , typename std::enable_if< detail::is_numeric_v< Scalar > &&detail::is_permutation_v< Perm >>::type * = nullptr> | |
decltype(auto) | TiledArray::subt (const Tile< Left > &left, const Tile< Right > &right, const Scalar factor, const Perm &perm) |
Subtract, scale, and permute tile arguments. More... | |
template<typename Arg , typename Scalar , typename std::enable_if< detail::is_numeric_v< Scalar >>::type * = nullptr> | |
decltype(auto) | TiledArray::subt (const Tile< Arg > &arg, const Scalar value) |
Subtract a scalar constant from the tile argument. More... | |
template<typename Arg , typename Scalar , typename Perm , typename std::enable_if< detail::is_numeric_v< Scalar > &&detail::is_permutation_v< Perm >>::type * = nullptr> | |
decltype(auto) | TiledArray::subt (const Tile< Arg > &arg, const Scalar value, const Perm &perm) |
Subtract a constant scalar and permute tile argument. More... | |
template<typename Result , typename Arg > | |
Tile< Result > & | TiledArray::subt_to (Tile< Result > &result, const Tile< Arg > &arg) |
Subtract from the result tile. More... | |
template<typename Result , typename Arg , typename Scalar , typename std::enable_if< detail::is_numeric_v< Scalar >>::type * = nullptr> | |
Tile< Result > & | TiledArray::subt_to (Tile< Result > &result, const Tile< Arg > &arg, const Scalar factor) |
Subtract and scale from the result tile. More... | |
template<typename Result , typename Scalar , typename std::enable_if< detail::is_numeric_v< Scalar >>::type * = nullptr> | |
Tile< Result > & | TiledArray::subt_to (Tile< Result > &result, const Scalar value) |
Subtract constant scalar from the result tile. More... | |
template<typename Left , typename Right > | |
decltype(auto) | TiledArray::mult (const Tile< Left > &left, const Tile< Right > &right) |
Multiplication tile arguments. More... | |
template<typename Left , typename Right , typename Scalar , typename std::enable_if< detail::is_numeric_v< Scalar >>::type * = nullptr> | |
decltype(auto) | TiledArray::mult (const Tile< Left > &left, const Tile< Right > &right, const Scalar factor) |
Multiplication and scale tile arguments. More... | |
template<typename Left , typename Right , typename Perm , typename = std::enable_if_t<detail::is_permutation_v<Perm>>> | |
decltype(auto) | TiledArray::mult (const Tile< Left > &left, const Tile< Right > &right, const Perm &perm) |
Multiplication and permute tile arguments. More... | |
template<typename Left , typename Right , typename Scalar , typename Perm , typename std::enable_if< detail::is_numeric_v< Scalar > &&detail::is_permutation_v< Perm >>::type * = nullptr> | |
decltype(auto) | TiledArray::mult (const Tile< Left > &left, const Tile< Right > &right, const Scalar factor, const Perm &perm) |
Multiplication, scale, and permute tile arguments. More... | |
template<typename Result , typename Arg > | |
Tile< Result > & | TiledArray::mult_to (Tile< Result > &result, const Tile< Arg > &arg) |
Multiply to the result tile. More... | |
template<typename Result , typename Arg , typename Scalar , typename std::enable_if< detail::is_numeric_v< Scalar >>::type * = nullptr> | |
Tile< Result > & | TiledArray::mult_to (Tile< Result > &result, const Tile< Arg > &arg, const Scalar factor) |
Multiply and scale to the result tile. More... | |
template<typename Left , typename Right , typename Op > | |
decltype(auto) | TiledArray::binary (const Tile< Left > &left, const Tile< Right > &right, Op &&op) |
Binary element-wise transform producing a new tile. More... | |
template<typename Left , typename Right , typename Op , typename Perm , typename = std::enable_if_t<detail::is_permutation_v<Perm>>> | |
decltype(auto) | TiledArray::binary (const Tile< Left > &left, const Tile< Right > &right, Op &&op, const Perm &perm) |
Binary element-wise transform producing a new tile. More... | |
template<typename Left , typename Right , typename Op > | |
Tile< Left > & | TiledArray::inplace_binary (Tile< Left > &left, const Tile< Right > &right, Op &&op) |
Binary element-wise in-place transform. More... | |
template<typename Arg , typename Scalar , typename std::enable_if< detail::is_numeric_v< Scalar >>::type * = nullptr> | |
decltype(auto) | TiledArray::scale (const Tile< Arg > &arg, const Scalar factor) |
Scalar the tile argument. More... | |
template<typename Arg , typename Scalar , typename Perm , typename std::enable_if< detail::is_numeric_v< Scalar > &&detail::is_permutation_v< Perm >>::type * = nullptr> | |
decltype(auto) | TiledArray::scale (const Tile< Arg > &arg, const Scalar factor, const Perm &perm) |
Scale and permute tile argument. More... | |
template<typename Result , typename Scalar , typename std::enable_if< detail::is_numeric_v< Scalar >>::type * = nullptr> | |
Tile< Result > & | TiledArray::scale_to (Tile< Result > &result, const Scalar factor) |
Scale to the result tile. More... | |
template<typename Arg > | |
decltype(auto) | TiledArray::neg (const Tile< Arg > &arg) |
Negate the tile argument. More... | |
template<typename Arg , typename Perm , typename = std::enable_if_t<detail::is_permutation_v<Perm>>> | |
decltype(auto) | TiledArray::neg (const Tile< Arg > &arg, const Perm &perm) |
Negate and permute tile argument. More... | |
template<typename Result > | |
Tile< Result > & | TiledArray::neg_to (Tile< Result > &result) |
In-place negate tile. More... | |
template<typename Arg > | |
decltype(auto) | TiledArray::conj (const Tile< Arg > &arg) |
Create a complex conjugated copy of a tile. More... | |
template<typename Arg , typename Scalar , typename std::enable_if< TiledArray::detail::is_numeric_v< Scalar >>::type * = nullptr> | |
decltype(auto) | TiledArray::conj (const Tile< Arg > &arg, const Scalar factor) |
Create a complex conjugated and scaled copy of a tile. More... | |
template<typename Arg , typename Perm , typename = std::enable_if_t<detail::is_permutation_v<Perm>>> | |
decltype(auto) | TiledArray::conj (const Tile< Arg > &arg, const Perm &perm) |
Create a complex conjugated and permuted copy of a tile. More... | |
template<typename Arg , typename Scalar , typename Perm , typename std::enable_if< TiledArray::detail::is_numeric_v< Scalar > &&detail::is_permutation_v< Perm >>::type * = nullptr> | |
decltype(auto) | TiledArray::conj (const Tile< Arg > &arg, const Scalar factor, const Perm &perm) |
Create a complex conjugated, scaled, and permuted copy of a tile. More... | |
template<typename Result > | |
Tile< Result > & | TiledArray::conj_to (Tile< Result > &result) |
In-place complex conjugate a tile. More... | |
template<typename Result , typename Scalar , typename std::enable_if< TiledArray::detail::is_numeric_v< Scalar >>::type * = nullptr> | |
Tile< Result > & | TiledArray::conj_to (Tile< Result > &result, const Scalar factor) |
In-place complex conjugate and scale a tile. More... | |
template<typename Arg , typename Op > | |
decltype(auto) | TiledArray::unary (const Tile< Arg > &arg, Op &&op) |
Unary element-wise transform producing a new tile. More... | |
template<typename Arg , typename Op , typename Perm , typename = std::enable_if_t<detail::is_permutation_v<Perm>>> | |
decltype(auto) | TiledArray::unary (const Tile< Arg > &arg, Op &&op, const Perm &perm) |
Unary element-wise transform producing a new tile. More... | |
template<typename Result , typename Op > | |
Tile< Result > & | TiledArray::inplace_unary (Tile< Result > &arg, Op &&op) |
Unary element-wise in-place transform. More... | |
template<typename Left , typename Right , typename Scalar , typename std::enable_if< detail::is_numeric_v< Scalar >>::type * = nullptr> | |
decltype(auto) | TiledArray::gemm (const Tile< Left > &left, const Tile< Right > &right, const Scalar factor, const math::GemmHelper &gemm_config) |
Contract 2 tensors over head/tail modes and scale the product. More... | |
template<typename Result , typename Left , typename Right , typename Scalar , typename std::enable_if< detail::is_numeric_v< Scalar >>::type * = nullptr> | |
Tile< Result > & | TiledArray::gemm (Tile< Result > &result, const Tile< Left > &left, const Tile< Right > &right, const Scalar factor, const math::GemmHelper &gemm_config) |
template<typename Result , typename Left , typename Right , typename ElementMultiplyAddOp , typename std::enable_if< std::is_invocable_r_v< void, std::remove_reference_t< ElementMultiplyAddOp >, typename Result::value_type &, const typename Left::value_type &, const typename Right::value_type & >>::type * = nullptr> | |
Tile< Result > & | TiledArray::gemm (Tile< Result > &result, const Tile< Left > &left, const Tile< Right > &right, const math::GemmHelper &gemm_config, ElementMultiplyAddOp &&element_multiplyadd_op) |
template<typename Arg > | |
decltype(auto) | TiledArray::trace (const Tile< Arg > &arg) |
Sum the hyper-diagonal elements a tile. More... | |
template<typename Arg > | |
decltype(auto) | TiledArray::sum (const Tile< Arg > &arg) |
Sum the elements of a tile. More... | |
template<typename Arg > | |
decltype(auto) | TiledArray::product (const Tile< Arg > &arg) |
Multiply the elements of a tile. More... | |
template<typename Arg > | |
decltype(auto) | TiledArray::squared_norm (const Tile< Arg > &arg) |
Squared vector 2-norm of the elements of a tile. More... | |
template<typename Arg > | |
decltype(auto) | TiledArray::norm (const Tile< Arg > &arg) |
Vector 2-norm of a tile. More... | |
template<typename Arg , typename ResultType > | |
void | TiledArray::norm (const Tile< Arg > &arg, ResultType &result) |
Vector 2-norm of a tile. More... | |
template<typename Arg > | |
decltype(auto) | TiledArray::max (const Tile< Arg > &arg) |
Maximum element of a tile. More... | |
template<typename Arg > | |
decltype(auto) | TiledArray::min (const Tile< Arg > &arg) |
Minimum element of a tile. More... | |
template<typename Arg > | |
decltype(auto) | TiledArray::abs_max (const Tile< Arg > &arg) |
Absolute maximum element of a tile. More... | |
template<typename Arg > | |
decltype(auto) | TiledArray::abs_min (const Tile< Arg > &arg) |
Absolute mainimum element of a tile. More... | |
template<typename Left , typename Right > | |
decltype(auto) | TiledArray::dot (const Tile< Left > &left, const Tile< Right > &right) |
Vector dot product of a tile. More... | |
template<typename Left , typename Right > | |
decltype(auto) | TiledArray::inner_product (const Tile< Left > &left, const Tile< Right > &right) |
Vector inner product of a tile. More... | |
template<typename T > | |
std::ostream & | TiledArray::operator<< (std::ostream &os, const Tile< T > &tile) |
template<typename T1 , typename T2 > | |
bool | TiledArray::operator== (const Tile< T1 > &t1, const Tile< T2 > &t2) |
Tile equality comparison. More... | |
template<typename T1 , typename T2 > | |
bool | TiledArray::operator!= (const Tile< T1 > &t1, const Tile< T2 > &t2) |
Tile inequality comparison. More... | |