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

Function IsTensorStridesColumnMajor

cpp/src/arrow/tensor.cc:127–137  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

125}
126
127inline bool IsTensorStridesColumnMajor(const std::shared_ptr<DataType>& type,
128 const std::vector<int64_t>& shape,
129 const std::vector<int64_t>& strides) {
130 std::vector<int64_t> f_strides;
131 const auto& fw_type = checked_cast<const FixedWidthType&>(*type);
132 if (internal::ComputeColumnMajorStrides(fw_type, shape, &f_strides).ok()) {
133 return strides == f_strides;
134 } else {
135 return false;
136 }
137}
138
139inline Status CheckTensorValidity(const std::shared_ptr<DataType>& type,
140 const std::shared_ptr<Buffer>& data,

Callers 2

is_column_majorMethod · 0.85

Calls 2

okMethod · 0.45

Tested by

no test coverage detected