Home
last modified time | relevance | path

Searched refs:OperatorType (Results 1 – 25 of 135) sorted by relevance

123456

/external/tensorflow/tensorflow/lite/toco/graph_transformations/
Dquantize.cc37 if (type == OperatorType::kUnsupported) { in SupportsQuantization()
41 if (op.type == OperatorType::kRange) { in SupportsQuantization()
47 static const std::set<OperatorType> supported_ops{ in SupportsQuantization()
48 OperatorType::kAdd, in SupportsQuantization()
49 OperatorType::kArgMax, in SupportsQuantization()
50 OperatorType::kAveragePool, in SupportsQuantization()
51 OperatorType::kBatchToSpaceND, in SupportsQuantization()
52 OperatorType::kConcatenation, in SupportsQuantization()
53 OperatorType::kConv, in SupportsQuantization()
54 OperatorType::kDepthToSpace, in SupportsQuantization()
[all …]
Dpropagate_array_data_types.cc57 case OperatorType::kDequantize: in Run()
61 case OperatorType::kLess: in Run()
62 case OperatorType::kLessEqual: in Run()
63 case OperatorType::kGreater: in Run()
64 case OperatorType::kGreaterEqual: in Run()
65 case OperatorType::kEqual: in Run()
66 case OperatorType::kNotEqual: in Run()
67 case OperatorType::kAny: in Run()
68 case OperatorType::kLogicalAnd: in Run()
69 case OperatorType::kLogicalNot: in Run()
[all …]
Dreorder_elementwise_unary.cc30 bool IsElementwiseOperator(OperatorType optype) { in IsElementwiseOperator()
32 case OperatorType::kCast: in IsElementwiseOperator()
33 case OperatorType::kCeil: in IsElementwiseOperator()
34 case OperatorType::kExp: in IsElementwiseOperator()
35 case OperatorType::kFloor: in IsElementwiseOperator()
36 case OperatorType::kNeg: in IsElementwiseOperator()
37 case OperatorType::kRelu: in IsElementwiseOperator()
38 case OperatorType::kRelu1: in IsElementwiseOperator()
39 case OperatorType::kRelu6: in IsElementwiseOperator()
40 case OperatorType::kRound: in IsElementwiseOperator()
[all …]
Dresolve_constant_unary.cc125 case OperatorType::kCast: in Run()
126 case OperatorType::kExp: in Run()
127 case OperatorType::kLog: in Run()
128 case OperatorType::kNeg: in Run()
129 case OperatorType::kRsqrt: in Run()
130 case OperatorType::kSqrt: in Run()
131 case OperatorType::kSquare: in Run()
132 case OperatorType::kSum: in Run()
133 case OperatorType::kReduceMin: // Reduction Min in Run()
134 case OperatorType::kReduceMax: // Reduction Max in Run()
[all …]
Dfuse_binary_into_preceding_affine.cc31 if (op.type == OperatorType::kConv || in GetBiasIndex()
32 op.type == OperatorType::kFullyConnected || in GetBiasIndex()
33 op.type == OperatorType::kDepthwiseConv) { in GetBiasIndex()
35 } else if (op.type == OperatorType::kTransposeConv) { in GetBiasIndex()
45 CHECK(add_or_sub_op->type == OperatorType::kAdd || in FuseAddOrSubParamsIntoPrecedingAffine()
46 add_or_sub_op->type == OperatorType::kSub); in FuseAddOrSubParamsIntoPrecedingAffine()
80 const OpType optype = (add_or_sub_op->type == OperatorType::kAdd) in FuseAddOrSubParamsIntoPrecedingAffine()
106 CHECK(mul_or_div_op->type == OperatorType::kMul || in FuseMulOrDivParamsIntoPrecedingAffine()
107 mul_or_div_op->type == OperatorType::kDiv); in FuseMulOrDivParamsIntoPrecedingAffine()
111 CHECK(mul_or_div_op->type != OperatorType::kDiv || in FuseMulOrDivParamsIntoPrecedingAffine()
[all …]
Didentify_lstm.cc39 OperatorType op_type, Operator** source_op) { in ValidateSourceOp()
40 if (op_type == OperatorType::kNone) { in ValidateSourceOp()
63 OperatorType op_type, Operator** connected_op) { in MatchOperatorInputs()
82 OperatorType a_op_type, Operator** a_op, in MatchOperatorInputs()
83 OperatorType b_op_type, Operator** b_op) { in MatchOperatorInputs()
107 OperatorType a_op_type, Operator** a_op, in MatchOperatorInputs()
108 OperatorType b_op_type, Operator** b_op, in MatchOperatorInputs()
109 OperatorType c_op_type, Operator** c_op) { in MatchOperatorInputs()
147 if (final_output_mul->type != OperatorType::kMul) { in Run()
158 if (!MatchOperatorInputs(*final_output_mul, *model, OperatorType::kTanh, in Run()
[all …]
Dfuse_binary_into_following_affine.cc34 CHECK(add_or_sub_op->type == OperatorType::kAdd || in FuseAddOrSubParamsIntoFollowingAffine()
35 add_or_sub_op->type == OperatorType::kSub); in FuseAddOrSubParamsIntoFollowingAffine()
40 CHECK(add_or_sub_op->type != OperatorType::kSub || in FuseAddOrSubParamsIntoFollowingAffine()
59 if (add_or_sub_op->type == OperatorType::kAdd) { in FuseAddOrSubParamsIntoFollowingAffine()
61 } else if (add_or_sub_op->type == OperatorType::kSub && in FuseAddOrSubParamsIntoFollowingAffine()
77 if (following_op->type == OperatorType::kConv || in FuseAddOrSubParamsIntoFollowingAffine()
78 following_op->type == OperatorType::kFullyConnected) { in FuseAddOrSubParamsIntoFollowingAffine()
94 } else if (following_op->type == OperatorType::kDepthwiseConv) { in FuseAddOrSubParamsIntoFollowingAffine()
116 CHECK(mul_or_div_op->type == OperatorType::kMul || in FuseMulOrDivParamsIntoFollowingAffine()
117 mul_or_div_op->type == OperatorType::kDiv); in FuseMulOrDivParamsIntoFollowingAffine()
[all …]
Dpropagate_fake_quant_num_bits.cc93 case OperatorType::kConcatenation: in DoesOpBlockBackwardPropagation()
94 case OperatorType::kConcat: in DoesOpBlockBackwardPropagation()
95 case OperatorType::kConcatV2: in DoesOpBlockBackwardPropagation()
99 case OperatorType::kDequantize: in DoesOpBlockBackwardPropagation()
102 case OperatorType::kGather: in DoesOpBlockBackwardPropagation()
104 case OperatorType::kReshape: in DoesOpBlockBackwardPropagation()
105 case OperatorType::kTranspose: in DoesOpBlockBackwardPropagation()
106 case OperatorType::kSelect: in DoesOpBlockBackwardPropagation()
107 case OperatorType::kTile: in DoesOpBlockBackwardPropagation()
109 case OperatorType::kRelu: in DoesOpBlockBackwardPropagation()
[all …]
Dresolve_constant_binary.cc137 if (binary_op->type == OperatorType::kAdd) { in EvaluateBinaryOperatorOnConstantInputs()
139 } else if (binary_op->type == OperatorType::kMul) { in EvaluateBinaryOperatorOnConstantInputs()
141 } else if (binary_op->type == OperatorType::kSub) { in EvaluateBinaryOperatorOnConstantInputs()
143 } else if (binary_op->type == OperatorType::kDiv) { in EvaluateBinaryOperatorOnConstantInputs()
145 } else if (binary_op->type == OperatorType::kFloorDiv) { in EvaluateBinaryOperatorOnConstantInputs()
147 } else if (binary_op->type == OperatorType::kFloorMod) { in EvaluateBinaryOperatorOnConstantInputs()
149 } else if (binary_op->type == OperatorType::kMinimum) { in EvaluateBinaryOperatorOnConstantInputs()
151 } else if (binary_op->type == OperatorType::kMaximum) { in EvaluateBinaryOperatorOnConstantInputs()
153 } else if (binary_op->type == OperatorType::kLess) { in EvaluateBinaryOperatorOnConstantInputs()
155 } else if (binary_op->type == OperatorType::kLessEqual) { in EvaluateBinaryOperatorOnConstantInputs()
[all …]
Densure_bias_vectors.cc32 if (op.type == OperatorType::kConv || in GetOutputDepthFromWeights()
33 op.type == OperatorType::kFullyConnected || in GetOutputDepthFromWeights()
34 op.type == OperatorType::kTransposeConv) { in GetOutputDepthFromWeights()
37 if (op.type == OperatorType::kDepthwiseConv) { in GetOutputDepthFromWeights()
45 if (op.type == OperatorType::kConv || in CheckOpInputSize()
46 op.type == OperatorType::kFullyConnected || in CheckOpInputSize()
47 op.type == OperatorType::kDepthwiseConv) { in CheckOpInputSize()
49 } else if (op.type == OperatorType::kTransposeConv) { in CheckOpInputSize()
81 if (op->type == OperatorType::kConv || in Run()
82 op->type == OperatorType::kDepthwiseConv || in Run()
[all …]
Dpropagate_fixed_sizes.cc535 case OperatorType::kReduceMin: // Reduction Min in KeepDims()
537 case OperatorType::kReduceMax: // Reduction Max in KeepDims()
539 case OperatorType::kSum: in KeepDims()
541 case OperatorType::kReduceProd: in KeepDims()
543 case OperatorType::kMean: in KeepDims()
545 case OperatorType::kAny: in KeepDims()
2161 case OperatorType::kAbs: in Run()
2162 case OperatorType::kBatchNormalization: in Run()
2163 case OperatorType::kL2Normalization: in Run()
2164 case OperatorType::kDequantize: in Run()
[all …]
Dgroup_bidirectional_sequence_ops.cc50 if ((*fw_output)->type != OperatorType::kUnpack || in MatchTwoUnpackOps()
51 (*bw_output)->type != OperatorType::kUnpack) { in MatchTwoUnpackOps()
74 if (reverse_output->type != OperatorType::kReverseV2 && in MatchDynamicBidirectionalSequenceOutputs()
75 reverse_output->type != OperatorType::kReverseSequence) { in MatchDynamicBidirectionalSequenceOutputs()
85 OperatorType operator_type, in FindUnidirectionalSequenceOp()
159 if (first_bw_sequence_op_input->type != OperatorType::kReverseV2 && in CheckTwoUnidirectionalSequenceOpsAreValid()
160 first_bw_sequence_op_input->type != OperatorType::kReverseSequence) { in CheckTwoUnidirectionalSequenceOpsAreValid()
172 if (first_fw_sequence_op_input->type != OperatorType::kPack || in CheckTwoUnidirectionalSequenceOpsAreValid()
173 first_bw_sequence_op_input->type != OperatorType::kPack) { in CheckTwoUnidirectionalSequenceOpsAreValid()
322 OperatorType operator_type, const std::string& input_array_name, in RewireBidirectionalSequenceSequenceOpsConnections()
[all …]
Dmove_binary_operator_before_reshape.cc64 if (binary_op->type != OperatorType::kAdd && in Run()
65 binary_op->type != OperatorType::kMul && in Run()
66 binary_op->type != OperatorType::kSub && in Run()
67 binary_op->type != OperatorType::kDiv && in Run()
68 binary_op->type != OperatorType::kFloorDiv && in Run()
69 binary_op->type != OperatorType::kFloorMod && in Run()
70 binary_op->type != OperatorType::kMinimum && in Run()
71 binary_op->type != OperatorType::kMaximum && in Run()
72 binary_op->type != OperatorType::kLess && in Run()
73 binary_op->type != OperatorType::kLessEqual && in Run()
[all …]
Dhardcode_min_max.cc433 case OperatorType::kConv: in Run()
437 case OperatorType::kL2Normalization: in Run()
441 case OperatorType::kRelu: in Run()
451 case OperatorType::kConcatenation: in Run()
455 case OperatorType::kSplit: in Run()
459 case OperatorType::kAveragePool: in Run()
460 case OperatorType::kMaxPool: in Run()
464 case OperatorType::kResizeBilinear: in Run()
465 case OperatorType::kResizeNearestNeighbor: in Run()
466 case OperatorType::kSlice: in Run()
[all …]
Didentify_l2_normalization.cc34 OperatorType expected_op_type_producing_div_or_mul_input; in Run()
35 if (div_or_mul_op->type == OperatorType::kDiv) { in Run()
36 expected_op_type_producing_div_or_mul_input = OperatorType::kSqrt; in Run()
37 } else if (div_or_mul_op->type == OperatorType::kMul) { in Run()
38 expected_op_type_producing_div_or_mul_input = OperatorType::kRsqrt; in Run()
65 if (op_producing_sqrt_or_rsqrt_input->type == OperatorType::kAdd || in Run()
66 op_producing_sqrt_or_rsqrt_input->type == OperatorType::kMaximum) { in Run()
103 if (sum_op->type != OperatorType::kSum) { in Run()
112 if (square_op->type != OperatorType::kSquare) { in Run()
Dremove_trivial_binary.cc55 if (binary_op->type != OperatorType::kAdd && in Run()
56 binary_op->type != OperatorType::kMul && in Run()
57 binary_op->type != OperatorType::kSub && in Run()
58 binary_op->type != OperatorType::kDiv) { in Run()
114 if (binary_op->type == OperatorType::kAdd) { in Run()
116 } else if (binary_op->type == OperatorType::kSub) { in Run()
119 } else if (binary_op->type == OperatorType::kMul) { in Run()
121 } else if (binary_op->type == OperatorType::kDiv) { in Run()
Didentify_dilated_conv.cc76 if (post_conv_op->type != OperatorType::kSqueeze) { in ResolveDilatedConv()
89 if (pad_op && pad_op->type == OperatorType::kPad) { in ResolveDilatedConv()
103 if (next_op->type == OperatorType::kAdd) { in ResolveDilatedConv()
110 if (bts_op->type != OperatorType::kBatchToSpaceND) { in ResolveDilatedConv()
118 if (bias_add_op->type != OperatorType::kAdd) { in ResolveDilatedConv()
131 if (pre_stb_pad_op && pre_stb_pad_op->type == OperatorType::kPad) { in ResolveDilatedConv()
179 if (stb_op->type != OperatorType::kSpaceToBatchND) { in Run()
202 if (post_stb_op->type == OperatorType::kExpandDims) { in Run()
213 if (conv_base_op->type == OperatorType::kConv) { in Run()
222 conv_base_op->type == OperatorType::kDepthwiseConv) { in Run()
Dresolve_reduce_attributes.cc53 case OperatorType::kMean: in Run()
56 case OperatorType::kSum: in Run()
60 case OperatorType::kReduceProd: in Run()
64 case OperatorType::kReduceMin: in Run()
68 case OperatorType::kReduceMax: in Run()
72 case OperatorType::kAny: in Run()
Dpropagate_activation_function_into_constants.cc34 if (ac_op->type != OperatorType::kRelu6 && in Run()
35 ac_op->type != OperatorType::kRelu1 && in Run()
36 ac_op->type != OperatorType::kRelu) { in Run()
57 case OperatorType::kGather: in Run()
93 case OperatorType::kRelu: { in Run()
98 case OperatorType::kRelu1: { in Run()
104 case OperatorType::kRelu6: { in Run()
Didentify_relu1.cc36 if (op_0->type != OperatorType::kMinimum && in Run()
37 op_0->type != OperatorType::kMaximum) { in Run()
44 (op_1->type != OperatorType::kMinimum && in Run()
45 op_1->type != OperatorType::kMaximum) || in Run()
50 const auto* min_op = op_0->type == OperatorType::kMinimum ? op_0 : op_1; in Run()
51 const auto* max_op = op_0->type == OperatorType::kMaximum ? op_0 : op_1; in Run()
Dfuse_activation_functions.cc35 if (ac_op->type != OperatorType::kRelu6 && in Run()
36 ac_op->type != OperatorType::kRelu1 && in Run()
37 ac_op->type != OperatorType::kRelu) { in Run()
92 if (ac_op->type == OperatorType::kRelu6) { in Run()
94 } else if (ac_op->type == OperatorType::kRelu1) { in Run()
96 } else if (ac_op->type == OperatorType::kRelu) { in Run()
Dfuse_broadcast_into_following_binary.cc35 if (op->type == OperatorType::kConcatenation) { in IsBroadcastingOp()
65 if (binary_op->type != OperatorType::kAdd && in Run()
66 binary_op->type != OperatorType::kMul && in Run()
67 binary_op->type != OperatorType::kSub && in Run()
68 binary_op->type != OperatorType::kDiv) { in Run()
/external/tensorflow/tensorflow/lite/toco/
Dmodel.h40 enum class OperatorType : uint8 { enum
393 const OperatorType type;
425 explicit Operator(OperatorType t)
477 ConvOperator() : Operator(OperatorType::kConv) {}
504 : Operator(OperatorType::kCTCBeamSearchDecoder) {}
520 DepthwiseConvOperator() : Operator(OperatorType::kDepthwiseConv) {}
539 DepthToSpaceOperator() : Operator(OperatorType::kDepthToSpace) {}
550 SpaceToDepthOperator() : Operator(OperatorType::kSpaceToDepth) {}
565 FullyConnectedOperator() : Operator(OperatorType::kFullyConnected) {}
598 DequantizeOperator() : Operator(OperatorType::kDequantize) {}
[all …]
/external/tensorflow/tensorflow/lite/toco/tflite/
Doperator_test.cc35 const BaseOperator& GetOperator(const std::string& name, OperatorType type) { in GetOperator()
37 using OpsByType = std::map<OperatorType, std::unique_ptr<BaseOperator>>; in GetOperator()
91 void CheckSimpleOperator(const std::string& name, OperatorType type) { in CheckSimpleOperator()
104 void CheckReducerOperator(const std::string& name, OperatorType type) { in CheckReducerOperator()
115 CheckSimpleOperator<FloorOperator>("FLOOR", OperatorType::kFloor); in TEST_F()
116 CheckSimpleOperator<CeilOperator>("CEIL", OperatorType::kCeil); in TEST_F()
117 CheckSimpleOperator<EluOperator>("ELU", OperatorType::kElu); in TEST_F()
118 CheckSimpleOperator<RoundOperator>("ROUND", OperatorType::kRound); in TEST_F()
119 CheckSimpleOperator<ReluOperator>("RELU", OperatorType::kRelu); in TEST_F()
120 CheckSimpleOperator<Relu1Operator>("RELU_N1_TO_1", OperatorType::kRelu1); in TEST_F()
[all …]
Doperator.cc1602 TensorFlowUnsupported(const std::string& name, OperatorType type, in TensorFlowUnsupported()
1837 MakeUnique<Add>(::tflite::BuiltinOperator_ADD, OperatorType::kAdd)); in BuildOperatorList()
1839 MakeUnique<AddN>(::tflite::BuiltinOperator_ADD_N, OperatorType::kAddN)); in BuildOperatorList()
1841 MakeUnique<Div>(::tflite::BuiltinOperator_DIV, OperatorType::kDiv)); in BuildOperatorList()
1843 MakeUnique<Sub>(::tflite::BuiltinOperator_SUB, OperatorType::kSub)); in BuildOperatorList()
1845 ::tflite::BuiltinOperator_AVERAGE_POOL_2D, OperatorType::kAveragePool)); in BuildOperatorList()
1848 OperatorType::kSpaceToBatchND)); in BuildOperatorList()
1851 OperatorType::kBatchToSpaceND)); in BuildOperatorList()
1853 ::tflite::BuiltinOperator_CONCATENATION, OperatorType::kConcatenation)); in BuildOperatorList()
1855 OperatorType::kConv)); in BuildOperatorList()
[all …]

123456