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

Function Eval

tensorflow/lite/kernels/one_hot.cc:158–183  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

156}
157
158TfLiteStatus Eval(TfLiteContext* context, TfLiteNode* node) {
159 OneHotContext op_context{context, node};
160
161 if (IsDynamicTensor(op_context.output)) {
162 ResizeOutputTensor(context, op_context);
163 }
164
165 switch (op_context.output->type) {
166 case kTfLiteFloat32:
167 OneHotCompute<float>(op_context);
168 break;
169 case kTfLiteInt32:
170 OneHotCompute<int>(op_context);
171 break;
172 case kTfLiteInt64:
173 OneHotCompute<int64_t>(op_context);
174 break;
175 case kTfLiteBool:
176 OneHotCompute<bool>(op_context);
177 break;
178 default:
179 return kTfLiteError;
180 }
181
182 return kTfLiteOk;
183}
184
185} // namespace one_hot
186

Callers

nothing calls this directly

Calls 2

IsDynamicTensorFunction · 0.85
ResizeOutputTensorFunction · 0.70

Tested by

no test coverage detected