Lines Matching refs:context
198 bool prepare(IOperationExecutionContext* context) { in prepare() argument
199 Shape roiShape = context->getInputShape(kRoiTensor); in prepare()
200 Shape bboxDeltasShape = context->getInputShape(kDeltaTensor); in prepare()
201 Shape batchesShape = context->getInputShape(kBatchesTensor); in prepare()
202 Shape imageInfoShape = context->getInputShape(kImageInfoTensor); in prepare()
203 Shape outputShape = context->getOutputShape(kOutputTensor); in prepare()
237 NN_RET_CHECK(context->setOutputShape(kOutputTensor, outputShape)); in prepare()
241 bool execute(IOperationExecutionContext* context) { in execute() argument
244 if (getNumberOfElements(context->getOutputShape(kOutputTensor)) == 0) return true; in execute()
245 switch (context->getInputType(kRoiTensor)) { in execute()
247 return bboxTransformFloat16(context->getInputBuffer<_Float16>(kRoiTensor), in execute()
248 context->getInputShape(kRoiTensor), in execute()
249 context->getInputBuffer<_Float16>(kDeltaTensor), in execute()
250 context->getInputShape(kDeltaTensor), in execute()
251 context->getInputBuffer<int32_t>(kBatchesTensor), in execute()
252 context->getInputShape(kBatchesTensor), in execute()
253 context->getInputBuffer<_Float16>(kImageInfoTensor), in execute()
254 context->getInputShape(kImageInfoTensor), in execute()
255 context->getOutputBuffer<_Float16>(kOutputTensor), in execute()
256 context->getOutputShape(kOutputTensor)); in execute()
259 return bboxTransformFloat32(context->getInputBuffer<float>(kRoiTensor), in execute()
260 context->getInputShape(kRoiTensor), in execute()
261 context->getInputBuffer<float>(kDeltaTensor), in execute()
262 context->getInputShape(kDeltaTensor), in execute()
263 context->getInputBuffer<int32_t>(kBatchesTensor), in execute()
264 context->getInputShape(kBatchesTensor), in execute()
265 context->getInputBuffer<float>(kImageInfoTensor), in execute()
266 context->getInputShape(kImageInfoTensor), in execute()
267 context->getOutputBuffer<float>(kOutputTensor), in execute()
268 context->getOutputShape(kOutputTensor)); in execute()
271 if (context->getInputType(kDeltaTensor) == OperandType::TENSOR_QUANT8_ASYMM) { in execute()
272 return bboxTransformQuant(context->getInputBuffer<uint16_t>(kRoiTensor), in execute()
273 context->getInputShape(kRoiTensor), in execute()
274 context->getInputBuffer<uint8_t>(kDeltaTensor), in execute()
275 context->getInputShape(kDeltaTensor), in execute()
276 context->getInputBuffer<int32_t>(kBatchesTensor), in execute()
277 context->getInputShape(kBatchesTensor), in execute()
278 context->getInputBuffer<uint16_t>(kImageInfoTensor), in execute()
279 context->getInputShape(kImageInfoTensor), in execute()
280 context->getOutputBuffer<uint16_t>(kOutputTensor), in execute()
281 context->getOutputShape(kOutputTensor)); in execute()
283 return bboxTransformQuant(context->getInputBuffer<uint16_t>(kRoiTensor), in execute()
284 context->getInputShape(kRoiTensor), in execute()
285 context->getInputBuffer<int8_t>(kDeltaTensor), in execute()
286 context->getInputShape(kDeltaTensor), in execute()
287 context->getInputBuffer<int32_t>(kBatchesTensor), in execute()
288 context->getInputShape(kBatchesTensor), in execute()
289 context->getInputBuffer<uint16_t>(kImageInfoTensor), in execute()
290 context->getInputShape(kImageInfoTensor), in execute()
291 context->getOutputBuffer<uint16_t>(kOutputTensor), in execute()
292 context->getOutputShape(kOutputTensor)); in execute()
521 IOperationExecutionContext* context) { in boxWithNmsLimitWriteOutput() argument
523 Shape scoresShape = context->getInputShape(kScoreTensor); in boxWithNmsLimitWriteOutput()
529 Shape scoresOutShape = context->getOutputShape(kOutputScoreTensor); in boxWithNmsLimitWriteOutput()
531 NN_RET_CHECK(context->setOutputShape(kOutputScoreTensor, scoresOutShape)); in boxWithNmsLimitWriteOutput()
533 Shape roiOutShape = context->getOutputShape(kOutputRoiTensor); in boxWithNmsLimitWriteOutput()
535 NN_RET_CHECK(context->setOutputShape(kOutputRoiTensor, roiOutShape)); in boxWithNmsLimitWriteOutput()
537 Shape classesOutShape = context->getOutputShape(kOutputClassTensor); in boxWithNmsLimitWriteOutput()
539 NN_RET_CHECK(context->setOutputShape(kOutputClassTensor, classesOutShape)); in boxWithNmsLimitWriteOutput()
541 Shape batchesOutShape = context->getOutputShape(kOutputBatchesTensor); in boxWithNmsLimitWriteOutput()
543 NN_RET_CHECK(context->setOutputShape(kOutputBatchesTensor, batchesOutShape)); in boxWithNmsLimitWriteOutput()
547 const T_Roi* roiBase = context->getInputBuffer<T_Roi>(kRoiTensor); in boxWithNmsLimitWriteOutput()
548 const int32_t* batchesInPtr = context->getInputBuffer<int32_t>(kBatchesTensor); in boxWithNmsLimitWriteOutput()
549 T_Score* scoresOutPtr = context->getOutputBuffer<T_Score>(kOutputScoreTensor); in boxWithNmsLimitWriteOutput()
550 T_Roi* roiOutPtr = context->getOutputBuffer<T_Roi>(kOutputRoiTensor); in boxWithNmsLimitWriteOutput()
551 int32_t* classesOutPtr = context->getOutputBuffer<int32_t>(kOutputClassTensor); in boxWithNmsLimitWriteOutput()
552 int32_t* batchesOutPtr = context->getOutputBuffer<int32_t>(kOutputBatchesTensor); in boxWithNmsLimitWriteOutput()
578 IOperationExecutionContext* context) { in boxWithNmsLimitFloat32() argument
590 scores_float32, context); in boxWithNmsLimitFloat32()
603 IOperationExecutionContext* context) { in boxWithNmsLimitFloat16() argument
614 scores_float32, context); in boxWithNmsLimitFloat16()
626 IOperationExecutionContext* context) { in boxWithNmsLimitQuant() argument
637 scores_float32, context); in boxWithNmsLimitQuant()
649 IOperationExecutionContext* context) { in boxWithNmsLimitQuant() argument
661 scores_float32, context); in boxWithNmsLimitQuant()
666 bool prepare(IOperationExecutionContext* context) { in prepare() argument
667 Shape scoreShape = context->getInputShape(kScoreTensor); in prepare()
668 Shape roiShape = context->getInputShape(kRoiTensor); in prepare()
669 Shape batchesShape = context->getInputShape(kBatchesTensor); in prepare()
670 Shape outputScoreShape = context->getOutputShape(kOutputScoreTensor); in prepare()
671 Shape outputRoiShape = context->getOutputShape(kOutputRoiTensor); in prepare()
672 Shape outputClassShape = context->getOutputShape(kOutputClassTensor); in prepare()
673 Shape outputBatchSplitShape = context->getOutputShape(kOutputBatchesTensor); in prepare()
698 NN_RET_CHECK(context->setOutputShape(kOutputScoreTensor, outputScoreShape)); in prepare()
708 NN_RET_CHECK(context->setOutputShape(kOutputRoiTensor, outputRoiShape)); in prepare()
712 NN_RET_CHECK(context->setOutputShape(kOutputClassTensor, outputClassShape)); in prepare()
716 NN_RET_CHECK(context->setOutputShape(kOutputBatchesTensor, outputBatchSplitShape)); in prepare()
720 bool execute(IOperationExecutionContext* context) { in execute() argument
723 if (getSizeOfDimension(context->getInputShape(kScoreTensor), 0) == 0) return true; in execute()
724 switch (context->getInputType(kScoreTensor)) { in execute()
727 context->getInputBuffer<_Float16>(kScoreTensor), in execute()
728 context->getInputShape(kScoreTensor), in execute()
729 context->getInputBuffer<_Float16>(kRoiTensor), in execute()
730 context->getInputShape(kRoiTensor), in execute()
731 context->getInputBuffer<int32_t>(kBatchesTensor), in execute()
732 context->getInputShape(kBatchesTensor), in execute()
733 context->getInputValue<_Float16>(kScoreThresholdScalar), in execute()
734 context->getInputValue<int32_t>(kMaxNumDetectionScalar), in execute()
735 context->getInputValue<int32_t>(kNmsKernelScalar), in execute()
736 context->getInputValue<_Float16>(kIoUThresholdScalar), in execute()
737 context->getInputValue<_Float16>(kSigmaScalar), in execute()
738 context->getInputValue<_Float16>(kNmsScoreThresholdScalar), in execute()
739 context->getOutputBuffer<_Float16>(kOutputScoreTensor), in execute()
740 context->getOutputShape(kOutputScoreTensor), in execute()
741 context->getOutputBuffer<_Float16>(kOutputRoiTensor), in execute()
742 context->getOutputShape(kOutputRoiTensor), in execute()
743 context->getOutputBuffer<int32_t>(kOutputClassTensor), in execute()
744 context->getOutputShape(kOutputClassTensor), in execute()
745 context->getOutputBuffer<int32_t>(kOutputBatchesTensor), in execute()
746 context->getOutputShape(kOutputBatchesTensor), context); in execute()
749 return boxWithNmsLimitFloat32(context->getInputBuffer<float>(kScoreTensor), in execute()
750 context->getInputShape(kScoreTensor), in execute()
751 context->getInputBuffer<float>(kRoiTensor), in execute()
752 context->getInputShape(kRoiTensor), in execute()
753 context->getInputBuffer<int32_t>(kBatchesTensor), in execute()
754 context->getInputShape(kBatchesTensor), in execute()
755 context->getInputValue<float>(kScoreThresholdScalar), in execute()
756 context->getInputValue<int32_t>(kMaxNumDetectionScalar), in execute()
757 context->getInputValue<int32_t>(kNmsKernelScalar), in execute()
758 context->getInputValue<float>(kIoUThresholdScalar), in execute()
759 context->getInputValue<float>(kSigmaScalar), in execute()
760 context->getInputValue<float>(kNmsScoreThresholdScalar), in execute()
761 context->getOutputBuffer<float>(kOutputScoreTensor), in execute()
762 context->getOutputShape(kOutputScoreTensor), in execute()
763 context->getOutputBuffer<float>(kOutputRoiTensor), in execute()
764 context->getOutputShape(kOutputRoiTensor), in execute()
765 context->getOutputBuffer<int32_t>(kOutputClassTensor), in execute()
766 context->getOutputShape(kOutputClassTensor), in execute()
767 context->getOutputBuffer<int32_t>(kOutputBatchesTensor), in execute()
768 context->getOutputShape(kOutputBatchesTensor), context); in execute()
771 return boxWithNmsLimitQuant(context->getInputBuffer<uint8_t>(kScoreTensor), in execute()
772 context->getInputShape(kScoreTensor), in execute()
773 context->getInputBuffer<uint16_t>(kRoiTensor), in execute()
774 context->getInputShape(kRoiTensor), in execute()
775 context->getInputBuffer<int32_t>(kBatchesTensor), in execute()
776 context->getInputShape(kBatchesTensor), in execute()
777 context->getInputValue<float>(kScoreThresholdScalar), in execute()
778 context->getInputValue<int32_t>(kMaxNumDetectionScalar), in execute()
779 context->getInputValue<int32_t>(kNmsKernelScalar), in execute()
780 context->getInputValue<float>(kIoUThresholdScalar), in execute()
781 context->getInputValue<float>(kSigmaScalar), in execute()
782 context->getInputValue<float>(kNmsScoreThresholdScalar), in execute()
783 context->getOutputBuffer<uint8_t>(kOutputScoreTensor), in execute()
784 context->getOutputShape(kOutputScoreTensor), in execute()
785 context->getOutputBuffer<uint16_t>(kOutputRoiTensor), in execute()
786 context->getOutputShape(kOutputRoiTensor), in execute()
787 context->getOutputBuffer<int32_t>(kOutputClassTensor), in execute()
788 context->getOutputShape(kOutputClassTensor), in execute()
789 context->getOutputBuffer<int32_t>(kOutputBatchesTensor), in execute()
790 context->getOutputShape(kOutputBatchesTensor), context); in execute()
793 return boxWithNmsLimitQuant(context->getInputBuffer<int8_t>(kScoreTensor), in execute()
794 context->getInputShape(kScoreTensor), in execute()
795 context->getInputBuffer<uint16_t>(kRoiTensor), in execute()
796 context->getInputShape(kRoiTensor), in execute()
797 context->getInputBuffer<int32_t>(kBatchesTensor), in execute()
798 context->getInputShape(kBatchesTensor), in execute()
799 context->getInputValue<float>(kScoreThresholdScalar), in execute()
800 context->getInputValue<int32_t>(kMaxNumDetectionScalar), in execute()
801 context->getInputValue<int32_t>(kNmsKernelScalar), in execute()
802 context->getInputValue<float>(kIoUThresholdScalar), in execute()
803 context->getInputValue<float>(kSigmaScalar), in execute()
804 context->getInputValue<float>(kNmsScoreThresholdScalar), in execute()
805 context->getOutputBuffer<int8_t>(kOutputScoreTensor), in execute()
806 context->getOutputShape(kOutputScoreTensor), in execute()
807 context->getOutputBuffer<uint16_t>(kOutputRoiTensor), in execute()
808 context->getOutputShape(kOutputRoiTensor), in execute()
809 context->getOutputBuffer<int32_t>(kOutputClassTensor), in execute()
810 context->getOutputShape(kOutputClassTensor), in execute()
811 context->getOutputBuffer<int32_t>(kOutputBatchesTensor), in execute()
812 context->getOutputShape(kOutputBatchesTensor), context); in execute()
973 IOperationExecutionContext* context) { in generateProposalsFloat32() argument
984 Shape scoresOutShape = context->getOutputShape(kOutputScoreTensor); in generateProposalsFloat32()
986 NN_RET_CHECK(context->setOutputShape(kOutputScoreTensor, scoresOutShape)); in generateProposalsFloat32()
987 Shape roiOutShape = context->getOutputShape(kOutputRoiTensor); in generateProposalsFloat32()
989 NN_RET_CHECK(context->setOutputShape(kOutputRoiTensor, roiOutShape)); in generateProposalsFloat32()
990 Shape batchesOutShape = context->getOutputShape(kOutputBatchesTensor); in generateProposalsFloat32()
992 NN_RET_CHECK(context->setOutputShape(kOutputBatchesTensor, batchesOutShape)); in generateProposalsFloat32()
995 float* scoresOutData = context->getOutputBuffer<float>(kOutputScoreTensor); in generateProposalsFloat32()
999 float* roiOutData = context->getOutputBuffer<float>(kOutputRoiTensor); in generateProposalsFloat32()
1003 int32_t* batchesOutData = context->getOutputBuffer<int32_t>(kOutputBatchesTensor); in generateProposalsFloat32()
1016 IOperationExecutionContext* context) { in generateProposalsFloat16() argument
1036 Shape scoresOutShape = context->getOutputShape(kOutputScoreTensor); in generateProposalsFloat16()
1038 NN_RET_CHECK(context->setOutputShape(kOutputScoreTensor, scoresOutShape)); in generateProposalsFloat16()
1039 Shape roiOutShape = context->getOutputShape(kOutputRoiTensor); in generateProposalsFloat16()
1041 NN_RET_CHECK(context->setOutputShape(kOutputRoiTensor, roiOutShape)); in generateProposalsFloat16()
1042 Shape batchesOutShape = context->getOutputShape(kOutputBatchesTensor); in generateProposalsFloat16()
1044 NN_RET_CHECK(context->setOutputShape(kOutputBatchesTensor, batchesOutShape)); in generateProposalsFloat16()
1047 _Float16* scoresOutData = context->getOutputBuffer<_Float16>(kOutputScoreTensor); in generateProposalsFloat16()
1049 _Float16* roiOutData = context->getOutputBuffer<_Float16>(kOutputRoiTensor); in generateProposalsFloat16()
1051 int32_t* batchesOutData = context->getOutputBuffer<int32_t>(kOutputBatchesTensor); in generateProposalsFloat16()
1065 IOperationExecutionContext* context) { in generateProposalsQuant() argument
1088 Shape scoresOutShape = context->getOutputShape(kOutputScoreTensor); in generateProposalsQuant()
1090 NN_RET_CHECK(context->setOutputShape(kOutputScoreTensor, scoresOutShape)); in generateProposalsQuant()
1091 Shape roiOutShape = context->getOutputShape(kOutputRoiTensor); in generateProposalsQuant()
1093 NN_RET_CHECK(context->setOutputShape(kOutputRoiTensor, roiOutShape)); in generateProposalsQuant()
1094 Shape batchesOutShape = context->getOutputShape(kOutputBatchesTensor); in generateProposalsQuant()
1096 NN_RET_CHECK(context->setOutputShape(kOutputBatchesTensor, batchesOutShape)); in generateProposalsQuant()
1099 T_8QInput* scoresOutData = context->getOutputBuffer<T_8QInput>(kOutputScoreTensor); in generateProposalsQuant()
1102 uint16_t* roiOutData = context->getOutputBuffer<uint16_t>(kOutputRoiTensor); in generateProposalsQuant()
1104 int32_t* batchesOutData = context->getOutputBuffer<int32_t>(kOutputBatchesTensor); in generateProposalsQuant()
1113 bool prepare(IOperationExecutionContext* context) { in prepare() argument
1114 bool useNchw = context->getInputValue<bool>(kLayoutScalar); in prepare()
1115 Shape scoreShape = context->getInputShape(kScoreTensor); in prepare()
1116 Shape bboxDeltasShape = context->getInputShape(kDeltaTensor); in prepare()
1117 Shape anchorsShape = context->getInputShape(kAnchorTensor); in prepare()
1118 Shape imageInfoDataShape = context->getInputShape(kImageInfoTensor); in prepare()
1119 Shape outputScoreShape = context->getOutputShape(kOutputScoreTensor); in prepare()
1120 Shape outputRoiShape = context->getOutputShape(kOutputRoiTensor); in prepare()
1121 Shape outputBatchSplitShape = context->getOutputShape(kOutputBatchesTensor); in prepare()
1153 NN_RET_CHECK(context->setOutputShape(kOutputScoreTensor, outputScoreShape)); in prepare()
1160 NN_RET_CHECK(context->setOutputShape(kOutputRoiTensor, outputRoiShape)); in prepare()
1163 NN_RET_CHECK(context->setOutputShape(kOutputBatchesTensor, outputBatchSplitShape)); in prepare()
1167 bool execute(IOperationExecutionContext* context) { in execute() argument
1169 switch (context->getInputType(kScoreTensor)) { in execute()
1171 return generateProposalsFloat16(context->getInputBuffer<_Float16>(kScoreTensor), in execute()
1172 context->getInputShape(kScoreTensor), in execute()
1173 context->getInputBuffer<_Float16>(kDeltaTensor), in execute()
1174 context->getInputShape(kDeltaTensor), in execute()
1175 context->getInputBuffer<_Float16>(kAnchorTensor), in execute()
1176 context->getInputShape(kAnchorTensor), in execute()
1177 context->getInputBuffer<_Float16>(kImageInfoTensor), in execute()
1178 context->getInputShape(kImageInfoTensor), in execute()
1179 context->getInputValue<_Float16>(kHeightStrideSalar), in execute()
1180 context->getInputValue<_Float16>(kWidthStrideScalar), in execute()
1181 context->getInputValue<int32_t>(kPreNmsMaxScalar), in execute()
1182 context->getInputValue<int32_t>(kPostNmsMaxScalar), in execute()
1183 context->getInputValue<_Float16>(kIoUThresholdScalar), in execute()
1184 context->getInputValue<_Float16>(kMinSizeScalar), in execute()
1185 context->getInputValue<bool>(kLayoutScalar), context); in execute()
1188 return generateProposalsFloat32(context->getInputBuffer<float>(kScoreTensor), in execute()
1189 context->getInputShape(kScoreTensor), in execute()
1190 context->getInputBuffer<float>(kDeltaTensor), in execute()
1191 context->getInputShape(kDeltaTensor), in execute()
1192 context->getInputBuffer<float>(kAnchorTensor), in execute()
1193 context->getInputShape(kAnchorTensor), in execute()
1194 context->getInputBuffer<float>(kImageInfoTensor), in execute()
1195 context->getInputShape(kImageInfoTensor), in execute()
1196 context->getInputValue<float>(kHeightStrideSalar), in execute()
1197 context->getInputValue<float>(kWidthStrideScalar), in execute()
1198 context->getInputValue<int32_t>(kPreNmsMaxScalar), in execute()
1199 context->getInputValue<int32_t>(kPostNmsMaxScalar), in execute()
1200 context->getInputValue<float>(kIoUThresholdScalar), in execute()
1201 context->getInputValue<float>(kMinSizeScalar), in execute()
1202 context->getInputValue<bool>(kLayoutScalar), context); in execute()
1205 return generateProposalsQuant(context->getInputBuffer<uint8_t>(kScoreTensor), in execute()
1206 context->getInputShape(kScoreTensor), in execute()
1207 context->getInputBuffer<uint8_t>(kDeltaTensor), in execute()
1208 context->getInputShape(kDeltaTensor), in execute()
1209 context->getInputBuffer<int16_t>(kAnchorTensor), in execute()
1210 context->getInputShape(kAnchorTensor), in execute()
1211 context->getInputBuffer<uint16_t>(kImageInfoTensor), in execute()
1212 context->getInputShape(kImageInfoTensor), in execute()
1213 context->getInputValue<float>(kHeightStrideSalar), in execute()
1214 context->getInputValue<float>(kWidthStrideScalar), in execute()
1215 context->getInputValue<int32_t>(kPreNmsMaxScalar), in execute()
1216 context->getInputValue<int32_t>(kPostNmsMaxScalar), in execute()
1217 context->getInputValue<float>(kIoUThresholdScalar), in execute()
1218 context->getInputValue<float>(kMinSizeScalar), in execute()
1219 context->getInputValue<bool>(kLayoutScalar), context); in execute()
1222 return generateProposalsQuant(context->getInputBuffer<int8_t>(kScoreTensor), in execute()
1223 context->getInputShape(kScoreTensor), in execute()
1224 context->getInputBuffer<int8_t>(kDeltaTensor), in execute()
1225 context->getInputShape(kDeltaTensor), in execute()
1226 context->getInputBuffer<int16_t>(kAnchorTensor), in execute()
1227 context->getInputShape(kAnchorTensor), in execute()
1228 context->getInputBuffer<uint16_t>(kImageInfoTensor), in execute()
1229 context->getInputShape(kImageInfoTensor), in execute()
1230 context->getInputValue<float>(kHeightStrideSalar), in execute()
1231 context->getInputValue<float>(kWidthStrideScalar), in execute()
1232 context->getInputValue<int32_t>(kPreNmsMaxScalar), in execute()
1233 context->getInputValue<int32_t>(kPostNmsMaxScalar), in execute()
1234 context->getInputValue<float>(kIoUThresholdScalar), in execute()
1235 context->getInputValue<float>(kMinSizeScalar), in execute()
1236 context->getInputValue<bool>(kLayoutScalar), context); in execute()
1389 bool prepare(IOperationExecutionContext* context) { in prepare() argument
1390 Shape scoreShape = context->getInputShape(kScoreTensor); in prepare()
1391 Shape deltasShape = context->getInputShape(kDeltaTensor); in prepare()
1392 Shape anchorsShape = context->getInputShape(kAnchorTensor); in prepare()
1393 Shape outputScoreShape = context->getOutputShape(kOutputScoreTensor); in prepare()
1394 Shape outputRoiShape = context->getOutputShape(kOutputRoiTensor); in prepare()
1395 Shape outputClassShape = context->getOutputShape(kOutputClassTensor); in prepare()
1396 Shape outputDetectionShape = context->getOutputShape(kOutputDetectionTensor); in prepare()
1407 uint32_t maxNumDetections = context->getInputValue<int32_t>(kMaxNumDetectionScalar); in prepare()
1409 context->getInputValue<int32_t>(kMaxClassesPerDetectionScalar); in prepare()
1418 NN_RET_CHECK_GT(context->getInputValue<float>(kScaleYScalar), 0); in prepare()
1419 NN_RET_CHECK_GT(context->getInputValue<float>(kScaleXScalar), 0); in prepare()
1420 NN_RET_CHECK_GT(context->getInputValue<float>(kScaleHScalar), 0); in prepare()
1421 NN_RET_CHECK_GT(context->getInputValue<float>(kScaleWScalar), 0); in prepare()
1422 NN_RET_CHECK_GE(context->getInputValue<float>(kScoreThresholdScalar), 0); in prepare()
1423 NN_RET_CHECK_GE(context->getInputValue<float>(kIoUThresholdScalar), 0); in prepare()
1425 NN_RET_CHECK(context->getInputValue<_Float16>(kScaleYScalar) > 0); in prepare()
1426 NN_RET_CHECK(context->getInputValue<_Float16>(kScaleXScalar) > 0); in prepare()
1427 NN_RET_CHECK(context->getInputValue<_Float16>(kScaleHScalar) > 0); in prepare()
1428 NN_RET_CHECK(context->getInputValue<_Float16>(kScaleWScalar) > 0); in prepare()
1429 NN_RET_CHECK(context->getInputValue<_Float16>(kScoreThresholdScalar) >= 0); in prepare()
1430 NN_RET_CHECK(context->getInputValue<_Float16>(kIoUThresholdScalar) >= 0); in prepare()
1437 if (context->getInputValue<bool>(kUseRegularNmsScalar)) { in prepare()
1438 NN_RET_CHECK_GT(context->getInputValue<int32_t>(kMaxNumDetectionPerClassScalar), 0); in prepare()
1446 NN_RET_CHECK(context->setOutputShape(kOutputScoreTensor, outputScoreShape)); in prepare()
1450 NN_RET_CHECK(context->setOutputShape(kOutputRoiTensor, outputRoiShape)); in prepare()
1454 NN_RET_CHECK(context->setOutputShape(kOutputClassTensor, outputClassShape)); in prepare()
1458 NN_RET_CHECK(context->setOutputShape(kOutputDetectionTensor, outputDetectionShape)); in prepare()
1462 bool execute(IOperationExecutionContext* context) { in execute() argument
1464 switch (context->getInputType(kScoreTensor)) { in execute()
1467 context->getInputBuffer<_Float16>(kScoreTensor), in execute()
1468 context->getInputShape(kScoreTensor), in execute()
1469 context->getInputBuffer<_Float16>(kDeltaTensor), in execute()
1470 context->getInputShape(kDeltaTensor), in execute()
1471 context->getInputBuffer<_Float16>(kAnchorTensor), in execute()
1472 context->getInputShape(kAnchorTensor), in execute()
1473 context->getInputValue<_Float16>(kScaleYScalar), in execute()
1474 context->getInputValue<_Float16>(kScaleXScalar), in execute()
1475 context->getInputValue<_Float16>(kScaleHScalar), in execute()
1476 context->getInputValue<_Float16>(kScaleWScalar), in execute()
1477 context->getInputValue<bool>(kUseRegularNmsScalar), in execute()
1478 context->getInputValue<int32_t>(kMaxNumDetectionScalar), in execute()
1479 context->getInputValue<int32_t>(kMaxClassesPerDetectionScalar), in execute()
1480 context->getInputValue<int32_t>(kMaxNumDetectionPerClassScalar), in execute()
1481 context->getInputValue<_Float16>(kIoUThresholdScalar), in execute()
1482 context->getInputValue<_Float16>(kScoreThresholdScalar), in execute()
1483 context->getInputValue<bool>(kIsBGInLabelScalar), in execute()
1484 context->getOutputBuffer<_Float16>(kOutputScoreTensor), in execute()
1485 context->getOutputShape(kOutputScoreTensor), in execute()
1486 context->getOutputBuffer<_Float16>(kOutputRoiTensor), in execute()
1487 context->getOutputShape(kOutputRoiTensor), in execute()
1488 context->getOutputBuffer<int32_t>(kOutputClassTensor), in execute()
1489 context->getOutputShape(kOutputClassTensor), in execute()
1490 context->getOutputBuffer<int32_t>(kOutputDetectionTensor), in execute()
1491 context->getOutputShape(kOutputDetectionTensor)); in execute()
1495 context->getInputBuffer<float>(kScoreTensor), in execute()
1496 context->getInputShape(kScoreTensor), in execute()
1497 context->getInputBuffer<float>(kDeltaTensor), in execute()
1498 context->getInputShape(kDeltaTensor), in execute()
1499 context->getInputBuffer<float>(kAnchorTensor), in execute()
1500 context->getInputShape(kAnchorTensor), in execute()
1501 context->getInputValue<float>(kScaleYScalar), in execute()
1502 context->getInputValue<float>(kScaleXScalar), in execute()
1503 context->getInputValue<float>(kScaleHScalar), in execute()
1504 context->getInputValue<float>(kScaleWScalar), in execute()
1505 context->getInputValue<bool>(kUseRegularNmsScalar), in execute()
1506 context->getInputValue<int32_t>(kMaxNumDetectionScalar), in execute()
1507 context->getInputValue<int32_t>(kMaxClassesPerDetectionScalar), in execute()
1508 context->getInputValue<int32_t>(kMaxNumDetectionPerClassScalar), in execute()
1509 context->getInputValue<float>(kIoUThresholdScalar), in execute()
1510 context->getInputValue<float>(kScoreThresholdScalar), in execute()
1511 context->getInputValue<bool>(kIsBGInLabelScalar), in execute()
1512 context->getOutputBuffer<float>(kOutputScoreTensor), in execute()
1513 context->getOutputShape(kOutputScoreTensor), in execute()
1514 context->getOutputBuffer<float>(kOutputRoiTensor), in execute()
1515 context->getOutputShape(kOutputRoiTensor), in execute()
1516 context->getOutputBuffer<int32_t>(kOutputClassTensor), in execute()
1517 context->getOutputShape(kOutputClassTensor), in execute()
1518 context->getOutputBuffer<int32_t>(kOutputDetectionTensor), in execute()
1519 context->getOutputShape(kOutputDetectionTensor)); in execute()