|
IncliArray
|
Functions | |
| std::vector< int > | _computeStrides (std::vector< int > newShape) |
| Computes strides from a new shape. | |
| std::vector< int > | _broadcastShape (std::vector< int > a, std::vector< int > b) |
| Computes the broadcasted shape of a and b together. | |
| std::vector< int > | _broadcastStrides (std::vector< int > originalShape, std::vector< int > originalStrides, std::vector< int > targetShape) |
| Computes the broadcasted strides based on original shape and strides, and target shape. | |
| int | _computeOffset (std::vector< int > index, std::vector< int > strides) |
| Computes offset based on the index and strides. | |
| std::vector< int > detail::_broadcastShape | ( | std::vector< int > | a, |
| std::vector< int > | b | ||
| ) |
Computes the broadcasted shape of a and b together.
| a | First object for shape broadcasting |
| a | Second object for shape broadcasting |
| std::vector< int > detail::_broadcastStrides | ( | std::vector< int > | originalShape, |
| std::vector< int > | originalStrides, | ||
| std::vector< int > | targetShape | ||
| ) |
Computes the broadcasted strides based on original shape and strides, and target shape.
| originalShape | Original shape |
| originalStrides | Original strides |
| targetShape | The target shape. It is the shape which the new stride will correspond to |
| int detail::_computeOffset | ( | std::vector< int > | index, |
| std::vector< int > | strides | ||
| ) |
Computes offset based on the index and strides.
| index | Indices based on which the offset will be computed |
| strides | Strides that will be used to compute the offset |
| std::vector< int > detail::_computeStrides | ( | std::vector< int > | newShape | ) |
Computes strides from a new shape.
| newShape | Shape with which strides should be computed |