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

Method get_workspace_in_bytes

dnn/src/cuda/group_norm/opr_impl.cpp:8–14  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

6namespace cuda {
7
8size_t GroupNormForwardImpl::get_workspace_in_bytes(
9 const TensorLayout&, const TensorLayout&, const TensorLayout&,
10 const TensorLayout&, const TensorLayout&, const TensorLayout& rstd) {
11 size_t N = rstd.shape[0];
12 size_t G = rstd.shape[1];
13 return get_workspace_bundle(N, G, rstd.dtype.size()).total_size_in_bytes();
14}
15
16WorkspaceBundle GroupNormForwardImpl::get_workspace_bundle(
17 size_t N, size_t G, size_t dtype_size, void* raw_ptr) {

Callers

nothing calls this directly

Calls 3

total_size_in_bytesMethod · 0.80
get_workspace_bundleFunction · 0.50
sizeMethod · 0.45

Tested by

no test coverage detected