MCPcopy Create free account
hub / github.com/apache/tvm / forward_shape

Method forward_shape

python/tvm/s_tir/data_layout.py:136–149  ·  view source on GitHub ↗

Given the shape of the src-layout, infer the dst shape. Parameters ---------- shape: Array of Expr The shape in src-layout. Returns ------- dst_shape: Array of Expr The inferred shape in dst-layout.

(self, shape)

Source from the content-addressed store, hash-verified

134 return _ffi_api.SBijectiveLayoutBackwardIndex(self, index) # type: ignore
135
136 def forward_shape(self, shape):
137 """Given the shape of the src-layout, infer the dst shape.
138
139 Parameters
140 ----------
141 shape: Array of Expr
142 The shape in src-layout.
143
144 Returns
145 -------
146 dst_shape: Array of Expr
147 The inferred shape in dst-layout.
148 """
149 return _ffi_api.SBijectiveLayoutForwardShape(self, shape) # type: ignore
150
151 def backward_shape(self, shape):
152 """Given the shape of the dst-layout, infer the src shape.

Callers 1

test_bilayout_shapeFunction · 0.80

Calls

no outgoing calls

Tested by 1

test_bilayout_shapeFunction · 0.64