aboutsummaryrefslogtreecommitdiffhomepage
path: root/unsupported/Eigen/CXX11/src/Tensor/Tensor.h
Commit message (Collapse)AuthorAge
* Re-implement move assignments.Gravatar Antonio Sanchez2021-03-10
| | | | | | | | | | | | | | | The original swap approach leads to potential undefined behavior (reading uninitialized memory) and results in unnecessary copying of data for static storage. Here we pass down the move assignment to the underlying storage. Static storage does a one-way copy, dynamic storage does a swap. Modified the tests to no longer read from the moved-from matrix/tensor, since that can lead to UB. Added a test to ensure we do not access uninitialized memory in a move. Fixes: #2119
* Fix rule-of-3 for the Tensor module.Gravatar Antonio Sanchez2020-11-18
| | | | | | | Adds copy constructors to Tensor ops, inherits assignment operators from `TensorBase`. Addresses #1863
* Fix most Doxygen warnings. Also add links to stable documentation from ↵Gravatar Christoph Hertzberg2018-10-19
| | | | | | | unsupported modules (by using the corresponding Doxytags file). Manually grafted from d107a371c61b764c73fd1570b1f3ed1c6400dd7e
* Support static dimensions (aka IndexList) in Tensor::resize(...)Gravatar Eugene Zhulenev2018-09-18
|
* Converting ad-hoc inline keyword to EIGEN_STRONG_INLINE MACRO.Gravatar Mehdi Goli2018-08-01
|
* Added a move constructor and move assignment operator to Tensor and wrote ↵Gravatar Viktor Csomor2018-02-07
| | | | some tests.
* Fix typos found using codespellGravatar Gael Guennebaud2018-06-07
|
* Deleted unnecessary explicit qualifiers.Gravatar Benoit Steiner2016-05-25
|
* Make EIGEN_HAS_VARIADIC_TEMPLATES user configurableGravatar Gael Guennebaud2016-05-20
|
* Decoupled the packet type definition from the definition of the tensor ops. ↵Gravatar Benoit Steiner2016-03-08
| | | | All the vectorization is now defined in the tensor evaluators. This will make it possible to relialably support devices with different packet types in the same compilation unit.
* Fixed clang comilation warningsGravatar Benoit Steiner2016-02-10
|
* Backout changeset 690bc950f70c61075d396671e63480bbd64bb297Gravatar Gael Guennebaud2016-01-22
|
* fix clang warningsGravatar Jan Prach2016-01-20
| | | | "braces around scalar initializer"
* Record whether the underlying tensor storage can be accessed directly during ↵Gravatar Benoit Steiner2016-01-19
| | | | the evaluation of an expression.
* Marked the tensor constructors as EIGEN_DEVICE_FUNC: This makes it possible ↵Gravatar Benoit Steiner2015-12-14
| | | | to call them from a CUDA kernel.
* Fixed a typo in the constructor of tensors of rank 5.Gravatar Benoit Steiner2015-12-10
|
* Use integers instead of std::size_t to encode the number of dimensions in ↵Gravatar Benoit Steiner2015-12-04
| | | | the Tensor class since most of the code currently already use integers.
* Started to add support for tensors of rank 0Gravatar Benoit Steiner2015-10-26
|
* Updated the custom indexing code: we can now use any container that provides ↵Gravatar Benoit Steiner2015-10-15
| | | | the [] operator to index a tensor. Added unit tests to validate the use of std::map and a few more types as valid custom index containers
* Tightened the definition of isOfNormalIndex to take into account integer ↵Gravatar Benoit Steiner2015-10-14
| | | | | | | types in addition to arrays of indices Only compile the custom index code when EIGEN_HAS_SFINAE is defined. For the time beeing, EIGEN_HAS_SFINAE is a synonym for EIGEN_HAS_VARIADIC_TEMPLATES, but this might evolve in the future. Moved some code around.
* name changes 2Gravatar Gabriel Nützi2015-10-09
| | | | | | | user: Gabriel Nützi <gnuetzi@gmx.ch> branch 'default' changed unsupported/Eigen/CXX11/src/Tensor/Tensor.h changed unsupported/Eigen/CXX11/src/Tensor/TensorMeta.h
* name changesGravatar Gabriel Nützi2015-10-09
| | | | | | user: Gabriel Nützi <gnuetzi@gmx.ch> branch 'default' changed unsupported/Eigen/CXX11/src/Tensor/Tensor.h
* added CustomIndex capability only to Tensor and not yet to TensorBase.Gravatar Gabriel Nützi2015-10-09
| | | | | | | | | | | | | | using Sfinae and is_base_of to select correct template which converts to array<Index,NumIndices> user: Gabriel Nützi <gnuetzi@gmx.ch> branch 'default' added unsupported/Eigen/CXX11/src/Tensor/TensorMetaMacros.h added unsupported/test/cxx11_tensor_customIndex.cpp changed unsupported/Eigen/CXX11/Tensor changed unsupported/Eigen/CXX11/src/Tensor/Tensor.h changed unsupported/Eigen/CXX11/src/Tensor/TensorMeta.h changed unsupported/test/CMakeLists.txt
* Many files were missing in previous changeset.Gravatar Gael Guennebaud2015-07-29
|
* Silenced a compilation warningGravatar Benoit Steiner2015-06-30
|
* Fixed a few compilation warningsGravatar Benoit Steiner2015-06-30
|
* Improved support for fixed size tensorsGravatar Benoit Steiner2015-06-29
|
* Added a few more missing EIGEN_DEVICE_FUNC statementsGravatar Benoit Steiner2015-05-26
|
* Made the index type a template parameter of the tensor class instead of ↵Gravatar Benoit Steiner2015-03-30
| | | | encoding it in the options.
* Added support for 32bit index on a per tensor/tensor expression. This ↵Gravatar Benoit Steiner2015-02-27
| | | | enables us to use 32bit indices to evaluate expressions on GPU faster while keeping the ability to use 64 bit indices to manipulate large tensors on CPU in the same binary.
* Marked a few functions as EIGEN_DEVICE_FUNC to enable the use of tensors in ↵Gravatar Benoit Steiner2015-02-10
| | | | cuda kernels.
* Silenced a few more compilation warningsGravatar Benoit Steiner2015-01-30
|
* Added missing apis to the tensor classGravatar Benoit Steiner2015-01-14
|
* Silenced a few compilation warningsGravatar Benoit Steiner2014-10-16
| | | | Generalized a TensorMap constructor
* Added missing tensor copy constructors. As a result it is now possible to ↵Gravatar Benoit Steiner2014-09-04
| | | | | | | declare and initialize a tensor on the same line, as in: Tensor<bla> T = A + B; or Tensor<bla> T(A.reshape(new_shape));
* The tensor assignment code now resizes the destination tensor as needed.Gravatar Benoit Steiner2014-07-31
|
* Fixed the assignment operator of the Tensor and TensorMap classes.Gravatar Benoit Steiner2014-07-22
|
* Reworked the expression evaluation mechanism in order to make it possible to ↵Gravatar Benoit Steiner2014-06-13
| | | | | | | | efficiently compute convolutions and contractions in the future: * The scheduling of computation is moved out the the assignment code and into a new TensorExecutor class * The assignment itself is now a regular node on the expression tree * The expression evaluators start by recursively evaluating all their subexpressions if needed
* Pulled latest updates from the Eigen main trunk.Gravatar Benoit Steiner2014-06-10
|\
| * unsupported/TensorSymmetry: factor out completely from Tensor moduleGravatar Christian Seiler2014-06-04
| | | | | | | | | | | | | | | | | | Remove the symCoeff() method of the the Tensor module and move the functionality into a new operator() of the symmetry classes. This makes the Tensor module now completely self-contained without symmetry support (even though previously it was only a forward declaration and a otherwise harmless trivial templated method) and also removes the inconsistency with the rest of eigen w.r.t. the method's naming scheme.
* | Added support for tensor contractionsGravatar Benoit Steiner2014-06-04
| | | | | | | | | | Updated expression evaluation mechanism to also compute the size of the tensor result Misc fixes and improvements.
* | Vectorized the evaluation of tensor expression (using SSE, AVX, NEON, ...)Gravatar Benoit Steiner2014-05-16
| | | | | | | | | | Added the ability to parallelize the evaluation of a tensor expression over multiple cpu cores. Added the ability to offload the evaluation of a tensor expression to a GPU.
* | Added support for fixed sized tensors.Gravatar Benoit Steiner2014-05-06
| | | | | | | | Improved support for tensor expressions.
* | Extended support for Tensors:Gravatar Benoit Steiner2014-04-28
|/ | | | | | * Added ability to map a region of the memory to a tensor * Added basic support for unary and binary coefficient wise expressions, such as addition or square root * Provided an emulation layer to make it possible to compile the code with compilers (such as nvcc) that don't support cxx11.
* C++11/Tensor: Fix copyright headersGravatar Christian Seiler2013-11-16
|
* CXX11/TensorSymmetry: add symmetry support for Tensor classGravatar Christian Seiler2013-11-14
| | | | | | | | | | | | | | | | | | | | | | | | | Add a symCoeff() method to the Tensor class template that allows the user of the class to set multiple elements of a tensor at once if they are connected by a symmetry operation with respect to the tensor's indices (symmetry/antisymmetry/hermiticity/antihermiticity under echange of two indices and combination thereof for different pairs of indices). A compile-time resolution of the required symmetry groups via meta templates is also implemented. For small enough groups this is used to unroll the loop that goes through all the elements of the Tensor that are connected by this group. For larger groups or groups where the symmetries are defined at run time, a standard run-time implementation of the same algorithm is provided. For example, the following code completely initializes all elements of the totally antisymmetric tensor in three dimensions ('epsilon tensor'): SGroup<3, AntiSymmetry<0,1>, AntiSymmetry<1,2>> sym; Eigen::Tensor<double, 3> epsilon(3,3,3); epsilon.setZero(); epsilon.symCoeff(sym, 0, 1, 2) = 1;
* CXX11/Tensor: add simple initial tensor implementationGravatar Christian Seiler2013-11-14
This commit adds an initial implementation of a class template Tensor that allows for the storage of objects with more than two indices. Currently, only storing data and setting the object to zero for POD data types are implemented.