39 template <
typename Index_ =
int>
87 Index const &
d()
const {
return this->
at(kD); }
95 Index const &
h()
const {
return this->
at(kH); }
static int kC
C dimension.
Definition: tile_coord.h:58
static int kD
D dimension.
Definition: tile_coord.h:49
static int kH
H dimension.
Definition: tile_coord.h:52
CUTLASS_HOST_DEVICE Coord< 3 > dhw() const
Gets D, H, and W dimensions as a Coord<3>
Definition: tile_coord.h:131
CUTLASS_HOST_DEVICE Index const & c() const
Returns the Celement of the coordinate.
Definition: tile_coord.h:111
CUTLASS_HOST_DEVICE Index const & h() const
Returns the H element of the coordinate.
Definition: tile_coord.h:95
A Coord is a coordinate of arbitrary rank into a tensor or matrix.
Index_ Index
Index type.
Definition: tile_coord.h:43
CUTLASS_HOST_DEVICE Index const & w() const
Returns the W element of the coordinate.
Definition: tile_coord.h:103
CUTLASS_HOST_DEVICE Coord< 1 > make_Coord(int _0)
Helper to make a 2-element coordinate.
Definition: coord.h:368
CUTLASS_HOST_DEVICE Index const & d() const
Returns the D element of the coordinate.
Definition: tile_coord.h:87
CUTLASS_HOST_DEVICE TileCoord & operator-=(Base const &b)
In-place subtraction.
Definition: tile_coord.h:172
CUTLASS_HOST_DEVICE TileCoord(Index d, Index h, Index w, Index c)
Helper to construct from a row and column.
Definition: tile_coord.h:83
CUTLASS_HOST_DEVICE TileCoord(Coord< 4, Index > const &coord)
Constructs from Coord<4>
Definition: tile_coord.h:75
CUTLASS_HOST_DEVICE TileCoord operator*(Base const &b) const
Element-wise multiplication.
Definition: tile_coord.h:153
CUTLASS_HOST_DEVICE Index & c()
Returns the C element of the coordinate.
Definition: tile_coord.h:115
CUTLASS_HOST_DEVICE Coord & operator*=(Coord const &b)
In-place multiplication.
Definition: coord.h:197
CUTLASS_HOST_DEVICE TileCoord(Coord< 3, Index > const &coord)
Constructs from Coord<3> and infers coord[kC] = 0.
Definition: tile_coord.h:70
CUTLASS_HOST_DEVICE TileCoord operator-(Base const &b) const
Element-wise subtraction.
Definition: tile_coord.h:147
CUTLASS_HOST_DEVICE TileCoord & operator*=(Base const &b)
In-place multiplication.
Definition: tile_coord.h:179
Definition: tile_coord.h:40
CUTLASS_HOST_DEVICE Coord< 3 > hwc() const
Gets H, W, and C dimensions as a Coord<3>
Definition: tile_coord.h:125
CUTLASS_HOST_DEVICE TileCoord()
Default ctor.
Definition: tile_coord.h:66
CUTLASS_HOST_DEVICE Index & w()
Returns the W element of the coordinate.
Definition: tile_coord.h:107
CUTLASS_HOST_DEVICE Coord< 2 > hw() const
Gets H and W dimensions as a Coord<2>
Definition: tile_coord.h:119
CUTLASS_HOST_DEVICE Coord & operator-=(Coord const &b)
In-place subtraction.
Definition: coord.h:188
CUTLASS_HOST_DEVICE TileCoord operator/(Base const &b) const
Element-wise division.
Definition: tile_coord.h:159
CUTLASS_HOST_DEVICE Coord & operator+=(Coord const &b)
In-place addition.
Definition: coord.h:179
Coord< 4, Index > Base
Underlying Coord<4>
Definition: tile_coord.h:46
#define CUTLASS_HOST_DEVICE
Definition: cutlass.h:46
CUTLASS_HOST_DEVICE Index & at()
Gets the index of a given Coord element.
Definition: coord.h:240
CUTLASS_HOST_DEVICE TileCoord & operator/=(Base const &b)
In-place division.
Definition: tile_coord.h:186
CUTLASS_HOST_DEVICE Coord & operator/=(Coord const &b)
In-place division.
Definition: coord.h:206
CUTLASS_HOST_DEVICE TileCoord(Index coord[4])
Constructs from an array of coordinate elements.
Definition: tile_coord.h:79
static int kW
W dimension.
Definition: tile_coord.h:55
Statically-sized array specifying Coords within a tensor.
Definition: coord.h:49
CUTLASS_HOST_DEVICE Index & h()
Returns the H element of the coordinate.
Definition: tile_coord.h:99
CUTLASS_HOST_DEVICE TileCoord & operator+=(Base const &b)
In-place addition.
Definition: tile_coord.h:165
CUTLASS_HOST_DEVICE TileCoord operator+(Base const &b) const
Element-wise addition.
Definition: tile_coord.h:141
CUTLASS_HOST_DEVICE Index & d()
Returns the D element of the coordinate.
Definition: tile_coord.h:91