MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / KernelsRegisteredForOp

Function KernelsRegisteredForOp

tensorflow/core/framework/op_kernel.cc:1455–1472  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1453}
1454
1455string KernelsRegisteredForOp(StringPiece op_name) {
1456 KernelList kernel_list = GetRegisteredKernelsForOp(op_name);
1457 if (kernel_list.kernel_size() == 0) return " <no registered kernels>\n";
1458 string ret;
1459 for (const auto& kernel_def : kernel_list.kernel()) {
1460 strings::StrAppend(&ret, " device='", kernel_def.device_type(), "'");
1461 if (!kernel_def.label().empty()) {
1462 strings::StrAppend(&ret, "; label='", kernel_def.label(), "'");
1463 }
1464 for (int i = 0; i < kernel_def.constraint_size(); ++i) {
1465 strings::StrAppend(
1466 &ret, "; ", kernel_def.constraint(i).name(), " in ",
1467 SummarizeAttrValue(kernel_def.constraint(i).allowed_values()));
1468 }
1469 strings::StrAppend(&ret, "\n");
1470 }
1471 return ret;
1472}
1473
1474std::unique_ptr<OpKernel> CreateOpKernel(
1475 DeviceType device_type, DeviceBase* device, Allocator* allocator,

Callers 7

FindKernelDefFunction · 0.85
CreateOpKernelFunction · 0.85
GetDevicesForNodeMethod · 0.85
InitializeMemberMethod · 0.85
SelectDeviceFunction · 0.85
IsMklLayoutDependentOpFunction · 0.85
IsMklNameChangeOpFunction · 0.85

Calls 9

SummarizeAttrValueFunction · 0.85
kernel_sizeMethod · 0.80
nameMethod · 0.65
StrAppendFunction · 0.50
kernelMethod · 0.45
device_typeMethod · 0.45
emptyMethod · 0.45
constraintMethod · 0.45

Tested by

no test coverage detected