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

Function DoNonZero

cpp/src/arrow/compute/kernels/vector_selection.cc:262–272  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

260};
261
262Status DoNonZero(const std::vector<ArraySpan>& arrays, int64_t total_length,
263 std::shared_ptr<ArrayData>* out) {
264 UInt64Builder builder;
265 RETURN_NOT_OK(builder.Reserve(total_length));
266
267 if (!arrays.empty()) {
268 NonZeroVisitor visitor(&builder, arrays);
269 RETURN_NOT_OK(VisitTypeInline(*arrays[0].type, &visitor));
270 }
271 return builder.FinishInternal(out);
272}
273
274Status IndicesNonZeroExec(KernelContext* ctx, const ExecSpan& batch, ExecResult* out) {
275 std::shared_ptr<ArrayData> result;

Callers 2

IndicesNonZeroExecFunction · 0.85

Calls 4

VisitTypeInlineFunction · 0.85
ReserveMethod · 0.45
emptyMethod · 0.45
FinishInternalMethod · 0.45

Tested by

no test coverage detected