Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/Oneflow-Inc/oneflow
/ GetFlatShape
Function
GetFlatShape
oneflow/user/kernels/gather_kernel.cpp:27–29 ·
view source on GitHub ↗
Source
from the content-addressed store, hash-verified
25
namespace {
26
27
Shape GetFlatShape(ShapeView shape, int64_t axis) {
28
return Shape({shape.Count(0, axis), shape.At(axis), shape.Count(axis + 1)});
29
}
30
31
class GatherOpKernelCache final : public user_op::OpKernelCache {
32
public:
Callers
1
Compute
Method · 0.70
Calls
3
Shape
Class · 0.50
Count
Method · 0.45
At
Method · 0.45
Tested by
no test coverage detected