Lines Matching refs:subgraph
109 const V1_3::Subgraph& subgraph, const std::vector<RunTimePoolInfo>& modelPoolInfos, in initializeRunTimeInfo() argument
111 const size_t count = subgraph.operands.size(); in initializeRunTimeInfo()
114 const V1_3::Operand& from = subgraph.operands[i]; in initializeRunTimeInfo()
175 std::unique_ptr<xnn_subgraph, decltype(&xnn_delete_subgraph)> subgraph( in Create() local
245 subgraph.get(), xnn_datatype_fp32, dims.size(), dims.data(), data, in Create()
255 if (VisitNode(subgraph.get(), operation, operands.data(), xnnpackTensors) != in Create()
263 status = xnn_create_runtime_v2(subgraph.get(), threadpool, /*flags=*/0, &runtimePtr); in Create()
496 static V1_3::ErrorStatus VisitNode(xnn_subgraph_t subgraph, const V1_3::Operation& operation, in VisitNode() argument
501 return VisitAbsNode(subgraph, operation, operands, xnnpackTensors); in VisitNode()
503 return VisitAddNode(subgraph, operation, operands, xnnpackTensors); in VisitNode()
505 return VisitAveragePool2DNode(subgraph, operation, operands, xnnpackTensors); in VisitNode()
507 return VisitConv2DNode(subgraph, operation, operands, xnnpackTensors); in VisitNode()
509 return VisitDepthwiseConv2DNode(subgraph, operation, operands, xnnpackTensors); in VisitNode()
511 return VisitDivNode(subgraph, operation, operands, xnnpackTensors); in VisitNode()
513 return VisitFloorNode(subgraph, operation, operands, xnnpackTensors); in VisitNode()
515 return VisitFullyConnectedNode(subgraph, operation, operands, xnnpackTensors); in VisitNode()
517 return VisitHardSwishNode(subgraph, operation, operands, xnnpackTensors); in VisitNode()
519 return VisitLogisticNode(subgraph, operation, operands, xnnpackTensors); in VisitNode()
521 return VisitMaxPool2DNode(subgraph, operation, operands, xnnpackTensors); in VisitNode()
523 return VisitMaximumNode(subgraph, operation, operands, xnnpackTensors); in VisitNode()
525 return VisitMeanNode(subgraph, operation, operands, xnnpackTensors); in VisitNode()
527 return VisitMinimumNode(subgraph, operation, operands, xnnpackTensors); in VisitNode()
529 return VisitMulNode(subgraph, operation, operands, xnnpackTensors); in VisitNode()
531 return VisitNegNode(subgraph, operation, operands, xnnpackTensors); in VisitNode()
533 return VisitPadNode(subgraph, operation, operands, 0.0f, xnnpackTensors); in VisitNode()
535 return VisitPadV2Node(subgraph, operation, operands, xnnpackTensors); in VisitNode()
537 return VisitReshapeNode(subgraph, operation, operands, xnnpackTensors); in VisitNode()
539 return VisitResizeBilinearNode(subgraph, operation, operands, xnnpackTensors); in VisitNode()
541 return VisitPreluNode(subgraph, operation, operands, xnnpackTensors); in VisitNode()
543 return VisitReluNode(subgraph, operation, operands, 0.0f, in VisitNode()
546 return VisitReluNode(subgraph, operation, operands, -1.0f, 1.0f, xnnpackTensors); in VisitNode()
548 return VisitReluNode(subgraph, operation, operands, 0.0f, 6.0f, xnnpackTensors); in VisitNode()
550 return VisitSqrtNode(subgraph, operation, operands, xnnpackTensors); in VisitNode()
552 return VisitSubNode(subgraph, operation, operands, xnnpackTensors); in VisitNode()
554 return VisitSoftmaxNode(subgraph, operation, operands, xnnpackTensors); in VisitNode()
560 static V1_3::ErrorStatus VisitAbsNode(xnn_subgraph_t subgraph, const V1_3::Operation& operation, in VisitAbsNode() argument
568 if (subgraph != nullptr) { in VisitAbsNode()
570 xnn_define_abs(subgraph, /*input_id=*/xnnpackTensors[ins[0]], in VisitAbsNode()
580 static V1_3::ErrorStatus VisitAddNode(xnn_subgraph_t subgraph, const V1_3::Operation& operation, in VisitAddNode() argument
596 if (subgraph != nullptr) { in VisitAddNode()
598 xnn_define_add2(subgraph, outputMin, outputMax, in VisitAddNode()
610 static V1_3::ErrorStatus VisitAveragePool2DNode(xnn_subgraph_t subgraph, in VisitAveragePool2DNode() argument
670 if (subgraph != nullptr) { in VisitAveragePool2DNode()
673 status = xnn_define_clamp(subgraph, outputMin, outputMax, in VisitAveragePool2DNode()
678 subgraph, input_padding_top, input_padding_right, input_padding_bottom, in VisitAveragePool2DNode()
693 static V1_3::ErrorStatus VisitConv2DNode(xnn_subgraph_t subgraph, in VisitConv2DNode() argument
769 if (subgraph != nullptr) { in VisitConv2DNode()
771 subgraph, input_padding_top, input_padding_right, input_padding_bottom, in VisitConv2DNode()
792 static V1_3::ErrorStatus VisitDepthwiseConv2DNode(xnn_subgraph_t subgraph, in VisitDepthwiseConv2DNode() argument
870 if (subgraph != nullptr) { in VisitDepthwiseConv2DNode()
872 subgraph, input_padding_top, input_padding_right, input_padding_bottom, in VisitDepthwiseConv2DNode()
893 static V1_3::ErrorStatus VisitDivNode(xnn_subgraph_t subgraph, const V1_3::Operation& operation, in VisitDivNode() argument
909 if (subgraph != nullptr) { in VisitDivNode()
911 xnn_define_divide(subgraph, outputMin, outputMax, in VisitDivNode()
923 static V1_3::ErrorStatus VisitFullyConnectedNode(xnn_subgraph_t subgraph, in VisitFullyConnectedNode() argument
943 if (subgraph != nullptr) { in VisitFullyConnectedNode()
945 xnn_define_fully_connected(subgraph, outputMin, outputMax, in VisitFullyConnectedNode()
959 static V1_3::ErrorStatus VisitFloorNode(xnn_subgraph_t subgraph, in VisitFloorNode() argument
968 if (subgraph != nullptr) { in VisitFloorNode()
970 xnn_define_floor(subgraph, in VisitFloorNode()
981 static V1_3::ErrorStatus VisitHardSwishNode(xnn_subgraph_t subgraph, in VisitHardSwishNode() argument
990 if (subgraph != nullptr) { in VisitHardSwishNode()
992 xnn_define_hardswish(subgraph, /*input_id=*/xnnpackTensors[ins[0]], in VisitHardSwishNode()
1002 static V1_3::ErrorStatus VisitLogisticNode(xnn_subgraph_t subgraph, in VisitLogisticNode() argument
1011 if (subgraph != nullptr) { in VisitLogisticNode()
1013 xnn_define_sigmoid(subgraph, /*input_id=*/xnnpackTensors[ins[0]], in VisitLogisticNode()
1023 static V1_3::ErrorStatus VisitMaxPool2DNode(xnn_subgraph_t subgraph, in VisitMaxPool2DNode() argument
1083 if (subgraph != nullptr) { in VisitMaxPool2DNode()
1086 status = xnn_define_clamp(subgraph, outputMin, outputMax, in VisitMaxPool2DNode()
1091 subgraph, input_padding_top, input_padding_right, input_padding_bottom, in VisitMaxPool2DNode()
1107 static V1_3::ErrorStatus VisitMaximumNode(xnn_subgraph_t subgraph, in VisitMaximumNode() argument
1124 if (subgraph != nullptr) { in VisitMaximumNode()
1126 xnn_define_maximum2(subgraph, in VisitMaximumNode()
1138 static V1_3::ErrorStatus VisitMeanNode(xnn_subgraph_t subgraph, in VisitMeanNode() argument
1167 if (subgraph != nullptr) { in VisitMeanNode()
1169 subgraph, in VisitMeanNode()
1182 static V1_3::ErrorStatus VisitMinimumNode(xnn_subgraph_t subgraph, in VisitMinimumNode() argument
1199 if (subgraph != nullptr) { in VisitMinimumNode()
1201 xnn_define_minimum2(subgraph, in VisitMinimumNode()
1213 static V1_3::ErrorStatus VisitMulNode(xnn_subgraph_t subgraph, const V1_3::Operation& operation, in VisitMulNode() argument
1229 if (subgraph != nullptr) { in VisitMulNode()
1231 xnn_define_multiply2(subgraph, outputMin, outputMax, in VisitMulNode()
1243 static V1_3::ErrorStatus VisitNegNode(xnn_subgraph_t subgraph, const V1_3::Operation& operation, in VisitNegNode() argument
1251 if (subgraph != nullptr) { in VisitNegNode()
1253 xnn_define_negate(subgraph, in VisitNegNode()
1264 static V1_3::ErrorStatus VisitPreluNode(xnn_subgraph_t subgraph, in VisitPreluNode() argument
1279 if (subgraph != nullptr) { in VisitPreluNode()
1281 xnn_define_prelu(subgraph, /*input_id=*/xnnpackTensors[ins[0]], in VisitPreluNode()
1292 static V1_3::ErrorStatus VisitPadNode(xnn_subgraph_t subgraph, const V1_3::Operation& operation, in VisitPadNode() argument
1309 if (subgraph != nullptr) { in VisitPadNode()
1317 subgraph, pre_paddings.data(), post_paddings.data(), padding_value, in VisitPadNode()
1328 static V1_3::ErrorStatus VisitPadV2Node(xnn_subgraph_t subgraph, in VisitPadV2Node() argument
1337 return VisitPadNode(subgraph, operation, operands, padding_value, xnnpackTensors); in VisitPadV2Node()
1340 static V1_3::ErrorStatus VisitReshapeNode(xnn_subgraph_t subgraph, in VisitReshapeNode() argument
1354 if (subgraph != nullptr) { in VisitReshapeNode()
1360 subgraph, static_cast<size_t>(operands[outs[0]].dimensions.size()), in VisitReshapeNode()
1372 static V1_3::ErrorStatus VisitResizeBilinearNode(xnn_subgraph_t subgraph, in VisitResizeBilinearNode() argument
1423 if (subgraph != nullptr) { in VisitResizeBilinearNode()
1431 subgraph, new_height, new_width, in VisitResizeBilinearNode()
1442 static V1_3::ErrorStatus VisitReluNode(xnn_subgraph_t subgraph, in VisitReluNode() argument
1452 if (subgraph != nullptr) { in VisitReluNode()
1454 xnn_define_clamp(subgraph, outputMin, outputMax, in VisitReluNode()
1465 static V1_3::ErrorStatus VisitSqrtNode(xnn_subgraph_t subgraph, in VisitSqrtNode() argument
1474 if (subgraph != nullptr) { in VisitSqrtNode()
1476 xnn_define_square_root(subgraph, in VisitSqrtNode()
1487 static V1_3::ErrorStatus VisitSubNode(xnn_subgraph_t subgraph, const V1_3::Operation& operation, in VisitSubNode() argument
1503 if (subgraph != nullptr) { in VisitSubNode()
1505 xnn_define_subtract(subgraph, outputMin, outputMax, in VisitSubNode()
1517 static V1_3::ErrorStatus VisitSoftmaxNode(xnn_subgraph_t subgraph, in VisitSoftmaxNode() argument
1540 if (subgraph != nullptr) { in VisitSoftmaxNode()
1542 xnn_define_softmax(subgraph, /*input_id=*/xnnpackTensors[ins[0]], in VisitSoftmaxNode()
1644 void asyncExecuteXNNPACK(Subgraph* subgraph, RunTimeOperandInfo* operands, in asyncExecuteXNNPACK() argument
1655 auto status = subgraph->Invoke(operands); in asyncExecuteXNNPACK()
1667 V1_3::ErrorStatus executeXNNPACKBase(Subgraph* subgraph, RunTimeOperandInfo* operands, in executeXNNPACKBase() argument
1691 std::thread([&subgraph, &operands, &model, request, measure, deadline, loopTimeoutDuration, in executeXNNPACKBase()
1693 asyncExecuteXNNPACK(subgraph, operands, request, measure, model, deadline, in executeXNNPACKBase()
1729 executeSynchronouslyXNNPACKBase(Subgraph* subgraph, RunTimeOperandInfo* operands, in executeSynchronouslyXNNPACKBase() argument
1751 auto status = subgraph->Invoke(operands); in executeSynchronouslyXNNPACKBase()