mirror of
https://gitlab.com/libeigen/eigen.git
synced 2024-12-15 07:10:37 +08:00
Add generic scan method
This commit is contained in:
parent
8d97ba6b22
commit
dc03b8f3a1
@ -498,6 +498,13 @@ class TensorBase<Derived, ReadOnlyAccessors>
|
||||
return TensorScanProdOp(derived(), axis);
|
||||
}
|
||||
|
||||
template <typename Reducer>
|
||||
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE
|
||||
const TensorScanOp<Reducer, const Derived>
|
||||
scan(const Index& axis, const Reducer& reducer) const {
|
||||
return TensorScanOp<Reducer, const Derived>(derived(), axis, reducer);
|
||||
}
|
||||
|
||||
// Reductions.
|
||||
template <typename Dims> EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE
|
||||
const TensorReductionOp<internal::SumReducer<CoeffReturnType>, const Dims, const Derived>
|
||||
|
Loading…
Reference in New Issue
Block a user