1 | // This file is MACHINE GENERATED! Do not edit. |
2 | |
3 | |
4 | #include "tensorflow/cc/ops/const_op.h" |
5 | #include "tensorflow/cc/ops/map_ops.h" |
6 | |
7 | namespace tensorflow { |
8 | namespace ops { |
9 | |
10 | EmptyTensorMap::EmptyTensorMap(const ::tensorflow::Scope& scope) { |
11 | if (!scope.ok()) return; |
12 | ::tensorflow::Node* ret; |
13 | const auto unique_name = scope.GetUniqueNameForOp("EmptyTensorMap" ); |
14 | auto builder = ::tensorflow::NodeBuilder(unique_name, "EmptyTensorMap" ) |
15 | ; |
16 | scope.UpdateBuilder(&builder); |
17 | scope.UpdateStatus(builder.Finalize(scope.graph(), &ret)); |
18 | if (!scope.ok()) return; |
19 | scope.UpdateStatus(scope.DoShapeInference(ret)); |
20 | this->operation = Operation(ret); |
21 | this->handle = Output(ret, 0); |
22 | } |
23 | |
24 | TensorMapErase::TensorMapErase(const ::tensorflow::Scope& scope, |
25 | ::tensorflow::Input input_handle, |
26 | ::tensorflow::Input key, DataType value_dtype) { |
27 | if (!scope.ok()) return; |
28 | auto _input_handle = ::tensorflow::ops::AsNodeOut(scope, input_handle); |
29 | if (!scope.ok()) return; |
30 | auto _key = ::tensorflow::ops::AsNodeOut(scope, key); |
31 | if (!scope.ok()) return; |
32 | ::tensorflow::Node* ret; |
33 | const auto unique_name = scope.GetUniqueNameForOp("TensorMapErase" ); |
34 | auto builder = ::tensorflow::NodeBuilder(unique_name, "TensorMapErase" ) |
35 | .Input(_input_handle) |
36 | .Input(_key) |
37 | .Attr("value_dtype" , value_dtype) |
38 | ; |
39 | scope.UpdateBuilder(&builder); |
40 | scope.UpdateStatus(builder.Finalize(scope.graph(), &ret)); |
41 | if (!scope.ok()) return; |
42 | scope.UpdateStatus(scope.DoShapeInference(ret)); |
43 | this->operation = Operation(ret); |
44 | this->output_handle = Output(ret, 0); |
45 | } |
46 | |
47 | TensorMapHasKey::TensorMapHasKey(const ::tensorflow::Scope& scope, |
48 | ::tensorflow::Input input_handle, |
49 | ::tensorflow::Input key) { |
50 | if (!scope.ok()) return; |
51 | auto _input_handle = ::tensorflow::ops::AsNodeOut(scope, input_handle); |
52 | if (!scope.ok()) return; |
53 | auto _key = ::tensorflow::ops::AsNodeOut(scope, key); |
54 | if (!scope.ok()) return; |
55 | ::tensorflow::Node* ret; |
56 | const auto unique_name = scope.GetUniqueNameForOp("TensorMapHasKey" ); |
57 | auto builder = ::tensorflow::NodeBuilder(unique_name, "TensorMapHasKey" ) |
58 | .Input(_input_handle) |
59 | .Input(_key) |
60 | ; |
61 | scope.UpdateBuilder(&builder); |
62 | scope.UpdateStatus(builder.Finalize(scope.graph(), &ret)); |
63 | if (!scope.ok()) return; |
64 | scope.UpdateStatus(scope.DoShapeInference(ret)); |
65 | this->operation = Operation(ret); |
66 | this->has_key = Output(ret, 0); |
67 | } |
68 | |
69 | TensorMapInsert::TensorMapInsert(const ::tensorflow::Scope& scope, |
70 | ::tensorflow::Input input_handle, |
71 | ::tensorflow::Input key, ::tensorflow::Input |
72 | value) { |
73 | if (!scope.ok()) return; |
74 | auto _input_handle = ::tensorflow::ops::AsNodeOut(scope, input_handle); |
75 | if (!scope.ok()) return; |
76 | auto _key = ::tensorflow::ops::AsNodeOut(scope, key); |
77 | if (!scope.ok()) return; |
78 | auto _value = ::tensorflow::ops::AsNodeOut(scope, value); |
79 | if (!scope.ok()) return; |
80 | ::tensorflow::Node* ret; |
81 | const auto unique_name = scope.GetUniqueNameForOp("TensorMapInsert" ); |
82 | auto builder = ::tensorflow::NodeBuilder(unique_name, "TensorMapInsert" ) |
83 | .Input(_input_handle) |
84 | .Input(_key) |
85 | .Input(_value) |
86 | ; |
87 | scope.UpdateBuilder(&builder); |
88 | scope.UpdateStatus(builder.Finalize(scope.graph(), &ret)); |
89 | if (!scope.ok()) return; |
90 | scope.UpdateStatus(scope.DoShapeInference(ret)); |
91 | this->operation = Operation(ret); |
92 | this->output_handle = Output(ret, 0); |
93 | } |
94 | |
95 | TensorMapLookup::TensorMapLookup(const ::tensorflow::Scope& scope, |
96 | ::tensorflow::Input input_handle, |
97 | ::tensorflow::Input key, DataType value_dtype) { |
98 | if (!scope.ok()) return; |
99 | auto _input_handle = ::tensorflow::ops::AsNodeOut(scope, input_handle); |
100 | if (!scope.ok()) return; |
101 | auto _key = ::tensorflow::ops::AsNodeOut(scope, key); |
102 | if (!scope.ok()) return; |
103 | ::tensorflow::Node* ret; |
104 | const auto unique_name = scope.GetUniqueNameForOp("TensorMapLookup" ); |
105 | auto builder = ::tensorflow::NodeBuilder(unique_name, "TensorMapLookup" ) |
106 | .Input(_input_handle) |
107 | .Input(_key) |
108 | .Attr("value_dtype" , value_dtype) |
109 | ; |
110 | scope.UpdateBuilder(&builder); |
111 | scope.UpdateStatus(builder.Finalize(scope.graph(), &ret)); |
112 | if (!scope.ok()) return; |
113 | scope.UpdateStatus(scope.DoShapeInference(ret)); |
114 | this->operation = Operation(ret); |
115 | this->value = Output(ret, 0); |
116 | } |
117 | |
118 | TensorMapSize::TensorMapSize(const ::tensorflow::Scope& scope, |
119 | ::tensorflow::Input input_handle) { |
120 | if (!scope.ok()) return; |
121 | auto _input_handle = ::tensorflow::ops::AsNodeOut(scope, input_handle); |
122 | if (!scope.ok()) return; |
123 | ::tensorflow::Node* ret; |
124 | const auto unique_name = scope.GetUniqueNameForOp("TensorMapSize" ); |
125 | auto builder = ::tensorflow::NodeBuilder(unique_name, "TensorMapSize" ) |
126 | .Input(_input_handle) |
127 | ; |
128 | scope.UpdateBuilder(&builder); |
129 | scope.UpdateStatus(builder.Finalize(scope.graph(), &ret)); |
130 | if (!scope.ok()) return; |
131 | scope.UpdateStatus(scope.DoShapeInference(ret)); |
132 | this->operation = Operation(ret); |
133 | this->size = Output(ret, 0); |
134 | } |
135 | |
136 | TensorMapStackKeys::TensorMapStackKeys(const ::tensorflow::Scope& scope, |
137 | ::tensorflow::Input input_handle, |
138 | DataType key_dtype) { |
139 | if (!scope.ok()) return; |
140 | auto _input_handle = ::tensorflow::ops::AsNodeOut(scope, input_handle); |
141 | if (!scope.ok()) return; |
142 | ::tensorflow::Node* ret; |
143 | const auto unique_name = scope.GetUniqueNameForOp("TensorMapStackKeys" ); |
144 | auto builder = ::tensorflow::NodeBuilder(unique_name, "TensorMapStackKeys" ) |
145 | .Input(_input_handle) |
146 | .Attr("key_dtype" , key_dtype) |
147 | ; |
148 | scope.UpdateBuilder(&builder); |
149 | scope.UpdateStatus(builder.Finalize(scope.graph(), &ret)); |
150 | if (!scope.ok()) return; |
151 | scope.UpdateStatus(scope.DoShapeInference(ret)); |
152 | this->operation = Operation(ret); |
153 | this->keys = Output(ret, 0); |
154 | } |
155 | |
156 | /// @} |
157 | |
158 | } // namespace ops |
159 | } // namespace tensorflow |
160 | |