Skip to content

Commit

Permalink
lintrunner
Browse files Browse the repository at this point in the history
  • Loading branch information
muchulee8 committed Sep 7, 2023
1 parent 76d2a97 commit 9077584
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions torch/_inductor/codegen/wrapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -1021,12 +1021,14 @@ def write_wrapper_decl(self):
for idx, constants_key in enumerate(V.graph.constants.keys()):
if V.graph.aot_mode:
self.prefix.writeline(
f"""at::Tensor {constants_key} = constants_->at("{constants_key}");"""
f"""auto {constants_key} = constants_->at("{constants_key}");"""
)
else:
# Append constants as inputs to the graph
constants_idx = inputs_len + idx
self.prefix.writeline(f"auto {constants_key} = args[{constants_idx}];")
self.prefix.writeline(
f"auto {constants_key} = args[{constants_idx}];"
)

self.codegen_inputs(self.prefix, V.graph.graph_inputs)

Expand Down

0 comments on commit 9077584

Please sign in to comment.