MCPcopy Create free account
hub / github.com/MegEngine/MegEngine / image_height

Method image_height

dnn/src/common/tensor_format.cpp:221–231  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

219}
220
221size_t Image2DTensorFormatBase::image_height(const TensorLayout& layout) const {
222 size_t accum = 1;
223 for (int i = m_align_axis - 1; i >= 0; --i) {
224 if (layout.stride[i] == 0) {
225 // this dimension is broadcasted
226 } else {
227 accum *= layout.shape[i];
228 }
229 }
230 return accum;
231}
232
233size_t Image2DTensorFormatBase::image_width_elems(const TensorLayout& layout) const {
234 size_t high_elem = 0;

Callers 3

executeMethod · 0.80
image_heightFunction · 0.80
TESTFunction · 0.80

Calls

no outgoing calls

Tested by 2

image_heightFunction · 0.64
TESTFunction · 0.64