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

Function fromArray

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

Source from the content-addressed store, hash-verified

807 */
808 template<int Rows, int Cols, int Batches>
809 static Matrix<_Scalar, ((Rows>1) ? Dynamic : 1), ((Cols>1) ? Dynamic : 1), ((Batches>1) ? Dynamic : 1), RowMajor>
810 fromArray(const _Scalar (&a)[Batches][Rows][Cols])
811 {
812 typedef Matrix<_Scalar, (Rows > 1) ? Dynamic : Rows, (Cols > 1) ? Dynamic : Cols, (Batches > 1) ? Dynamic : Batches, RowMajor> mt;
813 mt m(Rows, Cols, Batches);
814 m.copyFromHost((const _Scalar*)a);
815 CUMAT_PROFILING_INC(MemcpyHostToDevice);
816 return m;
817 }
818
819 /**
820 * \brief Performs a synchronous copy from host data into the

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected