File tree Expand file tree Collapse file tree 1 file changed +12
-2
lines changed
Expand file tree Collapse file tree 1 file changed +12
-2
lines changed Original file line number Diff line number Diff line change @@ -189,11 +189,16 @@ def define_node(
189189 if i == 0 :
190190 gather_index_name = reshaped_idxs .name
191191 else :
192+ add_idxs = tosa_graph .addIntermediate (
193+ reshaped_idxs .shape ,
194+ reshaped_idxs .dtype ,
195+ )
192196 tosa_graph .addOperator (
193197 ts .TosaOp .Op ().ADD ,
194198 [gather_index_name , reshaped_idxs .name ],
195- [gather_index_name ],
199+ [add_idxs . name ],
196200 )
201+ gather_index_name = add_idxs .name
197202
198203 gather_vals_shape = [N , K , C ]
199204 reshaped_input = tosa_graph .addIntermediate (gather_vals_shape , values .dtype )
@@ -314,11 +319,16 @@ def define_node(
314319 if i == 0 :
315320 gather_index_name = reshaped_idxs .name
316321 else :
322+ add_idxs = tosa_graph .addIntermediate (
323+ reshaped_idxs .shape ,
324+ reshaped_idxs .dtype ,
325+ )
317326 tosa_graph .addOperator (
318327 ts .TosaOp .Op ().ADD ,
319328 [gather_index_name , reshaped_idxs .name ],
320- [gather_index_name ],
329+ [add_idxs . name ],
321330 )
331+ gather_index_name = add_idxs .name
322332
323333 gather_vals_shape = [N , K , C ]
324334 reshaped_input = tosa_graph .addIntermediate (gather_vals_shape , values .dtype )
You can’t perform that action at this time.
0 commit comments