MCPcopy Create free account
hub / github.com/Oneflow-Inc/oneflow / ExpandDimIf0D

Function ExpandDimIf0D

oneflow/core/common/shape.cpp:123–126  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

121}
122
123Shape ExpandDimIf0D(const Shape& shape) {
124 if (shape.NumAxes() == 0) { return {1}; }
125 return shape;
126}
127
128Shape ExpandDimIf0D(ShapeView shape) {
129 if (shape.NumAxes() == 0) { return {1}; }

Callers 4

ComputeMethod · 0.85
InitOpKernelCacheMethod · 0.85
ComputeMethod · 0.85
ComputeMethod · 0.85

Calls 2

ShapeClass · 0.70
NumAxesMethod · 0.45

Tested by

no test coverage detected