MCPcopy Create free account
hub / github.com/apache/arrow / MakeSparseCSXMatrixFromTensor

Function MakeSparseCSXMatrixFromTensor

cpp/src/arrow/tensor/csx_converter.cc:146–158  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

144} // namespace
145
146Status MakeSparseCSXMatrixFromTensor(SparseMatrixCompressedAxis axis,
147 const Tensor& tensor,
148 const std::shared_ptr<DataType>& index_value_type,
149 MemoryPool* pool,
150 std::shared_ptr<SparseIndex>* out_sparse_index,
151 std::shared_ptr<Buffer>* out_data) {
152 SparseCSXMatrixConverter converter(axis, tensor, index_value_type, pool);
153 RETURN_NOT_OK(converter.Convert());
154
155 *out_sparse_index = converter.sparse_index;
156 *out_data = converter.data;
157 return Status::OK();
158}
159
160namespace {
161

Callers 1

Calls 2

OKFunction · 0.50
ConvertMethod · 0.45

Tested by

no test coverage detected