79 using RowMajorMatrixXf = Eigen::Matrix<float, Eigen::Dynamic, Eigen::Dynamic, Eigen::RowMajor>;
163 int64_t
size()
const;
169 const std::vector<int64_t>&
shape()
const;
176 int64_t
shape(
int dim)
const;
204 const float*
data()
const;
267 static int64_t computeSize(
const std::vector<int64_t>&
shape);
269 std::shared_ptr<std::vector<float>> m_storage;
270 float* m_data =
nullptr;
271 std::vector<int64_t> m_shape;
Export/import macros, build-stamp accessors and namespace anchor for the MLLIB machine-learning libra...
Tensors, model abstraction, ONNX Runtime inference and Python training drivers used across mne-cpp.
Eigen::MatrixXf toMatrixXf() const
Eigen::Map< RowMajorMatrixXf > RowMajorMatrixMap
Eigen::Matrix< float, Eigen::Dynamic, Eigen::Dynamic, Eigen::RowMajor > RowMajorMatrixXf
static MlTensor fromBuffer(const float *data, int rows, int cols)
Eigen::MatrixXd toMatrixXd() const
static MlTensor view(float *data, std::vector< int64_t > shape)
MlTensor(const Eigen::MatrixXd &mat)
RowMajorMatrixMap matrix()
MlTensor(const Eigen::MatrixXf &mat)
MlTensor reshape(std::vector< int64_t > newShape) const
const std::vector< int64_t > & shape() const
Eigen::Map< const RowMajorMatrixXf > ConstRowMajorMatrixMap