MCPcopy Create free account
hub / github.com/Meshcapade/difflocks / toEigen

Function toEigen

extensions/include/cuMat/src/Matrix.h:891–898  ·  view source on GitHub ↗

* \brief Converts this cuMat matrix to the corresponding Eigen matrix. * Note that Eigen does not support batched matrices. Hence, this * conversion is only possible, if * a) the matrix has a compile-time batch size of 1, or * b) the matrix has a dynamic batch size and the batch size is 1 during runtime. * * * Design decision: * Converting between cuMat and Eigen

Source from the content-addressed store, hash-verified

889 * \return the Eigen matrix with the contents of this matrix.
890 */
891 EigenMatrix_t toEigen() const
892 {
893 CUMAT_STATIC_ASSERT(_Batches == 1 || _Batches == Dynamic, "Compile-time batches>1 not allowed. Eigen does not support batches");
894 if (_Batches == Dynamic) CUMAT_ASSERT_ARGUMENT(batches() == 1);
895 EigenMatrix_t mat(rows(), cols());
896 copyToHost(mat.data());
897 return mat;
898 }
899
900 /**
901 * \brief Converts the specified Eigen matrix into the

Callers

nothing calls this directly

Calls 5

copyToHostFunction · 0.85
batchesFunction · 0.70
rowsFunction · 0.70
colsFunction · 0.70
dataMethod · 0.45

Tested by

no test coverage detected