Go to the documentation of this file.
   10 #ifndef EIGEN_CXX11_TENSOR_TENSOR_ASSIGN_H 
   11 #define EIGEN_CXX11_TENSOR_TENSOR_ASSIGN_H 
   24 template<
typename LhsXprType, 
typename RhsXprType>
 
   44 template<
typename LhsXprType, 
typename RhsXprType>
 
   50 template<
typename LhsXprType, 
typename RhsXprType>
 
   60 template<
typename LhsXprType, 
typename RhsXprType>
 
   91 template<
typename LeftArgType, 
typename RightArgType, 
typename Device>
 
  104   static const int NumDims = XprType::NumDims;
 
  128       m_leftImpl(op.lhsExpression(), device),
 
  129       m_rightImpl(op.rhsExpression(), device)
 
  134         YOU_MADE_A_PROGRAMMING_MISTAKE);
 
  142     return m_rightImpl.dimensions();
 
  147     m_leftImpl.evalSubExprsIfNeeded(
NULL);
 
  152     return m_rightImpl.evalSubExprsIfNeeded(m_leftImpl.data());
 
  155 #ifdef EIGEN_USE_THREADS 
  156   template <
typename EvalSubExprsCallback>
 
  159     m_leftImpl.evalSubExprsIfNeededAsync(
nullptr, [
this, done](
bool) {
 
  160       m_rightImpl.evalSubExprsIfNeededAsync(
 
  161           m_leftImpl.data(), [done](
bool need_assign) { done(need_assign); });
 
  164 #endif  // EIGEN_USE_THREADS 
  167     m_leftImpl.cleanup();
 
  168     m_rightImpl.cleanup();
 
  172     m_leftImpl.coeffRef(
i) = m_rightImpl.coeff(
i);
 
  178     m_leftImpl.template writePacket<LhsStoreMode>(
i, m_rightImpl.template packet<RhsLoadMode>(
i));
 
  182     return m_leftImpl.coeff(index);
 
  184   template<
int LoadMode>
 
  187     return m_leftImpl.template packet<LoadMode>(index);
 
  196     return m_rightImpl.costPerCoeff(vectorized) +
 
  199                left.bytes_stored(), 
left.compute_cycles()) +
 
  206         m_leftImpl.getResourceRequirements(),
 
  207         m_rightImpl.getResourceRequirements());
 
  216       desc.template AddDestinationBuffer<Layout>(
 
  217           m_leftImpl.data() + 
desc.offset(),
 
  218           internal::strides<Layout>(m_leftImpl.dimensions()));
 
  229 #ifdef EIGEN_USE_SYCL 
  232     m_leftImpl.bind(cgh);
 
  233     m_rightImpl.bind(cgh);
 
  247 #endif // EIGEN_CXX11_TENSOR_TENSOR_ASSIGN_H 
  
TensorEvaluator< const RightArgType, Device >::TensorBlock RightTensorBlock
#define EIGEN_DEVICE_FUNC
Namespace containing all symbols from the Eigen library.
EIGEN_STRONG_INLINE bool evalSubExprsIfNeeded(EvaluatorPointerType)
Eigen::NumTraits< Scalar >::Real RealScalar
const EIGEN_DEVICE_FUNC internal::remove_all< typename RhsXprType::Nested >::type & rhsExpression() const
TensorAssignOp< LeftArgType, RightArgType > XprType
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE internal::TensorBlockResourceRequirements getResourceRequirements() const
EIGEN_DEVICE_FUNC CoeffReturnType coeff(Index index) const
TensorAssignOp< LhsXprType, RhsXprType > type
EIGEN_DEVICE_FUNC internal::remove_all< typename LhsXprType::Nested >::type & lhsExpression() const
Eigen::internal::nested< TensorAssignOp >::type Nested
static EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorBlockResourceRequirements merge(const TensorBlockResourceRequirements &lhs, const TensorBlockResourceRequirements &rhs)
static const int PacketSize
internal::TensorBlockScratchAllocator< Device > TensorBlockScratch
remove_reference< RhsNested >::type _RhsNested
EIGEN_DEVICE_FUNC EIGEN_ALWAYS_INLINE bool dimensions_match(Dims1 dims1, Dims2 dims2)
EIGEN_DEVICE_FUNC EvaluatorPointerType data() const
internal::remove_all< typename LhsXprType::Nested >::type & m_lhs_xpr
internal::TensorBlockDescriptor< NumDims, Index > TensorBlockDesc
const internal::remove_all< typename RhsXprType::Nested >::type & m_rhs_xpr
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorAssignOp(LhsXprType &lhs, const RhsXprType &rhs)
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorOpCost costPerCoeff(bool vectorized) const
remove_reference< LhsNested >::type _LhsNested
EIGEN_DEVICE_FUNC EvaluatorPointerType data() const
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE void evalScalar(Index i)
EIGEN_DEVICE_FUNC PacketReturnType packet(Index index) const
Eigen::internal::traits< TensorAssignOp >::StorageKind StorageKind
TensorEvaluator(const XprType &op, const Device &device)
#define EIGEN_STRONG_INLINE
Eigen::internal::traits< TensorAssignOp >::Index Index
const EIGEN_DEVICE_FUNC Dimensions & dimensions() const
LhsXprType::Scalar Scalar
Storage::Type EvaluatorPointerType
traits< LhsXprType >::PointerType PointerType
StorageMemory< CoeffReturnType, Device > Storage
TensorEvaluator< RightArgType, Device > m_rightImpl
traits< LhsXprType >::StorageKind StorageKind
#define EIGEN_STATIC_ASSERT(CONDITION, MSG)
Storage::Type EvaluatorPointerType
TensorEvaluator< RightArgType, Device >::Dimensions Dimensions
EIGEN_STRONG_INLINE void cleanup()
promote_index_type< typename traits< LhsXprType >::Index, typename traits< RhsXprType >::Index >::type Index
A cost model used to limit the number of threads used for evaluating tensor expression.
TensorEvaluator< LeftArgType, Device > m_leftImpl
RhsXprType::Nested RhsNested
const typedef TensorAssignOp< LhsXprType, RhsXprType > & type
EIGEN_DEVICE_FUNC EIGEN_ALWAYS_INLINE T maxi(const T &x, const T &y)
LhsXprType::Nested LhsNested
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE void evalBlock(TensorBlockDesc &desc, TensorBlockScratch &scratch)
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE TensorBlock block(TensorBlockDesc &desc, TensorBlockScratch &scratch, bool=false) const
PacketType< CoeffReturnType, Device >::type PacketReturnType
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE void evalPacket(Index i)
XprType::CoeffReturnType CoeffReturnType
LhsXprType::CoeffReturnType CoeffReturnType
Eigen::internal::traits< TensorAssignOp >::Scalar Scalar
TensorBlockKind kind() const
gtsam
Author(s): 
autogenerated on Wed May 28 2025 03:04:25